Users browsing this thread: 1 Guest(s)
All Things Event Hacking
03-05-2011, 01:25 PM
Okay, I actually found it on my own by some miracle.
The 4D command invokes battles based on their Zone sets. The only Zone sets that are valid are the 2-option sets, the first of which is ID $00. It's imperative that you set both options to the same formation ID to insure the boss battle you want. (Alternately, randomized boss battles!)
Now my big problem is figuring out how to -stop- the command from continually activating once a battle is invoked.
Here's what I'm working on:
Trying to add a boss fight into this instance where a minor cutscene happens. It even has its own dedicated Event Bits, so I figured everything would work perfectly.
Lone Wolf pops in on the Cliff of Narshe just before the party can move to the next area for the big scene with Mog.
CC/D4A8: C1 If ($1E80($23C) [$1EC7, bit 4] is clear) or ($1E80($23D) [$1EC7, bit 5] is set), branch to $CA5EB3 (simply returns)
CC/D4B0: 3D Create object $1A
CC/D4B2: 41 Show object $1A
CC/D4B4: 45 Refresh objects
CC/D4B5: 1A Begin action queue for character $1A (NPC $1A), 2 bytes long (Wait until complete)
CC/D4B7: 89 Move vehicle/entity right 3 tiles
CC/D4B8: FF End queue
CC/D4B9: 1A Begin action queue for character $1A (NPC $1A), 5 bytes long (Wait until complete)
CC/D4BB: DC Make vehicle/entity jump (low)
CC/D4BC: CD Turn vehicle/entity right
CC/D4BD: E0 Pause for 4 * 4 (16) frames
CC/D4BF: FF End queue
CC/D4C0: 1A Begin action queue for character $1A (NPC $1A), 2 bytes long (Wait until complete)
CC/D4C2: 8B Move vehicle/entity left 3 tiles
CC/D4C3: FF End queue
CC/D4C4: 42 Hide object $1A
CC/D4C6: 45 Refresh objects
CC/D4C7: D4 Set event bit $1E80($23D) [$1EC7, bit 5]
CC/D4C9: DC Set event bit $1E80($640) [$1F48, bit 0]
CC/D4CB: 3D Create object $1C
CC/D4CD: 3D Create object $1B
CC/D4CF: 41 Show object $1C
CC/D4D1: 41 Show object $1B
CC/D4D3: 45 Refresh objects
CC/D4D4: 1C Begin action queue for character $1C (NPC $1C), 3 bytes long (Wait until complete)
CC/D4D6: C7 Set vehicle/entity to stay still when moving
CC/D4D7: 09 Do vehicle/entity graphical action $09 (kneeling)
CC/D4D8: FF End queue
CC/D4D9: DD Clear event bit $1E80($643) [$1F48, bit 3]
CC/D4DB: 3A Enable player to move while event commands execute
CC/D4DC: FE Return
In the italicized section, I tried this:
The idea was to kick out a party member and let Mog randomly struggle against Lone Wolf with you before you made your decision to save him or not.
3F 34 00 - remove Party member 3 from party
3F 0A 01 - assign character $0A to Party 1
D4 3D DC 40 - Set the Event bits as before.
4D 9A 3F - Invoke Battle $9A
B2 A9 5E 00 Call Subroutine for Game Over effect if the Party loses the fight.
96 - Restore screen from Fade-out
3F 0A 00 - remove character $0A from party
(Create Object $1C - beginning to setup the next cutscene where LoneWolf is actually holding poor Mog for leverage)
The problem is that once the battle ends with the party victorious... the map screen loads... and then the battle starts up again! It's an endless loop until you either quit the game or the party dies (Dying works perfectly). I tried this with and without the code where Mog replaced a party member and the same thing happened, so it's not any mistake there. I've tried NOPing out and restoring the "Refresh Screen" command. I tried using an FE Return command directing after the Fade-In, directly after the "Remove Mog" command, and not using one at all.
Something about the way the event bits are setup must be causing the loop, but I can't figure it out at all. I tried mimicking just about every different variation of the 4D command from the event dump and the best results I've gotten were the game just freezing up and looping the background music once the map screen returned after the fight.
Any thoughts?
The 4D command invokes battles based on their Zone sets. The only Zone sets that are valid are the 2-option sets, the first of which is ID $00. It's imperative that you set both options to the same formation ID to insure the boss battle you want. (Alternately, randomized boss battles!)
Now my big problem is figuring out how to -stop- the command from continually activating once a battle is invoked.
Here's what I'm working on:
Trying to add a boss fight into this instance where a minor cutscene happens. It even has its own dedicated Event Bits, so I figured everything would work perfectly.
Lone Wolf pops in on the Cliff of Narshe just before the party can move to the next area for the big scene with Mog.
CC/D4A8: C1 If ($1E80($23C) [$1EC7, bit 4] is clear) or ($1E80($23D) [$1EC7, bit 5] is set), branch to $CA5EB3 (simply returns)
CC/D4B0: 3D Create object $1A
CC/D4B2: 41 Show object $1A
CC/D4B4: 45 Refresh objects
CC/D4B5: 1A Begin action queue for character $1A (NPC $1A), 2 bytes long (Wait until complete)
CC/D4B7: 89 Move vehicle/entity right 3 tiles
CC/D4B8: FF End queue
CC/D4B9: 1A Begin action queue for character $1A (NPC $1A), 5 bytes long (Wait until complete)
CC/D4BB: DC Make vehicle/entity jump (low)
CC/D4BC: CD Turn vehicle/entity right
CC/D4BD: E0 Pause for 4 * 4 (16) frames
CC/D4BF: FF End queue
CC/D4C0: 1A Begin action queue for character $1A (NPC $1A), 2 bytes long (Wait until complete)
CC/D4C2: 8B Move vehicle/entity left 3 tiles
CC/D4C3: FF End queue
CC/D4C4: 42 Hide object $1A
CC/D4C6: 45 Refresh objects
CC/D4C7: D4 Set event bit $1E80($23D) [$1EC7, bit 5]
CC/D4C9: DC Set event bit $1E80($640) [$1F48, bit 0]
CC/D4CB: 3D Create object $1C
CC/D4CD: 3D Create object $1B
CC/D4CF: 41 Show object $1C
CC/D4D1: 41 Show object $1B
CC/D4D3: 45 Refresh objects
CC/D4D4: 1C Begin action queue for character $1C (NPC $1C), 3 bytes long (Wait until complete)
CC/D4D6: C7 Set vehicle/entity to stay still when moving
CC/D4D7: 09 Do vehicle/entity graphical action $09 (kneeling)
CC/D4D8: FF End queue
CC/D4D9: DD Clear event bit $1E80($643) [$1F48, bit 3]
CC/D4DB: 3A Enable player to move while event commands execute
CC/D4DC: FE Return
In the italicized section, I tried this:
The idea was to kick out a party member and let Mog randomly struggle against Lone Wolf with you before you made your decision to save him or not.
3F 34 00 - remove Party member 3 from party
3F 0A 01 - assign character $0A to Party 1
D4 3D DC 40 - Set the Event bits as before.
4D 9A 3F - Invoke Battle $9A
B2 A9 5E 00 Call Subroutine for Game Over effect if the Party loses the fight.
96 - Restore screen from Fade-out
3F 0A 00 - remove character $0A from party
(Create Object $1C - beginning to setup the next cutscene where LoneWolf is actually holding poor Mog for leverage)
The problem is that once the battle ends with the party victorious... the map screen loads... and then the battle starts up again! It's an endless loop until you either quit the game or the party dies (Dying works perfectly). I tried this with and without the code where Mog replaced a party member and the same thing happened, so it's not any mistake there. I've tried NOPing out and restoring the "Refresh Screen" command. I tried using an FE Return command directing after the Fade-In, directly after the "Remove Mog" command, and not using one at all.
Something about the way the event bits are setup must be causing the loop, but I can't figure it out at all. I tried mimicking just about every different variation of the 4D command from the event dump and the best results I've gotten were the game just freezing up and looping the background music once the map screen returned after the fight.
Any thoughts?
« Next Oldest | Next Newest »
Users browsing this thread: 1 Guest(s)