@Eat trigger stat increases are not disabled#1333
@Eat trigger stat increases are not disabled#1333canerksk wants to merge 1 commit intoSphereserver:devfrom
Conversation
Trigger was triggered after values were changed and hits, stam, mana gain could not be turned off.
|
Could you please explain better why does this need to trigger twice? |
|
Also we need to avoid integer overflows, i'll provide a saturating add function (i think i only wrote a saturating subtraction one). Anyways, i might be wrong, but isn't it there a method that changes the given stat value and does that overflow check itself? |
In order to get the food values before and after eating, it is unclear how much food value there is after eating under this trigger since it is triggered before eating in its initial state. |
|
I'd be cautious with changing how a trigger is called, since it can have profound compatibility issues with old scripts. I'm more open to add an @aftereat trigger, even if i'd ask why couldn't i get the new value with something like local.newhits = <max , +<local.hits>> |
The trigger was triggered after the values were changed and there was no option to turn off hits, stamina, mana gain.
Additionally, animation and sound changes were added to local variables.