
Free Runners does not provide step boost in Curio slot
xbt573 opened this issue ยท 3 comments
Issue description
Free Runners does not provide step boost when equiped in Curio slot, as opposed to regular armor slot.
This issue was introduced after improper manual merge (complete rewrite) of my pull request #8360 (althrough FreeRunner -> FreeRunners rename change will be nice to be projected everywhere, imho).
This issue should be fixed by either edits to CommonTickHandler or reopening given pull request, where this functionality should work.
Steps to reproduce
- Equip Free Runners in Curio slot
- Try to step boost in Regular mode
Minecraft version
1.21.1 (Latest)
NeoForge version
21.1.194
Mekanism version
10.7.14 (Latest)
Other relevant versions
No response
If a (crash)log is relevant for this issue, link it here: (It's almost always relevant)
No response
I believe 706b39d should fix it (though I haven't tested it). And while I agree that the way you did it, makes a bit more sense from an organization standpoint, I think the reason that thiakil did not do so is that the hydraulic propulsion in the mekasuit takes priority and can override the values for the free runners. Though given it doesn't have to load modules from NBT so it isn't as expensive as it used to be in 1.16 and is basically just a map lookup now, we can potentially just move the free runner check below the mekasuit one, and then use an interface. I will ask thiakil on his thoughts about it.
improper manual merge (complete rewrite)
Can you elaborate on what you believe was missed?
What matters the most is that manual merge only implemented fall damage absorption for Free Runners in Curios slot, step boost was missed entirely, and Curios support for Free Runners is in a hanged state
Relevant code places:
- getFallAbsorptionEnergyInfo: does check for Curios slot
- getStepBoost: does not check for Curios slot, resulting in undefined behavior of using Free Runners in Curios slot (fall damage is absorbed, but step boost doesn't work at all)
Other changes can be taken as personal preference of implementation, but, in my opinion, my implementation clearly extracts shared logic (IFreeRunnersItem
) and localizes all operations with slot to one place (just like as IJetpackItem
)