Hook crashing on save load in unexpected manner
Mod: https://github.com/budak7273/FasterManualCraftingRedux
troublesome hook (narrowed down to this via commenting the others out)
crash attached
Solution:Jump to solution
it seems like the cause of the crash is the
!self->mManufacturingButton->IsButtonHeld()
check7 Replies
not sure why
MovementComponent
is even invovled in the crash, maybe the hook is being too generous? this is one of the ones Turtlefight set up ages ago so I don't quite follow what it's doingit could be that the player movmeent and interaction are linked
but uh this line reeks of code smell
GetProducedCountRef(self) = 0;
even if it's right I hate it ❤️this mod's code is Very Creative
but solid F's is a -1, so I usually look for botched math as a where things are coming from
yes, it is reusing extra space in that bool (unreal allocates a lot of space for bools) to store an int
I have been taking the "don't touch what isn't broken" approach to maintaining this mod
Solution
it seems like the cause of the crash is the
!self->mManufacturingButton->IsButtonHeld()
checkehhh, the mod still moooostly works without that check. it just means that pausing crafting no longer resets the speed bonus
I have found other things that don't crash but also don't work and am partially questioning how the mod worked in the first place... I think I'll just release it as is. I think this breaking will enable people to keep their speed bonus when depot crafting something that trickles in, whereas that wouldn't have worked if this hadn't broken