TieredZ

TieredZ

1M Downloads

[Suggestion] Compatibility for Trinkets

RobertHDPotatoes opened this issue ยท 4 comments

commented

Would it be possible to add support for the mod Trinkets? Trinkets uses TrinketAttributeModifiers instead of AttributeModifiers, as well as having a slightly different system for slots, so I don't think it's possible to do just by making a custom tier for them. If it is possible through just the datapack system, sorry, but I haven't been able to get it to work

commented

What exactly isn't supported?

commented

Trinkets adds new data driven slots to the inventory, and equipping a trinket into those new slots only gives stats if the trinket's NBT data uses their special TrinketAttributeModifiers instead of AttributeModifiers (Normal armor and tools use AttributeModifiers). I have tried to add new modifier tiers for Trinkets to no avail, and I think it's due to lack of compatibility due to the slot and NBT data differences, but maybe I just don't understand how to properly add tiers for it?

An example of the /give command to give an item with AttributeModifiers
/give @p diamond_sword{AttributeModifiers:[{AttributeName:"generic.attack_damage",Amount:100,Slot:mainhand,Name:"generic.attack_damage",UUID:[I;-1221010,12967,143228,-25934]}]}

And here's an example of the /give command to give an item with the same AttributeModifiers, but it's a trinket from the mod Utilities.
/give @p utilities:balloon{TrinketAttributeModifiers:[{Slot:"hand/glove", AttributeName:"minecraft:generic.attack_damage", Name:"minecraft:generic.attack_damage", Amount:100.0, Operation:0, UUID:[I; 42853, 1689024593, -201178, -1559272105]}]}

commented

Tiered uses its own nbt tag to store its relevant information. Check out the nbt information of a normal tiered weapon and try to add it to a trinket.

commented

Doing this gives the trinket a modifier and changes its name and color, but no stats are given or displayed. This is probably because, as @RobertHDPotatoes mentioned, trinkets only give stats from TrinketAttributeModifiers, but Tiers only provide AttributeModifiers with their tiers. I'm not familiar with how Tiered is coded, but perhaps it is possible to prepend "Trinket" to AttributeModifiers on trinket items with a tier?