mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-22 05:02:18 +00:00
Enable Enforcement of modid formatting. Must be lowercase and <= 64 characters
This commit is contained in:
1 parent
babe0c2d53
commit
7fe8c48983
1 file changed
+6
-3
@@ -133,12 +133,15 @@ public class FMLModContainer implements ModContainer
|
||||
{
|
||||
throw new IllegalArgumentException("Modid cannot be null or empty");
|
||||
}
|
||||
if (modid.length() > 64) {
|
||||
FMLLog.bigWarning("The modid %s is longer than the recommended maximum of 64 characters. Truncation will be enforced in 1.11", modid);
|
||||
if (modid.length() > 64)
|
||||
{
|
||||
FMLLog.bigWarning("The modid %s is longer than the recommended maximum of 64 characters. Truncation is enforced in 1.11", modid);
|
||||
throw new IllegalArgumentException(String.format("The modid %s is longer than the recommended maximum of 64 characters. Truncation is enforced in 1.11", modid));
|
||||
}
|
||||
if (!modid.equals(modid.toLowerCase(Locale.ENGLISH)))
|
||||
{
|
||||
FMLLog.bigWarning("The modid %s is not the same as it's lowercase version. Lowercasing will be enforced in 1.11", modid);
|
||||
FMLLog.bigWarning("The modid %s is not the same as it's lowercase version. Lowercasing is enforced in 1.11", modid);
|
||||
throw new IllegalArgumentException(String.format("The modid %s is not the same as it's lowercase version. Lowercasing will be enforced in 1.11", modid));
|
||||
}
|
||||
}
|
||||
private ILanguageAdapter getLanguageAdapter()
|
||||
|
||||
Reference in new issue
Block a user