From 1a2784d4142572487fdf10a44aa4752de287e89f Mon Sep 17 00:00:00 2001 From: yenatch Date: Mon, 29 Dec 2014 08:08:03 -0800 Subject: [PATCH] Recombine the event engine objects. They must be in the same bank to work, and defining sections with static banks should only be used to produce an identical rom. They were only split in the first place to minimize the amount of code tahat needed to be rebuilt based on a single constant, which in retrospect was meaningless. --- Makefile | 4 +--- engine/events.asm | 2 ++ engine/events_2.asm | 4 ---- engine/events_crystal.asm | 2 ++ engine/scripting.asm | 6 ------ engine/scripting_crystal.asm | 3 --- 6 files changed, 5 insertions(+), 16 deletions(-) create mode 100644 engine/events_crystal.asm delete mode 100644 engine/scripting_crystal.asm diff --git a/Makefile b/Makefile index b77607436..ce6e87cb1 100644 --- a/Makefile +++ b/Makefile @@ -18,9 +18,7 @@ lib/mobile/main.o \ home.o \ audio.o \ maps_crystal.o \ -engine/events.o \ -engine/scripting_crystal.o \ -engine/events_2.o \ +engine/events_crystal.o \ engine/credits_crystal.o \ data/egg_moves_crystal.o \ data/evos_attacks_crystal.o \ diff --git a/engine/events.asm b/engine/events.asm index 18ec40838..ea7b996aa 100644 --- a/engine/events.asm +++ b/engine/events.asm @@ -1120,3 +1120,5 @@ UnknownScript_0x96c4f: ; 96c4f end ; 96c56 +INCLUDE "engine/scripting.asm" +INCLUDE "engine/events_2.asm" diff --git a/engine/events_2.asm b/engine/events_2.asm index 68f5027ab..3db0698ee 100644 --- a/engine/events_2.asm +++ b/engine/events_2.asm @@ -1,9 +1,5 @@ -INCLUDE "includes.asm" - - ; More overworld event handling. -SECTION "Events 2", ROMX, BANK[EVENTS] Function97c28:: ; 97c28 ld hl, StatusFlags2 diff --git a/engine/events_crystal.asm b/engine/events_crystal.asm new file mode 100644 index 000000000..56cb7a200 --- /dev/null +++ b/engine/events_crystal.asm @@ -0,0 +1,2 @@ +INCLUDE "pokecrystal.asm" +INCLUDE "engine/events.asm" diff --git a/engine/scripting.asm b/engine/scripting.asm index f08508901..2b334a54f 100644 --- a/engine/scripting.asm +++ b/engine/scripting.asm @@ -1,11 +1,6 @@ -INCLUDE "includes.asm" - ; Event scripting commands. -SECTION "Event Scripting", ROMX, BANK[EVENTS] - - Function96c56:: ; 96c56 push af ld a, 1 @@ -14,7 +9,6 @@ Function96c56:: ; 96c56 ret ; 96c5e - ScriptEvents:: ; 96c5e call StartScript .loop diff --git a/engine/scripting_crystal.asm b/engine/scripting_crystal.asm deleted file mode 100644 index 8df277248..000000000 --- a/engine/scripting_crystal.asm +++ /dev/null @@ -1,3 +0,0 @@ -INCLUDE "pokecrystal.asm" -INCLUDE "engine/scripting.asm" -