Daripher / Passive-Skill-Tree

Other
18 stars 29 forks source link

Potion NBT inconsistency resulting to non-stackability #227

Open MadServlet opened 3 months ago

MadServlet commented 3 months ago

I've noticed that when creating potions with potion making traits, it sometimes results to same potion and level but has a different NBT structure. This means they can't be stacked or considered same liquids when extracted by other mods.

Here's a sample:

{id: "minecraft:potion", Count: 1b, tag: {Potion: "minecraft:long_strength", SkillBonuses: [{type: "skilltree:potion_amplification", chance: 2.0f}, {type: "skilltree:potion_amplification", chance: 0.0f}, {type: "skilltree:potion_amplification", chance: 2.0f}, {type: "skilltree:potion_duration", multiplier: 0.05f}, {type: "skilltree:potion_duration", multiplier: 0.2f}, {type: "skilltree:potion_duration", multiplier: 0.2f}, {type: "skilltree:potion_duration", multiplier: 0.2f}, {type: "skilltree:potion_amplification", chance: 2.0f}, {type: "skilltree:potion_duration", multiplier: 0.4f}]}}

{id: "minecraft:potion", Count: 1b, tag: {Potion: "minecraft:long_strength", SkillBonuses: [{type: "skilltree:potion_amplification", chance: 2.0f}, {type: "skilltree:potion_amplification", chance: 2.0f}, {type: "skilltree:potion_amplification", chance: 0.0f}, {type: "skilltree:potion_duration", multiplier: 0.05f}, {type: "skilltree:potion_duration", multiplier: 0.2f}, {type: "skilltree:potion_duration", multiplier: 0.2f}, {type: "skilltree:potion_duration", multiplier: 0.2f}, {type: "skilltree:potion_amplification", chance: 2.0f}, {type: "skilltree:potion_duration", multiplier: 0.4f}]}}

^ to save you the headache, basically they have the same content but the sorting is different for some tags. image

Passive Skill Tree: 0.6.13a Forge 1.20.1

MadServlet commented 3 months ago

just to note, the stacking feature is from other storage mods that allows same nbt and type to stack such as AE2, Sophisticated Storage/Backpacks, etc.