Fixed #11548
This commit is contained in:
@@ -119,7 +119,15 @@ public class ContentParser{
|
||||
}
|
||||
return result;
|
||||
});
|
||||
put(Color.class, (type, data) -> Color.valueOf(data.asString()));
|
||||
put(Color.class, (type, data) -> {
|
||||
if(data.isNumber()){
|
||||
int len = data.asString().length();
|
||||
if(len != 6 && len != 8){
|
||||
warn("@Colors should strings, not numbers. Make sure you have quotes around the value, or they will not be parsed correctly: '@'", currentContent == null ? "" : "[" + currentContent.minfo.sourceFile.name() + "]: ", data);
|
||||
}
|
||||
}
|
||||
return Color.valueOf(data.asString());
|
||||
});
|
||||
put(StatusEffect.class, (type, data) -> {
|
||||
if(data.isString()){
|
||||
StatusEffect result = locate(ContentType.status, data.asString());
|
||||
|
||||
Reference in New Issue
Block a user