Budschie / BudschieMorphMod

This is a port of the morph mod to forge 1.16.5
MIT License
11 stars 9 forks source link

Abilities can't reference prefixed resource locations #132

Open Apceniy opened 7 months ago

Apceniy commented 7 months ago

Attempting to use prefixed resource locations in codec fields (for example, ability groups in "activate_ability_if" ability) results in the field (and if the field is mandatory, the whole codec) being invalidated. After some code analysis, I think that this happens because of this line. Currently we have this: result = new ResourceLocation(rl.result().get()); I assume it should be changed to this: result = new ResourceLocation(str); A couple of lines earlier we calculate str but the variable ends up unused, which is probably what should be used in place of rl.result().get() because the value of str also derives from it but then gets the prefix removed.