ref: c49dd99a986b58a9a19f6e53c6e132aa5c18c1de
parent: 2b961ceaf41c88edf4625d66aa35acf1dada825e
author: yenatch <yenatch@gmail.com>
date: Mon Jan 27 12:09:09 EST 2014
Split wram.asm from poke{red,blue}.o into wram.o wram.asm still defines some constants. They're moved into constants/wram_constants.asm.
--- a/Makefile
+++ b/Makefile
@@ -9,11 +9,13 @@
RED_OBJS := \
pokered.o \
audio_red.o \
+wram.o \
text.o
BLUE_OBJS := \
pokeblue.o \
audio_blue.o \
+wram.o \
text.o
OBJS := $(RED_OBJS) $(BLUE_OBJS)
--- a/constants.asm
+++ b/constants.asm
@@ -9,6 +9,8 @@
INCLUDE "constants/hardware_constants.asm"
INCLUDE "constants/oam_constants.asm"
+INCLUDE "constants/wram_constants.asm"
+
INCLUDE "constants/pokemon_constants.asm"
INCLUDE "constants/pokedex_constants.asm"
INCLUDE "constants/trainer_constants.asm"
--- /dev/null
+++ b/constants/wram_constants.asm
@@ -1,0 +1,7 @@
+
+SPRITEBUFFERSIZE EQU 7*7 * 8 ; 7 * 7 (tiles) * 8 (bytes per tile)
+
+; Overload enemy party data
+W_WATERRATE EQU $d8a4
+W_WATERMONS EQU $d8a5
+
--- a/pokeblue.asm
+++ b/pokeblue.asm
@@ -1,3 +1,2 @@
INCLUDE "blue.asm"
-INCLUDE "wram.asm"
INCLUDE "main.asm"
--- a/pokered.asm
+++ b/pokered.asm
@@ -1,3 +1,2 @@
INCLUDE "red.asm"
-INCLUDE "wram.asm"
INCLUDE "main.asm"
--- a/wram.asm
+++ b/wram.asm
@@ -1,5 +1,7 @@
+INCLUDE "constants/wram_constants.asm"
+
SECTION "WRAM Bank 0", WRAM0
@@ -189,7 +191,7 @@
; value can range from 1 - 13 ($1 to $D)
; 7 is normal
-wPlayerMonStatMods:
+wPlayerMonStatMods::
wPlayerMonAttackMod:: ; cd1a
ds 1
wPlayerMonDefenseMod:: ; cd1b
@@ -214,7 +216,7 @@
; value can range from 1 - 13 ($1 to $D)
; 7 is normal
-wEnemyMonStatMods:
+wEnemyMonStatMods::
wEnemyMonAttackMod:: ; cd2e
ds 1
wEnemyMonDefenseMod:: ; cd2f
@@ -643,8 +645,6 @@
SECTION "Sprite Buffers", SRAM
-SPRITEBUFFERSIZE EQU 7*7 * 8 ; 7 * 7 (tiles) * 8 (bytes per tile)
-
S_SPRITEBUFFER0:: ; a000
ds SPRITEBUFFERSIZE
S_SPRITEBUFFER1:: ; a188
@@ -903,11 +903,11 @@
wPokedexOwned:: ; d2f7
ds (150 / 8) + 1
-wPokedexOwnedEnd:
+wPokedexOwnedEnd::
wPokedexSeen:: ; d30a
ds (150 / 8) + 1
-wPokedexSeenEnd:
+wPokedexSeenEnd::
wNumBagItems:: ; d31d
@@ -1342,11 +1342,8 @@
ds 6
ds 1 ; end
-; Overload enemy party data
-W_WATERRATE EQU $d8a4
-W_WATERMONS EQU $d8a5
-wEnemyMons:
+wEnemyMons::
wEnemyMon1:: ; d8a4
wEnemyMon1Species:: ; d8a4