From 31d31d326034fde26dedaf2dadb1c608e00fb92f Mon Sep 17 00:00:00 2001 From: GriffinR Date: Wed, 8 Jan 2020 18:09:24 -0500 Subject: Sync compare macros, some event_scripts.s doc, begin map_scripts constants --- include/constants/global.h | 82 +++++++++++++++-------------------------- include/constants/map_scripts.h | 12 ++++++ include/constants/vars.h | 7 +++- include/global.h | 4 +- include/strings.h | 2 +- 5 files changed, 50 insertions(+), 57 deletions(-) create mode 100644 include/constants/map_scripts.h (limited to 'include') diff --git a/include/constants/global.h b/include/constants/global.h index 68c4f8246..4a4c83c62 100644 --- a/include/constants/global.h +++ b/include/constants/global.h @@ -7,24 +7,19 @@ #define POKEMON_NAME_LENGTH 10 #define OT_NAME_LENGTH 7 -enum -{ - VERSION_SAPPHIRE = 1, - VERSION_RUBY = 2, - VERSION_EMERALD = 3, - VERSION_FIRE_RED = 4, - VERSION_LEAF_GREEN = 5, -}; - -enum LanguageId { - LANGUAGE_JAPANESE = 1, - LANGUAGE_ENGLISH = 2, - LANGUAGE_FRENCH = 3, - LANGUAGE_ITALIAN = 4, - LANGUAGE_GERMAN = 5, +#define VERSION_SAPPHIRE 1 +#define VERSION_RUBY 2 +#define VERSION_EMERALD 3 +#define VERSION_FIRE_RED 4 +#define VERSION_LEAF_GREEN 5 + +#define LANGUAGE_JAPANESE 1 +#define LANGUAGE_ENGLISH 2 +#define LANGUAGE_FRENCH 3 +#define LANGUAGE_ITALIAN 4 +#define LANGUAGE_GERMAN 5 // 6 goes unused but the theory is it was meant to be Korean - LANGUAGE_SPANISH = 7, -}; +#define LANGUAGE_SPANISH 7 #ifdef ENGLISH #define GAME_LANGUAGE (LANGUAGE_ENGLISH) @@ -37,49 +32,32 @@ enum LanguageId { #define BAG_TMHM_COUNT 58 #define BAG_BERRIES_COUNT 43 -enum -{ - MALE, - FEMALE -}; +#define MALE 0 +#define FEMALE 1 -enum -{ - OPTIONS_BUTTON_MODE_HELP, - OPTIONS_BUTTON_MODE_LR, - OPTIONS_BUTTON_MODE_L_EQUALS_A -}; +#define OPTIONS_BUTTON_MODE_HELP 0 +#define OPTIONS_BUTTON_MODE_LR 1 +#define OPTIONS_BUTTON_MODE_L_EQUALS_A 2 -enum -{ - OPTIONS_TEXT_SPEED_SLOW, - OPTIONS_TEXT_SPEED_MID, - OPTIONS_TEXT_SPEED_FAST -}; +#define OPTIONS_TEXT_SPEED_SLOW 0 +#define OPTIONS_TEXT_SPEED_MID 1 +#define OPTIONS_TEXT_SPEED_FAST 2 -enum -{ - OPTIONS_SOUND_MONO, - OPTIONS_SOUND_STEREO -}; +#define OPTIONS_SOUND_MONO 0 +#define OPTIONS_SOUND_STEREO 1 -enum -{ - OPTIONS_BATTLE_STYLE_SHIFT, - OPTIONS_BATTLE_STYLE_SET -}; +#define OPTIONS_BATTLE_STYLE_SHIFT 0 +#define OPTIONS_BATTLE_STYLE_SET 1 -enum -{ - POCKET_ITEMS = 1, - POCKET_KEY_ITEMS, - POCKET_POKE_BALLS, - POCKET_TM_CASE, - POCKET_BERRY_POUCH, -}; +#define POCKET_ITEMS 1 +#define POCKET_KEY_ITEMS 2 +#define POCKET_POKE_BALLS 3 +#define POCKET_TM_CASE 4 +#define POCKET_BERRY_POUCH 5 #define NUM_BAG_POCKETS 5 +#define PARTY_SIZE 6 #define MULTI_PARTY_SIZE PARTY_SIZE / 2 #endif //GUARD_CONSTANTS_GLOBAL_H diff --git a/include/constants/map_scripts.h b/include/constants/map_scripts.h new file mode 100644 index 000000000..2ef3d2544 --- /dev/null +++ b/include/constants/map_scripts.h @@ -0,0 +1,12 @@ +#ifndef GUARD_CONSTANTS_MAP_SCRIPTS_H +#define GUARD_CONSTANTS_MAP_SCRIPTS_H + +#define MAP_SCRIPT_ON_LOAD 1 +#define MAP_SCRIPT_ON_FRAME_TABLE 2 +#define MAP_SCRIPT_ON_TRANSITION 3 +#define MAP_SCRIPT_ON_WARP_INTO_MAP_TABLE 4 +#define MAP_SCRIPT_ON_RESUME 5 +#define MAP_SCRIPT_ON_DIVE_WARP 6 +#define MAP_SCRIPT_ON_RETURN_TO_FIELD 7 + +#endif // GUARD_CONSTANTS_MAP_SCRIPTS_H diff --git a/include/constants/vars.h b/include/constants/vars.h index 3f171ede8..3635aef6b 100644 --- a/include/constants/vars.h +++ b/include/constants/vars.h @@ -303,7 +303,10 @@ #define VAR_0x40FE 0x40FE #define VAR_0x40FF 0x40FF -#define SPECIAL_VARS_START 0x8000 +#define VARS_END 0x40FF + +#define SPECIAL_VARS_START 0x8000 + #define VAR_0x8000 0x8000 #define VAR_0x8001 0x8001 #define VAR_0x8002 0x8002 @@ -326,4 +329,6 @@ #define VAR_MON_BOX_POS 0x8013 #define VAR_TEXT_COLOR 0x8014 +#define SPECIAL_VARS_END 0x8014 + #endif // GUARD_CONSTANTS_VARS_H diff --git a/include/global.h b/include/global.h index f4d21704b..d8ea62d5c 100644 --- a/include/global.h +++ b/include/global.h @@ -295,8 +295,6 @@ struct SaveBlock2 extern struct SaveBlock2 *gSaveBlock2Ptr; -#define PARTY_SIZE 6 - struct SecretBaseParty { u32 personality[PARTY_SIZE]; @@ -406,7 +404,7 @@ struct UnkMauvilleOldManStruct u8 unk_2D95; /*0x2D96*/ u16 mauvilleOldMan_ecArray[6]; /*0x2DA2*/ u16 mauvilleOldMan_ecArray2[6]; - /*0x2DAE*/ u8 playerName[8]; + /*0x2DAE*/ u8 playerName[PLAYER_NAME_LENGTH + 1]; /*0x2DB6*/ u8 filler_2DB6[0x3]; /*0x2DB9*/ u8 playerTrainerId[4]; u8 unk_2DBD; diff --git a/include/strings.h b/include/strings.h index 90fd49b52..4379ebb65 100644 --- a/include/strings.h +++ b/include/strings.h @@ -823,7 +823,7 @@ extern const u8 gText_Tough_2[]; extern const u8 gText_Items[]; extern const u8 gText_KeyItems[]; extern const u8 gText_PokeBalls[]; -extern const u8 gText_TmsgUnknown_8417B2CHms[]; +extern const u8 gText_TMsAndHMs[]; extern const u8 gText_Berries[]; extern const u8 gText_Boulderbadge[]; extern const u8 gText_Cascadebadge[]; -- cgit v1.2.3 From 2e5bf6c9ef4f4406b1dd725e91a88cbdd10ad5c2 Mon Sep 17 00:00:00 2001 From: GriffinR Date: Wed, 8 Jan 2020 19:16:45 -0500 Subject: Use map_script constants, name unique map_script labels --- include/constants/map_scripts.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/constants/map_scripts.h b/include/constants/map_scripts.h index 2ef3d2544..1353de360 100644 --- a/include/constants/map_scripts.h +++ b/include/constants/map_scripts.h @@ -6,7 +6,7 @@ #define MAP_SCRIPT_ON_TRANSITION 3 #define MAP_SCRIPT_ON_WARP_INTO_MAP_TABLE 4 #define MAP_SCRIPT_ON_RESUME 5 -#define MAP_SCRIPT_ON_DIVE_WARP 6 +#define MAP_SCRIPT_ON_DIVE_WARP 6 // Unused #define MAP_SCRIPT_ON_RETURN_TO_FIELD 7 #endif // GUARD_CONSTANTS_MAP_SCRIPTS_H -- cgit v1.2.3 From 7eb54648608888a0e3dccb775dc3f4284ac934e6 Mon Sep 17 00:00:00 2001 From: GriffinR Date: Wed, 8 Jan 2020 21:05:04 -0500 Subject: Sync some event_scripts.s, split files --- include/constants/event_objects.h | 7 +++++++ include/constants/movement_commands.h | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 include/constants/event_objects.h (limited to 'include') diff --git a/include/constants/event_objects.h b/include/constants/event_objects.h new file mode 100644 index 000000000..0a94dc03b --- /dev/null +++ b/include/constants/event_objects.h @@ -0,0 +1,7 @@ +#ifndef GUARD_CONSTANTS_EVENT_OBJECTS_H +#define GUARD_CONSTANTS_EVENT_OBJECTS_H + +#define OBJ_EVENT_ID_PLAYER 0xFF +#define OBJ_EVENT_ID_CAMERA 0x7F + +#endif // GUARD_CONSTANTS_EVENT_OBJECTS_H diff --git a/include/constants/movement_commands.h b/include/constants/movement_commands.h index 0451e16b7..3e61cbc14 100644 --- a/include/constants/movement_commands.h +++ b/include/constants/movement_commands.h @@ -99,7 +99,7 @@ enum step_5d, step_5e, step_5f, - step_60, + set_invisible, step_61, step_62, step_63, -- cgit v1.2.3 From 16dc234d9964e41443b965dc774a0ff60d3338fa Mon Sep 17 00:00:00 2001 From: GriffinR Date: Wed, 8 Jan 2020 23:44:55 -0500 Subject: Some stdscript sync, start syncing cable_club.inc --- include/constants/cable_club.h | 15 +++++++++++++++ include/constants/vars.h | 2 +- 2 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 include/constants/cable_club.h (limited to 'include') diff --git a/include/constants/cable_club.h b/include/constants/cable_club.h new file mode 100644 index 000000000..f2aa4120c --- /dev/null +++ b/include/constants/cable_club.h @@ -0,0 +1,15 @@ +#ifndef GUARD_CONSTANTS_CABLE_CLUB_H +#define GUARD_CONSTANTS_CABLE_CLUB_H + +// States for VAR_CABLE_CLUB_STATE +#define USING_SINGLE_BATTLE 1 +#define USING_DOUBLE_BATTLE 2 +#define USING_TRADE_CENTER 3 +#define USING_RECORD_CORNER 4 +#define USING_MULTI_BATTLE 5 +#define USING_UNION_ROOM 6 +#define USING_BERRY_CRUSH 7 +#define USING_MINIGAME 8 +#define USING_BATTLE_TOWER 9 + +#endif //GUARD_CONSTANTS_CABLE_CLUB_H diff --git a/include/constants/vars.h b/include/constants/vars.h index 3635aef6b..5806b8c42 100644 --- a/include/constants/vars.h +++ b/include/constants/vars.h @@ -155,7 +155,7 @@ #define VAR_MAP_SCENE_PEWTER_CITY 0x406C #define VAR_0x406D 0x406D #define VAR_MAP_SCENE_FUCHSIA_CITY_SAFARI_ZONE_ENTRANCE 0x406E -#define VAR_0x406F 0x406F +#define VAR_CABLE_CLUB_STATE 0x406F #define VAR_MAP_SCENE_PALLET_TOWN_SIGN_LADY 0x4070 #define VAR_MAP_SCENE_CINNABAR_ISLAND 0x4071 #define VAR_0x4072 0x4072 -- cgit v1.2.3 From c39d295386654b34982d384a332b8cb7b2e55e24 Mon Sep 17 00:00:00 2001 From: GriffinR Date: Thu, 9 Jan 2020 00:15:41 -0500 Subject: Label used movement steps --- include/constants/movement_commands.h | 188 +++++++++++++++++----------------- 1 file changed, 96 insertions(+), 92 deletions(-) (limited to 'include') diff --git a/include/constants/movement_commands.h b/include/constants/movement_commands.h index 3e61cbc14..0f90405dd 100644 --- a/include/constants/movement_commands.h +++ b/include/constants/movement_commands.h @@ -3,71 +3,71 @@ enum { - step_00, - step_01, - step_02, - step_03, - slow_step_down, - slow_step_up, - slow_step_left, - slow_step_right, - step_down, - step_up, - step_left, - step_right, - fast_step_down, - fast_step_up, - fast_step_left, - fast_step_right, - step_10, - step_11, - step_12, - step_13, - step_14, - step_15, - step_16, - step_17, - step_18, - step_19, - step_1a, - step_1b, - step_1c, - step_1d, - step_1e, - step_1f, - step_20, - step_21, - step_22, - step_23, - step_24, - step_25, - step_26, - step_27, - step_28, - step_29, - step_2a, - step_2b, - step_2c, - step_2d, - step_2e, - step_2f, - step_30, - step_31, - step_32, - step_33, - step_34, - step_35, - step_36, - step_37, - step_38, - step_39, - step_3a, - step_3b, - step_3c, - step_3d, - step_3e, - step_3f, - step_40, + face_down, + face_up, + face_left, + face_right, + face_down_2, + face_up_2, + face_left_2, + face_right_2, + walk_slowest_down, + walk_slowest_up, + walk_slowest_left, + walk_slowest_right, + walk_slow_down, + walk_slow_up, + walk_slow_left, + walk_slow_right, + walk_down, + walk_up, + walk_left, + walk_right, + jump_2_down, + jump_2_up, + jump_2_left, + jump_2_right, + delay_1, + delay_2, + delay_4, + delay_8, + delay_16, + walk_fast_down, + walk_fast_up, + walk_fast_left, + walk_fast_right, + walk_in_place_slow_down, + walk_in_place_slow_up, + walk_in_place_slow_left, + walk_in_place_slow_right, + walk_in_place_down, + walk_in_place_up, + walk_in_place_left, + walk_in_place_right, + walk_in_place_fast_down, + walk_in_place_fast_up, + walk_in_place_fast_left, + walk_in_place_fast_right, + walk_in_place_fastest_down, + walk_in_place_fastest_up, + walk_in_place_fastest_left, + walk_in_place_fastest_right, + ride_water_current_down, + ride_water_current_up, + ride_water_current_left, + ride_water_current_right, + walk_fastest_down, + walk_fastest_up, + walk_fastest_left, + walk_fastest_right, + slide_down, + slide_up, + slide_left, + slide_right, + player_run_down, + player_run_up, + player_run_left, + player_run_right, step_41, step_42, step_43, @@ -77,34 +77,38 @@ enum step_47, step_48, step_49, - step_4a, - step_4b, - step_4c, - step_4d, - step_4e, - step_4f, - step_50, - step_51, - step_52, - step_53, - step_54, - step_55, - step_56, - step_57, - step_58, - step_59, - step_5a, - step_5b, - step_5c, - step_5d, - step_5e, - step_5f, + face_player, + face_away_player, + lock_facing_direction, + unlock_facing_direction, + jump_down, + jump_up, + jump_left, + jump_right, + jump_in_place_down, + jump_in_place_up, + jump_in_place_left, + jump_in_place_right, + jump_in_place_down_up, + jump_in_place_up_down, + jump_in_place_left_right, + jump_in_place_right_left, + face_original_direction, + nurse_joy_bow, + enable_jump_landing_ground_effect, + disable_jump_landing_ground_effect, + disable_anim, + restore_anim, set_invisible, - step_61, - step_62, - step_63, - step_64, - step_65, + set_visible, + emote_exclamation_mark, + emote_question_mark, + emote_x, + emote_double_exclamation_mark, + step_66, + step_67, + rock_smash_break, + cut_tree, step_91 = 0x91, step_92, -- cgit v1.2.3 From a40c63fe4896ccd76f6f63bdbd940de8cc946fae Mon Sep 17 00:00:00 2001 From: GriffinR Date: Thu, 9 Jan 2020 13:25:10 -0500 Subject: Use dir constants --- include/constants/global.h | 8 +++++++- include/global.fieldmap.h | 9 --------- 2 files changed, 7 insertions(+), 10 deletions(-) (limited to 'include') diff --git a/include/constants/global.h b/include/constants/global.h index 4a4c83c62..c11945ed8 100644 --- a/include/constants/global.h +++ b/include/constants/global.h @@ -58,6 +58,12 @@ #define NUM_BAG_POCKETS 5 #define PARTY_SIZE 6 -#define MULTI_PARTY_SIZE PARTY_SIZE / 2 +#define MULTI_PARTY_SIZE (PARTY_SIZE / 2) + +#define DIR_NONE 0 +#define DIR_SOUTH 1 +#define DIR_NORTH 2 +#define DIR_WEST 3 +#define DIR_EAST 4 #endif //GUARD_CONSTANTS_GLOBAL_H diff --git a/include/global.fieldmap.h b/include/global.fieldmap.h index e567c6d5f..4402d5042 100644 --- a/include/global.fieldmap.h +++ b/include/global.fieldmap.h @@ -267,15 +267,6 @@ enum ACRO_BIKE_STATE6, }; -enum -{ - DIR_NONE, - DIR_SOUTH, - DIR_NORTH, - DIR_WEST, - DIR_EAST, -}; - enum { COLLISION_LEDGE_JUMP = 6 -- cgit v1.2.3 From d071f055041d551b33fafac01e6bbe28aaee746f Mon Sep 17 00:00:00 2001 From: GriffinR Date: Thu, 9 Jan 2020 13:25:10 -0500 Subject: Split more files from event_scripts.s --- include/event_scripts.h | 1 + include/strings.h | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/event_scripts.h b/include/event_scripts.h index b899a217b..08b5b8c01 100644 --- a/include/event_scripts.h +++ b/include/event_scripts.h @@ -1184,6 +1184,7 @@ extern const u8 Text_1BCB42[]; extern const u8 Text_1BCA95[]; extern const u8 Text_1BCACB[]; extern const u8 Text_1BCAF2[]; +extern const u8 EventScript_PC[]; extern const u8 EventScript_RepelWoreOff[]; diff --git a/include/strings.h b/include/strings.h index 4379ebb65..33650663d 100644 --- a/include/strings.h +++ b/include/strings.h @@ -706,6 +706,7 @@ extern const u8 gText_HpUp_1000[]; extern const u8 gText_PpUp_3000[]; // script_menu +extern const u8 Text_AccessWhichPC[]; extern const u8 gText_SomeoneSPc[]; extern const u8 gText_BillSPc[]; extern const u8 gText_SPc[]; @@ -713,7 +714,6 @@ extern const u8 gText_HallOfFame_2[]; extern const u8 gText_LogOff[]; extern const u8 gText_ProfOakSPc[]; extern const u8 gText_Other[]; -extern const u8 gUnknown_81A508A[]; extern const u8 gOtherText_Double[]; extern const u8 gOtherText_Knockout[]; extern const u8 gOtherText_Mixed[]; -- cgit v1.2.3 From 94fbc3ac489e529176533a1fad7deac7e1014b9d Mon Sep 17 00:00:00 2001 From: GriffinR Date: Thu, 9 Jan 2020 14:46:14 -0500 Subject: Sync temp vars --- include/constants/vars.h | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) (limited to 'include') diff --git a/include/constants/vars.h b/include/constants/vars.h index 5806b8c42..164ac7c7b 100644 --- a/include/constants/vars.h +++ b/include/constants/vars.h @@ -6,22 +6,22 @@ #define VARS_START 0x4000 // Temporary variables. Reset on map load. -#define VAR_0x4000 0x4000 -#define VAR_0x4001 0x4001 -#define VAR_0x4002 0x4002 -#define VAR_0x4003 0x4003 -#define VAR_0x4004 0x4004 -#define VAR_0x4005 0x4005 -#define VAR_0x4006 0x4006 -#define VAR_0x4007 0x4007 -#define VAR_0x4008 0x4008 -#define VAR_0x4009 0x4009 -#define VAR_0x400A 0x400A -#define VAR_0x400B 0x400B -#define VAR_0x400C 0x400C -#define VAR_0x400D 0x400D -#define VAR_0x400E 0x400E -#define VAR_0x400F 0x400F +#define VAR_TEMP_0 0x4000 +#define VAR_TEMP_1 0x4001 +#define VAR_TEMP_2 0x4002 +#define VAR_TEMP_3 0x4003 +#define VAR_TEMP_4 0x4004 +#define VAR_TEMP_5 0x4005 +#define VAR_TEMP_6 0x4006 +#define VAR_TEMP_7 0x4007 +#define VAR_TEMP_8 0x4008 +#define VAR_TEMP_9 0x4009 +#define VAR_TEMP_A 0x400A +#define VAR_TEMP_B 0x400B +#define VAR_TEMP_C 0x400C +#define VAR_TEMP_D 0x400D +#define VAR_TEMP_E 0x400E +#define VAR_TEMP_F 0x400F // Object event graphics IDs which can be changed by // script commands. -- cgit v1.2.3 From 9fafa122851dc4eecdefde2b36b88be6572656f0 Mon Sep 17 00:00:00 2001 From: GriffinR Date: Fri, 10 Jan 2020 03:19:11 -0500 Subject: More basic script constants --- include/constants/field_weather.h | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 include/constants/field_weather.h (limited to 'include') diff --git a/include/constants/field_weather.h b/include/constants/field_weather.h new file mode 100644 index 000000000..e84dbc48c --- /dev/null +++ b/include/constants/field_weather.h @@ -0,0 +1,24 @@ +#ifndef GUARD_CONSTANTS_FIELD_WEATHER_H +#define GUARD_CONSTANTS_FIELD_WEATHER_H + +#define MAX_RAIN_SPRITES 24 +#define NUM_CLOUD_SPRITES 3 +#define NUM_FOG_HORIZONTAL_SPRITES 20 +#define NUM_ASH_SPRITES 20 +#define NUM_FOG_DIAGONAL_SPRITES 20 +#define NUM_SANDSTORM_SPRITES 20 +#define NUM_SWIRL_SANDSTORM_SPRITES 5 + +// Controls how the weather should be changing the screen palettes. +#define WEATHER_PAL_STATE_CHANGING_WEATHER 0 +#define WEATHER_PAL_STATE_SCREEN_FADING_IN 1 +#define WEATHER_PAL_STATE_SCREEN_FADING_OUT 2 +#define WEATHER_PAL_STATE_IDLE 3 + +// Modes for FadeScreen +#define FADE_FROM_BLACK 0 +#define FADE_TO_BLACK 1 +#define FADE_FROM_WHITE 2 +#define FADE_TO_WHITE 3 + +#endif // GUARD_CONSTANTS_FIELD_WEATHER_H -- cgit v1.2.3 From 91bf7665c623011fb63a7045689ba600b4b1eda7 Mon Sep 17 00:00:00 2001 From: GriffinR Date: Fri, 10 Jan 2020 05:01:48 -0500 Subject: Sync split scripts, more misc splits/doc --- include/constants/flags.h | 2 +- include/constants/vars.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/constants/flags.h b/include/constants/flags.h index 8e7a6a694..982c90fcc 100644 --- a/include/constants/flags.h +++ b/include/constants/flags.h @@ -722,7 +722,7 @@ #define FLAG_TUTOR_THUNDER_WAVE 0x2C1 #define FLAG_TUTOR_ROCK_SLIDE 0x2C2 #define FLAG_TUTOR_EXPLOSION 0x2C3 -#define FLAG_TUTOR_META_PUNCH 0x2C4 +#define FLAG_TUTOR_MEGA_PUNCH 0x2C4 #define FLAG_TUTOR_MEGA_KICK 0x2C5 #define FLAG_TUTOR_DREAM_EATER 0x2C6 #define FLAG_TUTOR_SOFT_BOILED 0x2C7 diff --git a/include/constants/vars.h b/include/constants/vars.h index 164ac7c7b..de03ab6ee 100644 --- a/include/constants/vars.h +++ b/include/constants/vars.h @@ -52,7 +52,7 @@ #define VAR_FRIENDSHIP_STEP_COUNT 0x4021 // Maybe unused? -#define VAR_ICE_STEP_COUNT 0x4022 +#define VAR_0x4022 0x4022 // Step counter. Caps at 1500. If you enter a map with // renewable hidden items and this counter is capped, @@ -89,7 +89,7 @@ #define VAR_0x402F 0x402F -#define VAR_0x4030 0x4030 +#define VAR_ICE_STEP_COUNT 0x4030 #define VAR_STARTER_MON 0x4031 #define VAR_0x4032 0x4032 #define VAR_ENIGMA_BERRY_AVAILABLE 0x4033 -- cgit v1.2.3 From 0bb7f18b8e609f76a9021420470737bbd16cc2bd Mon Sep 17 00:00:00 2001 From: GriffinR Date: Fri, 10 Jan 2020 16:55:58 -0500 Subject: Sync Cable Club scripts --- include/constants/layouts.h | 10 +++++----- include/constants/map_groups.h | 10 +++++----- include/constants/pokemon.h | 4 ++++ include/constants/union_room.h | 28 ++++++++++++++++++++++++++++ include/event_scripts.h | 12 ++++++------ include/pokemon.h | 4 ---- include/script_pokemon_util_80A0058.h | 2 +- 7 files changed, 49 insertions(+), 21 deletions(-) create mode 100644 include/constants/union_room.h (limited to 'include') diff --git a/include/constants/layouts.h b/include/constants/layouts.h index 24cdcec13..a9d40220f 100644 --- a/include/constants/layouts.h +++ b/include/constants/layouts.h @@ -36,10 +36,10 @@ #define LAYOUT_CINNABAR_ISLAND_GYM 36 #define LAYOUT_VIRIDIAN_CITY_GYM 37 #define LAYOUT_UNUSED_LAYOUT_82D88C8 46 -#define LAYOUT_UNKNOWN_MAP_00_00 47 -#define LAYOUT_UNKNOWN_MAP_00_01 48 -#define LAYOUT_UNKNOWN_MAP_00_02 49 -#define LAYOUT_UNKNOWN_MAP_00_03 50 +#define LAYOUT_BATTLE_COLOSSEUM_2P 47 +#define LAYOUT_TRADE_CENTER 48 +#define LAYOUT_RECORD_CENTER 49 +#define LAYOUT_BATTLE_COLOSSEUM_4P 50 #define LAYOUT_FUCHSIA_CITY_SAFARI_ZONE_ENTRANCE 51 #define LAYOUT_UNUSED_LAYOUT_82D9B24 52 #define LAYOUT_UNUSED_LAYOUT_82DA7C8 53 @@ -244,7 +244,7 @@ #define LAYOUT_UNUSED_LAYOUT_83377F0 259 #define LAYOUT_UNUSED_LAYOUT_8338354 260 #define LAYOUT_UNUSED_LAYOUT_8338738 261 -#define LAYOUT_UNKNOWN_MAP_00_04 262 +#define LAYOUT_UNION_ROOM 262 #define LAYOUT_SAFFRON_CITY_POKEMON_TRAINER_FAN_CLUB 263 #define LAYOUT_UNUSED_LAYOUT_8338B4C 264 #define LAYOUT_SEVEN_ISLAND_HOUSE_ROOM2 265 diff --git a/include/constants/map_groups.h b/include/constants/map_groups.h index 13862d6c7..4d37b0dc8 100644 --- a/include/constants/map_groups.h +++ b/include/constants/map_groups.h @@ -2,11 +2,11 @@ #define GUARD_CONSTANTS_MAP_GROUPS_H // Map Group 0 -#define MAP_UNKNOWN_MAP_00_00 (0 | (0 << 8)) -#define MAP_UNKNOWN_MAP_00_01 (1 | (0 << 8)) -#define MAP_UNKNOWN_MAP_00_02 (2 | (0 << 8)) -#define MAP_UNKNOWN_MAP_00_03 (3 | (0 << 8)) -#define MAP_UNKNOWN_MAP_00_04 (4 | (0 << 8)) +#define MAP_BATTLE_COLOSSEUM_2P (0 | (0 << 8)) +#define MAP_TRADE_CENTER (1 | (0 << 8)) +#define MAP_RECORD_CENTER (2 | (0 << 8)) +#define MAP_BATTLE_COLOSSEUM_4P (3 | (0 << 8)) +#define MAP_UNION_ROOM (4 | (0 << 8)) // Map Group 1 #define MAP_VIRIDIAN_FOREST (0 | (1 << 8)) diff --git a/include/constants/pokemon.h b/include/constants/pokemon.h index a2ad90776..c6fc55003 100644 --- a/include/constants/pokemon.h +++ b/include/constants/pokemon.h @@ -87,4 +87,8 @@ #define MON_ALREADY_KNOWS_MOVE 0xFFFE #define MON_HAS_MAX_MOVES 0xFFFF +#define PLAYER_HAS_TWO_USABLE_MONS 0x0 +#define PLAYER_HAS_ONE_MON 0x1 +#define PLAYER_HAS_ONE_USABLE_MON 0x2 + #endif // GUARD_CONSTANTS_POKEMON_H diff --git a/include/constants/union_room.h b/include/constants/union_room.h new file mode 100644 index 000000000..2314f85a0 --- /dev/null +++ b/include/constants/union_room.h @@ -0,0 +1,28 @@ +#ifndef GUARD_CONSTANTS_UNION_ROOM_H +#define GUARD_CONSTANTS_UNION_ROOM_H + +#define LINK_GROUP_SINGLE_BATTLE 0 +#define LINK_GROUP_DOUBLE_BATTLE 1 +#define LINK_GROUP_MULTI_BATTLE 2 +#define LINK_GROUP_TRADE 3 +#define LINK_GROUP_POKEMON_JUMP 4 +#define LINK_GROUP_BERRY_CRUSH 5 +#define LINK_GROUP_BERRY_PICKING 6 +#define LINK_GROUP_WONDER_CARD 7 +#define LINK_GROUP_WONDER_NEWS 8 +#define LINK_GROUP_UNK_9 9 +#define LINK_GROUP_UNK_10 10 +#define LINK_GROUP_UNK_11 11 +#define LINK_GROUP_RECORD_CORNER 12 +#define LINK_GROUP_BERRY_BLENDER 13 +#define LINK_GROUP_UNK_14 14 +#define LINK_GROUP_COOL_CONTEST 15 +#define LINK_GROUP_BEAUTY_CONTEST 16 +#define LINK_GROUP_CUTE_CONTEST 17 +#define LINK_GROUP_SMART_CONTEST 18 +#define LINK_GROUP_TOUGH_CONTEST 19 +#define LINK_GROUP_BATTLE_TOWER 20 +#define LINK_GROUP_BATTLE_TOWER_OPEN 21 +#define NUM_LINK_GROUP_TYPES 22 + +#endif //GUARD_CONSTANTS_UNION_ROOM_H diff --git a/include/event_scripts.h b/include/event_scripts.h index 08b5b8c01..2fc045a37 100644 --- a/include/event_scripts.h +++ b/include/event_scripts.h @@ -1178,12 +1178,12 @@ extern const u8 gText_DifferentGameFile[]; // script_menu extern const u8 EventScript_1A7AE0[]; -extern const u8 Text_1BC388[]; -extern const u8 Text_1BC3C7[]; -extern const u8 Text_1BCB42[]; -extern const u8 Text_1BCA95[]; -extern const u8 Text_1BCACB[]; -extern const u8 Text_1BCAF2[]; +extern const u8 CableClub_Text_TradeMonsUsingLinkCable[]; +extern const u8 CableClub_Text_BattleUsingLinkCable[]; +extern const u8 CableClub_Text_CancelSelectedItem[]; +extern const u8 CableClub_Text_YouMayTradeHere[]; +extern const u8 CableClub_Text_YouMayBattleHere[]; +extern const u8 CableClub_Text_CanMakeBerryPowder[]; extern const u8 EventScript_PC[]; extern const u8 EventScript_RepelWoreOff[]; diff --git a/include/pokemon.h b/include/pokemon.h index 7bc1239f1..aa75a27fd 100644 --- a/include/pokemon.h +++ b/include/pokemon.h @@ -104,10 +104,6 @@ #define MON_GIVEN_TO_PC 0x1 #define MON_CANT_GIVE 0x2 -#define PLAYER_HAS_TWO_USABLE_MONS 0x0 -#define PLAYER_HAS_ONE_MON 0x1 -#define PLAYER_HAS_ONE_USABLE_MON 0x2 - #define MON_MALE 0x00 #define MON_FEMALE 0xFE #define MON_GENDERLESS 0xFF diff --git a/include/script_pokemon_util_80A0058.h b/include/script_pokemon_util_80A0058.h index b63a7b0ef..d0b8949e4 100644 --- a/include/script_pokemon_util_80A0058.h +++ b/include/script_pokemon_util_80A0058.h @@ -4,7 +4,7 @@ bool8 ScriptGiveMon(u16 species, u8 level, u16 item, u32 unk1, u32 unk2, u8 unk3); bool8 ScriptGiveEgg(u16 species); void ScriptSetMonMoveSlot(u8 partyIdx, u16 move, u8 slot); -void sp000_heal_pokemon(void); +void HealPlayerParty(void); void ReducePlayerPartyToThree(void); #endif //GUARD_SCRIPT_POKEMON_UTIL_80A0058_H -- cgit v1.2.3 From 6bcb508c3fd576bccbe589fee5bae31fb803841c Mon Sep 17 00:00:00 2001 From: GriffinR Date: Sat, 11 Jan 2020 01:00:50 -0500 Subject: Update some movement cmds --- include/constants/movement_commands.h | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) (limited to 'include') diff --git a/include/constants/movement_commands.h b/include/constants/movement_commands.h index 0f90405dd..8556ba951 100644 --- a/include/constants/movement_commands.h +++ b/include/constants/movement_commands.h @@ -7,10 +7,10 @@ enum face_up, face_left, face_right, - face_down_2, - face_up_2, - face_left_2, - face_right_2, + face_down_fast, + face_up_fast, + face_left_fast, + face_right_fast, walk_slowest_down, walk_slowest_up, walk_slowest_left, @@ -52,10 +52,10 @@ enum walk_in_place_fastest_up, walk_in_place_fastest_left, walk_in_place_fastest_right, - ride_water_current_down, - ride_water_current_up, - ride_water_current_left, - ride_water_current_right, + face_down_slow, + face_up_slow, + face_left_slow, + face_right_slow, walk_fastest_down, walk_fastest_up, walk_fastest_left, @@ -68,15 +68,15 @@ enum player_run_up, player_run_left, player_run_right, - step_41, - step_42, - step_43, - step_44, + player_run_down_slow, + player_run_up_slow, + player_run_left_slow, + player_run_right_slow, step_45, - step_46, - step_47, - step_48, - step_49, + jump_down_run, + jump_up_run, + jump_left_run, + jump_right_run, face_player, face_away_player, lock_facing_direction, @@ -105,7 +105,7 @@ enum emote_question_mark, emote_x, emote_double_exclamation_mark, - step_66, + emote_smile, step_67, rock_smash_break, cut_tree, -- cgit v1.2.3 From 0676e732869d0e62322b001cbab57b8500361005 Mon Sep 17 00:00:00 2001 From: GriffinR Date: Sun, 12 Jan 2020 16:53:55 -0500 Subject: Remove unused link groups, dead label --- include/constants/union_room.h | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) (limited to 'include') diff --git a/include/constants/union_room.h b/include/constants/union_room.h index 2314f85a0..021424773 100644 --- a/include/constants/union_room.h +++ b/include/constants/union_room.h @@ -10,19 +10,6 @@ #define LINK_GROUP_BERRY_PICKING 6 #define LINK_GROUP_WONDER_CARD 7 #define LINK_GROUP_WONDER_NEWS 8 -#define LINK_GROUP_UNK_9 9 -#define LINK_GROUP_UNK_10 10 -#define LINK_GROUP_UNK_11 11 -#define LINK_GROUP_RECORD_CORNER 12 -#define LINK_GROUP_BERRY_BLENDER 13 -#define LINK_GROUP_UNK_14 14 -#define LINK_GROUP_COOL_CONTEST 15 -#define LINK_GROUP_BEAUTY_CONTEST 16 -#define LINK_GROUP_CUTE_CONTEST 17 -#define LINK_GROUP_SMART_CONTEST 18 -#define LINK_GROUP_TOUGH_CONTEST 19 -#define LINK_GROUP_BATTLE_TOWER 20 -#define LINK_GROUP_BATTLE_TOWER_OPEN 21 -#define NUM_LINK_GROUP_TYPES 22 +#define NUM_LINK_GROUP_TYPES 9 #endif //GUARD_CONSTANTS_UNION_ROOM_H -- cgit v1.2.3