JavidPack/SummonersAssociation

[TODO] make API for SlotsFilledPerUse in 1.3 + add it back in 1.4

direwolf420 opened this issue · 2 comments

Currently there is no way of reliably getting the amount of minion slots occupied by using a weapon once, as we don't know its innate behavior. In vanilla, we know, such as Optic Staff summoning 2 minions of 0.5 slots each, averaging 1 slot per use. Spider Staff too, with 0.75 slots per use.
In modded however, we have to rely on data from tmls side, such as ItemID.Sets.StaffMinionSlotsRequired[item.type], which only accepts int, meaning it wont work for minions below 1 slot. A weapon that summons a single minion with 0.5 slots per use for example (Calamity Herring Staff) HAS to have it set to 1 otherwise it wont work properly)
My suggestion is to expand the current SlotsFilledPerUse approach we use for Spider Staff and expand it to modded minions, and use the aforementioned set as a fallback (in 1.4 it was removed as that weapon was changed to 1 slots per use).

Implementation wise it probably needs to go with the compatibility layer of MinionModel (not ItemModel, that ones not available to API) and it's calls.