Compare commits

..

3 commits

Author SHA1 Message Date
Ell
8a984911f6 41.3 2024-10-20 11:59:44 +02:00
Ell
27f51b39dd return an empty string on getLegacyStringSubtypeInfo for effect powders with no effect
closes #363
2024-10-20 11:55:53 +02:00
Harvey
7dd63845af
Fix book crafting (#364) 2024-10-20 11:34:50 +02:00
3 changed files with 4 additions and 3 deletions

View file

@ -31,7 +31,7 @@ mod_name=NaturesAura
# The license of the mod. Review your options at https://choosealicense.com/. All Rights Reserved is the default. # The license of the mod. Review your options at https://choosealicense.com/. All Rights Reserved is the default.
mod_license=MIT mod_license=MIT
# The mod version. See https://semver.org/ # The mod version. See https://semver.org/
mod_version=41.2 mod_version=41.3
# The group ID for the mod. It is only important when publishing as an artifact to a Maven repository. # The group ID for the mod. It is only important when publishing as an artifact to a Maven repository.
# This should match the base package used for the mod sources. # This should match the base package used for the mod sources.
# See https://maven.apache.org/guides/mini/guide-naming-conventions.html # See https://maven.apache.org/guides/mini/guide-naming-conventions.html

View file

@ -57,7 +57,8 @@ public class JEINaturesAuraPlugin implements IModPlugin {
@Override @Override
public String getLegacyStringSubtypeInfo(ItemStack ingredient, UidContext context) { public String getLegacyStringSubtypeInfo(ItemStack ingredient, UidContext context) {
return ItemEffectPowder.getEffect(ingredient).toString(); var effect = ItemEffectPowder.getEffect(ingredient);
return effect != null ? effect.toString() : "";
} }
}); });
registration.registerSubtypeInterpreter(VanillaTypes.ITEM_STACK, ModItems.AURA_BOTTLE, new ISubtypeInterpreter<>() { registration.registerSubtypeInterpreter(VanillaTypes.ITEM_STACK, ModItems.AURA_BOTTLE, new ISubtypeInterpreter<>() {

View file

@ -16,7 +16,7 @@
], ],
"result": { "result": {
"id": "patchouli:guide_book", "id": "patchouli:guide_book",
"nbt": { "components": {
"patchouli:book": "naturesaura:book" "patchouli:book": "naturesaura:book"
} }
} }