diff options
author | Remy Oukaour <remy.oukaour@gmail.com> | 2017-12-27 11:56:03 -0500 |
---|---|---|
committer | Remy Oukaour <remy.oukaour@gmail.com> | 2017-12-27 11:56:03 -0500 |
commit | e3e64fdf59a7d31705e8da9935bb1f3e8b207a26 (patch) | |
tree | b3bd07e3590e61426f493eab5b55d5d124816572 | |
parent | fbb492f9d7e50fb5d2ca82efd11f942805008e70 (diff) |
Move more decoration data to data/
-rw-r--r-- | constants/deco_constants.asm | 21 | ||||
-rw-r--r-- | data/decorations/attributes.asm (renamed from data/decoration_attributes.asm) | 0 | ||||
-rw-r--r-- | data/decorations/decorations.asm | 55 | ||||
-rw-r--r-- | data/decorations/names.asm | 29 | ||||
-rwxr-xr-x | engine/decorations.asm | 86 | ||||
-rwxr-xr-x | engine/mystery_gift.asm | 2 |
6 files changed, 100 insertions, 93 deletions
diff --git a/constants/deco_constants.asm b/constants/deco_constants.asm index 433b11e25..7546d9e1f 100644 --- a/constants/deco_constants.asm +++ b/constants/deco_constants.asm @@ -7,7 +7,7 @@ const_value = 1 const DECO_DOLL const DECO_BIGDOLL -; DecorationNames indexes (see engine/decorations.asm) +; DecorationNames indexes (see data/decorations/names.asm) const_value = 1 const PUT_IT_AWAY const MAGNAPLANT @@ -35,7 +35,7 @@ const_value = 1 const YELLOW_CARPET const GREEN_CARPET -; DoDecorationAction2 arguments (see engine/decorations.asm) +; DoDecorationAction2.DecoActions indexes (see engine/decorations.asm) const_value = 1 const SET_UP_BED const PUT_AWAY_BED @@ -59,43 +59,46 @@ deco: MACRO enum DECOFLAG_\1 endm -; decorations (see data/decoration_attribute.asm) +; decorations: +; - DecorationAttributes (see data/decorations/attributes.asm) +; - DecorationIDs (see data/decorations/decorations.asm) const_value = 1 __enum__ = 0 +; FindOwnedBeds.beds values (see engine/decorations.asm) const BEDS deco FEATHERY_BED deco PINK_BED deco POLKADOT_BED deco PIKACHU_BED - +; FindOwnedCarpets.carpets values (see engine/decorations.asm) const CARPETS deco RED_CARPET deco BLUE_CARPET deco YELLOW_CARPET deco GREEN_CARPET - +; FindOwnedPlants.plants values (see engine/decorations.asm) const PLANTS deco MAGNAPLANT deco TROPICPLANT deco JUMBOPLANT - +; FindOwnedPosters.posters values (see engine/decorations.asm) const POSTERS deco TOWN_MAP deco PIKACHU_POSTER deco CLEFAIRY_POSTER deco JIGGLYPUFF_POSTER - +; FindOwnedConsoles.consoles values (see engine/decorations.asm) const CONSOLES deco FAMICOM deco SNES deco N64 deco VIRTUAL_BOY - +; FindOwnedBigDolls.big_dolls values (see engine/decorations.asm) const BIG_DOLLS deco BIG_SNORLAX_DOLL deco BIG_ONIX_DOLL deco BIG_LAPRAS_DOLL - +; FindOwnedOrnaments.ornaments values (see engine/decorations.asm) const DOLLS deco PIKACHU_DOLL deco SURF_PIKACHU_DOLL diff --git a/data/decoration_attributes.asm b/data/decorations/attributes.asm index 209662a6f..209662a6f 100644 --- a/data/decoration_attributes.asm +++ b/data/decorations/attributes.asm diff --git a/data/decorations/decorations.asm b/data/decorations/decorations.asm new file mode 100644 index 000000000..7b76b8f6a --- /dev/null +++ b/data/decorations/decorations.asm @@ -0,0 +1,55 @@ +DecorationIDs: ; 26f2b +; see constants/deco_constants.asm + db DECO_FEATHERY_BED ; 2 + db DECO_PINK_BED ; 3 + db DECO_POLKADOT_BED ; 4 + db DECO_PIKACHU_BED ; 5 + + db DECO_RED_CARPET ; 7 + db DECO_BLUE_CARPET ; 8 + db DECO_YELLOW_CARPET ; 9 + db DECO_GREEN_CARPET ; a + + db DECO_MAGNAPLANT ; c + db DECO_TROPICPLANT ; d + db DECO_JUMBOPLANT ; e + + db DECO_TOWN_MAP ; 10 + db DECO_PIKACHU_POSTER ; 11 + db DECO_CLEFAIRY_POSTER ; 12 + db DECO_JIGGLYPUFF_POSTER ; 13 + + db DECO_FAMICOM ; 15 + db DECO_SNES ; 16 + db DECO_N64 ; 17 + db DECO_VIRTUAL_BOY ; 18 + + db DECO_PIKACHU_DOLL ; 1e + db DECO_SURF_PIKACHU_DOLL ; 1f + db DECO_CLEFAIRY_DOLL ; 20 + db DECO_JIGGLYPUFF_DOLL ; 21 + db DECO_BULBASAUR_DOLL ; 22 + db DECO_CHARMANDER_DOLL ; 23 + db DECO_SQUIRTLE_DOLL ; 24 + db DECO_POLIWAG_DOLL ; 25 + db DECO_DIGLETT_DOLL ; 26 + db DECO_STARMIE_DOLL ; 27 + db DECO_MAGIKARP_DOLL ; 28 + db DECO_ODDISH_DOLL ; 29 + db DECO_GENGAR_DOLL ; 2a + db DECO_SHELLDER_DOLL ; 2b + db DECO_GRIMER_DOLL ; 2c + db DECO_VOLTORB_DOLL ; 2d + db DECO_WEEDLE_DOLL ; 2e + db DECO_UNOWN_DOLL ; 2f + db DECO_GEODUDE_DOLL ; 30 + db DECO_MACHOP_DOLL ; 31 + db DECO_TENTACOOL_DOLL ; 32 + db DECO_BIG_SNORLAX_DOLL ; 1a + db DECO_BIG_ONIX_DOLL ; 1b + db DECO_BIG_LAPRAS_DOLL ; 1c +TrophyIDs: + db DECO_GOLD_TROPHY_DOLL ; 33 + db DECO_SILVER_TROPHY_DOLL ; 34 + db -1 +; 26f59 diff --git a/data/decorations/names.asm b/data/decorations/names.asm new file mode 100644 index 000000000..21f7eb2a0 --- /dev/null +++ b/data/decorations/names.asm @@ -0,0 +1,29 @@ +DecorationNames: ; 26b8d +; entries correspond to constants/deco_constants.asm + db "CANCEL@" + db "PUT IT AWAY@" + db "MAGNAPLANT@" + db "TROPICPLANT@" + db "JUMBOPLANT@" + db "TOWN MAP@" + db "NES@" + db "SUPER NES@" + db "NINTENDO 64@" + db "VIRTUAL BOY@" + db "GOLD TROPHY@" + db "SILVER TROPHY@" + db "SURF PIKACHU DOLL@" + db " BED@" + db " CARPET@" + db " POSTER@" + db " DOLL@" + db "BIG @" + db "FEATHERY@" + db "PIKACHU@" + db "PINK@" + db "POLKADOT@" + db "RED@" + db "BLUE@" + db "YELLOW@" + db "GREEN@" +; 26c72 diff --git a/engine/decorations.asm b/engine/decorations.asm index 1e9effe97..c1b703fb6 100755 --- a/engine/decorations.asm +++ b/engine/decorations.asm @@ -541,36 +541,9 @@ GetDecorationSprite: ; 26a44 ret ; 26a4f -INCLUDE "data/decoration_attributes.asm" +INCLUDE "data/decorations/attributes.asm" -DecorationNames: ; 26b8d - db "CANCEL@" - db "PUT IT AWAY@" - db "MAGNAPLANT@" - db "TROPICPLANT@" - db "JUMBOPLANT@" - db "TOWN MAP@" - db "NES@" - db "SUPER NES@" - db "NINTENDO 64@" - db "VIRTUAL BOY@" - db "GOLD TROPHY@" - db "SILVER TROPHY@" - db "SURF PIKACHU DOLL@" - db " BED@" - db " CARPET@" - db " POSTER@" - db " DOLL@" - db "BIG @" - db "FEATHERY@" - db "PIKACHU@" - db "PINK@" - db "POLKADOT@" - db "RED@" - db "BLUE@" - db "YELLOW@" - db "GREEN@" -; 26c72 +INCLUDE "data/decorations/names.asm" GetDecoName: ; 26c72 ld a, [hli] @@ -1084,60 +1057,7 @@ SetAllDecorationFlags: ; 26f19 ret ; 26f2b -DecorationIDs: ; 26f2b - db DECO_FEATHERY_BED ; 2 - db DECO_PINK_BED ; 3 - db DECO_POLKADOT_BED ; 4 - db DECO_PIKACHU_BED ; 5 - - db DECO_RED_CARPET ; 7 - db DECO_BLUE_CARPET ; 8 - db DECO_YELLOW_CARPET ; 9 - db DECO_GREEN_CARPET ; a - - db DECO_MAGNAPLANT ; c - db DECO_TROPICPLANT ; d - db DECO_JUMBOPLANT ; e - - db DECO_TOWN_MAP ; 10 - db DECO_PIKACHU_POSTER ; 11 - db DECO_CLEFAIRY_POSTER ; 12 - db DECO_JIGGLYPUFF_POSTER ; 13 - - db DECO_FAMICOM ; 15 - db DECO_SNES ; 16 - db DECO_N64 ; 17 - db DECO_VIRTUAL_BOY ; 18 - - db DECO_PIKACHU_DOLL ; 1e - db DECO_SURF_PIKACHU_DOLL ; 1f - db DECO_CLEFAIRY_DOLL ; 20 - db DECO_JIGGLYPUFF_DOLL ; 21 - db DECO_BULBASAUR_DOLL ; 22 - db DECO_CHARMANDER_DOLL ; 23 - db DECO_SQUIRTLE_DOLL ; 24 - db DECO_POLIWAG_DOLL ; 25 - db DECO_DIGLETT_DOLL ; 26 - db DECO_STARMIE_DOLL ; 27 - db DECO_MAGIKARP_DOLL ; 28 - db DECO_ODDISH_DOLL ; 29 - db DECO_GENGAR_DOLL ; 2a - db DECO_SHELLDER_DOLL ; 2b - db DECO_GRIMER_DOLL ; 2c - db DECO_VOLTORB_DOLL ; 2d - db DECO_WEEDLE_DOLL ; 2e - db DECO_UNOWN_DOLL ; 2f - db DECO_GEODUDE_DOLL ; 30 - db DECO_MACHOP_DOLL ; 31 - db DECO_TENTACOOL_DOLL ; 32 - db DECO_BIG_SNORLAX_DOLL ; 1a - db DECO_BIG_ONIX_DOLL ; 1b - db DECO_BIG_LAPRAS_DOLL ; 1c -Trophys: - db DECO_GOLD_TROPHY_DOLL ; 33 - db DECO_SILVER_TROPHY_DOLL ; 34 - db -1 -; 26f59 +INCLUDE "data/decorations/decorations.asm" DescribeDecoration:: ; 26f59 ld a, b diff --git a/engine/mystery_gift.asm b/engine/mystery_gift.asm index 9e097e6d4..3c8f9d029 100755 --- a/engine/mystery_gift.asm +++ b/engine/mystery_gift.asm @@ -1153,7 +1153,7 @@ MysteryGift_CopyReceivedDecosToPC: ; 105091 (41:5091) .skip inc c ld a, c - cp Trophys - DecorationIDs + cp TrophyIDs - DecorationIDs jr c, .loop jp CloseSRAM |