If the functions are more complex, I'll need one of the .exe wizards like NFITC to look into the value ranges of those things
Does anyone know where exactly sadness and anger are handled in the .exe?
Indeed! This is one of those problems only I have the brains to solve.
Your wish has been heard!!
Actually, probably a lot of other people could too, but since you called me out I guess I'll have to step up. I'll even break my MO and solve your problem for you!
It completely depends on the value you want to change it to.
Sadness:
If Target's Status includes Sadness
Damage = Damage - (Damage * 3 / 10)
End If
Return Damage
That comes off the wiki which I wrote so you know it's accurate.
Damage is multiplied by 3 then divided by 10 and the result is subtracted from the calculated damage and stored AS damage. It is a percentage change that happens in that order. The 3 and the 10 can be easily changed to anything, even to increase damage, but in the end it's still a percentage.
This starts at 0x5DE958 and the relevant values are at 0x5DE972 (0x1DDD72) and 0x5DE974 (0x1DDD75). That's the multiplier and divisor respectively.
Fury is essentially identical, but with the penalty to accuracy:
If NOT Acc = 255
If Actor's Status includes Fury
Acc = Acc - (Acc * 3 / 10)
End If
End If
Return Acc
This starts at 0x5DE582 and the relevant values are at 0x5DE5A5 (0x1DD9A5) and 0x5DE5A8 (0x1DD9A8). That's the multiplier and divisor respectively.
Now for the Limit bar (Dang this was hard to track down):
The checks start at 0x5DF28C. This checks Fury and will bit shift the damage factor consideration ( 256 * (300 * MHP) / HPLimitDivisor ) to the left by 1 (doubles the factor)
Sadness check starts at 0x5DF2A9 (which doesn't happen if the Fury check succeeds). This checks Sadness and will bit shift the damage factor consideration ( 256 * (300 * MHP) / HPLimitDivisor ) to the right by 1 (halves the factor)
It is not a hard thing to nullify these factors or multiply them by different amounts, but I'll get to that at a later time. I just have to prove how awesome I am.