Users browsing this thread: 1 Guest(s)
Banon, don't wander off! (Health fix)

Posts: 335
Threads: 26
Thanks Received: 135
Thanks Given: 125
Joined: Dec 2018
Reputation: 18
Banon's Health command casts Cure 2 on the party with a unique animation.

Because the animation is unique, it has the step-forward component built into it.  And because Cure 2 can be reflected, if the command his a mirrored target it will bounce and make Banon step forward again.  Used over and over, Banon can be made to walk completely off-screen.

This is a vanilla-in-practice bug, as it is present in Vanilla but there is no situation wherein it can be triggered, as there is no way to get Reflect status while Banon is in the party.  Nevertheless, it is a problem for hackers who work the Health command into other parts of their game.

The fix is fairly simple, which makes it a pity that it requires precious freespace in the clogged C1 bank.  I highly recommend deploying some of the C1 bank optimizations from Imzogelmo's Multisteal fix before trying to squeeze in this fix, if you can.
Essentially, we tell the HEALTH animation to ignore block graphics, which prevents the reflect animation from playing.  When encountering a reflection, the regular green Cure 2 animation will follow on the reflect recipient.

Health animation Fix (For FF3US1.0) (Keeps Banon from wandering off if Health gets reflected)
%% indicates hex values changed from Vanilla
C1/BB62: 20F7BB JSR $BBF7 (from C1/B76F, X = 1A)
C1/BB65: 900E BCC $BB75 [Exit on miss, necessary for proper block animation]
%%C1/BB67: 20 E5 FF JSR $FFE5 {Goes to precious freespace at the end of C1, will need adjustments in romhacks. Was 2035BC, JSR $BC35}
C1/BB6A: A26C0F LDX #$0F6C
C1/BB6D: 20F5B7 JSR $B7F5
C1/BB70: A927 LDA #$27
C1/BB72: 20E1BB JSR $BBE1
C1/BB75: 60 RTS
[C1 Freespace, 7 bytes used]
%%C1/FFE5: EE C0 62 INC $62C0 [Makes the animation ignore blocking graphics]
%%C1/FFE8: 20 35 BC JSR $BC35 [Call the subroutine that got displaced to inject the block override]
%%C1/FFEB: 60 RTS [Return to Sender]
No .ips patch, just code this time, since finding appropriate freespace in C1 is essential to the fix and the hacker will need to locate that data.
This fix will only be necessary for hacks and randomizations where Health can be used on reflected targets.

Note a similar fix would be necessary for Shock if Megahit were ever set to be reflectable; I have not investigated where exactly that code would need to be adjusted, but the hook and fix would be similar if not identical.

Forum Jump:

Users browsing this thread: 1 Guest(s)

Theme by Madsiur2017Custom Graphics by JamesWhite