Skip to content

Commit

Permalink
Merge branch 'Dynamic-OW-Sprites-and-Pals'
Browse files Browse the repository at this point in the history
  • Loading branch information
SoupPotato committed May 29, 2024
2 parents 4eee998 + f46362b commit 83bccaf
Show file tree
Hide file tree
Showing 58 changed files with 913 additions and 1,096 deletions.
13 changes: 4 additions & 9 deletions constants/map_object_constants.asm
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,11 @@ DEF OBJECT_1D rb ; 1d
DEF OBJECT_1E rb ; 1e
DEF OBJECT_JUMP_HEIGHT rb ; 1f
DEF OBJECT_RANGE rb ; 20
rb_skip 7
DEF OBJECT_PAL_INDEX rb ; 21
rb_skip 6
DEF OBJECT_LENGTH EQU _RS
DEF NUM_OBJECT_STRUCTS EQU 13 ; see wObjectStructs
DEF FIRST_VRAM1_OBJECT_STRUCT EQU 10

; object_struct OBJECT_DIRECTION values
DEF OW_DOWN EQU DOWN << 2
Expand Down Expand Up @@ -105,12 +107,8 @@ DEF MAPOBJECT_Y_COORD rb ; 2
DEF MAPOBJECT_X_COORD rb ; 3
DEF MAPOBJECT_MOVEMENT rb ; 4
DEF MAPOBJECT_RADIUS rb ; 5
DEF MAPOBJECT_HOUR_1 rb ; 6
DEF MAPOBJECT_HOUR_2 rb ; 7
rsset MAPOBJECT_HOUR_2
DEF MAPOBJECT_PALETTE rb ; 6
DEF MAPOBJECT_TIMEOFDAY rb ; 7
DEF MAPOBJECT_PALETTE rb ; 8
rsset MAPOBJECT_PALETTE
DEF MAPOBJECT_TYPE rb ; 8
DEF MAPOBJECT_SIGHT_RANGE rb ; 9
DEF MAPOBJECT_SCRIPT_POINTER rw ; a
Expand All @@ -120,9 +118,6 @@ DEF MAPOBJECT_LENGTH EQU _RS
DEF NUM_OBJECTS EQU 16
DEF PLAYER_OBJECT EQU 0

DEF MAPOBJECT_PALETTE_MASK EQU %11110000
DEF MAPOBJECT_TYPE_MASK EQU %00001111

; SpriteMovementData struct members (see data/sprites/map_objects.asm)
rsreset
DEF SPRITEMOVEATTR_MOVEMENT rb ; 0
Expand Down
218 changes: 108 additions & 110 deletions constants/sprite_anim_constants.asm
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ DEF NUM_SPRITEANIMDICT_ENTRIES EQU 10
const SPRITE_ANIM_OBJ_TRADEMON_BUBBLE ; 12
const SPRITE_ANIM_OBJ_EVOLUTION_BALL_OF_LIGHT ; 13
const SPRITE_ANIM_OBJ_RADIO_TUNING_KNOB ; 14
const SPRITE_ANIM_OBJ_MAGNET_TRAIN_RED ; 15
const SPRITE_ANIM_OBJ_MAGNET_TRAIN ; 15
const SPRITE_ANIM_OBJ_LEAF ; 16
const SPRITE_ANIM_OBJ_CUT_TREE ; 17
const SPRITE_ANIM_OBJ_FLY_LEAF ; 18
Expand All @@ -66,30 +66,29 @@ DEF NUM_SPRITEANIMDICT_ENTRIES EQU 10
const SPRITE_ANIM_OBJ_EGG_HATCH ; 1c
const SPRITE_ANIM_OBJ_EZCHAT_CURSOR ; 1d
const SPRITE_ANIM_OBJ_BLUE_WALK ; 1e
const SPRITE_ANIM_OBJ_MAGNET_TRAIN_BLUE ; 1f
const SPRITE_ANIM_OBJ_MOBILE_TRADE_SENT_BALL ; 20
const SPRITE_ANIM_OBJ_MOBILE_TRADE_OT_BALL ; 21
const SPRITE_ANIM_OBJ_MOBILE_TRADE_CABLE_BULGE ; 22
const SPRITE_ANIM_OBJ_MOBILE_TRADE_SENT_PULSE ; 23
const SPRITE_ANIM_OBJ_MOBILE_TRADE_OT_PULSE ; 24
const SPRITE_ANIM_OBJ_MOBILE_TRADE_PING ; 25
const SPRITE_ANIM_OBJ_INTRO_SUICUNE ; 26
const SPRITE_ANIM_OBJ_INTRO_PICHU ; 27
const SPRITE_ANIM_OBJ_INTRO_WOOPER ; 28
const SPRITE_ANIM_OBJ_INTRO_UNOWN ; 29
const SPRITE_ANIM_OBJ_INTRO_UNOWN_F ; 2a
const SPRITE_ANIM_OBJ_INTRO_SUICUNE_AWAY ; 2b
const SPRITE_ANIM_OBJ_CELEBI ; 2c
const SPRITE_ANIM_OBJ_PC_CURSOR ; 2d
const SPRITE_ANIM_OBJ_PC_QUICK ; 2e
const SPRITE_ANIM_OBJ_PC_MODE ; 2f
const SPRITE_ANIM_OBJ_PC_MODE2 ; 30
const SPRITE_ANIM_OBJ_PC_PACK ; 31
const SPRITE_ANIM_OBJ_PAGER_MON_RED ; 32
const SPRITE_ANIM_OBJ_PAGER_MON_BLUE ; 33
const SPRITE_ANIM_OBJ_PAGER_MON_GREEN ; 34
const SPRITE_ANIM_OBJ_PAGER_MON_BROWN ; 35
const SPRITE_ANIM_OBJ_PAGER_MON_GREY ; 36
const SPRITE_ANIM_OBJ_MOBILE_TRADE_SENT_BALL ; 1f
const SPRITE_ANIM_OBJ_MOBILE_TRADE_OT_BALL ; 20
const SPRITE_ANIM_OBJ_MOBILE_TRADE_CABLE_BULGE ; 21
const SPRITE_ANIM_OBJ_MOBILE_TRADE_SENT_PULSE ; 22
const SPRITE_ANIM_OBJ_MOBILE_TRADE_OT_PULSE ; 23
const SPRITE_ANIM_OBJ_MOBILE_TRADE_PING ; 24
const SPRITE_ANIM_OBJ_INTRO_SUICUNE ; 25
const SPRITE_ANIM_OBJ_INTRO_PICHU ; 26
const SPRITE_ANIM_OBJ_INTRO_WOOPER ; 27
const SPRITE_ANIM_OBJ_INTRO_UNOWN ; 28
const SPRITE_ANIM_OBJ_INTRO_UNOWN_F ; 29
const SPRITE_ANIM_OBJ_INTRO_SUICUNE_AWAY ; 2a
const SPRITE_ANIM_OBJ_CELEBI ; 2b
const SPRITE_ANIM_OBJ_PC_CURSOR ; 2c
const SPRITE_ANIM_OBJ_PC_QUICK ; 2d
const SPRITE_ANIM_OBJ_PC_MODE ; 2e
const SPRITE_ANIM_OBJ_PC_MODE2 ; 2f
const SPRITE_ANIM_OBJ_PC_PACK ; 30
const SPRITE_ANIM_OBJ_PAGER_MON_RED ; 31
const SPRITE_ANIM_OBJ_PAGER_MON_BLUE ; 32
const SPRITE_ANIM_OBJ_PAGER_MON_GREEN ; 33
const SPRITE_ANIM_OBJ_PAGER_MON_BROWN ; 34
const SPRITE_ANIM_OBJ_PAGER_MON_GREY ; 35
DEF NUM_SPRITE_ANIM_OBJS EQU const_value

; DoSpriteAnimFrame.Jumptable indexes (see engine/sprite_anims/functions.asm)
Expand Down Expand Up @@ -165,7 +164,7 @@ DEF NUM_SPRITE_ANIM_FUNCS EQU const_value
const SPRITE_ANIM_FRAMESET_TRADEMON_BUBBLE ; 18
const SPRITE_ANIM_FRAMESET_EVOLUTION_BALL_OF_LIGHT ; 19
const SPRITE_ANIM_FRAMESET_RADIO_TUNING_KNOB ; 1a
const SPRITE_ANIM_FRAMESET_MAGNET_TRAIN_RED ; 1b
const SPRITE_ANIM_FRAMESET_MAGNET_TRAIN ; 1b
const SPRITE_ANIM_FRAMESET_UNUSED_1C ; 1c
const SPRITE_ANIM_FRAMESET_LEAF ; 1d
const SPRITE_ANIM_FRAMESET_CUT_TREE ; 1e
Expand All @@ -184,37 +183,36 @@ DEF NUM_SPRITE_ANIM_FUNCS EQU const_value
const SPRITE_ANIM_FRAMESET_EZCHAT_CURSOR_6 ; 2b
const SPRITE_ANIM_FRAMESET_EZCHAT_CURSOR_7 ; 2c
const SPRITE_ANIM_FRAMESET_BLUE_WALK ; 2d
const SPRITE_ANIM_FRAMESET_MAGNET_TRAIN_BLUE ; 2e
const SPRITE_ANIM_FRAMESET_MOBILE_TRADE_SENT_BALL ; 2f
const SPRITE_ANIM_FRAMESET_MOBILE_TRADE_OT_BALL ; 30
const SPRITE_ANIM_FRAMESET_MOBILE_TRADE_CABLE_BULGE ; 31
const SPRITE_ANIM_FRAMESET_MOBILE_TRADE_SENT_PULSE ; 32
const SPRITE_ANIM_FRAMESET_MOBILE_TRADE_OT_PULSE ; 33
const SPRITE_ANIM_FRAMESET_MOBILE_TRADE_PING ; 34
const SPRITE_ANIM_FRAMESET_INTRO_SUICUNE ; 35
const SPRITE_ANIM_FRAMESET_INTRO_SUICUNE_2 ; 36
const SPRITE_ANIM_FRAMESET_INTRO_PICHU ; 37
const SPRITE_ANIM_FRAMESET_INTRO_WOOPER ; 38
const SPRITE_ANIM_FRAMESET_INTRO_UNOWN_1 ; 39
const SPRITE_ANIM_FRAMESET_INTRO_UNOWN_2 ; 3a
const SPRITE_ANIM_FRAMESET_INTRO_UNOWN_3 ; 3b
const SPRITE_ANIM_FRAMESET_INTRO_UNOWN_4 ; 3c
const SPRITE_ANIM_FRAMESET_INTRO_UNOWN_F_2 ; 3d
const SPRITE_ANIM_FRAMESET_INTRO_SUICUNE_AWAY ; 3e
const SPRITE_ANIM_FRAMESET_INTRO_UNOWN_F ; 3f
const SPRITE_ANIM_FRAMESET_CELEBI_LEFT ; 40
const SPRITE_ANIM_FRAMESET_CELEBI_RIGHT ; 41
const SPRITE_ANIM_FRAMESET_PC_CURSOR ; 42
const SPRITE_ANIM_FRAMESET_PC_CURSOR_ITEM ; 43
const SPRITE_ANIM_FRAMESET_PC_QUICK ; 44
const SPRITE_ANIM_FRAMESET_PC_MODE ; 45
const SPRITE_ANIM_FRAMESET_PC_MODE2 ; 46
const SPRITE_ANIM_FRAMESET_PC_PACK ; 47
const SPRITE_ANIM_FRAMESET_PAGER_MON_RED ; 48
const SPRITE_ANIM_FRAMESET_PAGER_MON_BLUE ; 49
const SPRITE_ANIM_FRAMESET_PAGER_MON_GREEN ; 4a
const SPRITE_ANIM_FRAMESET_PAGER_MON_BROWN ; 4b
const SPRITE_ANIM_FRAMESET_PAGER_MON_GREY ; 4c
const SPRITE_ANIM_FRAMESET_MOBILE_TRADE_SENT_BALL ; 2e
const SPRITE_ANIM_FRAMESET_MOBILE_TRADE_OT_BALL ; 2f
const SPRITE_ANIM_FRAMESET_MOBILE_TRADE_CABLE_BULGE ; 30
const SPRITE_ANIM_FRAMESET_MOBILE_TRADE_SENT_PULSE ; 31
const SPRITE_ANIM_FRAMESET_MOBILE_TRADE_OT_PULSE ; 32
const SPRITE_ANIM_FRAMESET_MOBILE_TRADE_PING ; 33
const SPRITE_ANIM_FRAMESET_INTRO_SUICUNE ; 34
const SPRITE_ANIM_FRAMESET_INTRO_SUICUNE_2 ; 35
const SPRITE_ANIM_FRAMESET_INTRO_PICHU ; 36
const SPRITE_ANIM_FRAMESET_INTRO_WOOPER ; 37
const SPRITE_ANIM_FRAMESET_INTRO_UNOWN_1 ; 38
const SPRITE_ANIM_FRAMESET_INTRO_UNOWN_2 ; 39
const SPRITE_ANIM_FRAMESET_INTRO_UNOWN_3 ; 3a
const SPRITE_ANIM_FRAMESET_INTRO_UNOWN_4 ; 3b
const SPRITE_ANIM_FRAMESET_INTRO_UNOWN_F_2 ; 3c
const SPRITE_ANIM_FRAMESET_INTRO_SUICUNE_AWAY ; 3d
const SPRITE_ANIM_FRAMESET_INTRO_UNOWN_F ; 3e
const SPRITE_ANIM_FRAMESET_CELEBI_LEFT ; 3f
const SPRITE_ANIM_FRAMESET_CELEBI_RIGHT ; 40
const SPRITE_ANIM_FRAMESET_PC_CURSOR ; 41
const SPRITE_ANIM_FRAMESET_PC_CURSOR_ITEM ; 42
const SPRITE_ANIM_FRAMESET_PC_QUICK ; 43
const SPRITE_ANIM_FRAMESET_PC_MODE ; 44
const SPRITE_ANIM_FRAMESET_PC_MODE2 ; 45
const SPRITE_ANIM_FRAMESET_PC_PACK ; 46
const SPRITE_ANIM_FRAMESET_PAGER_MON_RED ; 47
const SPRITE_ANIM_FRAMESET_PAGER_MON_BLUE ; 48
const SPRITE_ANIM_FRAMESET_PAGER_MON_GREEN ; 49
const SPRITE_ANIM_FRAMESET_PAGER_MON_BROWN ; 4a
const SPRITE_ANIM_FRAMESET_PAGER_MON_GREY ; 4b
DEF NUM_SPRITE_ANIM_FRAMESETS EQU const_value

; SpriteAnimOAMData indexes (see data/sprite_anims/oam.asm)
Expand Down Expand Up @@ -284,8 +282,8 @@ DEF NUM_SPRITE_ANIM_FRAMESETS EQU const_value
const SPRITE_ANIM_OAMSET_PARTY_MON_WITH_MAIL_2 ; 3e
const SPRITE_ANIM_OAMSET_PARTY_MON_WITH_ITEM_1 ; 3f
const SPRITE_ANIM_OAMSET_PARTY_MON_WITH_ITEM_2 ; 40
const SPRITE_ANIM_OAMSET_MAGNET_TRAIN_RED_1 ; 41
const SPRITE_ANIM_OAMSET_MAGNET_TRAIN_RED_2 ; 42
const SPRITE_ANIM_OAMSET_MAGNET_TRAIN_1 ; 41
const SPRITE_ANIM_OAMSET_MAGNET_TRAIN_2 ; 42
const SPRITE_ANIM_OAMSET_UNUSED_43 ; 43
const SPRITE_ANIM_OAMSET_UNUSED_44 ; 44
const SPRITE_ANIM_OAMSET_UNUSED_45 ; 45
Expand Down Expand Up @@ -320,57 +318,57 @@ DEF NUM_SPRITE_ANIM_FRAMESETS EQU const_value
const SPRITE_ANIM_OAMSET_EZCHAT_CURSOR_7 ; 62
const SPRITE_ANIM_OAMSET_BLUE_WALK_1 ; 63
const SPRITE_ANIM_OAMSET_BLUE_WALK_2 ; 64
const SPRITE_ANIM_OAMSET_MAGNET_TRAIN_BLUE_1 ; 65
const SPRITE_ANIM_OAMSET_MAGNET_TRAIN_BLUE_2 ; 66
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_CABLE_BULGE_1 ; 67
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_CABLE_BULGE_2 ; 68
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_PING_1 ; 69
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_PING_2 ; 6a
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_PING_3 ; 6b
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_SENT_PULSE ; 6c
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_OT_PULSE ; 6d
const SPRITE_ANIM_OAMSET_INTRO_SUICUNE_1 ; 6e
const SPRITE_ANIM_OAMSET_INTRO_SUICUNE_2 ; 6f
const SPRITE_ANIM_OAMSET_INTRO_SUICUNE_3 ; 70
const SPRITE_ANIM_OAMSET_INTRO_SUICUNE_4 ; 71
const SPRITE_ANIM_OAMSET_INTRO_PICHU_1 ; 72
const SPRITE_ANIM_OAMSET_INTRO_PICHU_2 ; 73
const SPRITE_ANIM_OAMSET_INTRO_PICHU_3 ; 74
const SPRITE_ANIM_OAMSET_INTRO_WOOPER ; 75
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_1 ; 76
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_2 ; 77
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_3 ; 78
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_F_2_1 ; 79
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_F_2_2 ; 7a
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_F_2_3 ; 7b
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_F_2_4 ; 7c
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_F_2_5 ; 7d
const SPRITE_ANIM_OAMSET_INTRO_SUICUNE_AWAY ; 7e
const SPRITE_ANIM_OAMSET_CELEBI_1 ; 7f
const SPRITE_ANIM_OAMSET_CELEBI_2 ; 80
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_1 ; 81
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_2 ; 82
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_3 ; 83
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_4 ; 84
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_5 ; 85
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_6 ; 86
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_7 ; 87
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_8 ; 88
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_9 ; 89
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_10 ; 8a
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_11 ; 8b
const SPRITE_ANIM_OAMSET_PARTY_MON_1 ; 8c
const SPRITE_ANIM_OAMSET_PARTY_MON_2 ; 8d
const SPRITE_ANIM_OAMSET_PC_CURSOR ; 8e
const SPRITE_ANIM_OAMSET_PC_CURSOR_ITEM ; 8f
const SPRITE_ANIM_OAMSET_PC_QUICK ; 90
const SPRITE_ANIM_OAMSET_PC_MODE ; 91
const SPRITE_ANIM_OAMSET_PC_MODE2 ; 92
const SPRITE_ANIM_OAMSET_PC_PACK ; 93
const SPRITE_ANIM_OAMSET_BROWN_WALK_1 ; 94
const SPRITE_ANIM_OAMSET_BROWN_WALK_2 ; 95
const SPRITE_ANIM_OAMSET_GREY_WALK_1 ; 96
const SPRITE_ANIM_OAMSET_GREY_WALK_2 ; 97
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_CABLE_BULGE_1 ; 65
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_CABLE_BULGE_2 ; 66
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_PING_1 ; 67
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_PING_2 ; 68
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_PING_3 ; 69
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_SENT_PULSE ; 6a
const SPRITE_ANIM_OAMSET_MOBILE_TRADE_OT_PULSE ; 6b
const SPRITE_ANIM_OAMSET_INTRO_SUICUNE_1 ; 6c
const SPRITE_ANIM_OAMSET_INTRO_SUICUNE_2 ; 6d
const SPRITE_ANIM_OAMSET_INTRO_SUICUNE_3 ; 6e
const SPRITE_ANIM_OAMSET_INTRO_SUICUNE_4 ; 6f
const SPRITE_ANIM_OAMSET_INTRO_PICHU_1 ; 70
const SPRITE_ANIM_OAMSET_INTRO_PICHU_2 ; 71
const SPRITE_ANIM_OAMSET_INTRO_PICHU_3 ; 72
const SPRITE_ANIM_OAMSET_INTRO_WOOPER ; 73
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_1 ; 74
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_2 ; 75
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_3 ; 76
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_F_2_1 ; 77
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_F_2_2 ; 78
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_F_2_3 ; 79
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_F_2_4 ; 7a
const SPRITE_ANIM_OAMSET_INTRO_UNOWN_F_2_5 ; 7b
const SPRITE_ANIM_OAMSET_INTRO_SUICUNE_AWAY ; 7c
const SPRITE_ANIM_OAMSET_CELEBI_1 ; 7d
const SPRITE_ANIM_OAMSET_CELEBI_2 ; 7e
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_1 ; 7f
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_2 ; 80
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_3 ; 81
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_4 ; 82
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_5 ; 83
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_6 ; 84
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_7 ; 85
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_8 ; 86
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_9 ; 87
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_10 ; 88
const SPRITE_ANIM_OAMSET_GAMEFREAK_LOGO_11 ; 89
const SPRITE_ANIM_OAMSET_PARTY_MON_1 ; 8a
const SPRITE_ANIM_OAMSET_PARTY_MON_2 ; 8b
const SPRITE_ANIM_OAMSET_PC_CURSOR ; 8c
const SPRITE_ANIM_OAMSET_PC_CURSOR_ITEM ; 8d
const SPRITE_ANIM_OAMSET_PC_QUICK ; 8e
const SPRITE_ANIM_OAMSET_PC_MODE ; 8f
const SPRITE_ANIM_OAMSET_PC_MODE2 ; 90
const SPRITE_ANIM_OAMSET_PC_PACK ; 91
const SPRITE_ANIM_OAMSET_BROWN_WALK_1 ; 92
const SPRITE_ANIM_OAMSET_BROWN_WALK_2 ; 93
const SPRITE_ANIM_OAMSET_GREY_WALK_1 ; 94
const SPRITE_ANIM_OAMSET_GREY_WALK_2 ; 95
const SPRITE_ANIM_OAMSET_GREEN_WALK_1 ; 96
const SPRITE_ANIM_OAMSET_GREEN_WALK_2 ; 97
DEF NUM_SPRITE_ANIM_OAMSETS EQU const_value

assert NUM_SPRITE_ANIM_OAMSETS <= FIRST_OAM_CMD, \
Expand Down
70 changes: 51 additions & 19 deletions constants/sprite_data_constants.asm
Original file line number Diff line number Diff line change
Expand Up @@ -13,25 +13,57 @@ DEF NUM_SPRITEDATA_FIELDS EQU _RS
const STANDING_SPRITE ; 2
const STILL_SPRITE ; 3

; object_events that set a pal value will override the sprite's default palette
DEF PAL_NPC_DEFAULT EQU 0

MACRO ow_npc_pal_const
const PAL_OW_\1
DEF PAL_NPC_\1 EQU PAL_OW_\1 + 1
ENDM

; sprite palettes
; MapObjectPals indexes (see gfx/overworld/npc_sprites.pal)
const_def
const PAL_OW_RED ; 0
const PAL_OW_BLUE ; 1
const PAL_OW_GREEN ; 2
const PAL_OW_BROWN ; 3
const PAL_OW_PINK ; 4
const PAL_OW_EMOTE ; 5
const PAL_OW_TREE ; 6
const PAL_OW_ROCK ; 7
ow_npc_pal_const RED ; 00
ow_npc_pal_const BLUE ; 01
ow_npc_pal_const GREEN ; 02
ow_npc_pal_const BROWN ; 03
ow_npc_pal_const PURPLE ; 04
ow_npc_pal_const GRAY ; 05
ow_npc_pal_const PINK ; 06
ow_npc_pal_const TEAL ; 07
ow_npc_pal_const YELLOW ; 08
ow_npc_pal_const ORANGE ; 09
ow_npc_pal_const AZURE ; 0a
ow_npc_pal_const WHITE ; 0b
ow_npc_pal_const BLACK ; 0c
ow_npc_pal_const POKE_BALL ; 0d (red)
ow_npc_pal_const DECO_ITEM ; 0e (blue)
ow_npc_pal_const KEY_ITEM ; 0f (green)
ow_npc_pal_const TREE ; 10
DEF NUM_OW_TIME_OF_DAY_PALS EQU const_value
ow_npc_pal_const EMOTE_GRAY ; 11
ow_npc_pal_const EMOTE_BLACK ; 12
ow_npc_pal_const EMOTE_GREEN ; 13
ow_npc_pal_const EMOTE_PURPLE ; 14
ow_npc_pal_const EMOTE_RED ; 15
ow_npc_pal_const EMOTE_ORANGE ; 16
ow_npc_pal_const EMOTE_BLUE ; 17
DEF NUM_OW_INDIVIDUAL_PALS EQU const_value - NUM_OW_TIME_OF_DAY_PALS
DEF FIRST_COPY_BG_PAL EQU const_value
ow_npc_pal_const COPY_BG_GRAY ; 18
ow_npc_pal_const COPY_BG_RED ; 19
ow_npc_pal_const COPY_BG_GREEN ; 1a
ow_npc_pal_const COPY_BG_WATER ; 1b
ow_npc_pal_const COPY_BG_YELLOW ; 1c
ow_npc_pal_const COPY_BG_BROWN ; 1d
ow_npc_pal_const COPY_BG_ROOF ; 1e
ow_npc_pal_const COPY_BG_TEXT ; 1f
DEF NUM_OW_BG_COPY_PALS EQU const_value - NUM_OW_INDIVIDUAL_PALS
DEF NUM_OW_PALS EQU const_value

; object_events set bit 3 so as not to use the sprite's default palette
; MapObjectPals indexes (see gfx/overworld/npc_sprites.pal)
const_def 1 << 3
const PAL_NPC_RED ; 8
const PAL_NPC_BLUE ; 9
const PAL_NPC_GREEN ; a
const PAL_NPC_BROWN ; b
const PAL_NPC_PINK ; c
const PAL_NPC_EMOTE ; d
const PAL_NPC_TREE ; e
const PAL_NPC_ROCK ; f
DEF PAL_OW_ROCK EQU PAL_OW_BROWN
DEF PAL_NPC_ROCK EQU PAL_NPC_BROWN
DEF PAL_OW_GREY EQU PAL_OW_GRAY
DEF PAL_NPC_SILVER EQU PAL_NPC_GRAY
DEF PAL_OW_SILVER EQU PAL_OW_GRAY
7 changes: 7 additions & 0 deletions constants/wram_constants.asm
Original file line number Diff line number Diff line change
Expand Up @@ -391,3 +391,10 @@ DEF DAYCARELADY_ACTIVE_F EQU 7
const UNLOCKED_UNOWNS_S_TO_W_F
const UNLOCKED_UNOWNS_X_TO_Z_F
DEF NUM_UNLOCKED_UNOWN_SETS EQU const_value

; wPalFlags
const_def
const NO_DYN_PAL_APPLY_F ; 0
const SCAN_OBJECTS_FIRST_F ; 1
const USE_DAYTIME_PAL_F ; 2
const DISABLE_DYN_PAL_F ; 3
1 change: 1 addition & 0 deletions data/events/special_pointers.asm
Original file line number Diff line number Diff line change
Expand Up @@ -184,3 +184,4 @@ SpecialsPointers::
add_special GiveSafariBalls
add_special RespawnOneOffs
add_special MoveReminder
add_special FadeInPalettes_EnableDynNoApply
Loading

0 comments on commit 83bccaf

Please sign in to comment.