Users browsing this thread: 1 Guest(s)
It is the apocalypse after all.
C-DudeYes, Gi is correct, a custom event that triggers some assembly code would work much better. I shouldn't have sent you astray the way I did, Masiur was right to begin with.
I've never coded something like that before, so you're going to be the guinea pig.
[i]
I am definitely going to use a fresh rom. But before I do, I just want to make sure I am processing the information correctly.
Step 1: C0/99A2 - $C00000 = 99A2 = write the new pointer change: (WAS 1A B9, NOW IT'S 83 DF)
Step 2 C0/DF83 - $C00000 = DF83 = write the new raw hex code in that offset.
Step 3: Re-write the A530C & 2EAF01 code as they remain unchanged.
Correct?
I've never coded something like that before, so you're going to be the guinea pig.
Code:
Custom Event $A4 (Inventory Flush) [This custom event command takes no arguments]
[I chose $A4 because event bit $0A4 means the game is in the World of Ruin. It's an easy way to remember which event got used for this]
POINTER
C0/99A2: 83 DF (act. A4: ** NOT USED **) [Was 1A B9]
COMMAND
C0/DF83: [Was Freespace, 29 bytes used]
A6 00 LDX $00 (Load X with $00)
A9 FF LDA #$FF (Get an "empty" item)
9D 69 18 STA $1869,X (Put it in inventory at X)
E8 INX (Increment X)
E0 00 01 CPX #$0100 (Is X over 256?)
D0 F5 BNE $AD2F (If not, branch -> get the next item)
C2 21 REP #$21 (16 bit accum./memory)
9C 60 18 STZ $1860 (Zero the low byte of GP)
7B TDC (Clear the accumulator)
E2 20 SEP #$20 (8 bit accum./memory)
9C 62 18 STZ $1862 (Zero the high byte of GP)
A9 01 LDA #$01 (Advance the script 1 place, as our command has no arguments)
4C 5C 9B JMP $9B5C
RAW HEX FOR COMMAND CODE
C0/DF83:
A6 00 A9 FF 9D 69 18 E8 E0 00 01 D0 F5 C2 21 9C 60 18 7B E2 20 9C 62 18 A9 01 4C 5C 9B
EVENT HOOK [Unchanged from earlier post]
CA/530C:
B2 01 AF 24 [Go to subroutine EE/AF01 (which is unused space in Vanilla)]
EVENT SUBROUTINE
EE/AF01:
88 06 00 00 [Clean Celes's statuses (displaced vanilla code)]
8D 06 [Unequip Celes]
A4 [Run Custom Command to flush inventory]
FE [Return to sender]
RAW HEX FOR EE/AF01 SUBROUTINE
88 06 00 00 8D 06 A4 FE
I am definitely going to use a fresh rom. But before I do, I just want to make sure I am processing the information correctly.
Step 1: C0/99A2 - $C00000 = 99A2 = write the new pointer change: (WAS 1A B9, NOW IT'S 83 DF)
Step 2 C0/DF83 - $C00000 = DF83 = write the new raw hex code in that offset.
Step 3: Re-write the A530C & 2EAF01 code as they remain unchanged.
Correct?
« Next Oldest | Next Newest »
Users browsing this thread: 1 Guest(s)