From 408c49cb75f6f3437e092be74fd02ffb52347537 Mon Sep 17 00:00:00 2001 From: Ethan Roseman Date: Thu, 8 Sep 2022 21:21:07 +0900 Subject: [PATCH] one for the books (#765) * func_802A1518_78BB18 * btl_state_update_select_target * wip * btl_state_draw_select_target and WIP * cleanup * render_shaded_sprite and wip * WIP/cleanup * wip * reset_player_status * btl_state_update_player_move and cleanup * func_802A2C84 * func_80242FE0 wip * btl_state_update_normal_start and cleanup * WIP * btl_state_update_end_turn * btl_state_update_enemy_striking_first * cleanup * cleanup & wip * item_entity_update & cleanup * update_item_entity_temp * appendGfx_item_entity * E21870 * mdl_create_mode * cleanup * func_802A9310_42D220 * area_flo2 battle funcs dun * b_area_isk_part_1_ChompChainUpdate * wip and rip * clean * partner_move_to_goal * partner_get_out * wip * cleanup * func_802BD1AC_31CD1C * func_802BD754_31D2C4 * Cleanin * fix func def * UnkShadowFunc001 * a bunch of kpa funcs * comment --- include/common_structs.h | 61 +- include/enums.h | 9 + include/functions.h | 24 +- include/model.h | 46 +- include/npc.h | 4 +- include/variables.h | 6 +- src/111f0_len_860.c | 4 +- src/16F740.c | 1537 ++++++++++++++-- src/16c8e0.c | 6 +- src/181810.c | 2 +- src/18C790.c | 6 +- src/190B20.c | 28 +- src/1a1f0_len_5390.c | 10 +- src/39210_len_aa0.c | 1 + src/415D90.c | 1585 +++++++++++++++-- src/7B440.c | 18 +- src/7fd10_len_b40.c | 10 +- src/80850_len_3060.c | 47 +- src/8a860_len_3f30.c | 6 +- src/C50A0.c | 595 ++++++- src/E20110.c | 49 +- src/E21870.c | 168 +- src/a5dd0_len_114e0.c | 138 +- src/battle/action_cmd/power_shock.c | 34 +- src/battle/area_flo2/5CE690.c | 61 +- .../area_isk_part_1/actor/stone_chomp.c | 108 +- .../area_isk_part_2/actor/chain_chomp.c | 115 +- src/battle/area_kpa2/6A2B50.c | 67 +- src/battle/battle.c | 18 +- src/battle/battle.h | 10 +- src/battle/star/refresh/78B600.c | 68 +- src/common/ChompChainUpdateHelperFunc2.inc.c | 4 +- src/d0a70_len_4fe0.c | 2 +- src/de740_len_23f0.c | 360 +++- src/encounter_api.c | 4 +- src/entity/Chest.c | 2 +- src/entity/HeartBlock.c | 4 +- src/entity/jan_iwa/Plants1.c | 2 +- src/hud_element.c | 5 - src/hud_element.h | 5 + src/npc.c | 4 +- src/pause/pause_main.c | 4 +- src/sprite.h | 2 +- src/state_file_select.c | 6 +- src/world/actions.c | 8 +- src/world/area_hos/hos_05/A2A240.c | 2 +- src/world/area_hos/hos_06/A397F0.c | 6 +- src/world/area_hos/hos_10/A3F740.c | 1 - src/world/area_isk/isk_11/98AA10.c | 2 +- src/world/area_jan/jan_05/B4ADC0.c | 2 +- src/world/area_jan/jan_06/B52BE0.c | 2 +- src/world/area_jan/jan_10/B6D4C0.c | 2 +- src/world/area_kpa/kpa_08/A4CA20.c | 12 +- src/world/area_kpa/kpa_09/A4F000.c | 12 +- src/world/area_kpa/kpa_100/A93160.c | 8 +- src/world/area_kpa/kpa_101/A93440.c | 8 +- src/world/area_kpa/kpa_12/A54950.c | 9 +- src/world/area_kpa/kpa_12/A54CA0.c | 20 +- src/world/area_kpa/kpa_13/A55F20.c | 9 +- src/world/area_kpa/kpa_13/A56270.c | 23 +- src/world/area_kpa/kpa_133/AA7790.c | 20 +- src/world/area_kpa/kpa_14/A574B0.c | 9 +- src/world/area_kpa/kpa_14/A57830.c | 28 +- src/world/area_kpa/kpa_51/A64090.c | 9 +- src/world/area_kpa/kpa_53/A6ACA0.c | 35 +- src/world/area_kpa/kpa_63/A735B0.c | 50 +- src/world/area_kpa/kpa_81/A784C0.c | 11 +- src/world/area_kpa/kpa_82/A7A500.c | 9 +- src/world/area_kpa/kpa_83/A83490.c | 9 +- src/world/common/UnkShadowFunc001.inc.c | 43 + src/world/partner/bombette.c | 363 +++- src/world/partner/bow.c | 4 +- src/world/partner/goombario.c | 7 +- src/world/partner/parakarry.c | 4 +- src/world/partner/watt.c | 211 ++- src/world/partners.c | 570 +++++- .../data/world/area_jan/jan_05/B4D7A0.data.s | 2 +- .../data/world/area_jan/jan_06/B55F40.data.s | 2 +- .../data/world/area_jan/jan_10/B6DB60.data.s | 2 +- .../16F740/btl_state_update_end_turn.s | 417 ----- .../btl_state_update_enemy_striking_first.s | 306 ---- .../16F740/btl_state_update_normal_start.s | 613 ------- .../16F740/btl_state_update_player_move.s | 697 -------- .../415D90/btl_state_draw_select_target.s | 440 ----- .../415D90/btl_state_update_select_target.s | 452 ----- .../asm/nonmatchings/415D90/func_802A2C84.s | 1120 ------------ .../nonmatchings/7B440/reset_player_status.s | 169 -- .../80850_len_3060/is_ability_active.s | 114 +- .../C50A0/appendGfx_item_entity.s | 719 -------- .../nonmatchings/C50A0/item_entity_update.s | 90 - .../C50A0/update_item_entity_temp.s | 894 ---------- .../asm/nonmatchings/E21870/func_802B704C.s | 67 - .../asm/nonmatchings/E21870/func_802B7140.s | 41 - .../asm/nonmatchings/E21870/func_802B71D4.s | 222 --- .../asm/nonmatchings/E21870/func_802B74F0.s | 95 - .../a5dd0_len_114e0/mdl_create_model.s | 305 ---- .../audio/28910_len_5090/func_8004E0F4.s | 32 - .../power_shock/func_802A9310_42D220.s | 412 ----- .../area_flo2/5CE690/func_80218440_5CEAD0.s | 117 -- .../b_area_isk_part_1_ChompChainUpdate.s | 280 --- ..._isk_part_2_chain_chomp_ChompChainUpdate.s | 289 --- .../refresh/78B600/func_802A1518_78BB18.s | 192 -- .../d0a70_len_4fe0/func_8013DAB4.s | 2 +- .../d0a70_len_4fe0/func_8013E2F0.s | 2 +- ...d_sprite.s => appendGfx_shading_palette.s} | 2 +- .../de740_len_23f0/render_shaded_sprite.s | 538 ------ .../sprite/spr_appendGfx_component_flat.s | 2 +- .../jan_05/B4ADC0/func_80240350_B4ADC0.s | 91 - .../jan_06/B52BE0/func_802403B0_B52BE0.s | 91 - .../jan_10/B6D4C0/func_80241130_B6D4C0.s | 91 - .../kpa_08/A4CA20/func_8024001C_A4CA3C.s | 38 - .../kpa_09/A4F000/func_8024001C_A4F01C.s | 38 - .../kpa_100/A93160/func_80240000_A93160.s | 34 - .../kpa_101/A93440/func_80240000_A93440.s | 34 - .../kpa_12/A54950/func_80240000_A54950.s | 21 - .../kpa_12/A54CA0/func_8024037C_A54CCC.s | 57 - .../kpa_13/A55F20/func_80240000_A55F20.s | 21 - .../kpa_13/A56270/func_8024037C_A5629C.s | 57 - .../kpa_133/AA7790/func_80240310_AA7790.s | 48 - .../kpa_133/AA7790/func_802403C0_AA7840.s | 48 - .../kpa_14/A574B0/func_80240000_A574B0.s | 21 - .../kpa_14/A57830/func_8024073C_A57BEC.s | 72 - .../kpa_51/A64090/func_80240000_A64090.s | 34 - .../kpa_53/A6ACA0/func_80240000_A6ACA0.s | 34 - .../kpa_53/A6ACA0/func_80240050_A6ACF0.s | 86 - .../kpa_63/A735B0/func_80240000_A735B0.s | 111 -- .../kpa_81/A784C0/func_80240000_A784C0.s | 34 - .../kpa_82/A7A500/func_80240000_A7A500.s | 34 - .../kpa_83/A83490/func_80240000_A83490.s | 34 - .../partner/goombario/func_802BD5D8_3174F8.s | 16 +- .../world/partner/watt/func_802BD1AC_31CD1C.s | 42 - .../world/partner/watt/func_802BD754_31D2C4.s | 391 ---- .../world/partners/partner_get_out.s | 411 ----- .../world/partners/partner_move_to_goal.s | 329 ---- ver/us/symbol_addrs.txt | 11 +- 135 files changed, 6291 insertions(+), 11426 deletions(-) create mode 100644 src/world/common/UnkShadowFunc001.inc.c delete mode 100644 ver/us/asm/nonmatchings/16F740/btl_state_update_end_turn.s delete mode 100644 ver/us/asm/nonmatchings/16F740/btl_state_update_enemy_striking_first.s delete mode 100644 ver/us/asm/nonmatchings/16F740/btl_state_update_normal_start.s delete mode 100644 ver/us/asm/nonmatchings/16F740/btl_state_update_player_move.s delete mode 100644 ver/us/asm/nonmatchings/415D90/btl_state_draw_select_target.s delete mode 100644 ver/us/asm/nonmatchings/415D90/btl_state_update_select_target.s delete mode 100644 ver/us/asm/nonmatchings/415D90/func_802A2C84.s delete mode 100644 ver/us/asm/nonmatchings/7B440/reset_player_status.s delete mode 100644 ver/us/asm/nonmatchings/C50A0/appendGfx_item_entity.s delete mode 100644 ver/us/asm/nonmatchings/C50A0/item_entity_update.s delete mode 100644 ver/us/asm/nonmatchings/C50A0/update_item_entity_temp.s delete mode 100644 ver/us/asm/nonmatchings/E21870/func_802B704C.s delete mode 100644 ver/us/asm/nonmatchings/E21870/func_802B7140.s delete mode 100644 ver/us/asm/nonmatchings/E21870/func_802B71D4.s delete mode 100644 ver/us/asm/nonmatchings/E21870/func_802B74F0.s delete mode 100644 ver/us/asm/nonmatchings/a5dd0_len_114e0/mdl_create_model.s delete mode 100644 ver/us/asm/nonmatchings/audio/28910_len_5090/func_8004E0F4.s delete mode 100644 ver/us/asm/nonmatchings/battle/action_cmd/power_shock/func_802A9310_42D220.s delete mode 100644 ver/us/asm/nonmatchings/battle/area_flo2/5CE690/func_80218440_5CEAD0.s delete mode 100644 ver/us/asm/nonmatchings/battle/area_isk_part_1/4E29B0/b_area_isk_part_1_ChompChainUpdate.s delete mode 100644 ver/us/asm/nonmatchings/battle/area_isk_part_2/4EF4A0/b_area_isk_part_2_chain_chomp_ChompChainUpdate.s delete mode 100644 ver/us/asm/nonmatchings/battle/star/refresh/78B600/func_802A1518_78BB18.s rename ver/us/asm/nonmatchings/de740_len_23f0/{appendGfx_shaded_sprite.s => appendGfx_shading_palette.s} (99%) delete mode 100644 ver/us/asm/nonmatchings/de740_len_23f0/render_shaded_sprite.s delete mode 100644 ver/us/asm/nonmatchings/world/area_jan/jan_05/B4ADC0/func_80240350_B4ADC0.s delete mode 100644 ver/us/asm/nonmatchings/world/area_jan/jan_06/B52BE0/func_802403B0_B52BE0.s delete mode 100644 ver/us/asm/nonmatchings/world/area_jan/jan_10/B6D4C0/func_80241130_B6D4C0.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_08/A4CA20/func_8024001C_A4CA3C.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_09/A4F000/func_8024001C_A4F01C.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_100/A93160/func_80240000_A93160.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_101/A93440/func_80240000_A93440.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_12/A54950/func_80240000_A54950.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_12/A54CA0/func_8024037C_A54CCC.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_13/A55F20/func_80240000_A55F20.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_13/A56270/func_8024037C_A5629C.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_133/AA7790/func_80240310_AA7790.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_133/AA7790/func_802403C0_AA7840.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_14/A574B0/func_80240000_A574B0.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_14/A57830/func_8024073C_A57BEC.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_51/A64090/func_80240000_A64090.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_53/A6ACA0/func_80240000_A6ACA0.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_53/A6ACA0/func_80240050_A6ACF0.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_63/A735B0/func_80240000_A735B0.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_81/A784C0/func_80240000_A784C0.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_82/A7A500/func_80240000_A7A500.s delete mode 100644 ver/us/asm/nonmatchings/world/area_kpa/kpa_83/A83490/func_80240000_A83490.s delete mode 100644 ver/us/asm/nonmatchings/world/partner/watt/func_802BD1AC_31CD1C.s delete mode 100644 ver/us/asm/nonmatchings/world/partner/watt/func_802BD754_31D2C4.s delete mode 100644 ver/us/asm/nonmatchings/world/partners/partner_get_out.s delete mode 100644 ver/us/asm/nonmatchings/world/partners/partner_move_to_goal.s diff --git a/include/common_structs.h b/include/common_structs.h index ccae3de596..94facf76e1 100644 --- a/include/common_structs.h +++ b/include/common_structs.h @@ -634,8 +634,8 @@ typedef struct UiStatus { /* 0x38 */ s16 showTimer; /* 0x3A */ s8 hidden; /* 0x3B */ s8 unk_3B[2]; - /* 0x3D */ u8 displayHP; - /* 0x3E */ u8 displayFP; + /* 0x3D */ s8 displayHP; + /* 0x3E */ s8 displayFP; /* 0x3F */ char unk_3F; /* 0x40 */ s16 displayCoins; /* 0x42 */ s16 displayStarpoints; @@ -644,20 +644,22 @@ typedef struct UiStatus { /* 0x47 */ s8 disabled; /* set != 0 for menu to be disabled completely */ /* 0x48 */ s16 displaySP; /* 0x4A */ s8 hpBlinking; /* bool */ - /* 0x4B */ u8 hpBlinkCounter; - /* 0x4C */ u8 hpBlinkTimer; /* until stop */ + /* 0x4B */ s8 hpBlinkCounter; + /* 0x4C */ s8 hpBlinkTimer; /* until stop */ /* 0x4D */ s8 fpBlinking; /* bool */ - /* 0x4E */ u8 fpBlinkCounter; - /* 0x4F */ u8 fpBlinkTimer; /* until stop */ + /* 0x4E */ s8 fpBlinkCounter; + /* 0x4F */ s8 fpBlinkTimer; /* until stop */ /* 0x50 */ s8 spBlinking; - /* 0x51 */ u8 spBlinkCounter; + /* 0x51 */ s8 spBlinkCounter; /* 0x52 */ s8 starpointsBlinking; /* bool */ - /* 0x53 */ u8 starpointsBlinkCounter; + /* 0x53 */ s8 starpointsBlinkCounter; /* 0x54 */ s8 coinsBlinking; /* bool */ - /* 0x55 */ u8 coinsBlinkCounter; - /* 0x56 */ u8 coinsBlinkTimer; /* until stop */ - /* 0x57 */ char unk_57[3]; - /* 0x5A */ u8 spBarsToBlink; /* how many sp bars to blink */ + /* 0x55 */ s8 coinsBlinkCounter; + /* 0x56 */ s8 coinsBlinkTimer; /* until stop */ + /* 0x57 */ u8 unk_57; + /* 0x58 */ u8 unk_58; + /* 0x59 */ u8 unk_59; + /* 0x5A */ s8 spBarsToBlink; /* how many sp bars to blink */ /* 0x5B */ char unk_5B; /* 0x5C */ s32 iconIndex10; /* 0x60 */ s32 iconIndex11; @@ -799,11 +801,6 @@ typedef struct Camera { /* 0x556 */ s16 unk_556; } Camera; // size = 0x558 -typedef struct FGModelData { - /* 0x00 */ char unk_00[0x18]; - /* 0x18 */ s32* idList; -} FGModelData; // size = unknown - typedef struct BattleStatus { /* 0x000 */ s32 flags1; /* 0x004 */ s32 flags2; @@ -813,7 +810,9 @@ typedef struct BattleStatus { /* */ void* varTablePtr[16]; /* */ }; /* 0x048 */ s8 currentSubmenu; - /* 0x049 */ char unk_49[3]; + /* 0x049 */ s8 unk_49; + /* 0x04A */ s8 unk_4A; + /* 0x04B */ s8 unk_4B; /* 0x04C */ s8 unk_4C[16]; /* 0x05C */ s8 unk_5C[16]; /* 0x06C */ s16 unk_6C; @@ -928,9 +927,9 @@ typedef struct BattleStatus { /* 0x430 */ s8 holdInputBufferPos; /* 0x431 */ s8 inputBufferPos; /* 0x432 */ s8 unk_432; - /* 0x433 */ char unk_433; + /* 0x433 */ u8 unk_433; /* 0x434 */ s32* unk_434; - /* 0x438 */ FGModelData* foregroundModelData; + /* 0x438 */ struct Stage* currentStage; /* 0x43C */ struct EffectInstance* buffEffect; /* 0x440 */ u8 tattleFlags[28]; /* 0x45C */ char unk_45C[4]; @@ -1107,8 +1106,8 @@ typedef struct ItemEntity { /* 0x22 */ char unk_22[2]; /* 0x24 */ u32* readPos; /* 0x28 */ u32* savedReadPos; - /* 0x2C */ s8 lookupRasterIndex; - /* 0x2D */ s8 lookupPaletteIndex; + /* 0x2C */ u8 lookupRasterIndex; + /* 0x2D */ u8 lookupPaletteIndex; /* 0x2E */ u8 nextUpdate; /* 0x2F */ u8 alpha; /* 0x30 */ f32 scale; @@ -2318,11 +2317,11 @@ typedef struct SpriteShadingLightSource { } SpriteShadingLightSource; // size = 0x18 typedef struct SpriteShadingProfile { - /* 0x00 */ s16 flags; + /* 0x00 */ u16 flags; /* 0x02 */ char unk_02[0x2]; /* 0x04 */ SpriteShadingLightSource sources[7]; /* 0xAC */ Color_RGB8 ambientColor; - /* 0xAF */ s8 ambientPower; // ? + /* 0xAF */ u8 ambientPower; // ? } SpriteShadingProfile; // size = 0xB0 typedef struct FoldImageRecPart { @@ -2457,4 +2456,18 @@ typedef struct CreditsUnkBeta { /* 0x02 */ s16 size; } CreditsUnkBeta; // size = 0x4 +typedef struct TempE20110 { + /* 0x00 */ Vec3f pos; + /* 0x0C */ f32 scale; + /* 0x10 */ f32 unk_10; + /* 0x14 */ char unk_14[0x4]; + /* 0x18 */ s32 unk_18; + /* 0x1C */ s32 unk_1C; + /* 0x20 */ s8 unk_20; + /* 0x21 */ s8 unk_21; + /* 0x22 */ s8 unk_22; + /* 0x23 */ s8 unk_23; + /* 0x24 */ s32 unk_24; +} TempE20110; // size = 0x28 + #endif diff --git a/include/enums.h b/include/enums.h index 053fa5ca30..5ae42e3459 100644 --- a/include/enums.h +++ b/include/enums.h @@ -494,6 +494,8 @@ enum Easings { enum SoundIDs { SOUND_0 = 0x00000000, + SOUND_1 = 0x00000001, + SOUND_2 = 0x00000002, SOUND_3 = 0x00000003, SOUND_4 = 0x00000004, SOUND_MENU_BADGE_EQUIP = 0x00000005, @@ -558,6 +560,7 @@ enum SoundIDs { SOUND_73 = 0x00000073, SOUND_74 = 0x00000074, SOUND_77 = 0x00000077, + SOUND_7D = 0x0000007D, SOUND_82 = 0x00000082, SOUND_83 = 0x00000083, SOUND_84 = 0x00000084, @@ -603,7 +606,9 @@ enum SoundIDs { SOUND_CC = 0x000000CC, SOUND_CD = 0x000000CD, SOUND_CE = 0x000000CE, + SOUND_D1 = 0x000000D1, SOUND_D2 = 0x000000D2, + SOUND_D3 = 0x000000D3, SOUND_D4 = 0x000000D4, SOUND_D5 = 0x000000D5, SOUND_D6 = 0x000000D6, @@ -622,6 +627,7 @@ enum SoundIDs { SOUND_HIT_FIRE = 0x000000EA, SOUND_HIT_ICE = 0x000000EB, SOUND_F1 = 0x000000F1, + SOUND_F2 = 0x000000F2, SOUND_F3 = 0x000000F3, SOUND_F4 = 0x000000F4, SOUND_F5 = 0x000000F5, @@ -735,6 +741,7 @@ enum SoundIDs { SOUND_1D0 = 0x000001D0, SOUND_1D1 = 0x000001D1, SOUND_1D2 = 0x000001D2, + SOUND_1D3 = 0x000001D3, SOUND_1D4 = 0x000001D4, SOUND_1D5 = 0x000001D5, SOUND_CREAKY_ROCKING_CHAIR = 0x000001D6, @@ -1064,6 +1071,7 @@ enum SoundIDs { SOUND_205F = 0x0000205F, SOUND_2060 = 0x00002060, SOUND_2061 = 0x00002061, + SOUND_2063 = 0x00002063, SOUND_2064 = 0x00002064, SOUND_2065 = 0x00002065, SOUND_2066 = 0x00002066, @@ -3719,6 +3727,7 @@ enum BattleStatusFlags2 { BS_FLAGS2_4 = 0x00000004, BS_FLAGS2_8 = 0x00000008, BS_FLAGS2_10 = 0x00000010, + BS_FLAGS2_20 = 0x00000020, BS_FLAGS2_40 = 0x00000040, BS_FLAGS2_80 = 0x00000080, BS_FLAGS2_100 = 0x00000100, diff --git a/include/functions.h b/include/functions.h index 877d3b4e8a..29322a44a3 100644 --- a/include/functions.h +++ b/include/functions.h @@ -148,7 +148,6 @@ s32 general_heap_free(void* data); s32 integer_log(s32 number, u32 base); -void set_battle_formation(s32); void set_battle_stage(s32); void load_battle(s32); @@ -221,6 +220,7 @@ void get_dpad_input_radial(f32* angle, f32* magnitude); void transform_point(Matrix4f mtx, f32 inX, f32 inY, f32 inZ, f32 inS, f32* outX, f32* outY, f32* outZ, f32* outS); void try_player_footstep_sounds(s32 arg0); void phys_update_interact_collider(void); +void phys_reset_spin_history(void); s32 phys_adjust_cam_on_landing(void); s32 phys_should_player_be_sliding(void); void phys_init_integrator_for_current_state(void); @@ -299,6 +299,10 @@ void init_model_animators(void); void play_model_animation(s32, s16*); s32 heap_free(void* ptr); +void load_battle_hit_asset(const char* hitName); +void load_data_for_models(struct ModelNode* model, s32 romOffset, s32 size); +void load_player_actor(void); + void btl_state_update_normal_start(void); void btl_state_draw_normal_start(void); void btl_state_update_begin_turn(void); @@ -520,6 +524,7 @@ s32 bgm_set_song(s32 playerIndex, s32 songID, s32 variation, s32 fadeOutTime, s1 void bgm_set_battle_song(s32, s32); void bgm_push_battle_song(void); s32 bgm_adjust_proximity(s32 playerIndex, s32 arg1, s16 arg2); +void func_801491E4(s32, s32, s32, s32, s32, s32 alpha); s32 func_8014A964(s32 playerIndex, s32 songID, s32 variation, s32 fadeInTime, s16 arg4, s16 arg5); #include "audio/public.h" @@ -721,6 +726,8 @@ void state_step_demo(void); void state_drawUI_demo(void); void game_mode_set_fpDrawAuxUI(s32 i, void (*fn)(void)); +void func_80260A60(void); + void func_802B2000(void); void func_802B203C(void); void func_802B2078(void); @@ -796,7 +803,7 @@ void mdl_get_copied_vertices(s32 copyIndex, Vtx** firstVertex, Vtx** copiedVerti void mdl_draw_hidden_panel_surface(Gfx** arg0, u16 treeIndex); s32 func_8011CFBC(void); void set_screen_overlay_center_worldpos(s32 idx, s32 posIdx, s32 x, s32 y, s32 z); -s32 mdl_get_next_texture_address(s32); +void* mdl_get_next_texture_address(s32); void draw_msg(s32 msgID, s32 posX, s32 posY, s32 opacity, s32 palette, u8 style); void get_background_color_blend(u8* r, u8* g, u8* b, u8* a); @@ -892,16 +899,22 @@ s32 add_badge(s32 itemID); void hide_coin_counter_immediately(void); void hide_popup_menu(void); void destroy_popup_menu(void); -void reset_player_status(void);; +void reset_player_status(void); +s32 has_valid_conversation_npc(void); +s32 func_800E06D8(void); void func_800E4F10(void); void func_800E5520(void); void func_800E6B68(void); +void func_800E9810(void); s32 func_800E9860(void); void func_800E98C4(void); void func_800E98EC(void); void func_800E9900(void); -void func_800F0D5C(void); void func_800F0C9C(void); +void func_800F0CB0(s32, f32, f32, f32); +void func_800F0D5C(void); +void func_800F0D80(void); +void func_800F102C(void); s32 get_item_count(void); s32 get_stored_empty_count(void); s32 get_stored_count(void); @@ -970,6 +983,9 @@ void status_menu_start_blinking_sp(void); void status_menu_stop_blinking_fp(void); void status_menu_stop_blinking_hp(void); void status_menu_stop_blinking_sp(void); +void status_menu_start_blinking_sp_bars(s8 numBarsToBlink); +void status_menu_draw_number(s32 iconID, s32 x, s32 y, s32 value, s32 numDigits); +void status_menu_draw_stat(s32 id, s32 x, s32 y, s32, s32); void set_background_size(s16, s16, s16, s16); void read_background_size(BackgroundHeader*); void set_max_SP(s8); diff --git a/include/model.h b/include/model.h index c0d4d7ac60..d1f196c317 100644 --- a/include/model.h +++ b/include/model.h @@ -9,6 +9,26 @@ typedef union ModelNodePropertyData { s32* p; } ModelNodePropertyData; +// In memory this is a list of ModelNodeProperty, but due to the way it uses +// the fields (storing into the "type" field) we decided to make a struct for this +typedef struct ModelBoundingBox { + /* 0x00 */ s32 key; // MODEL_PROP_KEY_BOUNDING_BOX + /* 0x04 */ s32 halfSizeX; + /* 0x08 */ f32 minX; + /* 0x0C */ char unk_0C[0x04]; + /* 0x10 */ s32 halfSizeY; + /* 0x14 */ f32 minY; + /* 0x18 */ char unk_18[0x04]; + /* 0x1C */ s32 halfSizeZ; + /* 0x20 */ f32 minZ; + /* 0x24 */ char unk_24[0x8]; + /* 0x2C */ f32 maxX; + /* 0x30 */ char unk_30[0x8]; + /* 0x38 */ f32 maxY; + /* 0x3C */ char unk_3C[0x8]; + /* 0x44 */ f32 maxZ; +} ModelBoundingBox; // size = 0x48? + typedef struct ModelNodeProperty { /* 0x0 */ s32 key; /* 0x4 */ s32 dataType; @@ -26,12 +46,12 @@ typedef struct ModelNode { typedef struct Model { /* 0x00 */ u16 flags; /* 0x02 */ u16 modelID; - /* 0x04 */ Matrix4s* currentMatrix; + /* 0x04 */ Mtx* currentMatrix; /* 0x08 */ ModelNode* modelNode; /* 0x0C */ ModelGroupData* groupData; /* 0x10 */ s32* currentSpecialMatrix; /* 0x14 */ char unk_14[4]; - /* 0x18 */ Matrix4s specialMatrix; + /* 0x18 */ Mtx specialMatrix; /* 0x58 */ Matrix4f transformMatrix; /* 0x98 */ Vec3f center; /* 0xA4 */ u8 texPannerID; @@ -92,7 +112,7 @@ typedef struct ModelBlueprint { /* 0x2 */ char unk_02[0x2]; /* 0x4 */ ModelNode* mdlNode; /* 0x8 */ ModelGroupData* groupData; - /* 0xC */ Matrix4s* mtx; + /* 0xC */ Mtx* mtx; } ModelBlueprint; // size = 0x10 typedef void(*ModelCustomGfxBuilderFunc)(s32 index); @@ -100,26 +120,6 @@ typedef void(*ModelCustomGfxBuilderFunc)(s32 index); typedef Gfx* ModelCustomGfxList[32]; typedef ModelCustomGfxBuilderFunc ModelCustomGfxBuilderList[32]; -// In memory this is a list of ModelNodeProperty, but due to the way it uses -// the fields (storing into the "type" field) we decided to make a struct for this -typedef struct ModelBoundingBox { - /* 0x00 */ s32 key; // MODEL_PROP_KEY_BOUNDING_BOX - /* 0x04 */ s32 halfSizeX; - /* 0x08 */ f32 minX; - /* 0x0C */ char unk_0C[0x04]; - /* 0x10 */ s32 halfSizeY; - /* 0x14 */ f32 minY; - /* 0x18 */ char unk_18[0x04]; - /* 0x1C */ s32 halfSizeZ; - /* 0x20 */ f32 minZ; - /* 0x24 */ char unk_24[0x8]; - /* 0x2C */ f32 maxX; - /* 0x30 */ char unk_30[0x8]; - /* 0x38 */ f32 maxY; - /* 0x3C */ char unk_3C[0x8]; - /* 0x44 */ f32 maxZ; -} ModelBoundingBox; // size = 0x48? - typedef enum ModelPropertyKeys { MODEL_PROP_KEY_RENDER_MODE = 0x5C, MODEL_PROP_KEY_CAMERA_DATA = 0x5D, diff --git a/include/npc.h b/include/npc.h index e8e4bffd1e..5f0a0e8585 100644 --- a/include/npc.h +++ b/include/npc.h @@ -348,7 +348,7 @@ typedef struct Encounter { typedef struct EncounterStatus { /* 0x000 */ s32 flags; - /* 0x004 */ s8 eFirstStrike; /* 0 = none, 1 = player, 2 = enemy */ + /* 0x004 */ s8 firstStrikeType; /* 0 = none, 1 = player, 2 = enemy */ /* 0x005 */ s8 hitType; /* 1 = none/enemy, 2 = jump */ /* 0x006 */ s8 hitTier; /* 0 = normal, 1 = super, 2 = ultra */ /* 0x007 */ char unk_07; @@ -360,7 +360,7 @@ typedef struct EncounterStatus { /* 0x00D */ char unk_0D; /* 0x00E */ s16 coinsEarned; /* valid after battle */ /* 0x010 */ char unk_10; - /* 0x011 */ u8 allowFleeing; + /* 0x011 */ s8 allowFleeing; /* 0x012 */ s8 unk_12; /* 0x013 */ u8 dropWhackaBump; /* 0x014 */ s32 songID; diff --git a/include/variables.h b/include/variables.h index d3e7287e8c..75fefc8647 100644 --- a/include/variables.h +++ b/include/variables.h @@ -29,7 +29,7 @@ extern u8 D_800DC4EB; // in the middle of the previous var extern s32 D_800DC4E0; extern s32 D_800DC4EC; extern s32 D_800DC4F0; -extern s32 D_800DC4F4; +extern struct Battle* D_800DC4F4; extern s32 D_800DC4F8; extern s32 gBattleDmaDest; @@ -96,7 +96,7 @@ extern MessagePrintState* SaveBlockResultPrinter; extern Entity* SwitchToLink; extern s32 CreateEntityVarArgBuffer[4]; -extern f32 DefaultMoveSpeeds[4]; +extern f32 D_800F7B74; extern CollisionData gZoneCollisionData; @@ -164,7 +164,7 @@ extern s16 D_800A0922; extern s32 wMapTexName; extern char wMapHitName[]; extern char wMapShapeName[]; -extern s32* D_80210000; +extern struct ModelNode* D_80210000; extern u8 D_802D9D70; // player alpha1 copy? extern u8 D_802D9D71; // player alpha2 copy? diff --git a/src/111f0_len_860.c b/src/111f0_len_860.c index 22efd828a6..e451c6f7eb 100644 --- a/src/111f0_len_860.c +++ b/src/111f0_len_860.c @@ -46,7 +46,7 @@ void state_step_enter_world(void) { } gGameStatusPtr->prevArea = gGameStatusPtr->areaID; - set_time_freeze_mode(0); + set_time_freeze_mode(TIME_FREEZE_NORMAL); if (gGameStatusPtr->demoState == 0) { disable_player_input(); } @@ -135,7 +135,7 @@ void state_step_change_map(void) { gGameStatusPtr->isBattle = FALSE; gGameStatusPtr->disableScripts = FALSE; load_map_by_IDs(gGameStatusPtr->areaID, gGameStatusPtr->mapID, 0); - set_time_freeze_mode(0); + set_time_freeze_mode(TIME_FREEZE_NORMAL); nuContRmbForceStopEnd(); if (gGameStatusPtr->demoState == 0) { disable_player_input(); diff --git a/src/16F740.c b/src/16F740.c index 51d31cfd9a..b567bc679d 100644 --- a/src/16F740.c +++ b/src/16F740.c @@ -4,12 +4,21 @@ #include "effects.h" #include "hud_element.h" #include "battle/battle.h" +#include "model.h" extern s32* D_800DC064; +extern BackgroundHeader func_80200000; + extern s16 D_802809F6; extern s16 D_802809F8; extern s32 D_80280A30; +extern EvtScript D_80280EB8[]; +extern s32 D_80281454[]; +extern EvtScript D_80284A20[]; +extern EvtScript D_80284A30[]; + +extern s32 D_8029F240; extern u8 D_8029F244; extern s32 D_8029F248; extern s32 D_8029F24C; @@ -172,7 +181,321 @@ void btl_set_state(s32 battleState) { } } -INCLUDE_ASM(s32, "16F740", btl_state_update_normal_start); +void btl_state_update_normal_start(void) { + BattleStatus* battleStatus = &gBattleStatus; + EncounterStatus* currentEncounter = &gCurrentEncounter; + Battle* battle; + Stage* stage; + s32 size; + void* compressedAsset; + ModelNode* model; + s32 textureRom; + Actor* actor; + Evt* script; + s32 cond; + s32 type; + s32 i; + s32 j; + + s32* types; + + battle = (*D_800DC4FC); + if (D_800DC4F4 != NULL) { + battle = D_800DC4F4; + } + + if (D_800DC064 == NULL) { + stage = battle->stage; + } else { + stage = D_800DC064[1]; + } + + battleStatus->currentStage = stage; + switch (gBattleState2) { + case BATTLE_STATE2_UNK_0: + D_8029F240 = battle->formationSize; + set_screen_overlay_params_back(0xFF, -1.0f); + compressedAsset = load_asset_by_name(stage->shape, &size); + decode_yay0(compressedAsset, &D_80210000); + general_heap_free(compressedAsset); + + ASSERT(size <= 0x8000); + + model = D_80210000; + textureRom = get_asset_offset(stage->texture, &size); + if (model != NULL) { + load_data_for_models(model, textureRom, size); + } + load_battle_hit_asset(stage->hit); + + if (stage->bg != NULL) { + load_map_bg(stage->bg); + read_background_size(&func_80200000); + } + + if (gGameStatusPtr->demoFlags & 1) { + set_curtain_scale_goal(1.0f); + } + + battleStatus->controlScript = NULL; + battleStatus->camMovementScript = NULL; + battleStatus->unk_90 = 0; + battleStatus->preUpdateCallback = NULL; + battleStatus->initBattleCallback = NULL; + battleStatus->currentSubmenu = 0; + battleStatus->unk_49 = 0; + battleStatus->unk_4A = 0; + battleStatus->unk_4B = 0; + battleStatus->totalStarPoints = 0; + battleStatus->pendingStarPoints = 0; + battleStatus->incrementStarPointDelay = 0; + battleStatus->damageTaken = 0; + battleStatus->nextMerleeSpellType = 0; + battleStatus->unk_83 = 0; + gCameras[CAM_DEFAULT].flags |= CAMERA_FLAGS_2; + gCameras[CAM_BATTLE].flags |= CAMERA_FLAGS_2; + gCameras[CAM_TATTLE].flags |= CAMERA_FLAGS_2; + if (is_ability_active(ABILITY_MYSTERY_SCROLL)) { + battleStatus->unk_83 = 1; + } + battleStatus->actionSuccess = 0; + battleStatus->unk_82 = 0; + battleStatus->menuDisableFlags = -1; + battleStatus->unk_74 = -1; + battleStatus->itemUsesLeft = 0; + battleStatus->hammerCharge = 0; + battleStatus->jumpCharge = 0; + battleStatus->unk_98 = 0; + battleStatus->hpDrainCount = 0; + gBattleStatus.flags2 |= BS_FLAGS2_20; + if (currentEncounter->allowFleeing) { + gBattleStatus.flags2 &= ~BS_FLAGS2_20; + } + battleStatus->unk_8D = 10; + battleStatus->unk_95 = 0; + battleStatus->hammerLossTurns = -1; + battleStatus->jumpLossTurns = -1; + battleStatus->itemLossTurns = -1; + battleStatus->outtaSightActive = 0; + battleStatus->waterBlockTurnsLeft = 0; + battleStatus->waterBlockAmount = 0; + battleStatus->waterBlockEffect = NULL; + battleStatus->cloudNineTurnsLeft = 0; + battleStatus->cloudNineDodgeChance = 0; + battleStatus->cloudNineEffect = NULL; + battleStatus->unk_92 = 0; + battleStatus->turboChargeTurnsLeft = 0; + battleStatus->turboChargeAmount = 0; + battleStatus->unk_8C = 0; + battleStatus->merleeAttackBoost = 0; + battleStatus->merleeDefenseBoost = 0; + battleStatus->unk_432 = 0; + battleStatus->unk_433 = -1; + battleStatus->hustleTurns = 0; + battleStatus->unk_93 = 0; + battleStatus->unk_94 = 0; + gBattleStatus.flags2 &= ~BS_FLAGS2_2; + gBattleStatus.flags2 &= ~BS_FLAGS2_4; + gBattleStatus.flags2 &= ~BS_FLAGS2_8; + gBattleStatus.flags2 &= ~BS_FLAGS2_10; + gBattleStatus.flags2 &= ~BS_FLAGS2_100; + gBattleStatus.flags2 &= ~BS_FLAGS2_200; + + for (i = 0; i < ARRAY_COUNT(battleStatus->varTable); i++) { + battleStatus->varTable[i] = 0; + } + + D_80280A30 = 255; + battleStatus->inputBitmask = 0xFEF3F; + battleStatus->buffEffect = fx_partner_buff(0, 0.0f, 0.0f, 0.0f, 0.0f, 0); + func_800E9810(); + gCurrentCameraID = CAM_BATTLE; + script = start_script(D_80280EB8, 0xA, 0); + battleStatus->camMovementScript = script; + gBattleState2 = BATTLE_STATE2_UNK_1; + battleStatus->camMovementScriptID = script->id; + break; + case BATTLE_STATE2_UNK_1: + if (!does_script_exist(battleStatus->camMovementScriptID)) { + UiStatus* uiStatus = &gUIStatus; + + if (stage->preBattle != NULL) { + script = start_script(stage->preBattle, 0xA, 0); + battleStatus->controlScript = script; + battleStatus->controlScriptID = script->id; + } + + uiStatus->hidden = 0; + gBattleStatus.flags1 |= BS_FLAGS1_1; + + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + battleStatus->enemyActors[i] = NULL; + } + battleStatus->initialEnemyCount = 0; + + for (i = 0; i < D_8029F240; i++) { + create_actor(&(*battle->formation)[i]); + types = D_80281454; + actor = battleStatus->enemyActors[i]; + + while (TRUE) { + type = *types; + if (type == -1) { + battleStatus->initialEnemyCount++; + break; + } else if (actor->actorType == type) { + break; + } + types++; + } + + actor->unk_208 = 0; + if (i == 0) { + actor->unk_208 = currentEncounter->unk_10; + if (currentEncounter->dizzyAttackStatus == 4) { + inflict_status_set_duration(actor, 4, 0x24, currentEncounter->dizzyAttackDuration); + } + } + } + + if (stage->specialFormationSize != 0 && + (stage->unk_24 == 0 || (stage->unk_24 > 0 && (rand_int(stage->unk_24) == 0)))) + { + D_8029F240 += stage->specialFormationSize; + for (j = 0; i < D_8029F240; i++, j++) { + create_actor(&(*stage->specialFormation)[j]); + actor = battleStatus->enemyActors[i]; + actor->unk_208 = 0; + if (i == 0) { + actor->unk_208 = 0; + if (currentEncounter->dizzyAttackStatus == 4) { + inflict_status_set_duration(actor, 4, 0x24, currentEncounter->dizzyAttackDuration); + } + } + + } + } + + load_player_actor(); + actor = battleStatus->playerActor; + if (gBattleStatus.flags2 & 0x40) { + script = start_script(D_80284A30, 0xA, 0); + } else { + script = start_script(D_80284A20, 0xA, 0); + } + actor->takeTurnScript = script; + actor->takeTurnID = script->id; + script->owner1.actorID = ACTOR_PLAYER; + load_partner_actor(); + gBattleState2 = BATTLE_STATE2_UNK_4; + } + break; + case BATTLE_STATE2_UNK_4: + cond = FALSE; + for (i = 0; i < D_8029F240; i++) { + actor = battleStatus->enemyActors[i]; + if (does_script_exist(actor->takeTurnID)) { + cond = TRUE; + break; + } else { + actor->takeTurnScript = NULL; + } + } + + if (!cond) { + actor = battleStatus->playerActor; + if (!does_script_exist(actor->takeTurnID)) { + actor->takeTurnScript = NULL; + actor = battleStatus->partnerActor; + if (actor != NULL) { + if (!does_script_exist(battleStatus->partnerActor->takeTurnID)) { + actor->takeTurnScript = NULL; + } else { + return; + } + } + + if (battle->unk_10 != 0) { + script = start_script(battle->unk_10, 0xA, 0); + battleStatus->controlScript = script; + battleStatus->controlScriptID = script->id; + } + if (battleStatus->unk_432 > 0) { + set_screen_overlay_color(1, 0, 0, 0); + set_screen_overlay_params_back(0, 215.0f); + } + if (is_ability_active(ABILITY_CHILL_OUT) && currentEncounter->firstStrikeType == FIRST_STRIKE_ENEMY) { + currentEncounter->firstStrikeType = FIRST_STRIKE_NONE; + } + + switch (currentEncounter->firstStrikeType) { + case FIRST_STRIKE_PLAYER: + btl_set_state(BATTLE_STATE_FIRST_STRIKE); + break; + case FIRST_STRIKE_ENEMY: + btl_set_state(BATTLE_STATE_ENEMY_FIRST_STRIKE); + break; + default: + if (!(gGameStatusPtr->demoFlags & 1)) { + actor = battleStatus->playerActor; + if (gBattleStatus.flags2 & 0x40) { + script = start_script(&PeachEnterStage, 0xA, 0); + } else { + script = start_script(&MarioEnterStage, 0xA, 0); + } + actor->takeTurnScript = script; + actor->takeTurnID = script->id; + script->owner1.actorID = ACTOR_PLAYER; + } + + if (currentEncounter->currentEnemy != NULL && + currentEncounter->currentEnemy->encountered == 3 && + is_ability_active(ABILITY_DIZZY_ATTACK)) + { + actor = battleStatus->enemyActors[0]; + script = start_script(&DoDizzyAttack, 0xA, 0); + actor->takeTurnScript = script; + actor->takeTurnID = script->id; + script->owner1.enemyID = ACTOR_ENEMY0; + } + + D_80280A30 = 305; + D_8029F248 = 0; + gBattleState2 = BATTLE_STATE2_UNK_7; + break; + } + } + } + break; + case BATTLE_STATE2_UNK_7: + if (D_80280A30 == 0) { + gBattleState2 = BATTLE_STATE2_UNK_8; + break; + } + + D_8029F248++; + if (D_8029F248 == 15) { + btl_cam_use_preset(BTL_CAM_PRESET_C); + } + + if (!(gGameStatusPtr->demoFlags & 1)) { + D_80280A30 -= 10; + } else { + D_80280A30 -= 50; + } + + if (D_80280A30 < 0) { + D_80280A30 = 0; + } + break; + case BATTLE_STATE2_UNK_8: + if (battleStatus->unk_8C == 0) { + set_screen_overlay_params_front(0xFF, -1.0f); + btl_set_state(BATTLE_STATE_BEGIN_TURN); + } + break; + } +} void btl_state_draw_normal_start(void) { set_screen_overlay_color(0, 0, 0, 0); @@ -218,7 +541,7 @@ void btl_state_update_begin_turn(void) { } if (battleStatus->hustleTurns != 0) { - battleStatus->flags1 |= BS_FLAGS1_4000000; + gBattleStatus.flags1 |= BS_FLAGS1_4000000; } numEnemyActors = 0; @@ -389,12 +712,12 @@ void btl_state_update_begin_player_turn(void) { battleStatus->selectedMoveID = 0; gBattleStatus.flags1 |= BS_FLAGS1_8; gBattleStatus.flags2 &= ~BS_FLAGS2_1000000; - player->unk_21D = 0; + player->disableDismissTimer = 0; player->flags |= 0x0C000000; if (partner != NULL) { player->flags |= 0x0C000000; - partner->unk_21D = 0; + partner->disableDismissTimer = 0; } battleStatus->unk_8C = 0; @@ -422,7 +745,7 @@ void btl_state_update_begin_player_turn(void) { if (gBattleState2 == BATTLE_STATE2_PLAYER_DEFEATED && (battleStatus->unk_8C == 0)) { if (battleStatus->waterBlockTurnsLeft != 0) { battleStatus->waterBlockTurnsLeft--; - battleStatus->buffEffect->data.partnerBuff->unk_0C[FX_BUFF_DATA_WATER_BLOCK].unk_04 = battleStatus->waterBlockTurnsLeft; + battleStatus->buffEffect->data.partnerBuff->unk_0C[FX_BUFF_DATA_WATER_BLOCK].turnsLeft = battleStatus->waterBlockTurnsLeft; if (battleStatus->waterBlockTurnsLeft <= 0) { battleStatus->waterBlockEffect->flags |= 0x10; fx_water_block(1, player->currentPos.x, player->currentPos.y + 18.0f, player->currentPos.z + 5.0f, 1.5f, 10); @@ -448,7 +771,7 @@ void btl_state_update_begin_player_turn(void) { case BATTLE_STATE2_UNK_B: if (battleStatus->cloudNineTurnsLeft != 0) { battleStatus->cloudNineTurnsLeft--; - battleStatus->buffEffect->data.partnerBuff->unk_0C[FX_BUFF_DATA_CLOUD_NINE].unk_04 = battleStatus->cloudNineTurnsLeft; + battleStatus->buffEffect->data.partnerBuff->unk_0C[FX_BUFF_DATA_CLOUD_NINE].turnsLeft = battleStatus->cloudNineTurnsLeft; if (battleStatus->cloudNineTurnsLeft <= 0) { remove_effect(battleStatus->cloudNineEffect); @@ -477,7 +800,7 @@ void btl_state_update_begin_player_turn(void) { gBattleState2 = BATTLE_STATE2_UNK_15; } else { battleStatus->turboChargeTurnsLeft--; - battleStatus->buffEffect->data.partnerBuff->unk_0C[FX_BUFF_DATA_TURBO_CHARGE].unk_04 = battleStatus->turboChargeTurnsLeft; + battleStatus->buffEffect->data.partnerBuff->unk_0C[FX_BUFF_DATA_TURBO_CHARGE].turnsLeft = battleStatus->turboChargeTurnsLeft; if (battleStatus->turboChargeTurnsLeft <= 0) { btl_show_battle_message(0x2B, 60); gBattleState2 = BATTLE_STATE2_UNK_10; @@ -521,8 +844,9 @@ void btl_state_update_begin_player_turn(void) { player->onHitScript = NULL; if (!btl_check_player_defeated()) { D_8029F254 = 0; - player->unk_21D = 0; + player->disableDismissTimer = 0; player->flags |= 0x0C000000; + if (is_ability_active(0xE)) { if (player->debuff != 0) { player->debuffDuration = 1; @@ -536,10 +860,11 @@ void btl_state_update_begin_player_turn(void) { if (player->koStatus != 0) { player->koDuration = 1; } - if (player->transStatus != 0) { - player->transDuration = 1; + if (player->transparentStatus != 0) { + player->transparentDuration = 1; } } + if (player->stoneStatus != 0) { player->stoneDuration--; if (player->stoneDuration <= 0) { @@ -547,7 +872,7 @@ void btl_state_update_begin_player_turn(void) { dispatch_event_player(0x31); } } else { - s32 debuffDuration; + s8 debuffDuration; s32 koDuration; if (!is_ability_active(0x13) && (player->staticStatus != 0)) { @@ -557,11 +882,11 @@ void btl_state_update_begin_player_turn(void) { remove_status_static(player->hudElementDataIndex); } } - if (player->transStatus != 0) { - player->transDuration--; + if (player->transparentStatus != 0) { + player->transparentDuration--; part->flags |= 0x100; - if (player->transDuration <= 0) { - player->transStatus = 0; + if (player->transparentDuration <= 0) { + player->transparentStatus = 0; part->flags &= ~0x100; remove_status_transparent(player->hudElementDataIndex); } @@ -588,13 +913,13 @@ void btl_state_update_begin_player_turn(void) { } } - debuffDuration = (u8) player->debuffDuration; + debuffDuration = player->debuffDuration; koDuration = player->koDuration; player->koDuration = debuffDuration; - if ((s8) debuffDuration > 0) { + if (debuffDuration <= 0) { player->koStatus = 0xD; player->disableEffect->data.disableX->unk_3C = player->koDuration; - } else if (koDuration != (s8) debuffDuration) { + } else if (koDuration != debuffDuration) { player->koStatus = 0; player->koDuration = 0; player->disableEffect->data.disableX->unk_3C = 0; @@ -623,10 +948,10 @@ void btl_state_update_begin_player_turn(void) { } if (gBattleState2 == BATTLE_STATE2_UNK_1) { - s32 phi_s0_2 = 1; - s32 phi_s0_3; - if (!btl_check_enemies_defeated()) { + s32 phi_s0_2 = 1; + s32 phi_s0_3; + battleStatus->unk_8C = 0; if (battleStatus->hammerLossTurns >= 0) { battleStatus->hammerLossTurns--; @@ -649,7 +974,7 @@ void btl_state_update_begin_player_turn(void) { script = start_script(RegainAbility, EVT_PRIORITY_A, 0); player->takeTurnScript = script; player->takeTurnID = script->id; - script->varTable[0] = phi_s0_3; + script->varTable[0] = phi_s0_2; script->owner1.actorID = ACTOR_PLAYER; script->varTable[10] = 0; battleStatus->unk_8C = 1; @@ -670,9 +995,9 @@ void btl_state_update_begin_player_turn(void) { } } gBattleState2 = BATTLE_STATE2_UNK_1E; + } else { + return; } - } else { - return; } if (gBattleState2 == BATTLE_STATE2_UNK_1E && (player->onHitScript == NULL || !does_script_exist(player->onHitID))) { @@ -745,7 +1070,7 @@ void btl_state_update_begin_partner_turn(void) { gBattleState2 = BATTLE_STATE2_PLAYER_DEFEATED; } else if ((battleStatus->flags2 & (BS_FLAGS2_4 | BS_FLAGS2_2)) != (BS_FLAGS2_4 | BS_FLAGS2_2)) { if (!(partner->flags & ACTOR_FLAG_NO_ATTACK)) { - btl_cam_use_preset(2); + btl_cam_use_preset(BTL_CAM_PRESET_C); btl_cam_move(5); gBattleState2 = BATTLE_STATE2_UNK_64; } else { @@ -878,7 +1203,290 @@ void btl_state_update_switch_to_partner(void) { void btl_state_draw_switch_to_partner(void) { } +// some ordering / tail merging / go-to issues +#ifdef NON_MATCHING +void func_80242FE0(void) { + BattleStatus* battleStatus = &gBattleStatus; + Actor* player = battleStatus->playerActor; + Actor* partner = battleStatus->partnerActor; + Actor* actor; + ActorState* state; + Evt* script; + s32 cond; + s32 i; + + s32 oldKoDuration; + + if (gBattleState2 == 0) { + if (gBattleStatus.flags2 & 2) { + if (partner != NULL) { + if (!(gBattleStatus.flags2 & 4) && !(partner->flags & 0x200000)) { + btl_set_state(0xB); + return; + } + } + + player->flags &= 0xF7FFFFFF; + player->flags |= 0x04000000; + if (partner != NULL) { + partner->flags &= 0xF7FFFFFF; + partner->flags |= 0x04000000; + } + + gBattleState2 = 1; + D_8029F258 = 0; + gBattleStatus.flags2 &= ~2; + gBattleStatus.flags2 &= ~4; + gBattleStatus.flags2 &= ~8; + gBattleStatus.flags2 &= ~0x10; + } else { + btl_set_state(0xA); + return; + } + } + + if (gBattleState2 == 1) { + cond = FALSE; + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if ((actor != NULL) && (actor->onHitScript != NULL)) { + if (does_script_exist(actor->onHitID)) { + cond = TRUE; + } else { + actor->onHitScript = NULL; + } + } + } + + if (!cond) { + reset_actor_turn_info(); + + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL) { + actor->flags |= 0x0C000000; + actor->flags &= 0xFFFEFFFF; + + if (actor->debuff != 0) { + if (actor->debuff == 3 || + actor->debuff == 4 || + actor->debuff == 5 || + actor->debuff == 6 || + actor->debuff == 7 || + actor->debuff == 8) + { + actor->flags |= 0x10000; + } + actor->debuffDuration--; + if (actor->debuffDuration <= 0) { + actor->debuff = 0; + remove_status_debuff(actor->hudElementDataIndex); + dispatch_event_actor(actor, 0x31); + D_8029F258 = 0x14; + } + } + + if (actor->staticStatus != 0) { + actor->staticDuration--; + if (actor->staticDuration <= 0) { + actor->staticStatus = 0; + remove_status_static(actor->hudElementDataIndex); + D_8029F258 = 0x14; + } + } + + if (actor->transparentStatus != 0) { + actor->transparentDuration--; + if (actor->transparentDuration <= 0) { + actor->transparentStatus = 0; + remove_status_transparent(actor->hudElementDataIndex); + D_8029F258 = 0x14; + } + } + + if (actor->stoneStatus != 0) { + actor->stoneDuration--; + if (actor->stoneDuration <= 0) { + actor->stoneStatus = 0; + D_8029F258 = 0x14; + } + } + + oldKoDuration = actor->koDuration; + actor->koDuration = actor->debuffDuration; + if (actor->koDuration > 0) { + actor->koStatus = 0xD; + actor->disableEffect->data.disableX->unk_3C = actor->koDuration; + } else if (oldKoDuration != actor->koDuration) { + actor->koStatus = 0; + actor->disableEffect->data.disableX->unk_3C = 0; + } + if (actor->debuff == 9) { + gBattleStatus.flags1 |= 0x20; + dispatch_damage_event_actor_0(actor, 1, 0xA); + D_8029F258 = 0x14; + } + } + } + gBattleState2 = 2; + } + } + + if (gBattleState2 == 2 && (player->onHitScript == NULL || !does_script_exist(player->onHitID))) { + player->onHitScript = NULL; + if (partner != NULL) { + if ((partner->onHitScript == NULL) || !does_script_exist(partner->onHitID)) { + partner->onHitScript = NULL; + goto block_52; + } + } else { +block_52: + cond = FALSE; + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if ((actor != NULL) && (actor->onHitScript != NULL)) { + if (does_script_exist(actor->onHitID)) { + cond = TRUE; + } else { + actor->onHitScript = NULL; + } + } + } + + if (!cond) { + if (btl_check_player_defeated() || btl_check_enemies_defeated()) { + return; + } + + btl_cam_use_preset(2); + if (partner == NULL || !(gBattleStatus.flags1 & 0x100000)) { + gBattleState2 = 4; + } else if (gBattleStatus.flags2 & 0x40) { + gBattleState2 = 4; + } else { + player->flags &= 0xF7FFFFFF; + partner->flags &= 0xF7FFFFFF; + player->flags |= 0x04000000; + partner->flags |= 0x04000000; + state = &partner->state; + if (!battleStatus->outtaSightActive) { + partner->state.currentPos.x = partner->homePos.x; + partner->state.currentPos.z = partner->homePos.z; + partner->state.goalPos.x = player->homePos.x; + partner->state.goalPos.z = player->homePos.z; + } else { + partner->state.currentPos.x = partner->homePos.x; + partner->state.currentPos.z = partner->homePos.z; + partner->state.goalPos.x = partner->homePos.x; + partner->state.goalPos.z = partner->homePos.z + 5.0f; + partner->homePos.x = player->homePos.x; + partner->homePos.z = player->homePos.z; + } + state->moveTime = 4; + state->angle = 0.0f; + gBattleState2 = 3; + } + } + } + } + + if (gBattleState2 == 3) { + if (partner->state.moveTime != 0) { + partner->currentPos.x += (partner->state.goalPos.x - partner->currentPos.x) / partner->state.moveTime; + partner->currentPos.z += (partner->state.goalPos.z - partner->currentPos.z) / partner->state.moveTime; + player->currentPos.x += (partner->state.currentPos.x - player->currentPos.x) / partner->state.moveTime; + player->currentPos.z += (partner->state.currentPos.z - player->currentPos.z) / partner->state.moveTime; + } + partner->currentPos.z -= sin_rad((partner->state.angle * TAU) / 360.0f) * 16.0f; + partner->yaw = clamp_angle(partner->state.angle); + player->currentPos.z += sin_rad((partner->state.angle * TAU) / 360.0f) * 16.0f; + player->yaw = clamp_angle(partner->state.angle); + partner->state.angle += 90.0f; + + if (partner->state.moveTime != 0) { + partner->state.moveTime--; + } else { + partner->currentPos.x = partner->state.goalPos.x; + partner->currentPos.z = partner->state.goalPos.z; + player->currentPos.x = partner->state.currentPos.x; + player->currentPos.z = partner->state.currentPos.z; + if (!battleStatus->outtaSightActive ) { + partner->homePos.x = partner->currentPos.x; + partner->homePos.z = partner->currentPos.z; + } + player->homePos.x = player->currentPos.x; + player->homePos.z = player->currentPos.z; + gBattleState2 = 4; + gBattleStatus.flags1 &= 0xFFEFFFFF; + } + } + + if (gBattleState2 == 4) { + if (D_8029F258 != 0) { + D_8029F258--; + } else { + if (battleStatus->nextMerleeSpellType == 2) { + battleStatus->merleeDefenseBoost = 3; + battleStatus->nextMerleeSpellType = 0; + battleStatus->battlePhase = PHASE_MERLEE_DEFENSE_BONUS; + script = start_script(PlayerScriptDispatcher, 0xA, 0); + player->takeTurnScript = script; + player->takeTurnID = script->id; + script->owner1.actorID = ACTOR_PLAYER; + } + gBattleStatus.flags1 &= ~2; + player->flags &= 0xF7FFFFFF; + player->flags |= 0x04000000; + if (partner != NULL) { + partner->flags &= 0xF7FFFFFF; + partner->flags |= 0x04000000; + } + gBattleState2 = 5; + gBattleStatus.flags2 &= ~2; + gBattleStatus.flags2 &= ~4; + gBattleStatus.flags2 &= ~8; + gBattleStatus.flags2 &= ~0x10; + } + } + + if (gBattleState2 == 5) { + if ((player->takeTurnScript == NULL) || (does_script_exist(player->takeTurnID) == 0)) { + player->takeTurnScript = NULL; + + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL && actor->onTurnChanceScriptSource != NULL) { + battleStatus->battlePhase = PHASE_PLAYER_END; + script = start_script(actor->onTurnChanceScriptSource, 0xA, 0); + actor->onTurnChangeScript = script; + actor->onTurnChangeID = script->id; + script->owner1.enemyID = i | 0x200; + } + } + gBattleState2 = 6; + } + } + + cond = FALSE; + if (gBattleState2 == 6) { + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL && actor->onTurnChanceScriptSource != NULL && does_script_exist(actor->onTurnChangeID)) { + cond = TRUE; + } + } + if (!cond) { + gBattleState2 = 7; + } + } + + if (gBattleState2 == 7) { + btl_set_state(0x14); + } +} +#else INCLUDE_ASM(s32, "16F740", func_80242FE0); +#endif void func_80243910(void) { } @@ -913,7 +1521,168 @@ void btl_state_update_prepare_menu(void) { void btl_state_draw_prepare_menu(void) { } -INCLUDE_ASM(s32, "16F740", btl_state_update_end_turn); +void btl_state_update_end_turn(void) { + BattleStatus* battleStatus = &gBattleStatus; + PlayerData* playerData = &gPlayerData; + Actor* player = battleStatus->playerActor; + Actor* partner = battleStatus->partnerActor; + Actor* actor; + Evt* script; + s32 i; + + if (gBattleState2 == BATTLE_STATE2_UNK_0) { + s32 cond = FALSE; + + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL && actor->onHitScript != NULL) { + if (does_script_exist(actor->onHitID)) { + do { + cond = TRUE; + } while (0); // TODO required to match + } else { + actor->onHitScript = NULL; + } + } + } + + if (!cond) { + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL && actor->takeTurnScript != NULL) { + if (does_script_exist(actor->takeTurnID)) { + cond = TRUE; + } else { + actor->takeTurnScript = NULL; + } + } + } + + if (!cond) { + btl_cam_use_preset(BTL_CAM_PRESET_C); + gBattleState2 = BATTLE_STATE2_UNK_1; + } + } + } + + if (gBattleState2 == BATTLE_STATE2_UNK_1) { + if (gBattleStatus.flags2 & BS_FLAGS2_40) { + gBattleState2 = BATTLE_STATE2_UNK_C; + } else if (!(gBattleStatus.flags1 & BS_FLAGS1_100000)) { + gBattleState2 = BATTLE_STATE2_UNK_C; + } else { + player->flags &= ~ACTOR_FLAG_8000000; + partner->flags &= ~ACTOR_FLAG_8000000; + player->flags |= ACTOR_FLAG_4000000; + partner->flags |= ACTOR_FLAG_4000000; + partner->state.currentPos.x = partner->homePos.x; + partner->state.currentPos.z = partner->homePos.z; + partner->state.goalPos.x = player->homePos.x; + partner->state.goalPos.z = player->homePos.z; + partner->state.moveTime = 4; + partner->state.angle = 0.0f; + gBattleState2 = BATTLE_STATE2_UNK_B; + } + } + + if (gBattleState2 == BATTLE_STATE2_UNK_B) { + if (partner->state.moveTime != 0) { + partner->currentPos.x += (partner->state.goalPos.x - partner->currentPos.x) / partner->state.moveTime; + partner->currentPos.z += (partner->state.goalPos.z - partner->currentPos.z) / partner->state.moveTime; + player->currentPos.x += (partner->state.currentPos.x - player->currentPos.x) / partner->state.moveTime; + player->currentPos.z += (partner->state.currentPos.z - player->currentPos.z) / partner->state.moveTime; + } + partner->currentPos.z -= sin_rad((partner->state.angle * TAU) / 360.0f) * 16.0f; + partner->yaw = clamp_angle(partner->state.angle); + player->currentPos.z += sin_rad((partner->state.angle * TAU) / 360.0f) * 16.0f; + player->yaw = clamp_angle(partner->state.angle); + partner->state.angle += 90.0f; + if (partner->state.moveTime != 0) { + partner->state.moveTime--; + } else { + partner->currentPos.x = partner->state.goalPos.x; + partner->currentPos.z = partner->state.goalPos.z; + player->currentPos.x = partner->state.currentPos.x; + player->currentPos.z = partner->state.currentPos.z; + partner->homePos.x = partner->currentPos.x; + partner->homePos.z = partner->currentPos.z; + player->homePos.x = player->currentPos.x; + player->homePos.z = player->currentPos.z; + player->flags |= ACTOR_FLAG_8000000; + partner->flags |= ACTOR_FLAG_8000000; + if (gBattleStatus.flags2 & BS_FLAGS2_40) { + gBattleStatus.flags1 |= BS_FLAGS1_100000; + } else { + gBattleStatus.flags1 &= ~BS_FLAGS1_100000; + } + gBattleState2 = BATTLE_STATE2_UNK_C; + } + } + + if (gBattleState2 == BATTLE_STATE2_UNK_C) { + gBattleStatus.flags2 &= ~BS_FLAGS2_10000; + player->disableDismissTimer = 0; + player->flags |= ACTOR_FLAG_8000000 | ACTOR_FLAG_4000000; + if (partner != NULL) { + player->flags |= ACTOR_FLAG_8000000 | ACTOR_FLAG_4000000; + partner->disableDismissTimer = 0; + } + + func_80260A60(); + gBattleStatus.flags1 &= ~BS_FLAGS1_PLAYER_DEFENDING; + playerData->specialBarsFilled += 32; + if (playerData->specialBarsFilled > playerData->maxStarPower * 256) { + playerData->specialBarsFilled = playerData->maxStarPower * 256; + } + + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL && actor->onTurnChanceScriptSource != NULL) { + battleStatus->battlePhase = PHASE_ENEMY_END; + script = start_script(actor->onTurnChanceScriptSource, 0xA, 0); + actor->onTurnChangeScript = script; + actor->onTurnChangeID = script->id; + script->owner1.enemyID = i | ACTOR_ENEMY0; + } + } + + if (partner != NULL && partner->onTurnChanceScriptSource != NULL) { + battleStatus->battlePhase = PHASE_ENEMY_END; + script = start_script(partner->onTurnChanceScriptSource, 0xA, 0); + partner->onTurnChangeScript = script; + partner->onTurnChangeID = script->id; + script->owner1.actorID = ACTOR_PARTNER; + } + gBattleState2 = BATTLE_STATE2_UNK_2; + } + + if (gBattleState2 == BATTLE_STATE2_UNK_2) { + s32 cond = FALSE; + + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL && actor->onTurnChanceScriptSource != NULL && does_script_exist(actor->onTurnChangeID)) { + cond = TRUE; + } + } + + if (partner != NULL && partner->onTurnChanceScriptSource != NULL && does_script_exist(partner->onTurnChangeID)) { + cond = TRUE; + } + + if (!cond) { + btl_cam_use_preset(BTL_CAM_PRESET_C); + gBattleState2 = BATTLE_STATE2_UNK_3; + } + } + + switch (gBattleState2) { + case 3: + case 4: + btl_set_state(5); + break; + } +} void btl_state_draw_end_turn(void) { } @@ -1103,7 +1872,7 @@ void btl_state_update_victory(void) { } } - if (gBattleState2 == BATTLE_STATE2_UNK_4 && (s8) battleStatus->pendingStarPoints <= 0) { + if (gBattleState2 == BATTLE_STATE2_UNK_4 && battleStatus->pendingStarPoints <= 0) { if (gBattleStatus.flags1 & BS_FLAGS1_1000000) { gBattleStatus.flags1 &= ~BS_FLAGS1_40000; } @@ -1767,12 +2536,537 @@ void btl_state_update_change_partner(void) { void btl_state_draw_change_partner(void) { } -INCLUDE_ASM(s32, "16F740", btl_state_update_player_move); +void btl_state_update_player_move(void) { + BattleStatus* battleStatus = &gBattleStatus; + Actor* player = battleStatus->playerActor; + Actor* partner = battleStatus->partnerActor; + s32 messageIndex; + Actor* actor; + Evt* script; + s32 cond; + s8 temp_a0; + s32 i; + + if (gBattleState2 == BATTLE_STATE2_UNK_0) { + battleStatus->unk_86 = 0x7F; + battleStatus->blockResult = 0x7F; + battleStatus->unk_8C = 0; + battleStatus->lastAttackDamage = 0; + battleStatus->unk_19A = 0; + gBattleStatus.flags1 &= ~BS_FLAGS1_1000; + gBattleStatus.flags1 &= ~BS_FLAGS1_2; + reset_actor_turn_info(); + player->flags &= ~ACTOR_FLAG_8000000; + if (partner != NULL) { + partner->flags &= ~ACTOR_FLAG_8000000; + } + btl_cam_target_actor(0); + gBattleStatus.flags1 &= ~BS_FLAGS1_8; + player->status = 0; + gBattleStatus.flags2 |= BS_FLAGS2_8; + gBattleStatus.flags1 &= ~BS_FLAGS1_200000; + + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL) { + actor->status = 0; + } + } + + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL) { + actor->flags &= ~ACTOR_FLAG_80000; + actor->flags &= ~ACTOR_FLAG_8000000; + } + } + + if (battleStatus->moveCategory == 0 || battleStatus->moveCategory == 1) { + if (battleStatus->nextMerleeSpellType == 1) { + battleStatus->merleeAttackBoost = 3; + battleStatus->nextMerleeSpellType = 0; + battleStatus->battlePhase = PHASE_MERLEE_ATTACK_BONUS; + script = start_script(&PlayerScriptDispatcher, 0xA, 0); + player->takeTurnScript = script; + player->takeTurnID = script->id; + script->owner1.actorID = ACTOR_PLAYER; + gBattleStatus.flags1 |= BS_FLAGS1_10000; + close_action_command_instruction_popup(); + gBattleState2 = BATTLE_STATE2_UNK_1; + } else { + gBattleState2 = BATTLE_STATE2_UNK_3; + gBattleStatus.flags1 &= ~BS_FLAGS1_2; + } + } else { + gBattleState2 = BATTLE_STATE2_UNK_3; + gBattleStatus.flags1 &= ~BS_FLAGS1_2; + } + } + + switch (gBattleState2) { + case BATTLE_STATE2_UNK_1: + if (player->takeTurnScript == NULL || !does_script_exist(player->takeTurnID)) { + player->takeTurnScript = NULL; + if (!is_ability_active(ABILITY_BERSERKER)) { + if (battleStatus->selectedMoveID != MOVE_NONE) { + temp_a0 = gMoveTable[battleStatus->selectedMoveID].actionTip; + if (temp_a0 >= 0) { + btl_show_battle_message(temp_a0 + 0x2E, 60); + } + } + } + D_8029F248 = 2; + gBattleState2 = BATTLE_STATE2_UNK_2; + } + break; + case BATTLE_STATE2_UNK_2: + if (D_8029F248 != 0) { + D_8029F248--; + } else { + gBattleState2 = BATTLE_STATE2_UNK_3; + } + break; + } + + switch (gBattleState2) { + case BATTLE_STATE2_UNK_3: + gBattleStatus.flags1 &= ~BS_FLAGS1_4000; + gBattleStatus.flags1 &= ~BS_FLAGS1_10000; + increment_status_menu_disabled(); + gBattleStatus.flags1 |= BS_FLAGS1_100; + reset_all_actor_sounds(player); + battleStatus->battlePhase = PHASE_EXECUTE_ACTION; + if (gBattleStatus.flags2 & BS_FLAGS2_40) { + script = start_script(&PeachScriptDispatcher, 0xA, 0); + } else { + script = start_script(&PlayerScriptDispatcher, 0xA, 0); + } + player->takeTurnScript = script; + gBattleState2 = BATTLE_STATE2_UNK_4; + player->takeTurnID = script->id; + script->owner1.actorID = ACTOR_PLAYER; + break; + case BATTLE_STATE2_UNK_4: + if (!(gBattleStatus.flags1 & BS_FLAGS1_200000)) { + if (player->takeTurnScript != NULL && does_script_exist(player->takeTurnID)) { + break; + } + player->takeTurnScript = NULL; + } + + gBattleStatus.flags1 &= ~BS_FLAGS1_100; + if (player->onHitScript == NULL || !does_script_exist(player->onHitID)) { + player->onHitScript = NULL; + if (partner != NULL) { + if (partner->onHitScript != NULL && does_script_exist(partner->onHitID)) { + break; + } + partner->onHitScript = NULL; + } + + cond = FALSE; + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL && actor->takeTurnScript != NULL) { + if (does_script_exist(actor->takeTurnID)) { + cond = TRUE; + } else { + actor->takeTurnScript = NULL; + } + } + } + + if (!cond) { + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL && actor->onHitScript != NULL) { + if (does_script_exist(actor->onHitID)) { + cond = TRUE; + } else { + actor->onHitScript = NULL; + } + } + } + + if (!cond) { + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL) { + actor->flags &= ~ACTOR_FLAG_80000; + } + } + + if (battleStatus->unk_8C == 0) { + if (gGameStatusPtr->demoFlags & 1) { + btl_set_state(BATTLE_STATE_END_DEMO_BATTLE); + break; + } + decrement_status_menu_disabled(); + gBattleStatus.flags1 |= BS_FLAGS1_8; + gBattleStatus.flags2 &= ~BS_FLAGS2_8; + if (btl_check_player_defeated()) { + return; + } + + if (battleStatus->moveCategory == 1) { + if ((battleStatus->selectedMoveID != MOVE_SMASH_CHARGE0) && + (battleStatus->selectedMoveID != MOVE_SMASH_CHARGE) && + (battleStatus->selectedMoveID != MOVE_SUPER_SMASH_CHARGE)) + { + gBattleStatus.flags1 &= ~BS_FLAGS1_10000000; + } + } + if (battleStatus->moveCategory == 0) { + if ((battleStatus->selectedMoveID != MOVE_JUMP_CHARGE0) && + (battleStatus->selectedMoveID != MOVE_JUMP_CHARGE) && + (battleStatus->selectedMoveID != MOVE_SUPER_JUMP_CHARGE)) + { + gBattleStatus.flags1 &= ~BS_FLAGS1_20000000; + } + } + + if (!(gBattleStatus.flags1 & BS_FLAGS1_20000000)) { + battleStatus->jumpCharge = 0; + } + if (!(gBattleStatus.flags1 & BS_FLAGS1_10000000)) { + battleStatus->hammerCharge = 0; + } + + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL && !(actor->flags & ACTOR_FLAG_NO_DMG_APPLY)) { + actor->flags |= ACTOR_FLAG_8000000 | ACTOR_FLAG_4000000; + } + } + + cond = FALSE; + btl_update_ko_status(); + + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL) { + if (actor->status != 0) { + cond = TRUE; + break; + } + } + } + + if (!cond) { + gBattleState2 = BATTLE_STATE2_UNK_14; + } else { + btl_cam_use_preset(BTL_CAM_PRESET_D); + switch (actor->status) { + case 4: + messageIndex = 0x12; + break; + case 6: + messageIndex = 0x13; + break; + case 7: + messageIndex = 0x14; + break; + case 9: + messageIndex = 0x15; + break; + case 10: + messageIndex = 0x16; + break; + case 5: + messageIndex = 0x17; + break; + case 11: + messageIndex = 0x18; + break; + case 8: + messageIndex = 0x19; + break; + default: + messageIndex = 0; + gBattleState2 = BATTLE_STATE2_UNK_14; + break; + } + sfx_play_sound(SOUND_2107); + btl_show_battle_message(messageIndex, 60); + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL) { + actor->status = 0; + } + } + gBattleState2 = BATTLE_STATE2_UNK_B; + } + } + } + } + } + break; + case BATTLE_STATE2_UNK_B: + if (!btl_is_popup_displayed()) { + btl_cam_use_preset(BTL_CAM_PRESET_C); + btl_cam_move(15); + D_8029F248 = 10; + gBattleState2 = BATTLE_STATE2_UNK_C; + } + break; + case BATTLE_STATE2_UNK_C: + if (D_8029F248 != 0) { + D_8029F248--; + } else { + gBattleState2 = BATTLE_STATE2_UNK_14; + } + break; + } + + switch (gBattleState2) { + case BATTLE_STATE2_UNK_14: + if (player->status != 0) { + btl_cam_use_preset(BTL_CAM_PRESET_33); + switch (player->status) { + case 4: + messageIndex = 0xA; + break; + case 6: + messageIndex = 0xB; + break; + case 7: + messageIndex = 0xC; + break; + case 9: + messageIndex = 0xD; + break; + case 10: + messageIndex = 0xE; + break; + case 5: + messageIndex = 0xF; + break; + case 11: + messageIndex = 0x10; + break; + default: + messageIndex = 0; + gBattleState2 = BATTLE_STATE2_UNK_1E; + break; + } + btl_show_battle_message(messageIndex, 60); + player->status = 0; + player->disableDismissTimer = 0; + gBattleState2 = BATTLE_STATE2_UNK_15; + player->flags |= ACTOR_FLAG_8000000; + } else { + gBattleState2 = BATTLE_STATE2_UNK_1E; + } + break; + case BATTLE_STATE2_UNK_15: + if (!btl_is_popup_displayed()) { + btl_cam_use_preset(BTL_CAM_PRESET_C); + btl_cam_move(15); + D_8029F248 = 10; + gBattleState2 = BATTLE_STATE2_UNK_16; + } + break; + case BATTLE_STATE2_UNK_16: + if (D_8029F248 != 0) { + D_8029F248--; + } else { + gBattleState2 = BATTLE_STATE2_UNK_1E; + } + break; + } + + if (gBattleState2 == BATTLE_STATE2_UNK_1E && + (player->takeTurnScript == NULL || !does_script_exist(player->takeTurnID))) + { + player->takeTurnScript = NULL; + btl_set_state(BATTLE_STATE_END_PLAYER_TURN); + } +} void btl_state_draw_player_move(void) { } +// control flow +#ifdef NON_MATCHING +void btl_state_update_end_player_turn(void) { + BattleStatus* battleStatus = &gBattleStatus; + Actor* player = battleStatus->playerActor; + Actor* partner = battleStatus->partnerActor; + Evt* script; + + if (gBattleState2 == 0) { + if ((battleStatus->moveCategory == 2) && (battleStatus->itemUsesLeft >= 2)) { + gBattleState2 = 5; + } else if ( + ((gBattleStatus.flags2 & 0x04000000) || + is_ability_active(0x12) || + is_ability_active(0x1F) || + is_ability_active(0x34) + ) && + player->stoneStatus != 0xC && + !battleStatus->outtaSightActive) + { + s32 prevHPDrainCount = 0; + s32 var_s2 = 0; + s32 var_s4 = 0; + + if (gBattleStatus.flags2 & 0x04000000) { + prevHPDrainCount = battleStatus->hpDrainCount; + battleStatus->hpDrainCount = 0; + } + + if (rand_int(100) < 50) { + var_s2 = is_ability_active(0x1F) * 3; + } + if (rand_int(100) < 50) { + var_s2 += is_ability_active(0x12); + } + if (rand_int(100) < 50) { + var_s4 = is_ability_active(0x34); + } + + if (prevHPDrainCount + var_s2 + var_s4 == 0) { + gBattleState2 = 5; + } else { + battleStatus->battlePhase = PHASE_PLAYER_HAPPY; + script = start_script(&PlayerScriptDispatcher, 0xA, 0); + player->takeTurnScript = script; + player->takeTurnID = script->id; + script->owner1.actorID = ACTOR_PLAYER; + if (gBattleStatus.flags2 & 0x04000000) { + script->varTable[10] += battleStatus->hpDrainCount; + battleStatus->hpDrainCount = 0; + } + script->varTable[10] = prevHPDrainCount; + script->varTable[11] = var_s2; + script->varTable[12] = var_s4; + + if (script->varTable[10] > 99) { + script->varTable[10] = 99; + } + if (script->varTable[11] > 99) { + script->varTable[11] = 99; + } + if (script->varTable[12] > 99) { + script->varTable[12] = 99; + } + + gBattleStatus.flags2 &= 0xFBFFFFFF; + gBattleState2 = 5; + } + } else { + gBattleState2 = 5; + } + } + + if (gBattleState2 == 5) { + if ((player->takeTurnScript == NULL) || (does_script_exist(player->takeTurnID) == 0)) { + player->takeTurnScript = NULL; + if (!(gBattleStatus.flags2 & 0x40) || (gBattleStatus.flags1 & 0x100000)) { + gBattleState2 = 0xA; + } else { + player->state.currentPos.x = player->homePos.x; + player->state.currentPos.z = player->homePos.z; + player->state.goalPos.x = partner->homePos.x; + player->state.goalPos.z = partner->homePos.z; + player->state.moveTime = 4; + player->state.angle = 0.0f; + gBattleState2 = 6; + } + } + } + + if (gBattleState2 == 6) { + if (player->state.moveTime != 0) { + player->currentPos.x += (player->state.goalPos.x - player->currentPos.x) / player->state.moveTime; + player->currentPos.z += (player->state.goalPos.z - player->currentPos.z) / player->state.moveTime; + partner->currentPos.x += (player->state.currentPos.x - partner->currentPos.x) / player->state.moveTime; + partner->currentPos.z += (player->state.currentPos.z - partner->currentPos.z) / player->state.moveTime; + } + player->currentPos.z += sin_rad((player->state.angle * TAU) / 360.0f) * 16.0f; + player->yaw = clamp_angle(-player->state.angle); + partner->currentPos.z -= sin_rad((player->state.angle * TAU) / 360.0f) * 16.0f; + partner->yaw = clamp_angle(-player->state.angle); + player->state.angle += 90.0f; + + if (player->state.moveTime != 0) { + player->state.moveTime--; + } else { + player->currentPos.x = player->state.goalPos.x; + player->currentPos.z = player->state.goalPos.z; + partner->currentPos.x = player->state.currentPos.x; + partner->currentPos.z = player->state.currentPos.z; + player->homePos.x = player->currentPos.x; + player->homePos.z = player->currentPos.z; + partner->homePos.x = partner->currentPos.x; + partner->homePos.z = partner->currentPos.z; + gBattleStatus.flags1 |= 0x100000; + gBattleState2 = 0xA; + } + } + + if (gBattleState2 == 0xA && !btl_check_enemies_defeated()) { + if (battleStatus->moveCategory == 2 && battleStatus->itemUsesLeft >= 2) { + btl_cam_use_preset(2); + btl_cam_move(0xA); + gBattleStatus.flags2 &= ~2; + } else { + gBattleStatus.flags2 |= 2; + } + + if (battleStatus->unk_94 < 0) { + battleStatus->unk_94 = 0; + battleStatus->itemUsesLeft = 0; + btl_set_state(6); + return; + } + + if (battleStatus->itemUsesLeft != 0) { + battleStatus->itemUsesLeft--; + if (battleStatus->itemUsesLeft != 0) { + btl_set_state(0xC); + gBattleState2 = 0x46; + return; + } + + if (gBattleStatus.flags1 & 0x04000000) { + if (battleStatus->hustleTurns != 0) { + battleStatus->hustleTurns--; + } + } + + if (battleStatus->hustleTurns != 0 && (gBattleStatus.flags1 & 0x04000000)) { + gBattleStatus.flags2 &= ~2; + btl_set_state(0xC); + } else { + gBattleStatus.flags1 &= 0xFBFFFFFF; + btl_set_state(8); + } + return; + } + + if (gBattleStatus.flags1 & 0x04000000) { + if (battleStatus->hustleTurns != 0) { + battleStatus->hustleTurns--; + } + } + + if ((battleStatus->hustleTurns != 0) && (gBattleStatus.flags1 & 0x04000000)) { + gBattleStatus.flags2 &= ~2; + btl_set_state(0xC); + } else { + gBattleStatus.flags1 &= 0xFBFFFFFF; + if (!(gBattleStatus.flags2 & 0x40)) { + btl_set_state(8); + } else { + btl_set_state(9); + } + } + } +} +#else INCLUDE_ASM(s32, "16F740", btl_state_update_end_player_turn); +#endif void btl_state_draw_end_player_turn(void) { } @@ -1907,7 +3201,7 @@ void btl_state_update_partner_move(void) { btl_update_ko_status(); - if ((s8) partner->status == 0xD && btl_are_all_enemies_defeated() == FALSE) { + if (partner->status == 0xD && !btl_are_all_enemies_defeated()) { btl_cam_use_preset(BTL_CAM_PRESET_54); btl_show_battle_message(0x23, 60); partner->status = 0; @@ -1929,7 +3223,7 @@ void btl_state_update_partner_move(void) { if (btl_is_popup_displayed() == FALSE) { btl_cam_use_preset(BTL_CAM_PRESET_C); btl_cam_move(15); - D_8029F248 = 0xA; + D_8029F248 = 10; gBattleState2 = BATTLE_STATE2_UNK_C; } break; @@ -2445,7 +3739,7 @@ void btl_state_update_first_strike(void) { battleStatus->currentTargetListFlags = gMoveTable[MOVE_UNUSED_HAMMER4].flags; break; case 6: - btl_set_state(3); + btl_set_state(BATTLE_STATE_PARTNER_FIRST_STRIKE); return; } @@ -2776,34 +4070,24 @@ void btl_state_draw_partner_striking_first(void) { } } -// ugly loops and such -#ifdef NON_EQUIVALENT void btl_state_update_enemy_striking_first(void) { PlayerData* playerData = &gPlayerData; BattleStatus* battleStatus = &gBattleStatus; Actor* player = battleStatus->playerActor; Actor* partner = battleStatus->partnerActor; Evt* script; - Actor* enemy; + Actor* actor; + u16* enemyIDs; + s16 activeEnemyActorID; + s32 nextEnemyIdx; + s32 count; + s32 flags; s32 cond; s32 i; s32 j; - Actor* temp_s0; - s32 temp_t0; - s32 temp_a1; - s16* temp_t4; - s16* var_a2; - s16* var_t3; - s32 temp_v0; - s32 var_a3; - s32 var_t2; - - s32 nextEnemyIdx; - s32 count; - switch (gBattleState2) { - case 0: + case BATTLE_STATE2_UNK_0: battleStatus->unk_8C = 0; battleStatus->lastAttackDamage = 0; battleStatus->unk_19A = 0; @@ -2814,128 +4098,112 @@ void btl_state_update_enemy_striking_first(void) { if (partner != NULL) { partner->flags &= ~ACTOR_FLAG_8000000; } - battleStatus->flags2 |= 0x01000000 | 0x4000; + battleStatus->flags2 |= BS_FLAGS2_1000000 | BS_FLAGS2_4000; count = 0; + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { - if (battleStatus->enemyActors[i] != NULL) { - battleStatus->enemyIDs[i] = i | 0x200; + actor = battleStatus->enemyActors[i]; + if (actor != NULL) { + battleStatus->enemyIDs[count] = i | ACTOR_ENEMY0; count++; } } battleStatus->numEnemyActors = count; - // for (i = 0; i < count - 1; i++) { - // for (j = i + 1; j < count; j++) { - // s32 temp_t0; - // s32 temp_a1; - // temp_t0 = battleStatus->enemyActors[battleStatus->enemyIDs[i]]->turnPriority; - // temp_a1 = battleStatus->enemyActors[battleStatus->enemyIDs[j]]->turnPriority; - // if (temp_t0 < temp_a1) { - // battleStatus->enemyActors[battleStatus->enemyIDs[i]]->turnPriority = temp_a1; - // battleStatus->enemyActors[battleStatus->enemyIDs[j]]->turnPriority = temp_t0; - // } - // } - // } + enemyIDs = battleStatus->enemyIDs; + for (i = 0; i < count - 1; i++) { + for (j = i + 1; j < count; j++) { + s32 iVal = enemyIDs[i]; + s32 jVal = enemyIDs[j]; - i = 0; - temp_v0 = var_t2 - 1; - temp_t4 = battleStatus->enemyIDs; - if (temp_v0 > 0) { - var_t3 = temp_t4; - do { - var_a3 = i + 1; - if (var_a3 < var_t2) { - var_a2 = &temp_t4[var_a3]; - do { - temp_t0 = (u16) *var_t3; - temp_a1 = (u16) *var_a2; - var_a3 += 1; - if (battleStatus->enemyActors[temp_t0 & 0xFF]->turnPriority < battleStatus->enemyActors[temp_a1 & 0xFF]->turnPriority) { - *var_t3 = temp_a1; - *var_a2 = temp_t0; - } - var_a2 += 2; - } while (var_a3 < var_t2); + if (battleStatus->enemyActors[iVal & 0xFF]->turnPriority < + battleStatus->enemyActors[jVal & 0xFF]->turnPriority) + { + enemyIDs[i] = jVal; + enemyIDs[j] = iVal; } - i++; - var_t3 += 2; - } while (i < temp_v0); + } } battleStatus->nextEnemyIndex = 0; - i = 0; - loop_18: - loop_19: - temp_s0 = battleStatus->enemyActors[battleStatus->enemyIDs[i]]; - if (temp_s0 == NULL) { - block_21: - i++; - if (i >= battleStatus->numEnemyActors) { - i = 0; - goto loop_18; + nextEnemyIdx = 0; + flags = ACTOR_FLAG_NO_ATTACK | ACTOR_FLAG_TARGET_ONLY; + + while (TRUE) { + actor = battleStatus->enemyActors[battleStatus->enemyIDs[nextEnemyIdx] & 0xFF]; + if (actor == NULL || (actor->flags & flags)) { + nextEnemyIdx++; + if (nextEnemyIdx >= battleStatus->numEnemyActors) { + nextEnemyIdx = 0; + } + } else { + break; } - goto loop_19; - } - if (temp_s0->flags & 0x204000) { - goto block_21; } - nextEnemyIdx = i + 1; - battleStatus->currentTurnEnemy = enemy; - battleStatus->activeEnemyActorID = battleStatus->enemyIDs[i]; + activeEnemyActorID = battleStatus->enemyIDs[nextEnemyIdx]; + nextEnemyIdx++; + battleStatus->currentTurnEnemy = actor; + battleStatus->activeEnemyActorID = activeEnemyActorID; if (nextEnemyIdx >= battleStatus->numEnemyActors) { nextEnemyIdx = 0; } battleStatus->nextEnemyIndex = nextEnemyIdx; btl_cam_target_actor(battleStatus->activeEnemyActorID); - enemy = battleStatus->currentTurnEnemy; + actor = battleStatus->currentTurnEnemy; reset_actor_turn_info(); battleStatus->battlePhase = PHASE_FIRST_STRIKE; - script = start_script(enemy->takeTurnScriptSource, EVT_PRIORITY_A, 0); - enemy->takeTurnScript = script; + script = start_script(actor->takeTurnScriptSource, EVT_PRIORITY_A, 0); + actor->takeTurnScript = script; D_8029F248 = 3; - enemy->takeTurnID = script->id; - gBattleState2 = 2; + actor->takeTurnID = script->id; + gBattleState2 = BATTLE_STATE2_UNK_2; script->owner1.actorID = battleStatus->activeEnemyActorID; break; - case 2: + case BATTLE_STATE2_UNK_2: if (D_8029F248 != 0) { D_8029F248--; } else { D_8029F254 = 1; } - enemy = battleStatus->currentTurnEnemy; - if ((enemy->takeTurnScript == NULL || !does_script_exist(enemy->takeTurnID)) && - ((enemy->takeTurnScript = NULL, (player->onHitScript == NULL)) || !does_script_exist(player->onHitID))) { - player->onHitScript = NULL; - if (partner != NULL) { - if (partner->onHitScript == NULL || !does_script_exist(partner->onHitID)) { - partner->onHitScript = NULL; - goto block_39; + actor = battleStatus->currentTurnEnemy; + if (actor->takeTurnScript == NULL || !does_script_exist(actor->takeTurnID)) { + actor->takeTurnScript = NULL; + + if (player->onHitScript == NULL || !does_script_exist(player->onHitID)) { + player->onHitScript = NULL; + + if (partner != NULL) { + if (partner->onHitScript == NULL || !does_script_exist(partner->onHitID)) { + partner->onHitScript = NULL; + } else { + return; + } } - } else { - block_39: + + cond = FALSE; + for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { - enemy = battleStatus->enemyActors[i]; - if (enemy != NULL && enemy->takeTurnScript != NULL) { - if (does_script_exist(enemy->takeTurnID)) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL && actor->takeTurnScript != NULL) { + if (does_script_exist(actor->takeTurnID)) { cond = TRUE; } else { - enemy->takeTurnScript = NULL; + actor->takeTurnScript = NULL; } } } if (!cond) { for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { - enemy = battleStatus->enemyActors[i]; - if (enemy != NULL && enemy->onHitScript != NULL) { - if (does_script_exist(enemy->onHitID)) { + actor = battleStatus->enemyActors[i]; + if (actor != NULL && actor->onHitScript != NULL) { + if (does_script_exist(actor->onHitID)) { cond = TRUE; } else { - enemy->onHitScript = NULL; + actor->onHitScript = NULL; } } } @@ -2943,9 +4211,9 @@ void btl_state_update_enemy_striking_first(void) { if (!cond) { gBattleStatus.flags2 &= ~BS_FLAGS2_4000; for (i = 0; i < ARRAY_COUNT(battleStatus->enemyActors); i++) { - enemy = battleStatus->enemyActors[i]; - if (enemy != NULL) { - enemy->flags &= 0xFFF7FFFF; + actor = battleStatus->enemyActors[i]; + if (actor != NULL) { + actor->flags &= ~ACTOR_FLAG_80000; } } @@ -2953,7 +4221,7 @@ void btl_state_update_enemy_striking_first(void) { !btl_check_player_defeated() && !btl_check_enemies_defeated()) { - btl_set_state(5); + btl_set_state(BATTLE_STATE_BEGIN_TURN); } } } @@ -2962,9 +4230,6 @@ void btl_state_update_enemy_striking_first(void) { break; } } -#else -INCLUDE_ASM(s32, "16F740", btl_state_update_enemy_striking_first); -#endif void btl_state_draw_enemy_striking_first(void) { if (D_8029F254 != 0) { @@ -3004,13 +4269,13 @@ void btl_state_update_end_demo_battle(void) { gBattleState2 = BATTLE_STATE2_UNK_2; return; case -1: - if (D_80280A30 == 0xFF) { + if (D_80280A30 == 255) { gBattleState2 = BATTLE_STATE2_UNK_2; return; } D_80280A30 += 50; - if (D_80280A30 > 0xFF) { - D_80280A30 = 0xFF; + if (D_80280A30 > 255) { + D_80280A30 = 255; } return; } diff --git a/src/16c8e0.c b/src/16c8e0.c index 01b7784d9c..9d29483b96 100644 --- a/src/16c8e0.c +++ b/src/16c8e0.c @@ -904,8 +904,8 @@ void btl_update_starpoints_display(void) { } for (; i < ARRAY_COUNT(D_8029EFC0); i++) { - hud_element_set_flags(D_8029EFC0[i], 2); - hud_element_set_flags(D_8029EFE8[i], 2); + hud_element_set_flags(D_8029EFC0[i], HUD_ELEMENT_FLAGS_FILTER_TEX); + hud_element_set_flags(D_8029EFE8[i], HUD_ELEMENT_FLAGS_FILTER_TEX); } posX = D_8029DA40; @@ -929,7 +929,7 @@ void btl_update_starpoints_display(void) { } for (; i < ARRAY_COUNT(D_8029F010); i++) { - hud_element_set_flags(D_8029F010[i], 2); + hud_element_set_flags(D_8029F010[i], HUD_ELEMENT_FLAGS_FILTER_TEX); } } } diff --git a/src/181810.c b/src/181810.c index a65185585d..00d8ca5f44 100644 --- a/src/181810.c +++ b/src/181810.c @@ -425,7 +425,7 @@ INCLUDE_ASM(s32, "181810", load_tattle_flags); ApiStatus func_80253FB0(Evt* script, s32 isInitialCall) { gCurrentEncounter.battleOutcome = 3; - btl_set_state(0x20); + btl_set_state(BATTLE_STATE_END_BATTLE); return ApiStatus_DONE2; } diff --git a/src/18C790.c b/src/18C790.c index 8db3bcc24d..60d4fce383 100644 --- a/src/18C790.c +++ b/src/18C790.c @@ -229,7 +229,7 @@ void btl_state_update_celebration(void) { if (partner != NULL) { partner->flags &= ~(ACTOR_FLAG_4000000 | ACTOR_FLAG_8000000); } - battleStatus->battlePhase = 5; + battleStatus->battlePhase = PHASE_5; script = start_script(&PlayerScriptDispatcher, EVT_PRIORITY_A, 0); player->takeTurnScript = script; player->takeTurnID = script->id; @@ -762,7 +762,7 @@ void btl_state_update_celebration(void) { hud_element_free(D_8029FB48); set_background_color_blend(0, 0, 0, 0); - btl_set_state(0x20); + btl_set_state(BATTLE_STATE_END_BATTLE); gBattleState2 = BATTLE_STATE2_UNK_2; break; case BATTLE_STATE2_UNK_F: @@ -837,7 +837,7 @@ void btl_state_update_celebration(void) { if (partner != NULL && does_script_exist(partner->takeTurnID)) { kill_script_by_ID(partner->takeTurnID); } - btl_set_state(0x20); + btl_set_state(BATTLE_STATE_END_BATTLE); gBattleState2 = BATTLE_STATE2_UNK_2; break; } diff --git a/src/190B20.c b/src/190B20.c index 06991b6cfc..dbb2caf27b 100644 --- a/src/190B20.c +++ b/src/190B20.c @@ -232,7 +232,7 @@ s32 btl_check_player_defeated(void) { } D_800DC4E4 = gBattleState; D_800DC4D8 = gBattleState2; - btl_set_state(0x1B); + btl_set_state(BATTLE_STATE_DEFEAT); return TRUE; } @@ -1279,7 +1279,7 @@ Actor* create_actor(Formation formation) { } actor = battleStatus->enemyActors[i] = heap_malloc(sizeof(*actor)); - + ASSERT(actor != NULL); actor->unk_134 = battleStatus->unk_93++; @@ -2603,10 +2603,10 @@ void reset_all_actor_sounds(Actor* actor) { } void hide_foreground_models_unchecked(void) { - FGModelData* data = gBattleStatus.foregroundModelData; + Stage* data = gBattleStatus.currentStage; - if (data != NULL && data->idList != NULL) { - s32* idList = data->idList; + if (data != NULL && data->foregroundModelList != NULL) { + s32* idList = data->foregroundModelList; while (*idList != 0) { s32 id = *idList++; if (id >= 0) { @@ -2618,10 +2618,10 @@ void hide_foreground_models_unchecked(void) { } void show_foreground_models_unchecked(void) { - FGModelData* data = gBattleStatus.foregroundModelData; + Stage* data = gBattleStatus.currentStage; - if (data != NULL && data->idList != NULL) { - s32* idList = data->idList; + if (data != NULL && data->foregroundModelList != NULL) { + s32* idList = data->foregroundModelList; while (*idList != 0) { s32 id = *idList++; if (id >= 0) { @@ -2633,10 +2633,10 @@ void show_foreground_models_unchecked(void) { } void hide_foreground_models(void) { - FGModelData* data = gBattleStatus.foregroundModelData; + Stage* data = gBattleStatus.currentStage; - if (data != NULL && data->idList != NULL) { - s32* idList = data->idList; + if (data != NULL && data->foregroundModelList != NULL) { + s32* idList = data->foregroundModelList; while (*idList != 0) { s32 id = *idList++; if (id < 0) { @@ -2651,10 +2651,10 @@ void hide_foreground_models(void) { } void show_foreground_models(void) { - FGModelData* data = gBattleStatus.foregroundModelData; + Stage* data = gBattleStatus.currentStage; - if (data != NULL && data->idList != NULL) { - s32* idList = data->idList; + if (data != NULL && data->foregroundModelList != NULL) { + s32* idList = data->foregroundModelList; while (*idList != 0) { s32 id = *idList++; if (id < 0) { diff --git a/src/1a1f0_len_5390.c b/src/1a1f0_len_5390.c index 9d8284eef9..83fc64c777 100644 --- a/src/1a1f0_len_5390.c +++ b/src/1a1f0_len_5390.c @@ -14,6 +14,8 @@ extern f32 D_800A0BA4; extern EffectInstance* WorldMerleeOrbEffect; extern EffectInstance* WorldMerleeWaveEffect; +void set_battle_formation(Battle*); + s32 get_defeated(s32 mapID, s32 encounterID) { EncounterStatus* currentEncounter = &gCurrentEncounter; s32 encounterIdx = encounterID / 32; @@ -389,7 +391,7 @@ void update_encounters_pre_battle(void) { } if (currentEncounter->songID < 0) { - switch (currentEncounter->eFirstStrike) { + switch (currentEncounter->firstStrikeType) { case 0: bgm_set_battle_song(SONG_NORMAL_BATTLE, FIRST_STRIKE_NONE); break; @@ -443,7 +445,7 @@ void update_encounters_pre_battle(void) { sfx_stop_sound(SOUND_2112); sfx_stop_sound(SOUND_2113); sfx_stop_sound(SOUND_2114); - set_battle_formation(0); + set_battle_formation(NULL); set_battle_stage(encounter->stage); load_battle(encounter->battle); currentEncounter->unk_07 = 1; @@ -582,7 +584,7 @@ void show_first_strike_message(void) { screenWidthHalf = SCREEN_WIDTH / 2; - switch (currentEncounter->eFirstStrike) { + switch (currentEncounter->firstStrikeType) { case FIRST_STRIKE_PLAYER: switch (currentEncounter->hitType) { case 2: @@ -815,7 +817,7 @@ s32 check_conversation_trigger(void) { enemy->encountered = ENCOUNTER_TRIGGER_CONVERSATION; encounterStatus->currentEncounter = encounter; encounterStatus->currentEnemy = enemy; - encounterStatus->eFirstStrike = FIRST_STRIKE_PLAYER; + encounterStatus->firstStrikeType = FIRST_STRIKE_PLAYER; return TRUE; } } diff --git a/src/39210_len_aa0.c b/src/39210_len_aa0.c index 648a0a0f93..68f93e10e3 100644 --- a/src/39210_len_aa0.c +++ b/src/39210_len_aa0.c @@ -28,6 +28,7 @@ void get_npc_pos(s32 npcID, f32* outX, f32* outY, f32* outZ, s32* arg4) { } +void func_8005DECC(Npc* npc, s32 arg1, void* arg2, f32 arg3, f32 arg4, s32 arg5, s32 arg6); INCLUDE_ASM(s32, "39210_len_aa0", func_8005DECC); INCLUDE_ASM(s32, "39210_len_aa0", func_8005DFD4); diff --git a/src/415D90.c b/src/415D90.c index 964c53f156..1b79790de5 100644 --- a/src/415D90.c +++ b/src/415D90.c @@ -1,4 +1,5 @@ #include "common.h" +#include "battle/battle.h" #include "hud_element.h" extern HudScript HES_YellowArrow; @@ -86,90 +87,25 @@ extern HudScript HES_MoveRedOrbDisabled; extern HudScript HES_GreenArrowDown; extern HudScript HES_GreenArrowUp; extern HudScript HES_HandPointer; +extern HudScript HES_HandPointDownLoop; +extern HudScript HES_HandPointLeftLoop; -extern s32 D_802ACC60; -extern s32 D_802ACC6C; -extern s8 D_802AD000; -extern u8 D_802AD001; -extern s16 D_802AD006; -extern s16 D_802AD008; -extern s32 D_802AD010[]; -extern s32 D_802AD028[]; -extern s32 D_802AD040; -extern s32 D_802AD044; -extern s32 D_802AD048; -extern s32 D_802AD04C; -extern s32 D_802AD05C; -extern s32 D_802AD050; -extern s32 D_802AD054; -extern s32 D_802AD058; -extern s8 D_802AD068; -extern s32 main_menu_numOptions; -extern s32 D_802AD0A8; -extern s32 D_802AD0B0; -extern s32 D_802AD0BB[]; -extern s32 D_802AD100; -extern s32 D_802AD104; -extern s32 battle_menu_isEnabled; -extern s32 battle_menu_isMessageDisabled; -extern s32 battle_menu_messageIDs[]; -extern s32 battle_menu_submenuIDs; -extern HudScript* main_battle_menu_JumpHudScripts; -extern s8 D_802AD10A; -extern s8 D_802AD10D; -extern s8 D_802AD10E; -extern s8 D_802AD10F; -extern s16 D_802AD112; -extern s32 battle_menu_moveOptionActive; -extern s8 battle_menu_moveScrollLine; -extern s16 battle_menu_moveScrollOffset; -extern u8 battle_menu_moveState; -extern s8 battle_menu_moveCursorPos; -extern s32 battle_menu_moveOptionDescriptions[24]; -extern s32 battle_menu_moveOptionIndexMap[24]; -extern s16 battle_menu_moveTextColor; -extern s16 battle_menu_moveTextOpacity; -extern s32 battle_menu_moveCursorIcon; -extern s32 battle_menu_moveUpArrowIcon; -extern s32 battle_menu_moveDownArrowIcon; -extern s32 battle_menu_moveOptionIconIDs[24]; -extern s32 battle_menu_moveTitleIcon; -extern s32 battle_menu_moveOptionCostUnitIconIDs[24]; - -extern s32 D_802AD258; -extern s32 D_802AD4A8; -extern s32 battle_menu_hasSpiritsMenu; -extern s32 battle_menu_moveOptionCount; -extern s8 D_802AD604; -extern s8 D_802AD605; -extern s8 D_802AD606; -extern s8 D_802AD607; -extern s8 D_802AD608; -extern s8 D_802AD609; -extern s8 D_802AD60A; -extern s8 D_802AD60B; -extern s16 D_802AD60C; -extern s16 D_802AD60E; -extern s16 D_802AD610; -extern s16 D_802AD612; -extern s8 D_802AD614; -extern s32 D_802AD618; -extern s32 D_802AD61C; -extern s32 D_802AD620; -extern s32 D_802AD624; -extern s32 D_802AD628[]; -extern s16 D_802AD63C; -extern s16 D_802AD63E; -extern HudScript* D_802AD640[]; -extern s32 D_802AD658[]; // msg IDs -extern s32 D_802AD66C; -extern u8 D_802AD66F; -extern s8 D_802AD673; -extern s32 D_802AD678[]; -extern s32 D_802AD690[]; -extern s32 D_802AD6A8[]; -extern s32 D_802AD6C0[]; -extern s32 D_802AD6D4; +extern HudScript HES_FPCost; +extern HudScript HES_FPCostReduced; +extern HudScript HES_FPCostReducedTwice; +extern HudScript HES_POWCost; +extern HudScript HES_POWCostReduced; +extern HudScript HES_POWCostReducedTwice; +extern HudScript HES_StatusFlower; +extern HudScript HES_NotEnoughFP; +extern HudScript HES_NotEnoughPOW; +extern HudScript HES_ProjectorBeam; +extern HudScript HES_ProjectorReel; +extern HudScript HES_ProjectorSpot; +extern HudScript HES_SwapArrowLeft; +extern HudScript HES_SwapArrowRight; +extern HudScript HES_SwapBackground; +extern HudScript HES_SwapZ; s16 D_802AB340[] = { 28, 40 }; @@ -284,6 +220,120 @@ s32 D_802AB738[] = { 0x001D000F, 0x001D0010, 0x001D0011, 0x001D0012, 0x00000000 }; +extern s32 D_802ACC60; +extern s32 D_802ACC64; +extern s32 D_802ACC68; +extern s32 D_802ACC6C; +extern s32 D_802ACC70[]; +extern s8 D_802AD000; +extern s8 D_802AD001; +extern s8 D_802AD002; +extern s8 D_802AD003; +extern s8 D_802AD004; +extern s16 D_802AD006; +extern s16 D_802AD008; +extern s16 D_802AD00A; +extern s32 D_802AD010[]; +extern s32 D_802AD028[]; +extern s32 D_802AD040; +extern s32 D_802AD044; +extern s32 D_802AD048; +extern s32 D_802AD04C; +extern s32 D_802AD05C; +extern s32 D_802AD050; +extern s32 D_802AD054; +extern s32 D_802AD058; +extern s32 D_802AD060; +extern s32 D_802AD064; +extern s8 D_802AD068; +extern s8 D_802AD069; +extern s8 D_802AD06A; +extern s8 D_802AD06B; +extern f32 D_802AD06C; +extern f32 D_802AD070; +extern HudScript* main_battle_menu_JumpHudScripts[]; +extern s32 battle_menu_messageIDs[]; +extern s32 main_menu_numOptions; +extern s32 D_802AD0A8; +extern s32 D_802AD0B0; +extern s8 D_802AD0B3; +extern s32 battle_menu_submenuIDs[]; +extern s32 battle_menu_isEnabled[]; +extern s32 battle_menu_isMessageDisabled[]; +extern s32 D_802AD100; +extern s32 D_802AD104; +extern s8 battle_menu_moveState; +extern s8 battle_menu_moveCursorPos; +extern s8 D_802AD10A; +extern s8 D_802AD10B; +extern s8 battle_menu_moveScrollLine; +extern s8 D_802AD10D; +extern s8 D_802AD10E; +extern s8 D_802AD10F; +extern s16 battle_menu_moveScrollOffset; +extern s16 D_802AD112; +extern s16 battle_menu_moveTextColor; +extern s16 battle_menu_moveTextOpacity; +extern s32 battle_menu_moveCursorIcon; +extern s32 battle_menu_moveUpArrowIcon; +extern s32 battle_menu_moveDownArrowIcon; +extern s32 battle_menu_moveOptionIconIDs[24]; +extern s32 battle_menu_moveTitleIcon; +extern s32 battle_menu_moveOptionCostUnitIconIDs[24]; +extern s16 battle_menu_moveX; +extern s16 battle_menu_moveY; +extern s32 battle_menu_moveOptionIndexMap[24]; +extern s32 D_802AD258; +extern HudScript* battle_menu_moveOptionIconScripts[]; +extern s32 battle_menu_moveOptionNames[]; +extern s32 battle_menu_moveOptionDisplayCosts[]; +extern s32 battle_menu_moveOptionDisplayCostReductions[]; +extern s32 battle_menu_moveOptionDisplayCostReductionColors[]; +extern s32 battle_menu_moveOptionBPCosts[]; +extern s32 battle_menu_hasSpiritsMenu; +extern s32 battle_menu_moveOptionCount; +extern s32 D_802AD4A8; +extern s32 battle_menu_moveOptionsEnabled[]; +extern s32 battle_menu_moveOptionDescriptions[24]; +extern s8 battle_menu_moveOptionSortPriorities[]; +extern s8 battle_menu_moveOptionCantUseTypes[]; +extern s32 battle_menu_moveOptionActive; +extern s8 D_802AD604; +extern s8 D_802AD605; +extern s8 D_802AD606; +extern s8 D_802AD607; +extern s8 D_802AD608; +extern s8 D_802AD609; +extern s8 D_802AD60A; +extern s8 D_802AD60B; +extern s16 D_802AD60C; +extern s16 D_802AD60E; +extern s16 D_802AD610; +extern s16 D_802AD612; +extern s8 D_802AD614; +extern s32 D_802AD618; +extern s32 D_802AD61C; +extern s32 D_802AD620; +extern s32 D_802AD624; +extern s32 D_802AD628[]; +extern s16 D_802AD63C; +extern s16 D_802AD63E; +extern HudScript* D_802AD640[]; +extern s32 D_802AD658[]; // msg IDs +extern s32 D_802AD66C; +extern u8 D_802AD66F; +extern s8 D_802AD673; +extern s32 D_802AD678[]; +extern s32 D_802AD690[]; +extern s32 D_802AD6A8[]; +extern s32 D_802AD6C0[]; +extern s32 D_802AD6D4; + +void func_802A3C98(s32 x, s32 y); +void func_802A43DC(s32 arg0, s32 x, s32 y); +void func_802A4448(s32 arg0, s32 x, s32 y); +void func_802A4494(s32 arg0, s32 x, s32 y); +void func_802A4534(s32 arg0, s32 x, s32 y); void func_802A5290(s32 arg0, s32 x, s32 y); void func_802A56F8(s32 arg0, s32 x, s32 y); void func_802A5738(s32 arg0, s32 x, s32 y); @@ -339,7 +389,228 @@ void func_802A10B8(void) { } s32 func_802A11B0(void); +// so close +#ifdef NON_MATCHING +s32 func_802A11B0(void) { + BattleStatus* battleStatus = &gBattleStatus; + f32 var_f20; + s32 id; + s32 i; + f32 x, y; + f32 x2, y2; + + switch (D_802AD000) { + case 0: + D_802AD060 = 54; + D_802AD064 = 173; + D_802AD070 = 0.3f; + D_802AD004 = 0; + D_802AD06B = D_802AD0B3; + D_802AD069 = -D_802AD0B3; + D_802AD06A = main_menu_numOptions - 1; + D_802AD06A -= D_802AD0B3; + + for (i = 0; i < main_menu_numOptions; i++) { + D_802AD010[i] = id = hud_element_create(main_battle_menu_JumpHudScripts[i]); + hud_element_set_render_depth(id, 5); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_FILTER_TEX); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_80); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_DISABLED); + hud_element_set_scale(id, 0.75f); + + D_802AD028[i] = id = hud_element_create(&HES_ProjectorSpot); + hud_element_create_transform_B(id); + hud_element_set_render_depth(id, 10); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_80); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_FILTER_TEX); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_DISABLED); + } + + D_802AD040 = id = hud_element_create(&HES_ProjectorSpot); + hud_element_create_transform_B(id); + hud_element_set_render_depth(id, 7); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_80); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_FILTER_TEX); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_DISABLED); + + D_802AD044 = id = hud_element_create(&HES_ProjectorReel); + hud_element_create_transform_B(id); + hud_element_set_render_depth(id, 0); + hud_element_set_render_pos(id, 40, 212); + hud_element_set_tint(id, 0, 91, 127); + hud_element_set_transform_rotation_pivot(id, 0x10, -0x10); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_80); + hud_element_clear_flags(id, HUD_ELEMENT_FLAGS_FILTER_TEX); + hud_element_set_alpha(id, 240); + + D_802AD048 = id = hud_element_create(&HES_ProjectorReel); + hud_element_create_transform_B(id); + hud_element_set_render_depth(id, 2); + hud_element_set_render_pos(id, 39, 212); + hud_element_set_tint(id, 0, 91, 127); + hud_element_set_transform_rotation_pivot(id, 0x10, -0x10); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_80); + hud_element_clear_flags(id, HUD_ELEMENT_FLAGS_FILTER_TEX); + hud_element_set_alpha(id, 240); + + D_802AD04C = id = hud_element_create(&HES_ProjectorBeam); + hud_element_create_transform_B(id); + hud_element_set_render_depth(id, 20); + hud_element_set_render_pos(id, 78, 178); + hud_element_set_tint(id, 255, 255, 255); + hud_element_set_transform_rotation_pivot(id, 0, 0); + hud_element_set_transform_rotation(id, 0.0f, 0.0f, -45.0f); + hud_element_set_alpha(id, 200); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_80); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_FILTER_TEX); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_DISABLED); + + D_802AD05C = id = hud_element_create(&HES_SwapBackground); + hud_element_set_render_depth(id, 0); + hud_element_set_render_pos(id, 97, 208); + hud_element_set_tint(id, 255, 255, 255); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_80); + hud_element_clear_flags(id, HUD_ELEMENT_FLAGS_FILTER_TEX); + hud_element_set_alpha(id, 230); + + D_802AD050 = id = hud_element_create(&HES_SwapZ); + hud_element_set_render_depth(id, 5); + hud_element_clear_flags(id, HUD_ELEMENT_FLAGS_FILTER_TEX); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_80); + hud_element_set_render_pos(id, 94, 209); + + D_802AD054 = id = hud_element_create(&HES_SwapArrowLeft); + hud_element_set_render_depth(id, 5); + hud_element_clear_flags(id, HUD_ELEMENT_FLAGS_FILTER_TEX); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_80); + hud_element_set_render_pos(id, 81, 210); + + D_802AD058 = id = hud_element_create(&HES_SwapArrowRight); + hud_element_set_render_depth(id, 5); + hud_element_clear_flags(id, HUD_ELEMENT_FLAGS_FILTER_TEX); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_80); + hud_element_set_render_pos(id, 102, 210); + D_802AD00A = 100; + D_802AD001 = 3; + D_802AD000 = 1; + D_802AD06C = var_f20 = D_802AD100 * 28; + break; + case 1: + D_802AD00A = (D_802AD001 * 100) / 3; + + switch (D_802AD001) { + case 1: + if (D_802AD001 == 1) { + id = D_802AD04C; + hud_element_clear_flags(id, 2); + } + default: + D_802AD001--; + break; + case 0: + D_802AD002 = 0; + D_802AD003 = 0; + + D_802AD06C = var_f20 = D_802AD100 * 28; + for (i = 0; i < main_menu_numOptions; i++, var_f20 += 28.0f) { + s32 id; + + x = 0.0f; + y = 0.0f; + add_vec2D_polar(&x, &y, 87.0f, var_f20); + + x2 = D_802AD060 + x; + y2 = D_802AD064 + y; + id = D_802AD010[i]; + hud_element_set_render_pos(id, x2, y2); + hud_element_clear_flags(id, 2); + + id = D_802AD028[i]; + hud_element_set_render_pos(id, x2, y2); + hud_element_set_alpha(id, 100); + hud_element_clear_flags(id, 2); + } + + x = 0.0f; + y = 0.0f; + add_vec2D_polar(&x, &y, 87.0f, D_802AD100 * 28); + + id = D_802AD040; + hud_element_set_render_pos(id, D_802AD060 + x, D_802AD064 + y); + hud_element_set_alpha(id, 180); + hud_element_set_scale(id, 0.85f); + hud_element_clear_flags(id, 2); + D_802AD000 = 2; + break; + } + break; + case 2: + if (battleStatus->currentButtonsPressed & BUTTON_A) { + if (battle_menu_isEnabled[D_802AD002 + D_802AD06B] == 1) { + sfx_play_sound(SOUND_MENU_NEXT); + D_802AD000 = -1; + } else { + sfx_play_sound(SOUND_MENU_ERROR); + D_802AD068 = battle_menu_isMessageDisabled[D_802AD002 + D_802AD06B]; + D_802AD000 = 100; + } + } else { + D_802AD003 = D_802AD002; + if (D_802AD004 == 0) { + if ((battleStatus->currentButtonsHeld & (BUTTON_STICK_LEFT | BUTTON_STICK_UP)) && + (D_802AD069 < D_802AD002)) + { + D_802AD002--; + } + if ((battleStatus->currentButtonsHeld & (BUTTON_STICK_RIGHT | BUTTON_STICK_DOWN)) && + (D_802AD002 < D_802AD06A)) + { + D_802AD002++; + } + } + + if (D_802AD003 != D_802AD002) { + D_802AD004 = 1; + sfx_play_sound(SOUND_MENU_CHANGE_TAB); + } + } + break; + case -1: + D_802AD008 = 100; + return D_802AD002 + D_802AD06B + 1; + case 10: + D_802AD001 = 0; + D_802AD006 = 0; + D_802AD000 = 11; + return D_802AD002 + D_802AD06B + 1; + case 11: + return D_802AD002 + D_802AD06B + 1; + case 20: + D_802AD001 = 3; + D_802AD006 = 255; + D_802AD000 = 2; + return D_802AD002 + D_802AD06B + 1; + case 30: + D_802AD001 = 3; + D_802AD006 = 255; + D_802AD000 = -1; + break; + case 100: + btl_show_battle_message(D_802AD068, 90); + D_802AD000 = 101; + break; + case 101: + if (!btl_is_popup_displayed()) { + D_802AD068 = -1; + D_802AD000 = 2; + } + break; + } + return 0; +} +#else INCLUDE_ASM(s32, "415D90", func_802A11B0); +#endif void btl_draw_menu_wheel(void); @@ -703,9 +974,560 @@ void func_802A2C58(void) { battle_menu_moveState = 30; } -INCLUDE_ASM(s32, "415D90", func_802A2C84); +s32 func_802A2C84(void) { + BattleStatus* battleStatus = &gBattleStatus; + s8 temp_v0_14; + s32 moveX; + s32 moveY; + s32 msgWidth; + s32 msgX; + s32 msgID; + s32 cond; + s32 id; + s32 i; + s32 j; + switch (battle_menu_moveState) { + case 0: + battle_menu_moveScrollOffset = -battle_menu_moveScrollLine * 13; + D_802AD112 = (battle_menu_moveCursorPos - battle_menu_moveScrollLine) * 13; + battle_menu_moveX = 20; + battle_menu_moveY = 68; + + for (i = 0; i < battle_menu_moveOptionCount; i++) { + battle_menu_moveOptionIndexMap[i] = i; + } + + if (!battle_menu_hasSpiritsMenu) { + for (i = 0; i < (battle_menu_moveOptionCount - 1); i++) { + for (j = i + 1; j < battle_menu_moveOptionCount; j++) { + do { + s32 temp1 = battle_menu_moveOptionIndexMap[i]; + s32 temp2 = battle_menu_moveOptionIndexMap[j]; + + if (battle_menu_moveOptionSortPriorities[temp1] < battle_menu_moveOptionSortPriorities[temp2]) { + continue; + } + + if ( + battle_menu_moveOptionSortPriorities[temp1] != battle_menu_moveOptionSortPriorities[temp2] || + (battle_menu_moveOptionDisplayCosts[temp1] >= battle_menu_moveOptionDisplayCosts[temp2]) && + (battle_menu_moveOptionDisplayCosts[temp1] != battle_menu_moveOptionDisplayCosts[temp2] || + battle_menu_moveOptionBPCosts[temp1] >= battle_menu_moveOptionBPCosts[temp2]) + ) + { + s32 swapTmp = battle_menu_moveOptionIndexMap[i]; + battle_menu_moveOptionIndexMap[i] = battle_menu_moveOptionIndexMap[j]; + battle_menu_moveOptionIndexMap[j] = swapTmp; + } + } while (0); + } + } + } + + for (i = 0; i < battle_menu_moveOptionCount; i++) { + id = hud_element_create(battle_menu_moveOptionIconScripts[battle_menu_moveOptionIndexMap[i]]); + battle_menu_moveOptionIconIDs[i] = id; + hud_element_set_scale(id, 0.45f); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_FILTER_TEX | HUD_ELEMENT_FLAGS_80); + } + + id = hud_element_create(&HES_AnimatedHandPointer); + battle_menu_moveCursorIcon = id; + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_DROP_SHADOW | HUD_ELEMENT_FLAGS_80); + hud_element_set_render_pos(id, battle_menu_moveX, battle_menu_moveY); + + id = hud_element_create(&HES_GreenArrowUp); + battle_menu_moveUpArrowIcon = id; + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_DROP_SHADOW | HUD_ELEMENT_FLAGS_80); + hud_element_set_render_pos(id, battle_menu_moveX + 39, battle_menu_moveY - 7); + + id = hud_element_create(&HES_GreenArrowDown); + battle_menu_moveDownArrowIcon = id; + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_DROP_SHADOW | HUD_ELEMENT_FLAGS_80); + hud_element_set_render_pos(id, battle_menu_moveX + 39, battle_menu_moveY + 78); + + if (battle_menu_hasSpiritsMenu == 0) { + id = hud_element_create(&HES_StatusFlower); + battle_menu_moveTitleIcon = id; + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_80); + } else { + id = hud_element_create(&HES_MenuStarPower); + battle_menu_moveTitleIcon = id; + hud_element_set_scale(id, 0.75f); + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_80); + } + hud_element_set_render_pos(id, battle_menu_moveX + 56, battle_menu_moveY); + + for (i = 0; i < battle_menu_moveOptionCount; i++) { + if (!battle_menu_hasSpiritsMenu) { + switch (battle_menu_moveOptionDisplayCostReductionColors[i]) { + case 0: + id = hud_element_create(&HES_FPCost); + battle_menu_moveOptionCostUnitIconIDs[i] = id; + break; + case 1: + id = hud_element_create(&HES_FPCostReduced); + battle_menu_moveOptionCostUnitIconIDs[i] = id; + break; + default: + id = hud_element_create(&HES_FPCostReducedTwice); + battle_menu_moveOptionCostUnitIconIDs[i] = id; + break; + } + } else { + switch (battle_menu_moveOptionDisplayCostReductionColors[i]) { + case 0: + id = hud_element_create(&HES_POWCost); + battle_menu_moveOptionCostUnitIconIDs[i] = id; + break; + case 1: + id = hud_element_create(&HES_POWCostReduced); + battle_menu_moveOptionCostUnitIconIDs[i] = id; + break; + default: + id = hud_element_create(&HES_POWCostReducedTwice); + battle_menu_moveOptionCostUnitIconIDs[i] = id; + break; + } + } + hud_element_set_flags(id, HUD_ELEMENT_FLAGS_80); + hud_element_set_render_pos(id, battle_menu_moveX + 56, battle_menu_moveY); + } + + battle_menu_moveTextColor = 0xA; + + moveX = battle_menu_moveX; + moveY = battle_menu_moveY; + if (!battle_menu_hasSpiritsMenu) { + set_window_properties(1, moveX, moveY, 150, (D_802AD10E * 13) + 28, 0, func_802A3C98, NULL, -1); + set_window_properties(2, moveX + 16, moveY - 6, 90, 16, 1, func_802A43DC, NULL, -1); + set_window_properties(3, moveX + 114, moveY - 12, 32, 32, 1, func_802A4448, NULL, -1); + } else { + s16 new_var; + + set_window_properties(1, moveX, moveY, 144, (D_802AD10E * 13) + 28, 0, func_802A3C98, NULL, -1); + new_var = moveY; // todo required to match + set_window_properties(4, moveX + 10, new_var - 6, 100, 16, 1, func_802A43DC, 0, -1); + set_window_properties(5, moveX + 110, new_var - 12, 32, 35, 1, func_802A4448, 0, -1); + } + + moveX = 20; + moveY = battle_menu_moveY; + set_window_properties(8, moveX, 186, 280, 32, 20, func_802A4494, NULL, -1); + set_window_update(1, 1); + if (!battle_menu_hasSpiritsMenu) { + set_window_update(2, 1); + set_window_update(3, 1); + } else { + set_window_update(4, 1); + set_window_update(5, 1); + } + set_window_update(8, 1); + + do { + cond = FALSE; + if (battle_menu_moveCursorPos >= (battle_menu_moveScrollLine + D_802AD10D) - 1) { + battle_menu_moveScrollLine++; + if (battle_menu_moveScrollLine > battle_menu_moveOptionCount - 6) { + battle_menu_moveScrollLine = battle_menu_moveOptionCount - 6; + if (battle_menu_moveScrollLine < 0) { + battle_menu_moveScrollLine = 0; + } + } else { + cond = TRUE; + } + } + } while (cond); + + battle_menu_moveState = 1; + D_802AD10D = battle_menu_moveScrollLine + 6; + battle_menu_moveScrollOffset = -battle_menu_moveScrollLine * 13; + D_802AD112 = (battle_menu_moveCursorPos - battle_menu_moveScrollLine) * 13; + break; + case 1: + D_802AD10A = battle_menu_moveCursorPos; + if (battleStatus->currentButtonsHeld & (BUTTON_STICK_UP | BUTTON_Z)) { + if (battle_menu_moveCursorPos > 0) { + battle_menu_moveCursorPos--; + } else if (battleStatus->currentButtonsPressed & (BUTTON_STICK_UP | BUTTON_Z)) { + battle_menu_moveCursorPos--; + } + } + + if (battleStatus->currentButtonsHeld & (BUTTON_STICK_DOWN | BUTTON_R)) { + if (battle_menu_moveCursorPos < battle_menu_moveOptionCount - 1) { + battle_menu_moveCursorPos++; + } else if (battleStatus->currentButtonsPressed & (BUTTON_STICK_DOWN | BUTTON_R)) { + battle_menu_moveCursorPos++; + } + } + + if (battle_menu_moveCursorPos < 0) { + battle_menu_moveCursorPos = battle_menu_moveOptionCount - 1; + } + + if (battle_menu_moveOptionCount - 1 < battle_menu_moveCursorPos) { + battle_menu_moveCursorPos = 0; + } + + if (D_802AD10A != battle_menu_moveCursorPos) { + hud_element_set_scale(battle_menu_moveOptionIconIDs[D_802AD10A], 0.45f); + sfx_play_sound(SOUND_MENU_CHANGE_SELECTION); + } + + if (battle_menu_moveCursorPos < battle_menu_moveScrollLine + 1) { + battle_menu_moveScrollLine--; + if (battle_menu_moveScrollLine < 0) { + battle_menu_moveScrollLine = 0; + } + } + + if (battle_menu_moveCursorPos >= (D_802AD10D - 1)) { + battle_menu_moveScrollLine++; + if (battle_menu_moveScrollLine > battle_menu_moveOptionCount - 6) { + battle_menu_moveScrollLine = battle_menu_moveOptionCount - 6; + if (battle_menu_moveScrollLine < 0) { + battle_menu_moveScrollLine = 0; + } + } + } + + D_802AD10D = battle_menu_moveScrollLine + 6; + if (battleStatus->currentButtonsPressed & BUTTON_A) { + if (battle_menu_moveOptionsEnabled[battle_menu_moveOptionIndexMap[battle_menu_moveCursorPos]] == 1) { + sfx_play_sound(SOUND_MENU_NEXT); + battle_menu_moveState = -1; + } else { + sfx_play_sound(SOUND_MENU_ERROR); + D_802AD258 = 0; + temp_v0_14 = battle_menu_moveOptionCantUseTypes[battle_menu_moveOptionIndexMap[battle_menu_moveCursorPos]]; + if (temp_v0_14 != 0) { + D_802AD258 = temp_v0_14; + } + battle_menu_moveState = 40; + } + break; + } + + if (battleStatus->currentButtonsPressed & 0x4000) { + sfx_play_sound(SOUND_MENU_BACK); + func_802A27E4(); + battle_menu_moveState = -2; + } + break; + case -1: + for (i = 0; i < battle_menu_moveOptionCount; i++) { + id = battle_menu_moveOptionIconIDs[i]; + hud_element_set_tint(id, 160, 160, 160); + } + hud_element_set_tint(battle_menu_moveCursorIcon, 160, 160, 160); + hud_element_set_tint(battle_menu_moveUpArrowIcon, 160, 160, 160); + hud_element_set_tint(battle_menu_moveDownArrowIcon, 160, 160, 160); + hud_element_set_tint(battle_menu_moveTitleIcon, 160, 160, 160); + + for (i = 0; i < battle_menu_moveOptionCount; i++) { + id = battle_menu_moveOptionCostUnitIconIDs[i]; + hud_element_set_tint(id, 160, 160, 160); + } + + hud_element_set_script(battle_menu_moveCursorIcon, &HES_HandPointer); + battle_menu_moveTextColor = 0xD; + set_window_update(1, 4); + if (!battle_menu_hasSpiritsMenu) { + set_window_update(2, 4); + set_window_update(3, 4); + } else { + set_window_update(4, 4); + set_window_update(5, 4); + } + set_window_update(8, 2); + if (!battle_menu_hasSpiritsMenu) { + status_menu_stop_blinking_fp(); + } else { + status_menu_stop_blinking_sp(); + } + battle_menu_moveOptionActive = battle_menu_moveCursorPos; + return battle_menu_moveOptionIndexMap[battle_menu_moveCursorPos] + 1; + case -2: + if (!battle_menu_hasSpiritsMenu) { + status_menu_stop_blinking_fp(); + } else { + status_menu_stop_blinking_sp(); + } + return 255; + case 10: + set_window_update(1, 2); + if (!battle_menu_hasSpiritsMenu) { + set_window_update(2, 2); + set_window_update(3, 2); + } else { + set_window_update(4, 2); + set_window_update(5, 2); + } + set_window_update(8, 2); + if (!battle_menu_hasSpiritsMenu) { + status_menu_stop_blinking_fp(); + } else { + status_menu_stop_blinking_sp(); + } + battle_menu_moveState = 11; + battle_menu_moveOptionActive = battle_menu_moveCursorPos; + return battle_menu_moveOptionIndexMap[battle_menu_moveCursorPos] + 1; + case 11: + battle_menu_moveOptionActive = battle_menu_moveCursorPos; + return battle_menu_moveOptionIndexMap[battle_menu_moveCursorPos] + 1; + case 20: + set_window_update(1, 1); + if (!battle_menu_hasSpiritsMenu) { + set_window_update(2, 1); + set_window_update(3, 1); + } else { + set_window_update(4, 1); + set_window_update(5, 1); + } + set_window_update(8, 1); + battle_menu_moveState = 1; + battle_menu_moveOptionActive = battle_menu_moveCursorPos; + return battle_menu_moveOptionIndexMap[battle_menu_moveCursorPos] + 1; + case 30: + set_window_update(1, 9); + if (!battle_menu_hasSpiritsMenu) { + set_window_update(2, 9); + set_window_update(3, 9); + } else { + set_window_update(4, 9); + set_window_update(5, 9); + } + set_window_update(8, 2); + battle_menu_moveState = -1; + break; + case 40: + battle_menu_moveOptionActive = -1; + battle_menu_moveState = 41; + return -1; + case 41: + set_window_update(1, 2); + if (!battle_menu_hasSpiritsMenu) { + set_window_update(2, 2); + set_window_update(3, 2); + } else { + set_window_update(4, 2); + set_window_update(5, 2); + } + set_window_update(8, 2); + + msgID = 0x1D00C3; + if (D_802AD258 == 0) { + if (!battle_menu_hasSpiritsMenu) { + msgID = 0x1D009F; + } else { + msgID = 0x1D00A0; + } + } + + msgWidth = get_msg_width(msgID, 0) + 23; + moveX = (SCREEN_WIDTH / 2) - (msgWidth / 2); + set_window_properties(9, moveX, 80, msgWidth, D_802AB340[get_msg_lines(msgID) - 1], 0x14, func_802A4534, NULL, -1); + set_window_update(9, 1); + D_802AD10B = 60; + battle_menu_moveState = 42; + return -1; + case 42: + if (gGameStatusPtr->pressedButtons[0] & (BUTTON_A | BUTTON_B)) { + D_802AD10B = 0; + } + if (D_802AD10B != 0) { + D_802AD10B--; + return -1; + } + set_window_update(9, 2); + set_window_update(1, 1); + if (!battle_menu_hasSpiritsMenu) { + set_window_update(2, 1); + set_window_update(3, 1); + } else { + set_window_update(4, 1); + set_window_update(5, 1); + } + set_window_update(8, 1); + battle_menu_moveState = 1; + break; + } + return 0; +} + +const f32 padding3 = 0.0f; + +// needs a lot of work +#ifdef NON_MATCHING +void func_802A3C98(s32 x, s32 y) { + s32 palette; + s32 num; + s32 id; + s32 i; + + s32 var_t0; + s32 var_t0_4; + s32 temp_f6_2; + s32 moveOptX; + s32 moveOptY; + s32 t2; + s32 temp1; + + switch (battle_menu_moveState) { + case -1: + case 1: + case 10: + case 20: + case 30: + case 40: + case 41: + temp_f6_2 = ((-battle_menu_moveScrollLine * 13) - battle_menu_moveScrollOffset) * 0.5; + var_t0 = battle_menu_moveScrollOffset + temp_f6_2; + if (temp_f6_2 == 0) { + var_t0 = -battle_menu_moveScrollLine * 13; + } + battle_menu_moveScrollOffset = var_t0; + t2 = D_802AD10E * 13; + + moveOptY = y + (battle_menu_moveScrollOffset + 19); + moveOptX = x + 31; + + temp1 = y + 18 + (t2 + 1); + + gDPSetScissor( + gMasterGfxPos++, G_SC_NON_INTERLACE, + x + 2, + y + 18, + x + 153, + temp1 + ); + + for (i = 0; i < battle_menu_moveOptionCount; i++) { + if ((i >= battle_menu_moveScrollLine - 1) && (i <= battle_menu_moveScrollLine + D_802AD10E)) { + palette = battle_menu_moveTextColor; + if (battle_menu_moveOptionsEnabled[battle_menu_moveOptionIndexMap[i]] <= 0) { + palette = 0xB; + } + + if (battle_menu_moveOptionNames[battle_menu_moveOptionIndexMap[i]] >= 0) { + draw_msg(battle_menu_moveOptionNames[battle_menu_moveOptionIndexMap[i]], moveOptX, moveOptY, battle_menu_moveTextOpacity, palette, 1); + } + + num = battle_menu_moveOptionDisplayCosts[battle_menu_moveOptionIndexMap[i]] - battle_menu_moveOptionDisplayCostReductions[battle_menu_moveOptionIndexMap[i]]; + if ((battle_menu_moveOptionDisplayCosts[battle_menu_moveOptionIndexMap[i]] != 0) && (num <= 0)) { + num = 1; + } + + if (!battle_menu_hasSpiritsMenu) { + if (i == battle_menu_moveCursorPos) { + if (num == 0 || (battle_menu_moveOptionsEnabled[battle_menu_moveOptionIndexMap[i]] <= 0)) { + status_menu_stop_blinking_fp(); + } else { + status_menu_start_blinking_fp(); + } + } + } else { + if (i == battle_menu_moveCursorPos) { + if (num == 0 || (battle_menu_moveOptionsEnabled[battle_menu_moveOptionIndexMap[i]] <= 0)) { + status_menu_stop_blinking_sp(); + } else { + status_menu_start_blinking_sp_bars(battle_menu_moveOptionDisplayCosts[battle_menu_moveOptionIndexMap[i]]); + } + } + } + + switch (battle_menu_moveOptionDisplayCostReductionColors[i]) { + case 0: + palette = 0xA; + break; + case 1: + palette = 0x37; + break; + default: + palette = 0x38; + break; + } + + if (battle_menu_moveOptionsEnabled[battle_menu_moveOptionIndexMap[i]] <= 0) { + palette = 0xB; + } + + if (battle_menu_moveOptionDisplayCosts[battle_menu_moveOptionIndexMap[i]] != 0) { + id = battle_menu_moveOptionCostUnitIconIDs[i]; + if (!battle_menu_hasSpiritsMenu) { + draw_number(num, moveOptX + 108, moveOptY, 1, palette, battle_menu_moveTextOpacity, 3); + if (battle_menu_moveOptionsEnabled[battle_menu_moveOptionIndexMap[i]] <= 0) { + hud_element_set_script(id, &HES_NotEnoughFP); + } + moveOptX += 116; + } else { + draw_number(num, moveOptX + 93, moveOptY, 1, palette, battle_menu_moveTextOpacity, 3); + if (battle_menu_moveOptionsEnabled[battle_menu_moveOptionIndexMap[i]] <= 0) { + hud_element_set_script(id, &HES_NotEnoughPOW); + } + moveOptX += 102; + } + hud_element_set_render_pos(id, moveOptX, moveOptY + 7); + hud_element_set_alpha(id, battle_menu_moveTextOpacity); + hud_element_draw_without_clipping(id); + } + moveOptY += 13; + } + } + + moveOptX = x + 24; + moveOptY = battle_menu_moveScrollOffset + y + 24; + for (i = 0; i < battle_menu_moveOptionCount; i++) { + if (i >= (battle_menu_moveScrollLine - 1) && i <= (battle_menu_moveScrollLine + D_802AD10E)) { + id = battle_menu_moveOptionIconIDs[i]; + hud_element_set_render_pos(id, moveOptX, moveOptY); + hud_element_set_alpha(id, battle_menu_moveTextOpacity); + hud_element_draw_without_clipping(id); + } + moveOptY += 13; + } + + temp_f6_2 = (f64) ((battle_menu_moveCursorPos - battle_menu_moveScrollLine) * 13 - D_802AD112); + var_t0_4 = D_802AD112 + temp_f6_2; + if (temp_f6_2 == 0) { + var_t0_4 = (battle_menu_moveCursorPos - battle_menu_moveScrollLine) * 13; + } + D_802AD112 = var_t0_4; + + id = battle_menu_moveCursorIcon; + hud_element_set_render_pos(id, x + 10, y + (var_t0_4 + 26)); + hud_element_set_alpha(id, battle_menu_moveTextOpacity); + hud_element_draw_without_clipping(id); + + if (battle_menu_moveScrollLine > 0) { + id = battle_menu_moveUpArrowIcon; + hud_element_set_render_pos(id, x + 72, y + 15); + hud_element_set_alpha(id, battle_menu_moveTextOpacity); + hud_element_draw_clipped(id); + } + + if (D_802AD10D < battle_menu_moveOptionCount) { + id = battle_menu_moveDownArrowIcon; + hud_element_set_render_pos(id, x + 72, y + 100); + hud_element_set_alpha(id, battle_menu_moveTextOpacity); + hud_element_draw_clipped(id); + } + + if (battle_menu_moveState == -1) { + if (!battle_menu_hasSpiritsMenu) { + status_menu_stop_blinking_fp(); + } else { + status_menu_stop_blinking_sp(); + } + } + break; + } +} +#else INCLUDE_ASM(s32, "415D90", func_802A3C98); +#endif void func_802A43DC(s32 arg0, s32 x, s32 y) { s32 msgID; @@ -763,7 +1585,7 @@ void func_802A4534(s32 arg0, s32 x, s32 y) { if (D_802AD258 != 0) { msgID = 0x1D00C3; - } else if (battle_menu_hasSpiritsMenu == FALSE) { + } else if (!battle_menu_hasSpiritsMenu) { msgID = 0x1D009F; } else { msgID = 0x1D00A0; @@ -888,6 +1710,7 @@ s32 func_802A4A54(void) { s32 x; s32 y; s32 width; + s32 msgID; s32 i; switch (D_802AD604) { @@ -1033,12 +1856,14 @@ s32 func_802A4A54(void) { set_window_update(7, 2); set_window_update(8, 2); if (D_802AD610 == 0) { - width = get_msg_width(0x1D00CB, 0); - set_window_properties(9, (SCREEN_WIDTH / 2) - ((width + 23) / 2), 80, width + 23, 28, 0x14, func_802A57C8, NULL, -1); + msgID = 0x1D0000; + msgID |= 0xCB; } else { - width = get_msg_width(0x1D00CC, 0); - set_window_properties(9, (SCREEN_WIDTH / 2) - ((width + 23) / 2), 80, width + 23, 28, 0x14, func_802A57C8, NULL, -1); + msgID = 0x1D0000; + msgID |= 0xCC; } + width = get_msg_width(msgID, 0) + 23; + set_window_properties(9, (SCREEN_WIDTH / 2) - ((width) / 2), 80, width, 28, 0x14, func_802A57C8, NULL, -1); set_window_update(9, 1); D_802AD612 = 60; D_802AD604 = 42; @@ -1107,7 +1932,7 @@ void func_802A5290(s32 arg0, s32 x, s32 y) { xTemp = x + 33; phi_s1 = y + (D_802AD60C + 19); - for (i = 0; i < D_802AD66C; i++, phi_s1 += 0xD) { + for (i = 0; i < D_802AD66C; i++, phi_s1 += 13) { s32 palette = D_802AD614; if (D_802AD678[i] == 5 && is_ability_active(ABILITY_QUICK_CHANGE)) { @@ -1121,7 +1946,7 @@ void func_802A5290(s32 arg0, s32 x, s32 y) { xTemp = x + 24; phi_s1_2 = D_802AD60C + y + 24; - for (i = 0; i < D_802AD66C; i++, phi_s1_2 += 0xD) { + for (i = 0; i < D_802AD66C; i++, phi_s1_2 += 13) { iconIndex = D_802AD628[i]; hud_element_set_render_pos(iconIndex, xTemp, phi_s1_2); @@ -1184,14 +2009,22 @@ void func_802A5738(s32 arg0, s32 x, s32 y) { // regalloc, arg setting order dumbness #ifdef NON_EQUIVALENT void func_802A57C8(s32 arg0, s32 x, s32 y) { - x += 11; - y += 6; + s32 a0; + + s32 x2; + s32 y2; + + x2 = x + 11; + y2 = y + 6; if (D_802AD610 == 0) { - draw_msg(0x1D00CB, x, y, 255, 15, 0); + a0 = 0x1D0000; + a0 |= 0xCB; } else { - draw_msg(0x1D00CC, x, y, 255, 15, 0); + a0 = 0x1D0000; + a0 |= 0xCC; } + draw_msg(a0, x2, y2, 255, 15, 0); } #else INCLUDE_ASM(s32, "415D90", func_802A57C8); @@ -1205,8 +2038,11 @@ s32 can_btl_state_update_switch_to_player(void) { return FALSE; } else { s8 debuff = player->debuff; - s32 playerCantMove = player->koStatus == STATUS_DAZE; + s32 playerCantMove = FALSE; + if (player->koStatus == STATUS_DAZE) { + playerCantMove = TRUE; + } if (debuff == STATUS_POISON) { playerCantMove = FALSE; } @@ -1252,8 +2088,11 @@ s32 func_802A58D0(void) { } partnerDebuff = partner->debuff; - partnerCantMove = partner->koStatus == STATUS_DAZE; + partnerCantMove = FALSE; + if (partner->koStatus == STATUS_DAZE) { + partnerCantMove = TRUE; + } if (partnerDebuff == STATUS_POISON) { partnerCantMove = FALSE; } @@ -1518,7 +2357,7 @@ void btl_state_update_peach_menu(void) { battleStatus->selectedMoveID = MOVE_PEACH_FOCUS; battleStatus->selectedItemID = 0xA; battleStatus->currentTargetListFlags = gMoveTable[MOVE_PEACH_FOCUS].flags; - btl_set_state(0x11); + btl_set_state(BATTLE_STATE_SELECT_TARGET); } break; case 4: @@ -1579,7 +2418,180 @@ s32 func_802AA0A4(void) { return (gBattleStatus.flags2 & 2) <= 0; } +// weird sub stuff +#ifdef NON_MATCHING +void btl_state_update_twink_menu(void) { + BattleStatus* battleStatus = &gBattleStatus; + Actor* player = battleStatus->playerActor; + Actor* partner = battleStatus->partnerActor; + s32 temp_s0_2; + s32 var_v0_2; + s32 cond; + s32 z; + + switch (gBattleState2) { + case BATTLE_STATE2_UNK_0: + cond = FALSE; + if (player->debuff == STATUS_SLEEP) { + cond = TRUE; + } + if (player->debuff == STATUS_FEAR) { + cond = TRUE; + } + if (player->debuff == STATUS_DIZZY) { + cond = TRUE; + } + if (player->debuff == STATUS_PARALYZE) { + cond = TRUE; + } + if (player->debuff == STATUS_FROZEN) { + cond = TRUE; + } + if (player->debuff == STATUS_STOP) { + cond = TRUE; + } + if (player->stoneStatus == STATUS_STONE) { + cond = TRUE; + } + if (player->koStatus == STATUS_DAZE) { + cond = TRUE; + } + + if (cond) { + btl_set_state(BATTLE_STATE_END_PLAYER_TURN); + break; + } + + btl_cam_use_preset(BTL_CAM_PRESET_C); + btl_cam_move(10); + if (!(gBattleStatus.flags1 & BS_FLAGS1_100000)) { + player->state.currentPos.x = player->homePos.x; + player->state.currentPos.z = player->homePos.z; + player->state.goalPos.x = partner->homePos.x; + player->state.goalPos.z = partner->homePos.z; + gBattleState2 = BATTLE_STATE2_PLAYER_DEFEATED; + player->state.moveTime = 4; + player->state.angle = 0.0f; + break; + } + gBattleState2 = BATTLE_STATE2_UNK_B; + break; + case BATTLE_STATE2_PLAYER_DEFEATED: + if (player->state.moveTime != 0) { + player->currentPos.x += (player->state.goalPos.x - player->currentPos.x) / player->state.moveTime; + player->currentPos.z += (player->state.goalPos.z - player->currentPos.z) / player->state.moveTime; + partner->currentPos.x += (player->state.currentPos.x - partner->currentPos.x) / player->state.moveTime; + partner->currentPos.z += (player->state.currentPos.z - partner->currentPos.z) / player->state.moveTime; + } + player->currentPos.z += sin_rad((player->state.angle * TAU) / 360.0f) * 16.0f; + player->yaw = clamp_angle(-player->state.angle); + partner->currentPos.z -= sin_rad((player->state.angle * TAU) / 360.0f) * 16.0f; + partner->yaw = clamp_angle(-player->state.angle); + player->state.angle += 90.0f; + if (player->state.moveTime != 0) { + player->state.moveTime--; + break; + } + player->currentPos.x = player->state.goalPos.x; + player->currentPos.z = player->state.goalPos.z; + partner->currentPos.x = player->state.currentPos.x; + partner->currentPos.z = player->state.currentPos.z; + player->homePos.x = player->currentPos.x; + player->homePos.z = player->currentPos.z; + partner->homePos.x = partner->currentPos.x; + partner->homePos.z = partner->currentPos.z; + gBattleStatus.flags1 |= BS_FLAGS1_100000; + case BATTLE_STATE2_UNK_B: + gBattleStatus.flags1 |= BS_FLAGS1_2; + player->flags &= ~ACTOR_FLAG_4000000; + player->flags |= ACTOR_FLAG_8000000; + if (partner != NULL) { + partner->flags |= ACTOR_FLAG_4000000; + partner->flags |= ACTOR_FLAG_8000000; + } + battleStatus->selectedMoveID = MOVE_NONE; + battle_menu_submenuIDs = 8; + + battle_menu_isEnabled = TRUE; + battle_menu_isMessageDisabled = 0; + main_battle_menu_JumpHudScripts = battle_menu_TwinkStarPowerHudScripts[0]; + *battle_menu_messageIDs = *D_802AB734; + if (!(battleStatus->menuDisableFlags & 0x100)) { + battle_menu_isEnabled = FALSE; + battle_menu_isMessageDisabled = 0x48; + main_battle_menu_JumpHudScripts = battle_menu_TwinkStarPowerHudScripts[1]; + } + + z = 0; + if (func_802AA0A4() != 0) { + D_802AD104 = 1; + var_v0_2 = 2 - z; + } else { + D_802AD104 = 0; + var_v0_2 = 2 - z; + } + main_menu_numOptions = 1; + D_802AD0A8 = 0; + D_802AD0B0 = 0; + D_802AD100 = var_v0_2; + + func_802A1000(); + D_802ACC60 = 8; + gBattleState2 = BATTLE_STATE2_UNK_1; + break; + case BATTLE_STATE2_UNK_1: + set_animation(ACTOR_PARTNER, 0, 0x200001); + temp_s0_2 = func_802A11B0(); + if (D_802ACC60 != 0) { + D_802ACC60--; + break; + } + if (temp_s0_2 != 0) { + set_animation(ACTOR_PARTNER, 0, 0x200008); + battleStatus->currentSubmenu = battle_menu_submenuIDs[temp_s0_2 - 1]; + func_802A1030(); + D_802ACC60 = 8; + D_802ACC6C = 4; + gBattleState2 = BATTLE_STATE2_UNK_2; + } + break; + case BATTLE_STATE2_UNK_2: + if (func_802A11B0() != 0) { + battleStatus->unk_6C = 4; + battleStatus->unk_6E = 5; + battleStatus->moveCategory = 8; + battleStatus->selectedMoveID = MOVE_TWINK_DASH; + battleStatus->selectedItemID = ITEM_NONE; + battleStatus->currentTargetListFlags = gMoveTable[MOVE_TWINK_DASH].flags; + btl_set_state(BATTLE_STATE_SELECT_TARGET); + } + break; + case BATTLE_STATE2_UNK_4: + func_802A1050(); + gBattleState2 = BATTLE_STATE2_UNK_1; + btl_state_update_twink_menu(); + btl_state_update_twink_menu(); + break; + case BATTLE_STATE2_UNK_5: + func_802A10B8(); + break; + case BATTLE_STATE2_UNK_8: + btl_show_variable_battle_message(0x50, 60, 0); + D_802AD607 = 1; + gBattleState2 = BATTLE_STATE2_UNK_9; + break; + case BATTLE_STATE2_UNK_9: + if (!btl_is_popup_displayed()) { + D_802AD607 = 0; + D_802ACC60 = 0; + gBattleState2 = BATTLE_STATE2_UNK_1; + } + break; + } +} +#else INCLUDE_ASM(s32, "415D90", btl_state_update_twink_menu); // look into m2c bug +#endif void btl_state_draw_twink_menu(void) { switch (gBattleState2) { @@ -1606,9 +2618,382 @@ void btl_state_draw_twink_menu(void) { } } -INCLUDE_ASM(s32, "415D90", btl_state_update_select_target); +void btl_state_update_select_target(void) { + BattleStatus* battleStatus = &gBattleStatus; + Actor* actor; + s32 targetListLength; + s32 selectedTargetIndex; + s32 id; + s8* targetIndexList; + SelectableTarget* target; + s32 i; -INCLUDE_ASM(s32, "415D90", btl_state_draw_select_target); + if (!(gBattleStatus.flags1 & BS_FLAGS1_80000)) { + actor = battleStatus->playerActor; + } else { + actor = battleStatus->partnerActor; + } + targetListLength = actor->targetListLength; + selectedTargetIndex = actor->selectedTargetIndex; + + actor->flags &= ~ACTOR_FLAG_8000000; + targetIndexList = actor->targetIndexList; + switch (gBattleState2) { + case BATTLE_STATE2_UNK_0: + D_802ACC64 = 0xFF; + D_802ACC68 = -100; + gBattleStatus.flags1 &= ~BS_FLAGS1_2; + if (!is_ability_active(ABILITY_BERSERKER) || (gBattleStatus.flags1 & BS_FLAGS1_80000)) { + if (battleStatus->selectedMoveID != MOVE_NONE) { + s8 actionTip = gMoveTable[battleStatus->selectedMoveID].actionTip; + + if (actionTip >= 0) { + btl_show_battle_message(actionTip + 0x2E, 60); + } + } + } + player_create_target_list(actor); + targetListLength = actor->targetListLength; + if (battleStatus->currentTargetListFlags & 1) { + targetIndexList = actor->targetIndexList; + for (i = 0; i < targetListLength; i++) { + target = &actor->targetData[targetIndexList[i]]; + if (get_actor_part(get_actor(target->actorID), target->partID)->flags & ACTOR_PART_FLAG_8) { + actor->selectedTargetIndex = i; + break; + } + } + } + + if (battleStatus->currentTargetListFlags < 0) { + if (!(gBattleStatus.flags1 & BS_FLAGS1_80000)) { + gBattleState2 = battleStatus->unk_6E; + if (gBattleStatus.flags2 & BS_FLAGS2_40) { + btl_state_update_player_menu(); + } else { + btl_state_update_player_menu(); + } + btl_set_state(BATTLE_STATE_PLAYER_MOVE); + } else { + gBattleState2 = battleStatus->unk_6E; + if (gBattleStatus.flags2 & BS_FLAGS2_40) { + btl_state_update_twink_menu(); + } else { + btl_state_update_partner_menu(); + } + btl_set_state(BATTLE_STATE_PARTNER_MOVE); + } + return; + } + + if (targetListLength == 0) { + if (!(gBattleStatus.flags1 & BS_FLAGS1_80000)) { + gBattleState2 = battleStatus->unk_6E; + if (gBattleStatus.flags2 & BS_FLAGS2_40) { + btl_state_update_player_menu(); + } else { + btl_state_update_player_menu(); + } + btl_set_state(BATTLE_STATE_PLAYER_MOVE); + } else { + gBattleState2 = battleStatus->unk_6E; + if (gBattleStatus.flags2 & BS_FLAGS2_40) { + btl_state_update_twink_menu(); + } else { + btl_state_update_partner_menu(); + } + btl_set_state(BATTLE_STATE_PARTNER_MOVE); + } + return; + } + + for (i = 0; i < targetListLength; i++) { + id = hud_element_create(&HES_HandPointDownLoop); + D_802ACC70[i] = id; + hud_element_set_render_depth(id, 0); + hud_element_set_render_pos(id, 0, -100); + } + gBattleState2 = BATTLE_STATE2_UNK_1; + break; + case BATTLE_STATE2_UNK_1: + if (D_802ACC68 < 0) { + D_802ACC68 += 20; + if (D_802ACC68 > 0) { + D_802ACC68 = 0; + } + } + + if (battleStatus->currentButtonsPressed & BUTTON_B) { + sfx_play_sound(SOUND_MENU_BACK); + gBattleState2 = BATTLE_STATE2_PLAYER_DEFEATED; + break; + } + + if (battleStatus->currentButtonsPressed & BUTTON_A) { + sfx_play_sound(SOUND_MENU_NEXT); + D_802ACC60 = 8; + D_802ACC6C = 4; + gBattleState2 = BATTLE_STATE2_UNK_2; + break; + } + + gBattleStatus.flags1 |= BS_FLAGS1_2; + if (battleStatus->currentButtonsDown & (BUTTON_Z | BUTTON_R)) { + gBattleStatus.flags1 &= ~BS_FLAGS1_2; + break; + } + + if (battleStatus->currentTargetListFlags & 1) { + s32 oldSelectedTargetIndex = selectedTargetIndex; + + if (battleStatus->currentButtonsHeld & BUTTON_STICK_LEFT) { + selectedTargetIndex--; + } + if (battleStatus->currentButtonsHeld & BUTTON_STICK_RIGHT) { + selectedTargetIndex++; + } + if (selectedTargetIndex < 0) { + selectedTargetIndex = targetListLength - 1; + } + if (selectedTargetIndex >= targetListLength) { + selectedTargetIndex = 0; + } + if (selectedTargetIndex != oldSelectedTargetIndex) { + s32 actorFlags; + + target = &actor->targetData[targetIndexList[selectedTargetIndex]]; + actorFlags = get_actor(target->actorID)->flags; + id = D_802ACC70[0]; + + if (actorFlags & ACTOR_FLAG_HP_OFFSET_BELOW) { + hud_element_set_script(id, &HES_HandPointLeftLoop); + } else { + hud_element_set_script(id, &HES_HandPointDownLoop); + } + sfx_play_sound(SOUND_MENU_CHANGE_SELECTION); + } + actor->selectedTargetIndex = selectedTargetIndex; + } + break; + case BATTLE_STATE2_UNK_2: + gBattleStatus.flags1 &= ~BS_FLAGS1_2; + target = &actor->targetData[targetIndexList[actor->selectedTargetIndex]]; + actor->targetActorID = target->actorID; + actor->targetPartIndex = target->partID; + for (i = 0; i < targetListLength; i++) { + hud_element_free(D_802ACC70[i]); + } + + if (!(gBattleStatus.flags1 & BS_FLAGS1_80000)) { + gBattleState2 = battleStatus->unk_6E; + if (gBattleStatus.flags2 & BS_FLAGS2_40) { + btl_state_update_peach_menu(); + } else { + btl_state_update_player_menu(); + } + btl_set_state(BATTLE_STATE_PLAYER_MOVE); + } else { + gBattleState2 = battleStatus->unk_6E; + if (gBattleStatus.flags2 & BS_FLAGS2_40) { + btl_state_update_twink_menu(); + } else { + btl_state_update_partner_menu(); + } + btl_set_state(BATTLE_STATE_PARTNER_MOVE); + } + break; + case BATTLE_STATE2_PLAYER_DEFEATED: + for (i = 0; i < targetListLength; i++) { + hud_element_free(D_802ACC70[i]); + } + gBattleStatus.flags1 |= BS_FLAGS1_10000 | BS_FLAGS1_2; + actor->flags |= ACTOR_FLAG_8000000; + + if (battleStatus->itemUsesLeft != 0) { + btl_set_state(BATTLE_STATE_PLAYER_MENU); + gBattleState2 = battleStatus->unk_6C; + if (gBattleStatus.flags2 & BS_FLAGS2_40) { + btl_state_update_peach_menu(); + } else { + btl_state_update_player_menu(); + } + } else if (!(gBattleStatus.flags1 & BS_FLAGS1_80000)) { + btl_set_state(BATTLE_STATE_PLAYER_MENU); + gBattleState2 = battleStatus->unk_6C; + if (gBattleStatus.flags2 & BS_FLAGS2_40) { + btl_state_update_peach_menu(); + } else { + btl_state_update_player_menu(); + } + } else { + btl_set_state(BATTLE_STATE_PARTNER_MENU); + gBattleState2 = battleStatus->unk_6C; + if (gBattleStatus.flags2 & BS_FLAGS2_40) { + btl_state_update_twink_menu(); + } else { + btl_state_update_partner_menu(); + } + } + break; + } +} + +void btl_state_draw_select_target(void) { + BattleStatus* battleStatus = &gBattleStatus; + PlayerData* playerData = &gPlayerData; + s32 msgID; + s32 msgX; + s32 msgY; + s32 targetListLength; + s32 currentPartner; + s32 actorID; + SelectableTarget* target; + Actor* actor; + Actor* anotherActor; + s32 id; + s32 msgWidth; + s32 xOffset, yOffset; + f32 targetX, targetY, targetZ; + s32 screenX, screenY, screenZ; + s32 selectedTargetIndex; + s8* targetIndexList; + s32* tmpPtr; // TODO required to match and CURSED + + if (!(gBattleStatus.flags1 & BS_FLAGS1_80000)) { + actor = battleStatus->playerActor; + } else { + actor = battleStatus->partnerActor; + } + + targetListLength = actor->targetListLength; + target = actor->targetData; + selectedTargetIndex = actor->selectedTargetIndex; + targetIndexList = actor->targetIndexList; + + tmpPtr = &D_802ACC68; + + if (targetListLength != 0) { + if (battleStatus->currentTargetListFlags & 1) { + target = &actor->targetData[targetIndexList[selectedTargetIndex]]; + anotherActor = get_actor(target->actorID); + id = D_802ACC70[0]; + targetX = target->pos.x; + targetY = target->pos.y; + targetZ = target->pos.z; + + if (anotherActor->flags & ACTOR_FLAG_HP_OFFSET_BELOW) { + xOffset = 16; + yOffset = 2; + if (hud_element_get_script(id) != &HES_HandPointLeftLoop) { + hud_element_set_script(id, &HES_HandPointLeftLoop); + } + } else { + xOffset = 5; + yOffset = -11; + if (hud_element_get_script(id) != &HES_HandPointDownLoop) { + hud_element_set_script(id, &HES_HandPointDownLoop); + } + } + + get_screen_coords(1, targetX, targetY, targetZ, &screenX, &screenY, &screenZ); + hud_element_set_render_pos(id, screenX + xOffset, screenY + yOffset); + hud_element_set_alpha(id, D_802ACC64); + } else { + s32 i; + + for (i = 0; i < targetListLength; i++) { + target = &actor->targetData[targetIndexList[i]]; + anotherActor = get_actor(target->actorID); + id = D_802ACC70[i]; + targetX = target->pos.x; + targetY = target->pos.y; + targetZ = target->pos.z; + if (anotherActor->flags & ACTOR_FLAG_HP_OFFSET_BELOW) { + xOffset = 16; + yOffset = 2; + if (hud_element_get_script(id) != &HES_HandPointLeftLoop) { + hud_element_set_script(id, &HES_HandPointLeftLoop); + } + } else { + xOffset = 5; + yOffset = -11; + if (hud_element_get_script(id) != &HES_HandPointDownLoop) { + hud_element_set_script(id, &HES_HandPointDownLoop); + } + } + get_screen_coords(1, targetX, targetY, targetZ, &screenX, &screenY, &screenZ); + hud_element_set_render_pos(id, screenX + xOffset, screenY + yOffset); + hud_element_set_alpha(id, D_802ACC64); + } + } + + currentPartner = playerData->currentPartner; + screenX = 52; + screenY = 64; + if (gBattleStatus.flags2 & BS_FLAGS2_40) { + currentPartner = PARTNER_TWINK; + } + + if ((battleStatus->currentTargetListFlags & 1) || targetListLength == 1) { + actorID = target->actorID; + if (actorID == ACTOR_PLAYER) { + msgWidth = get_msg_width(0x1D00C4, 0) + 10; + } else if (actorID == ACTOR_PARTNER) { + msgWidth = get_msg_width(D_802AB738[currentPartner], 0) + 10; + } else { + target = &actor->targetData[targetIndexList[selectedTargetIndex]]; + anotherActor = get_actor(target->actorID); + msgID = get_actor_part(anotherActor, target->partID)->staticData->unk_20; + if (msgID == 0) { + msgID = bActorNames[anotherActor->actorType]; + } + msgWidth = get_msg_width(msgID, 0) + 10; + } + } else { + target = &actor->targetData[targetIndexList[selectedTargetIndex]]; + actorID = target->actorID; + if (actorID == ACTOR_PLAYER) { + msgWidth = get_msg_width(0x1D00C4, 0) + 10; + } else if (actorID == ACTOR_PARTNER) { + msgWidth = get_msg_width(D_802AB738[currentPartner], 0) + 10; + } else { + msgWidth = get_msg_width(0x1D00C5, 0) + 10; + } + } + + draw_box(0, 4, screenX + D_802ACC68, screenY, 0, msgWidth, 20, 255, 0, + 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, NULL, NULL, NULL, SCREEN_WIDTH, SCREEN_HEIGHT, NULL); + + screenX += 4; + screenY += 2; + if ((battleStatus->currentTargetListFlags & 1) || targetListLength == 1) { + actorID = target->actorID; + if (actorID == ACTOR_PLAYER) { + draw_msg(0x1D00C4, screenX + D_802ACC68, screenY, 255, 0x36, 0); + } else if (actorID == ACTOR_PARTNER) { + draw_msg(D_802AB738[currentPartner], screenX + D_802ACC68, screenY, 255, 0x36, 0); + } else { + target = &actor->targetData[targetIndexList[selectedTargetIndex]]; + anotherActor = get_actor(target->actorID); + msgID = get_actor_part(anotherActor, target->partID)->staticData->unk_20; + if (msgID == 0) { + msgID = bActorNames[anotherActor->actorType]; + } + draw_msg(msgID, screenX + *tmpPtr, screenY, 255, 0x36, 0); // TODO required to match + } + } else { + target = &actor->targetData[targetIndexList[selectedTargetIndex]]; + actorID = target->actorID; + if (actorID == ACTOR_PLAYER) { + draw_msg(0x1D00C4, screenX + D_802ACC68, screenY, 255, 0x36, 0); + } else if (actorID == ACTOR_PARTNER) { + draw_msg(D_802AB738[currentPartner], screenX + D_802ACC68, screenY, 255, 0x36, 0); + } else { + draw_msg(0x1D00C5, screenX + D_802ACC68, screenY, 255, 0x36, 0); + } + } + } +} void btl_state_update_22(void) { } diff --git a/src/7B440.c b/src/7B440.c index 01eba479d7..36888157dc 100644 --- a/src/7B440.c +++ b/src/7B440.c @@ -36,7 +36,6 @@ void update_player_input(void) { } } -#ifdef NON_MATCHING void reset_player_status(void) { PlayerStatus* playerStatus = &gPlayerStatus; MapSettings* mapSettings; @@ -80,11 +79,11 @@ void reset_player_status(void) { gGameStatusPtr->peachCookingIngredient = 0; } - // This grossness is needed for matching - floatsTemp = &DefaultMoveSpeeds[0]; - playerStatus->walkSpeed = *(floatsTemp++) * one; - playerStatus->runSpeed = *(floatsTemp++) * one; - playerStatus->maxJumpSpeed = *(floatsTemp++) * one; + // TODO required to match + floatsTemp = &(&D_800F7B74)[-1]; // index of 0 does not work + playerStatus->walkSpeed = *floatsTemp++ * one; + playerStatus->runSpeed = *floatsTemp++ * one; + playerStatus->maxJumpSpeed = *floatsTemp++ * one; set_action_state(ACTION_STATE_IDLE); @@ -103,7 +102,7 @@ void reset_player_status(void) { playerStatus->unk_90[CAM_TATTLE] = 0.0f; playerStatus->unk_90[CAM_3] = 0.0f; - mapSettings = gAreas[gGameStatusPtr->areaID].maps[gGameStatusPtr->mapID].config; + mapSettings = gAreas[gGameStatusPtr->areaID].maps[gGameStatusPtr->mapID].settings; if (mapSettings->entryList != NULL) { if (gGameStatusPtr->entryID < mapSettings->entryCount) { @@ -118,12 +117,9 @@ void reset_player_status(void) { gCameras[CAM_DEFAULT].targetPos.y = playerStatus->position.y; gCameras[CAM_DEFAULT].targetPos.z = playerStatus->position.z; - phys_reset_spin_history(mapSettings); + phys_reset_spin_history(); mem_clear(&gPlayerSpinState, sizeof(gPlayerSpinState)); } -#else -INCLUDE_ASM(s32, "7B440", reset_player_status); -#endif void get_packed_buttons(s32* arg0) { PlayerStatus* playerStatus = &gPlayerStatus; diff --git a/src/7fd10_len_b40.c b/src/7fd10_len_b40.c index 61c4b79a78..aba4263b44 100644 --- a/src/7fd10_len_b40.c +++ b/src/7fd10_len_b40.c @@ -233,12 +233,12 @@ block_17: switch (D_8010CCF8) { case 0: if (playerStatus->flags & PLAYER_STATUS_FLAGS_40) { - sfx_play_sound(0x21D); + sfx_play_sound(SOUND_MENU_ERROR); if (D_8010C9C0) { func_800E6860(); playerStatus->flags &= ~PLAYER_STATUS_FLAGS_20; gOverrideFlags &= ~GLOBAL_OVERRIDES_40; - set_time_freeze_mode(0); + set_time_freeze_mode(TIME_FREEZE_NORMAL); } } else { numEntries = setup_partner_popup(popup); @@ -280,7 +280,7 @@ block_17: func_800E6860(); playerStatus->flags &= ~PLAYER_STATUS_FLAGS_20; gOverrideFlags &= ~GLOBAL_OVERRIDES_40; - set_time_freeze_mode(0); + set_time_freeze_mode(TIME_FREEZE_NORMAL); } } else { D_8010CCFA--; @@ -299,7 +299,7 @@ block_17: return; } create_popup_menu(popup); - set_time_freeze_mode(3); + set_time_freeze_mode(TIME_FREEZE_PARTNER_MENU); if (partnerActionStatus->partnerActionState == 0) { set_action_state(ACTION_STATE_IDLE); } @@ -353,7 +353,7 @@ block_17: func_800E6860(); playerStatus->flags &= ~PLAYER_STATUS_FLAGS_20; gOverrideFlags &= ~GLOBAL_OVERRIDES_40; - set_time_freeze_mode(0); + set_time_freeze_mode(TIME_FREEZE_NORMAL); } break; case 10: diff --git a/src/80850_len_3060.c b/src/80850_len_3060.c index b75d1b1cce..1aea43c4b3 100644 --- a/src/80850_len_3060.c +++ b/src/80850_len_3060.c @@ -1,10 +1,20 @@ #include "common.h" #include "hud_element.h" +extern HudScript* TimesHudScript; +extern HudScript* SPIncrementHudScripts[]; +extern HudScript* SPStarHudScripts[]; +extern s32 D_800F7FE8; +extern s32 D_800F7FEC; +extern s32 D_800F7FF0; +extern s32 D_800F7FF4; +extern s32 D_800F7FF8; +extern s32 D_800F7FFC; +extern s32 D_800F8000[]; + extern s16 D_8010CD10; extern s16 D_8010CD12; -extern s32 TimesHudScript; extern s32 DigitHudScripts[10]; extern HudScript HES_StatusHP; @@ -16,6 +26,8 @@ extern HudScript HES_StatusStarPoint; extern HudScript HES_StatusStar1; extern HudScript HES_StatusTimes; extern HudScript HES_StatusSPShine; +extern HudScript HES_StatusSPEmptyIncrement; +extern HudScript HES_StatusStarEmpty; extern HudScript SlashHudScript; @@ -325,10 +337,10 @@ void initialize_status_menu(void) { uiStatus->starpointsBlinkCounter = 0; uiStatus->unk_6C[2] = -1; uiStatus->unk_3B[1] = 0; - uiStatus->unk_57[0] = 0; - uiStatus->unk_57[1] = 0; - uiStatus->unk_57[2] = 0; - uiStatus->unk_57[3] = 0; + uiStatus->unk_57 = 0; + uiStatus->unk_58 = 0; + uiStatus->unk_59 = 0; + uiStatus->spBarsToBlink = 0; uiStatus->unk_6C[0] = 0; uiStatus->unk_6C[1] = 0; uiStatus->iconIndex12 = -1; @@ -955,13 +967,14 @@ void reset_status_menu(void) { // Weird order of loading stuff #ifdef NON_EQUIVALENT s32 is_ability_active(s32 ability) { - s32 abilityMoveID; PlayerData* playerData = &gPlayerData; s32 attackFXArray[6]; + s32 abilityMoveID; s32 ret; s32 attackFXIndex; - s32 badgeMoveID; s32 i; + s32 badgeMoveID; + u8* moveID; ret = 0; attackFXIndex = 0; @@ -974,17 +987,15 @@ s32 is_ability_active(s32 ability) { return 0; } - for (i = 0; i < ARRAY_COUNT(playerData->equippedBadges); i++) { - s32 b = playerData->equippedBadges[i]; + badgeMoveID = playerData->equippedBadges[i]; - if (b != 0) { - badgeMoveID = gItemTable[b].moveID; + if (badgeMoveID != 0) { + moveID = &gItemTable[badgeMoveID].moveID; + badgeMoveID = *moveID; } switch (ability) { - default: - continue; case ABILITY_DODGE_MASTER: abilityMoveID = 0x4c; break; @@ -1178,6 +1189,9 @@ s32 is_ability_active(s32 ability) { case ABILITY_HEALTHY_HEALTHY: abilityMoveID = 0x4a; break; + default: + do { } while (0); + continue; } if (badgeMoveID == abilityMoveID) { ret++; @@ -1193,7 +1207,6 @@ s32 is_ability_active(s32 ability) { INCLUDE_ASM(s32, "80850_len_3060", is_ability_active); #endif - s32 is_partner_ability_active(s32 ability) { return 0; } @@ -1274,14 +1287,14 @@ void add_SP(s32 amt) { s32 phi_v1; s32 maxPower; - uiStatus->unk_57[0] = 1; - uiStatus->unk_57[1] = 60; + uiStatus->unk_57 = 1; + uiStatus->unk_58 = 60; phi_v1 = playerData->specialBarsFilled; if (playerData->specialBarsFilled < 0) { phi_v1 = playerData->specialBarsFilled + 31; } - uiStatus->unk_57[2] = phi_v1 >> 5; + uiStatus->unk_59 = phi_v1 >> 5; playerData->specialBarsFilled += amt; diff --git a/src/8a860_len_3f30.c b/src/8a860_len_3f30.c index fb198e8f08..8da6c35bd1 100644 --- a/src/8a860_len_3f30.c +++ b/src/8a860_len_3f30.c @@ -401,20 +401,20 @@ s32 popup_menu_update(void) { case 9: case 12: set_window_update(WINDOW_ID_14, (s32)basic_window_update); - sfx_play_sound(1); + sfx_play_sound(SOUND_1); set_window_update(WINDOW_ID_19, (s32)basic_window_update); break; case 1: case 4: set_window_update(WINDOW_ID_14, (s32)basic_window_update); - sfx_play_sound(2); + sfx_play_sound(SOUND_2); set_window_update(WINDOW_ID_19, (s32)basic_window_update); break; case 10: case 11: case 13: set_window_update(WINDOW_ID_14, (s32)basic_window_update); - sfx_play_sound(1); + sfx_play_sound(SOUND_1); break; } set_window_update(WINDOW_ID_21, WINDOW_UPDATE_SHOW); diff --git a/src/C50A0.c b/src/C50A0.c index 81d31ae8ed..13328db57a 100644 --- a/src/C50A0.c +++ b/src/C50A0.c @@ -4,13 +4,19 @@ #include "pause/pause_common.h" #include "world/partners.h" #include "sparkle_script.h" +#include "item_entity.h" #define MAX_ITEM_ENTITIES 256 extern SparkleScript SparkleScript_Coin; +extern Gfx D_8014B870[]; +extern Gfx D_8014BBD8[]; extern Lights1 D_8014C6C8; +extern HudCacheEntry* gHudElementCacheTableRaster; +extern HudCacheEntry* gHudElementCacheTablePalette; + extern s32 ItemEntitiesCreated; extern s32 D_80155D80; extern s32 ItemEntityAlternatingSpawn; @@ -45,6 +51,7 @@ void update_item_entity_static(ItemEntity*); void func_801356C4(ItemEntity*); void func_801356CC(ItemEntity*); void func_801356D4(ItemEntity*); +void func_801363A0(ItemEntity*); void update_item_entity_temp(ItemEntity*); s32 draw_image_with_clipping(IMG_PTR raster, s32 width, s32 height, s32 fmt, s32 bitDepth, s16 posX, s16 posY, u16 clipULx, u16 clipULy, u16 clipLRx, u16 clipRLy); @@ -668,10 +675,53 @@ s32 make_item_entity_at_player(s32 itemID, s32 arg1, s32 pickupMsgFlags) { return id; } -//TODO remove this -static const f32 rodata_padding_2 = 0.0f; +void item_entity_update(ItemEntity* entity) { + s32* args; + s32 max, threshold; -INCLUDE_ASM(s32, "C50A0", item_entity_update); + entity->nextUpdate--; + if (entity->nextUpdate != 0) { + return; + } + + do { + args = entity->readPos; + switch(*args++) { + case ITEM_SCRIPT_OP_End: + entity->nextUpdate = 60; + return; + case ITEM_SCRIPT_OP_SetImage: + entity->nextUpdate = *args++; + *args++; + *args++; + if (!gGameStatusPtr->isBattle) { + entity->lookupRasterIndex = *args++ & 0xFFFF; + entity->lookupPaletteIndex = *args++ & 0xFFFF; + } else { + entity->lookupRasterIndex = *args++ >> 16; + entity->lookupPaletteIndex = *args++ >> 16; + } + entity->readPos = args; + return; + case ITEM_SCRIPT_OP_Restart: + entity->readPos = entity->savedReadPos; + break; + case ITEM_SCRIPT_OP_Loop: + entity->savedReadPos = args; + entity->readPos = args; + break; + case ITEM_SCRIPT_OP_RandomRestart: + max = *args++; + threshold = *args++; + if (rand_int(max) < threshold) { + entity->readPos = entity->savedReadPos; + } else { + entity->readPos = args; + } + break; + } + } while (TRUE); +} void update_item_entities(void) { ItemEntity* entity; @@ -761,7 +811,153 @@ void update_item_entities(void) { } } -INCLUDE_ASM(s32, "C50A0", appendGfx_item_entity); +void appendGfx_item_entity(void* data) { + ItemEntity* itemEntity = (ItemEntity*)data; + Mtx sp18; + Matrix4f sp58, sp98, spD8; + s32 alpha = 255; + s32 yOffset; + f32 rot; + + if (itemEntity->flags & (ITEM_ENTITY_FLAGS_8000000 | ITEM_ENTITY_FLAGS_TRANSPARENT)) { + if (itemEntity->flags & ITEM_ENTITY_FLAGS_TRANSPARENT) { + alpha = 255; + alpha = (itemEntity->alpha * alpha) / 255; + } + if (itemEntity->flags & ITEM_ENTITY_FLAGS_8000000) { + u8 r, g, b, a; + + get_background_color_blend(&r, &g, &b, &a); + alpha = (alpha * (255 - a)) / 255; + } + } + + if (!(itemEntity->flags & ITEM_ENTITY_FLAGS_40000)) { + yOffset = -2; + } else { + yOffset = -3; + } + + if (itemEntity->itemID == ITEM_COIN || itemEntity->itemID == ITEM_STAR_POINT || itemEntity->itemID == ITEM_HEART) { + itemEntity->scale = 1.0f; + } + + rot = clamp_angle(180.0f - gCameras[gCurrentCamID].currentYaw); + guTranslateF(sp58, itemEntity->position.x, itemEntity->position.y + yOffset, itemEntity->position.z); + guRotateF(sp98, rot, 0.0f, 1.0f, 0.0f); + if (itemEntity->flags & ITEM_ENTITY_FLAGS_TINY) { + guScaleF(spD8, itemEntity->scale, itemEntity->scale, itemEntity->scale); + guMtxCatF(sp98, spD8, sp98); + } + guMtxCatF(sp98, sp58, sp58); + guMtxF2L(sp58, &sp18); + + gDisplayContext->matrixStack[gMatrixListPos] = sp18; + + gSPMatrix(gMasterGfxPos++, &gDisplayContext->matrixStack[gMatrixListPos++], + G_MTX_PUSH | G_MTX_LOAD | G_MTX_MODELVIEW); + + if (D_80151328->flags != 0) { + gSPDisplayList(gMasterGfxPos++, D_8014BBD8); + } else { + gSPDisplayList(gMasterGfxPos++, D_8014B870); + } + gSPClearGeometryMode(gMasterGfxPos++, G_CULL_BOTH | G_LIGHTING); + gSPDisplayList(gMasterGfxPos++, D_8014C620); + + if (itemEntity->flags & (ITEM_ENTITY_FLAGS_8000000 | ITEM_ENTITY_FLAGS_TRANSPARENT)) { + if (D_80151328->flags != 0) { + gDPSetRenderMode(gMasterGfxPos++, AA_EN | IM_RD | CVG_DST_SAVE | ZMODE_OPA | FORCE_BL | G_RM_PASS, + AA_EN | IM_RD | CVG_DST_SAVE | ZMODE_OPA | FORCE_BL | + GBL_c2(G_BL_CLR_IN, G_BL_A_IN, G_BL_CLR_MEM, G_BL_1MA)); + } else { + gDPSetRenderMode(gMasterGfxPos++, AA_EN | IM_RD | CVG_DST_SAVE | ZMODE_OPA | FORCE_BL | + GBL_c1(G_BL_CLR_IN, G_BL_A_IN, G_BL_CLR_MEM, G_BL_1MA), + AA_EN | IM_RD | CVG_DST_SAVE | ZMODE_OPA | FORCE_BL | + GBL_c2(G_BL_CLR_IN, G_BL_A_IN, G_BL_CLR_MEM, G_BL_1MA)); + gDPSetCombineLERP(gMasterGfxPos++, PRIMITIVE, 0, TEXEL0, 0, PRIMITIVE, 0, TEXEL0, 0, PRIMITIVE, 0, + TEXEL0, 0, TEXEL0, 0, PRIMITIVE, 0); + gDPSetPrimColor(gMasterGfxPos++, 0, 0, 255, 255, 255, alpha); + } + } + + if (!(itemEntity->flags & ITEM_ENTITY_FLAGS_40000)) { + gDPLoadTLUT_pal16(gMasterGfxPos++, 0, gHudElementCacheTablePalette[itemEntity->lookupPaletteIndex].data); + if (D_80151328->flags != 0) { + gDPSetTextureImage(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_8b, 12, gHudElementCacheTableRaster[itemEntity->lookupRasterIndex].data); + gDPSetTile(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_8b, 2, 0x0000, G_TX_LOADTILE, 0, G_TX_NOMIRROR | + G_TX_CLAMP, 8, G_TX_NOLOD, G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD); + gDPLoadSync(gMasterGfxPos++); + gDPLoadTile(gMasterGfxPos++, G_TX_LOADTILE, 0, 0, 0x002E, 0x005C); + gDPPipeSync(gMasterGfxPos++); + gDPSetTile(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_4b, 2, 0x0000, 1, 0, G_TX_NOMIRROR | G_TX_CLAMP, 8, + G_TX_NOLOD, G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD); + gDPSetTileSize(gMasterGfxPos++, 1, 0x0400, 0x0400, 0x045C, 0x045C); + gDPSetTile(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_4b, 2, 0x0000, G_TX_RENDERTILE, 1, + G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD, G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD); + gDPSetTile(gMasterGfxPos++, G_IM_FMT_RGBA, G_IM_SIZ_16b, 4, 0x0100, 2, 0, G_TX_NOMIRROR | G_TX_WRAP, + G_TX_NOMASK, G_TX_NOLOD, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMASK, G_TX_NOLOD); + gDPSetTileSize(gMasterGfxPos++, 2, 0, 0, 0x00FC, 0); + + if (itemEntity->flags & (ITEM_ENTITY_FLAGS_8000000 | ITEM_ENTITY_FLAGS_TRANSPARENT)) { + func_801491E4(&sp58, 0, 0, 0x18, 0x18, alpha); + } else { + func_801491E4(&sp58, 0, 0, 0x18, 0x18, 255); + } + } else { + gDPSetTextureImage(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_8b, 12, gHudElementCacheTableRaster[itemEntity->lookupRasterIndex].data); + gDPSetTile(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_8b, 2, 0x0000, G_TX_LOADTILE, 0, + G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD, G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD); + gDPLoadSync(gMasterGfxPos++); + gDPLoadTile(gMasterGfxPos++, G_TX_LOADTILE, 0, 0, 0x002E, 0x005C); + gDPPipeSync(gMasterGfxPos++); + gDPSetTile(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_4b, 2, 0x0000, G_TX_RENDERTILE, 0, + G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD, G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD); + gDPSetTileSize(gMasterGfxPos++, G_TX_RENDERTILE, 0x0400, 0x0400, 0x045C, 0x045C); + } + gSPDisplayList(gMasterGfxPos++, D_8014C678); + } else { + gDPLoadTLUT_pal16(gMasterGfxPos++, 0, gHudElementCacheTablePalette[itemEntity->lookupPaletteIndex].data); + if (D_80151328->flags != 0) { + gDPSetTextureImage(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_8b, 16, gHudElementCacheTableRaster[itemEntity->lookupRasterIndex].data); + gDPSetTile(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_8b, 2, 0x0000, G_TX_LOADTILE, 0, + G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD, G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD); + gDPLoadSync(gMasterGfxPos++); + gDPLoadTile(gMasterGfxPos++, G_TX_LOADTILE, 0, 0, 0x003E, 0x007C); + gDPPipeSync(gMasterGfxPos++); + gDPSetTile(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_4b, 2, 0x0000, 1, 0, G_TX_NOMIRROR | G_TX_CLAMP, + 8, G_TX_NOLOD, G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD); + gDPSetTileSize(gMasterGfxPos++, 1, 0x0400, 0x0400, 0x047C, 0x047C); + gDPSetTile(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_4b, 2, 0x0000, G_TX_RENDERTILE, 1, + G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD, G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD); + gDPSetTile(gMasterGfxPos++, G_IM_FMT_RGBA, G_IM_SIZ_16b, 4, 0x0100, 2, 0, G_TX_NOMIRROR | G_TX_WRAP, + G_TX_NOMASK, G_TX_NOLOD, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMASK, G_TX_NOLOD); + gDPSetTileSize(gMasterGfxPos++, 2, 0, 0, 0x00FC, 0); + if (itemEntity->flags & (ITEM_ENTITY_FLAGS_8000000 | ITEM_ENTITY_FLAGS_TRANSPARENT)) { + func_801491E4(&sp58, 0, 0, 0x20, 0x20, alpha); + } else { + func_801491E4(&sp58, 0, 0, 0x20, 0x20, 255); + } + } else { + gDPSetTextureImage(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_8b, 16, gHudElementCacheTableRaster[itemEntity->lookupRasterIndex].data); + gDPSetTile(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_8b, 2, 0x0000, G_TX_LOADTILE, 0, + G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD, G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD); + gDPLoadSync(gMasterGfxPos++); + gDPLoadTile(gMasterGfxPos++, G_TX_LOADTILE, 0, 0, 0x003E, 0x007C); + gDPPipeSync(gMasterGfxPos++); + gDPSetTile(gMasterGfxPos++, G_IM_FMT_CI, G_IM_SIZ_4b, 2, 0x0000, G_TX_RENDERTILE, 0, + G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD, G_TX_NOMIRROR | G_TX_CLAMP, 8, G_TX_NOLOD); + gDPSetTileSize(gMasterGfxPos++, G_TX_RENDERTILE, 0x0400, 0x0400, 0x047C, 0x047C); + } + gSPDisplayList(gMasterGfxPos++, D_8014C6A0); + } + gSPPopMatrix(gMasterGfxPos++, G_MTX_MODELVIEW); + gDPPipeSync(gMasterGfxPos++); + + if (itemEntity->itemID == ITEM_COIN) { + draw_coin_sparkles(itemEntity); + } +} void draw_item_entities(void) { RenderTask rt; @@ -961,7 +1157,7 @@ s32 test_item_player_collision(ItemEntity* item) { return FALSE; } - if (gOverrideFlags & 0x200000) { + if (gOverrideFlags & GLOBAL_OVERRIDES_200000) { return FALSE; } @@ -1622,8 +1818,392 @@ void func_801356CC(ItemEntity* itemEntity) { void func_801356D4(ItemEntity* itemEntity) { } -INCLUDE_ASM(s32, "C50A0", update_item_entity_temp); +void update_item_entity_temp(ItemEntity* itemEntity) { + PlayerData* playerData = &gPlayerData; + PlayerStatus* playerStatus = &gPlayerStatus; + PopupMenu* menu = &D_801565B0; + ItemData* itemData; + s32 numEntries; + s32 msgID; + s32 i; + if (itemEntity->state == 0) { + isPickingUpItem = TRUE; + if (!(itemEntity->flags & ITEM_ENTITY_FLAGS_2000000)) { + disable_player_input(); + partner_disable_input(); + gOverrideFlags |= GLOBAL_OVERRIDES_40; + set_time_freeze_mode(TIME_FREEZE_FULL); + } + item_entity_disable_shadow(itemEntity); + itemEntity->state = 1; + } + + switch (itemEntity->state) { + case 1: + if (!(itemEntity->flags & ITEM_ENTITY_FLAGS_2000000)) { + s32 actionState = playerStatus->actionState; + + if (!(playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_10000000) && + ((playerStatus->timeInAir == 0 && + actionState != ACTION_STATE_JUMP && + actionState != ACTION_STATE_FALLING) || + !playerStatus->enableCollisionOverlapsCheck || + playerStatus->inputEnabledCounter == 0) && + actionState != ACTION_STATE_LAUNCH && + actionState != ACTION_STATE_RIDE && + actionState != ACTION_STATE_IDLE && + (actionState != ACTION_STATE_USE_SPINNING_FLOWER || playerStatus->fallState != 1) + ) { + break; + } + } + + if (!(itemEntity->pickupMsgFlags & 1)) { + if (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_BADGE) { + sfx_play_sound(SOUND_D3); + } else if (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_KEY) { + sfx_play_sound(SOUND_D2); + } else if (itemEntity->itemID == ITEM_COIN) { + sfx_play_sound_at_position( + SOUND_211, 0, itemEntity->position.x, itemEntity->position.y, itemEntity->position.z + ); + } else { + sfx_play_sound(SOUND_D1); + } + } + D_801568E0 = hud_element_create(gItemHudScripts[gItemTable[itemEntity->itemID].hudElemID].enabled); + hud_element_set_flags(D_801568E0, 0x80); + hud_element_set_render_pos(D_801568E0, -100, -100); + itemEntity->state = 2; + + if (!(itemEntity->flags & ITEM_ENTITY_FLAGS_2000000)) { + if (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_CONSUMABLE) { + for (i = 0; i < ARRAY_COUNT(playerData->invItems); i++) { + if (playerData->invItems[i] == ITEM_NONE) { + break; + } + } + + if (i < ARRAY_COUNT(playerData->invItems)) { + playerData->invItems[i] = itemEntity->itemID; + } else { + itemEntity->state = 0xA; + goto block_47; // TODO required to match + } + } + + if (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_KEY) { + for (i = 0; i < ARRAY_COUNT(playerData->keyItems); i++) { + if (playerData->keyItems[i] == ITEM_NONE) { + break; + } + } + + if (i < ARRAY_COUNT(playerData->keyItems)) { + playerData->keyItems[i] = itemEntity->itemID; + } else { + itemEntity->state = 0xA; + goto block_47; // TODO required to match + } + } + + if (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_BADGE) { + for (i = 0; i < ARRAY_COUNT(playerData->badges); i++) { + if (playerData->badges[i] == ITEM_NONE) { + break; + } + } + + if (i < ARRAY_COUNT(playerData->badges)) { + playerData->badges[i] = itemEntity->itemID; + } else { + itemEntity->state = 0xA; + goto block_47; // TODO required to match + } + } + + if (itemEntity->itemID == ITEM_STAR_PIECE) { + playerData->starPieces++; + if (playerData->starPieces > 222) { + playerData->starPieces = 222; + } + } + + if (itemEntity->itemID == ITEM_LUCKY_STAR) { + playerData->hasActionCommands = 1; + } + + if (itemEntity->itemID == ITEM_HAMMER || + itemEntity->itemID == ITEM_SUPER_HAMMER || + itemEntity->itemID == ITEM_ULTRA_HAMMER) + { + playerData->hammerLevel = itemEntity->itemID - 4; + } + + if (itemEntity->itemID == ITEM_JUMP || + itemEntity->itemID == ITEM_SPIN_JUMP || + itemEntity->itemID == ITEM_TORNADO_JUMP) + { + playerData->bootsLevel = itemEntity->itemID - 1; + } + } + +block_47: // TODO required to match + if (itemEntity->flags & ITEM_ENTITY_FLAGS_80000000) { + set_global_flag(itemEntity->boundVar); + } + if (itemEntity->state == 0xA) { + func_801363A0(itemEntity); + set_window_update(0xC, (s32) basic_window_update); + set_window_update(0x11, (s32) basic_window_update); + set_window_update(0x13, (s32) basic_window_update); + } + increment_status_menu_disabled(); + D_801568E4 = 10; + break; + case 2: + if (D_801568E4 == 9) { + if ((gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_BADGE) || + (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_KEY) || + (itemEntity->itemID == ITEM_STAR_PIECE) || + (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_GEAR) || + (itemEntity->flags & ITEM_ENTITY_FLAGS_4000000) || + (itemEntity->pickupMsgFlags & 2)) + { + itemEntity->position.x = playerStatus->position.x; + itemEntity->position.y = playerStatus->position.y + playerStatus->colliderHeight; + itemEntity->position.z = playerStatus->position.z; + suggest_player_anim_setUnkFlag(0x6000C); + } + + if (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_GEAR) { + fx_got_item_outline( + 1, + itemEntity->position.x, + itemEntity->position.y + 8.0f, + itemEntity->position.z, + 1.0f, + &D_801568F0 + ); + } + } + + if (D_801568E4 < 9) { + if ((gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_BADGE) || + (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_KEY) || + (itemEntity->itemID == ITEM_STAR_PIECE) || + (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_GEAR) || + (itemEntity->flags & ITEM_ENTITY_FLAGS_4000000) || + (itemEntity->pickupMsgFlags & 2)) + { + suggest_player_anim_setUnkFlag(0x6000C); + } + } + + if (D_801568E4 == 7) { + if ((gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_BADGE) || + (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_KEY) || + itemEntity->itemID == ITEM_STAR_PIECE || + (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_GEAR) || + (itemEntity->flags & ITEM_ENTITY_FLAGS_4000000) || + (itemEntity->pickupMsgFlags & 2)) + { + itemEntity->flags &= ~ITEM_ENTITY_FLAGS_40; + } + } + + if (D_801568E4 == 6) { + func_801363A0(itemEntity); + set_window_update(0xC, (s32) basic_window_update); + if (itemEntity->itemID != ITEM_STAR_PIECE && itemEntity->itemID != ITEM_COIN) { + set_window_update(0x13, (s32) basic_window_update); + } + } + + if (D_801568E4 != 0) { + D_801568E4--; + return; + } + + if (gGameStatusPtr->pressedButtons[0] & + (BUTTON_STICK_RIGHT | BUTTON_STICK_LEFT | BUTTON_STICK_DOWN | BUTTON_STICK_UP | BUTTON_A | BUTTON_B)) + { + item_entity_disable_shadow(itemEntity); + if (func_800DFCF4() && + playerStatus->actionState != ACTION_STATE_USE_SPINNING_FLOWER && + !(playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_10000000)) + { + set_action_state(ACTION_STATE_IDLE); + } + + if (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_GEAR) { + D_801568F0->data.gotItemOutline->unk_14 = 0xA; + } + set_window_update(0xC, (s32) basic_hidden_window_update); + set_window_update(0x13, (s32) basic_hidden_window_update); + itemEntity->state = 3; + } + break; + case 3: + if (!(gWindows[12].flags & WINDOW_FLAGS_INITIAL_ANIMATION) && + !(gWindows[19].flags & WINDOW_FLAGS_INITIAL_ANIMATION)) + { + itemEntity->state = 4; + } + break; + case 4: + if ((gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_CONSUMABLE) && + !evt_get_variable(NULL, GSWF(97))) + { + evt_set_variable(NULL, GSWF(97), TRUE); + itemEntity->state = 5; + break; + } + + if (itemEntity->itemID == ITEM_STAR_PIECE && !evt_get_variable(NULL, GSWF(101))) { + evt_set_variable(NULL, GSWF(101), TRUE); + itemEntity->state = 5; + break; + } + itemEntity->state = 9; + break; + case 5: + msgID = 0; + if (gItemTable[itemEntity->itemID].typeFlags & ITEM_TYPE_FLAG_CONSUMABLE) { + msgID = 0x1D0002; + } + if (itemEntity->itemID == ITEM_STAR_PIECE) { + msgID = 0x1D0003; + } + D_801568F4 = msg_get_printer_for_msg(msgID, &D_801568F8); + msg_printer_set_origin_pos(D_801568F4, 0, 0); + itemEntity->state = 6; + break; + case 6: + if (D_801568F8 == TRUE) { + isPickingUpItem = FALSE; + } else { + break; + } + case 9: + if (!(itemEntity->flags & ITEM_ENTITY_FLAGS_2000000)) { + set_time_freeze_mode(TIME_FREEZE_NORMAL); + enable_player_input(); + partner_enable_input(); + gOverrideFlags &= ~GLOBAL_OVERRIDES_40; + } + hud_element_free(D_801568E0); + remove_item_entity_by_reference(itemEntity); + sort_items(); + decrement_status_menu_disabled(); + isPickingUpItem = FALSE; + break; + case 10: + numEntries = 0; + if (gGameStatusPtr->pressedButtons[0] & BUTTON_A) { + itemData = &gItemTable[itemEntity->itemID]; + menu->ptrIcon[numEntries] = gItemHudScripts[itemData->hudElemID].enabled; + menu->userIndex[numEntries] = itemEntity->itemID; + menu->enabled[numEntries] = TRUE; + menu->nameMsg[numEntries] = itemData->nameMsg; + menu->descMsg[numEntries] = itemData->shortDescMsg; + numEntries++; + for (i = 0; i < ARRAY_COUNT(playerData->invItems); i++) { + if (playerData->invItems[i] != 0) { + itemData = &gItemTable[playerData->invItems[i]]; + menu->ptrIcon[numEntries] = gItemHudScripts[itemData->hudElemID].enabled; + menu->userIndex[numEntries] = playerData->invItems[i]; + menu->enabled[numEntries] = TRUE; + menu->nameMsg[numEntries] = itemData->nameMsg; + menu->descMsg[numEntries] = itemData->shortDescMsg; + numEntries++; + } + } + menu->popupType = 2; + menu->numEntries = numEntries; + menu->initialPos = 0; + create_popup_menu(menu); + set_window_update(0xC, (s32) basic_hidden_window_update); + set_window_update(0x11, (s32) basic_hidden_window_update); + D_801568E4 = 0; + itemEntity->state = 0xB; + } + break; + case 11: + if (!(gWindows[12].flags & WINDOW_FLAGS_INITIAL_ANIMATION) && + !(gWindows[17].flags & WINDOW_FLAGS_INITIAL_ANIMATION) && + !(gWindows[19].flags & WINDOW_FLAGS_INITIAL_ANIMATION)) + { + itemEntity->state = 0xC; + } + break; + case 12: + if (D_801568E4 == 0) { + D_801568E8 = menu->result; + if (D_801568E8 == 0) { + break; + } + hide_popup_menu(); + } + D_801568E4++; + if (D_801568E4 >= 15) { + destroy_popup_menu(); + if (D_801568E8 == 255) { + D_801568E8 = 1; + } + D_801568EC = menu->userIndex[D_801568E8 - 1]; + hud_element_set_script(D_801568E0, menu->ptrIcon[D_801568E8 - 1]); + + get_item_entity( + make_item_entity_delayed( + D_801568EC, + playerStatus->position.x, + playerStatus->position.y + playerStatus->colliderHeight, + playerStatus->position.z, 3, 0, 0 + ) + )->renderGroup = -1; + + if (D_801568E8 >= 2) { + playerData->invItems[D_801568E8 - 2] = 0; + sort_items(); + add_item(itemEntity->itemID); + } + suggest_player_anim_setUnkFlag(0x6000C); + func_801363A0(itemEntity); + set_window_update(0xC, (s32) basic_window_update); + D_801568E4 = 50; + itemEntity->state = 0xD; + } + break; + case 13: + if (gGameStatusPtr->pressedButtons[0] & BUTTON_A) { + set_window_update(0xC, (s32) basic_hidden_window_update); + itemEntity->state = 0xE; + } + break; + case 14: + if (!(gWindows[12].flags & WINDOW_FLAGS_INITIAL_ANIMATION) && + !(gWindows[17].flags & WINDOW_FLAGS_INITIAL_ANIMATION) && + !(gWindows[19].flags & WINDOW_FLAGS_INITIAL_ANIMATION)) + { + itemEntity->state = 15; + } + break; + case 15: + suggest_player_anim_setUnkFlag(0x10002); + set_time_freeze_mode(TIME_FREEZE_NORMAL); + enable_player_input(); + partner_enable_input(); + gOverrideFlags &= ~GLOBAL_OVERRIDES_40; + hud_element_free(D_801568E0); + remove_item_entity_by_reference(itemEntity); + sort_items(); + decrement_status_menu_disabled(); + isPickingUpItem = FALSE; + break; + } +} #ifdef NON_EQUIVALENT void func_801363A0(ItemEntity* itemEntity) { @@ -1814,6 +2394,3 @@ void func_80136A08(ItemEntity* itemEntity, s32 posX, s32 posY) { break; } } - -// TODO remove this -static const f32 rodata_padding[] = { 0.0f, 0.0f }; diff --git a/src/E20110.c b/src/E20110.c index f44affe0e3..106acf0522 100644 --- a/src/E20110.c +++ b/src/E20110.c @@ -2,19 +2,40 @@ #define NAMESPACE E20110 -typedef struct TempE20110 { - /* 0x00 */ Vec3f unk_00; - /* 0x0C */ char unk_0C[0x14]; - /* 0x20 */ char unk_20[0x1]; - /* 0x21 */ s8 unk_21; - /* 0x22 */ s8 unk_22; -} TempE20110; - extern TempE20110* D_802B7CB8_E20DC8; #include "common/UnkAngleFunc1.inc.c" +void func_802B7728_E20838(void); + +// floatz +#ifdef NON_MATCHING +void func_802B70B4_E201C4(void) { + PlayerStatus* playerStatus = &gPlayerStatus; + f32 new_var; + + if (playerStatus->animFlags & 0x10) { + mem_clear(D_802B7CB8_E20DC8, sizeof(*D_802B7CB8_E20DC8)); + D_8010C950 = -1; + D_802B7CB8_E20DC8->unk_00.x = playerStatus->position.x; + new_var = playerStatus->position.y + playerStatus->colliderHeight; + if (!(playerStatus->animFlags & 0x1000)) { + D_802B7CB8_E20DC8->unk_00.y = new_var + 8.0f; + } else { + D_802B7CB8_E20DC8->unk_00.y = new_var + 2.0f; + } + D_802B7CB8_E20DC8->unk_00.z = playerStatus->position.z; + D_802B7CB8_E20DC8->unk_10 = 0.4f; + D_802B7CB8_E20DC8->unk_23 = 0; + D_802B7CB8_E20DC8->unk_0C = -gCameras[gCurrentCameraID].currentYaw; + D_8010C958 = func_802B7728_E20838; + D_802B7CB8_E20DC8->unk_24 = 0xFF; + D_802B7CB8_E20DC8->unk_1C = 0xFF; + } +} +#else INCLUDE_ASM(s32, "E20110", func_802B70B4_E201C4); +#endif INCLUDE_ASM(s32, "E20110", func_802B71E8_E202F8); @@ -38,20 +59,20 @@ void func_802B75E8_E206F8(void) { D_802B7CB8_E20DC8->unk_21 = -4; } - delta = (playerStatus->position.x - D_802B7CB8_E20DC8->unk_00.x) * 0.666f; - D_802B7CB8_E20DC8->unk_00.x += delta; - delta = (playerStatus->position.z - D_802B7CB8_E20DC8->unk_00.z) * 0.666f; - D_802B7CB8_E20DC8->unk_00.z += delta; + delta = (playerStatus->position.x - D_802B7CB8_E20DC8->pos.x) * 0.666f; + D_802B7CB8_E20DC8->pos.x += delta; + delta = (playerStatus->position.z - D_802B7CB8_E20DC8->pos.z) * 0.666f; + D_802B7CB8_E20DC8->pos.z += delta; yTemp = playerStatus->position.y + playerStatus->colliderHeight; unk_21 = D_802B7CB8_E20DC8->unk_21; - y = D_802B7CB8_E20DC8->unk_00.y; + y = D_802B7CB8_E20DC8->pos.y; if (!(playerStatus->animFlags & 0x1000)) { delta = (yTemp + 8.0f + unk_21 - y) * 0.25f; } else { delta = (yTemp + 2.0f + unk_21 - y) * 0.25f; } - D_802B7CB8_E20DC8->unk_00.y += delta; + D_802B7CB8_E20DC8->pos.y += delta; } INCLUDE_ASM(s32, "E20110", func_802B7728_E20838); diff --git a/src/E21870.c b/src/E21870.c index d8309954bc..ceda324f2c 100644 --- a/src/E21870.c +++ b/src/E21870.c @@ -1,23 +1,177 @@ #include "common.h" +typedef struct TempE21870 { + /* 0x00 */ Vec3f pos; + /* 0x0C */ f32 scale; + /* 0x10 */ f32 unk_10; + /* 0x14 */ char unk_14[0x4]; + /* 0x18 */ s32 unk_18; + /* 0x1C */ s32 unk_1C; + /* 0x20 */ s32 unk_20; + /* 0x24 */ s32 unk_24; +} TempE21870; // size = 0x28 + +extern u8 D_802B7640_E21EB0[]; +extern u16 D_802B7C60_E224D0[]; +extern u16 D_802B7C80_E224F0[]; +extern Gfx D_802B7CA0_E22510[]; +extern TempE21870* D_802B7D18_E22588; + +void func_802B74F0(void); + s32 func_802B7000_2(void) { + PlayerStatus* playerStatus = &gPlayerStatus; PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus; - s8 actionState = gPlayerStatus.actionState; + s8 actionState = playerStatus->actionState; if (actionState != ACTION_STATE_USE_TWEESTER) { if (partnerActionStatus->partnerActionState != PARTNER_ACTION_USE || (partnerActionStatus->actingPartner != PARTNER_BOW && partnerActionStatus->actingPartner != PARTNER_PARAKARRY)) { - return 0; + return FALSE; } } - return 1; + return TRUE; } -INCLUDE_ASM(s32, "E21870", func_802B704C); +s32 func_802B704C(void) { + PlayerStatus* playerStatus = &gPlayerStatus; -INCLUDE_ASM(s32, "E21870", func_802B7140); + if (!is_starting_conversation()) { + if (!(playerStatus->flags & PLAYER_STATUS_FLAGS_20)) { + if (playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_USING_PULSE_STONE) { + if (!has_valid_conversation_npc()) { + if (!func_800E06D8()) { + s32 dx = abs((gGameStatusPtr->mapID % 7) - 2); + s32 dy = gGameStatusPtr->mapID / 7; -INCLUDE_ASM(s32, "E21870", func_802B71D4); + if ((dx + dy) < 6) { + if (!func_802B7000_2()) { + dy = TRUE; // TODO required to set dy to 1 and return that -INCLUDE_ASM(s32, "E21870", func_802B74F0); + return dy; + } + } + } + } + } + } + } + return FALSE; +} + +void func_802B7140(void) { + PlayerStatus* playerStatus = &gPlayerStatus; + + mem_clear(D_802B7D18_E22588, sizeof(*D_802B7D18_E22588)); + D_802B7D18_E22588->pos.x = playerStatus->position.x; + D_802B7D18_E22588->pos.y = playerStatus->position.y + playerStatus->colliderHeight + 8.0f; + D_802B7D18_E22588->pos.z = playerStatus->position.z; + playerStatus->animFlags |= PLAYER_STATUS_ANIM_FLAGS_40; + D_8010C920 = func_802B74F0; +} + +void func_802B71D4(void) { + PlayerStatus* playerStatus = &gPlayerStatus; + Matrix4f sp18, sp58; + FoldImageRecPart part; + s32 var_v1; + s32 dx, dy; + + if (playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_40) { + guScaleF(sp18, D_802B7D18_E22588->scale, D_802B7D18_E22588->scale, D_802B7D18_E22588->scale); + guRotateF(sp58, -gCameras[gCurrentCameraID].currentYaw, 0.0f, 1.0f, 0.0f); + guMtxCatF(sp18, sp58, sp18); + guTranslateF(sp58, D_802B7D18_E22588->pos.x, D_802B7D18_E22588->pos.y, D_802B7D18_E22588->pos.z); + guMtxCatF(sp18, sp58, sp58); + guMtxF2L(sp58, &gDisplayContext->matrixStack[gMatrixListPos]); + + gSPMatrix(gMasterGfxPos++, &gDisplayContext->matrixStack[gMatrixListPos++], + G_MTX_PUSH | G_MTX_LOAD | G_MTX_MODELVIEW); + gSPDisplayList(gMasterGfxPos++, D_802B7CA0_E22510); + + dx = abs((gGameStatusPtr->mapID % 7) - 2); + dy = gGameStatusPtr->mapID / 7; + + switch (dx + dy) { + case 0: + var_v1 = 4; + break; + case 1: + var_v1 = 8; + break; + case 2: + var_v1 = 16; + break; + case 3: + var_v1 = 32; + break; + case 4: + var_v1 = 64; + break; + case 5: + var_v1 = 128; + break; + default: + var_v1 = -1; + D_802B7D18_E22588->unk_20 = 0; + break; + } + + part.palette = D_802B7C60_E224D0; + if (var_v1 >= 0) { + D_802B7D18_E22588->unk_20++; + if (D_802B7D18_E22588->unk_20 >= var_v1 + 2) { + D_802B7D18_E22588->unk_20 = 0; + sfx_play_sound_at_player(SOUND_7D, 0); + } + if (D_802B7D18_E22588->unk_20 < 2) { + part.palette = D_802B7C80_E224F0; + } else { + part.palette = D_802B7C60_E224D0; + } + } + + part.raster = D_802B7640_E21EB0; + part.width = 56; + part.height = 56; + part.xOffset = -28; + part.yOffset = 46; + part.opacity = 255; + fold_appendGfx_component(0, &part, 0, sp58); + gSPPopMatrix(gMasterGfxPos++, G_MTX_MODELVIEW); + } +} + +void func_802B74F0(void) { + PlayerStatus* playerStatus = &gPlayerStatus; + + D_802B7D18_E22588->pos.y += + ((playerStatus->position.y + playerStatus->colliderHeight + 10.0f) - D_802B7D18_E22588->pos.y) / 1.5f; + D_802B7D18_E22588->pos.x = playerStatus->position.x; + D_802B7D18_E22588->pos.z = playerStatus->position.z; + + if (!func_802B704C()) { + D_8010C920 = NULL; + playerStatus->animFlags &= ~PLAYER_STATUS_ANIM_FLAGS_40; + return; + } + + switch (D_802B7D18_E22588->unk_24) { + case 0: + if (D_802B7D18_E22588->unk_18++ < 6) { + break; + } + D_802B7D18_E22588->scale = 0.36f; + D_802B7D18_E22588->unk_24++; + break; + case 1: + D_802B7D18_E22588->scale = 0.57f; + D_802B7D18_E22588->unk_24++; + break; + case 2: + D_802B7D18_E22588->scale = 0.53f; + D_802B7D18_E22588->unk_24++; + break; + } +} diff --git a/src/a5dd0_len_114e0.c b/src/a5dd0_len_114e0.c index 355dd9eaf9..29f913f5b2 100644 --- a/src/a5dd0_len_114e0.c +++ b/src/a5dd0_len_114e0.c @@ -3,6 +3,8 @@ #include "ld_addrs.h" #include "stdlib/stdarg.h" #include "entity.h" +#include "hud_element.h" +#include "effects.h" typedef struct GameMode { /* 0x00 */ u16 flags; @@ -997,7 +999,6 @@ s32 mdl_renderTaskBasePriorities[RENDER_MODE_COUNT] = { [RENDER_MODE_CLOUD_NO_ZB] = 700000, }; - s8 D_8014C248[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, }; // BSS @@ -1008,8 +1009,8 @@ extern s32 D_80151304; extern s32 D_80151344; extern s32 entity_numEntities; extern s32 gEntityHeapBase; -extern s32 gHudElementCacheTableRaster; -extern s32 gHudElementCacheTablePalette[4]; +extern HudCacheEntry* gHudElementCacheTableRaster; +extern HudCacheEntry* gHudElementCacheTablePalette; extern ModelNode** gCurrentModelTreeRoot; extern ModelTransformGroupList* gCurrentTransformGroups; extern s8 gMsgGlobalWaveCounter[0x4]; @@ -1098,7 +1099,9 @@ void func_80117D00(Model* model); void appendGfx_model_group(Model* model); void render_transform_group_node(ModelNode* node); void render_transform_group(ModelTransformGroup* group); +void func_801180E8(TextureHeader*, void**, u8* raster, u16* palette, u8* auxRaster, u16* auxPalette, s32, s32, s32, s32); void load_model_transforms(ModelNode* model, ModelNode* parent, Matrix4f mdlTxMtx, s32 treeDepth); +s32 is_identity_fixed_mtx(Mtx* mtx); void update_entities(void) { s32 i; @@ -1407,13 +1410,13 @@ void render_entities(void) { if (D_8014AFB0 == 0xFF) { if (entity->renderSetupFunc != NULL) { bind_entity_model_setupGfx(entity->virtualModelIndex, - entity->listIndex, + (void*)(u32)entity->listIndex, entity->renderSetupFunc); } else { get_entity_model(entity->virtualModelIndex)->fpSetupGfxCallback = NULL; } } else { - bind_entity_model_setupGfx(entity->virtualModelIndex, entity->listIndex, func_8010FE44); + bind_entity_model_setupGfx(entity->virtualModelIndex, (void*)(u32)entity->listIndex, func_8010FE44); } if (entity->gfxBaseAddr == NULL) { @@ -1463,7 +1466,7 @@ void render_shadows(void) { } } - bind_entity_model_setupGfx(shadow->entityModelID, (void*)shadow->alpha, entity_model_set_shadow_color); + bind_entity_model_setupGfx(shadow->entityModelID, (void*)(u32)shadow->alpha, entity_model_set_shadow_color); if (shadow->vertexArray == NULL) { draw_entity_model_A(shadow->entityModelID, &shadow->transformMatrix); @@ -3186,8 +3189,118 @@ void calculate_model_sizes(void) { } } -void mdl_create_model(ModelBlueprint* bp, s32 arg1); -INCLUDE_ASM(s32, "a5dd0_len_114e0", mdl_create_model); +void mdl_create_model(ModelBlueprint* bp, s32 arg1) { + EffectInstance* effect; + ModelNode* node = bp->mdlNode; + ModelNodeProperty* prop; + ModelBoundingBox* bb; + s32 modelIdx; + Model* model; + f32 x, y, z; + + prop = get_model_property(node, MODEL_PROP_KEY_SPECIAL); + modelIdx = 0; + if (prop != NULL) { + s32 temp_s1 = (u8) prop->data.s / 16; + + if (temp_s1 != 0) { + prop = get_model_property(node, MODEL_PROP_KEY_BOUNDING_BOX); + if (prop != NULL) { + ModelBoundingBox* bb = (ModelBoundingBox*) prop; + + fx_flame( + temp_s1 - 1, (bb->minX + bb->maxX) * 0.5f, bb->minY, (bb->minZ + bb->maxZ) * 0.5f, 1.0f, &effect + ); + return; + } + } + } + + for (modelIdx = 0; modelIdx < ARRAY_COUNT(*gCurrentModels); modelIdx++) { + if ((*gCurrentModels)[modelIdx] == NULL) { + break; + } + } + + (*gCurrentModels)[modelIdx] = model = heap_malloc(sizeof(*model)); + model->flags = bp->flags | 1; + model->modelID = D_80153226; + model->modelNode = bp->mdlNode; + model->groupData = bp->groupData; + model->matrixMode = 0; + node = model->modelNode; + prop = get_model_property(node, MODEL_PROP_KEY_SPECIAL); + if (prop != NULL) { + model->texPannerID = prop->data.s & 0xF; + } else { + model->texPannerID = 0; + } + model->customGfxIndex = 0; + + if (node->type != SHAPE_TYPE_GROUP) { + prop = get_model_property(node, MODEL_PROP_KEY_RENDER_MODE); + } else { + prop = get_model_property(node, MODEL_PROP_KEY_GROUP_TYPE); + + if (prop != NULL) { + prop = &prop[1]; + } + } + + if (prop != NULL) { + model->renderMode = prop->data.s; + } else { + model->renderMode = 1; + } + + model->textureID = (*mdl_currentModelTreeNodeInfo)[mdl_treeIterPos].textureID; + model->textureVariation = 0; + + if (!is_identity_fixed_mtx(bp->mtx)) { + model->currentMatrix = heap_malloc(sizeof(*model->currentMatrix)); + *model->currentMatrix = *bp->mtx; + model->specialMatrix = *model->currentMatrix; + } else { + model->currentMatrix = NULL; + guMtxIdent(&model->specialMatrix); + model->flags |= 0x2000; + } + + guMtxIdentF(model->transformMatrix); + model->currentSpecialMatrix = NULL; + prop = get_model_property(node, MODEL_PROP_KEY_BOUNDING_BOX); + if (prop != NULL) { + ModelBoundingBox* bb = (ModelBoundingBox*) prop; + + x = (bb->minX + bb->maxX) * 0.5f; + y = (bb->minY + bb->maxY) * 0.5f; + z = (bb->minZ + bb->maxZ) * 0.5f; + } else { + x = y = z = 0.0f; + } + + if (model->currentMatrix != NULL) { + guMtxXFML(model->currentMatrix, x, y, z, &x, &y, &z); + } + + model->center.x = x; + model->center.y = y; + model->center.z = z; + + + bb = (ModelBoundingBox*) prop; + x = bb->maxX - bb->minX; + y = bb->maxY - bb->minY; + z = bb->maxZ - bb->minZ; + bb->halfSizeX = x * 0.5; + bb->halfSizeY = y * 0.5; + bb->halfSizeZ = z * 0.5; + + if (model->currentMatrix == NULL && x < 100.0f && y < 100.0f && z < 100.0f) { + model->flags |= 0x200; + } + (*mdl_currentModelTreeNodeInfo)[mdl_treeIterPos].modelIndex = modelIdx; +} // The global here is getting optimized out because nothing is happening to it. Very weird #ifdef NON_EQUIVALENT @@ -4069,7 +4182,8 @@ void build_custom_gfx(void) { // weird temps necessary to match /// @returns TRUE if mtx is NULL or identity. -s32 is_identity_fixed_mtx(Matrix4s* mtx) { +// TODO takes a Matrix4f, not a Matrix4s - types being weird +s32 is_identity_fixed_mtx(Mtx* mtx) { s32* mtxIt = (s32*)mtx; s32* identityIt; s32 i; @@ -4254,7 +4368,7 @@ void mdl_draw_hidden_panel_surface(Gfx** arg0, u16 treeIndex) { oldGfxPos = gMasterGfxPos; gMasterGfxPos = *arg0; - copied.flags = 0x80 | 0x1; + copied.flags = MODEL_FLAGS_HAS_LOCAL_VERTEX_COPY | MODEL_FLAGS_FLAG_1; appendGfx_model(&copied); *arg0 = gMasterGfxPos; @@ -4264,13 +4378,13 @@ void mdl_draw_hidden_panel_surface(Gfx** arg0, u16 treeIndex) { } } -s32 mdl_get_next_texture_address(s32 size) { +void* mdl_get_next_texture_address(s32 size) { u32 offset = mdl_nextTextureAddress - mdl_textureBaseAddress + 0x3F; offset = (offset >> 6) << 6; if (size + offset > 0x28000) { - return 0; + return NULL; } else { return mdl_textureBaseAddress + offset; } diff --git a/src/battle/action_cmd/power_shock.c b/src/battle/action_cmd/power_shock.c index bb35d1fb03..4af9f8dad8 100644 --- a/src/battle/action_cmd/power_shock.c +++ b/src/battle/action_cmd/power_shock.c @@ -100,14 +100,13 @@ ApiStatus func_802A9210_42D120(Evt* script, s32 isInitialCall) { return ApiStatus_DONE2; } -#ifdef NON_EQUIVALENT void func_802A9310_42D220(void) { ActionCommandStatus* actionCommandStatus = &gActionCommandStatus; BattleStatus* battleStatus = &gBattleStatus; s32 id; - s32 temp_v0_2; s32 phi_a1; s32 cutoff; + s32 new_var; switch (actionCommandStatus->state) { case 0: @@ -147,12 +146,11 @@ void func_802A9310_42D220(void) { actionCommandStatus->hudElementX, actionCommandStatus->hudElementY + 28); - cutoff = 100 - actionCommandStatus->unk_46; - cutoff = (cutoff * 60) / 100; - temp_v0_2 = 29 - cutoff; + phi_a1 = 100 - actionCommandStatus->unk_46; + new_var = 29 - (phi_a1 * 60) / 100; hud_element_set_render_pos( actionCommandStatus->hudElements[4], - actionCommandStatus->hudElementX - temp_v0_2, + actionCommandStatus->hudElementX - new_var, actionCommandStatus->hudElementY + 17); } break; @@ -163,7 +161,7 @@ void func_802A9310_42D220(void) { break; } hud_element_set_script(actionCommandStatus->hudElements[0], &HES_MashAButton); - actionCommandStatus->unk_44 = 0; + actionCommandStatus->barFillLevel = 0; actionCommandStatus->unk_5C = 0; D_802A9B00 = 1; actionCommandStatus->unk_54 = actionCommandStatus->unk_52; @@ -174,7 +172,7 @@ void func_802A9310_42D220(void) { btl_set_popup_duration(99); if (actionCommandStatus->unk_68 == 0) { - if (actionCommandStatus->unk_64 != 0) { + if (actionCommandStatus->easyVersion != 0) { cutoff = actionCommandStatus->mashMeterCutoffs[actionCommandStatus->mashMeterIntervals]; actionCommandStatus->barFillLevel -= D_802A9AA0_42D9B0[actionCommandStatus->barFillLevel / cutoff / 20]; if (actionCommandStatus->barFillLevel < 0) { @@ -189,12 +187,13 @@ void func_802A9310_42D220(void) { } if (battleStatus->currentButtonsPressed & BUTTON_A) { - phi_a1 = actionCommandStatus->unk_64; - // unk_434 = array of scaling values based on attack difficulty (unk_50). + phi_a1 = actionCommandStatus->easyVersion; if (phi_a1 != 0) { - s32 a; - a = battleStatus->unk_434[actionCommandStatus->unk_50]; - actionCommandStatus->barFillLevel += a * 850 / 100 * phi_a1 / 100; + // unk_434 = array of scaling values based on attack difficulty (unk_50). + s32 a = battleStatus->unk_434[actionCommandStatus->unk_50]; + + phi_a1 = (((a * 850) / 100) * phi_a1) / 100; + actionCommandStatus->barFillLevel += phi_a1; } else { actionCommandStatus->barFillLevel += 100; if (actionCommandStatus->barFillLevel >= 500) { @@ -204,9 +203,9 @@ void func_802A9310_42D220(void) { } if (actionCommandStatus->barFillLevel > 10000) { - id = actionCommandStatus->hudElements[3]; actionCommandStatus->barFillLevel = 10000; actionCommandStatus->unk_68 = 1; + id = actionCommandStatus->hudElements[3]; hud_element_set_render_pos( id, actionCommandStatus->hudElementX + 50, @@ -219,7 +218,7 @@ void func_802A9310_42D220(void) { if (actionCommandStatus->unk_54 == 0) { phi_a1 = actionCommandStatus->barFillLevel; - if (actionCommandStatus->unk_64 == 0) { + if (actionCommandStatus->easyVersion == 0) { phi_a1 = 0; } @@ -252,7 +251,7 @@ void func_802A9310_42D220(void) { } break; case 12: - if (actionCommandStatus->unk_64 == 0) { + if (actionCommandStatus->easyVersion == 0) { actionCommandStatus->barFillLevel -= 100; if (actionCommandStatus->barFillLevel < 0) { actionCommandStatus->barFillLevel = 0; @@ -287,9 +286,6 @@ void func_802A9310_42D220(void) { } } } -#else -INCLUDE_ASM(s32, "battle/action_cmd/power_shock", func_802A9310_42D220, void); -#endif void N(draw_hud_elements)(void) { ActionCommandStatus* actionCommandStatus = &gActionCommandStatus; diff --git a/src/battle/area_flo2/5CE690.c b/src/battle/area_flo2/5CE690.c index 748ef8620f..8091889c90 100644 --- a/src/battle/area_flo2/5CE690.c +++ b/src/battle/area_flo2/5CE690.c @@ -50,7 +50,66 @@ ApiStatus func_802182A4_5CE934(Evt* script, s32 isInitialCall) { return ApiStatus_DONE2; } -INCLUDE_ASM(s32, "battle/area_flo2/5CE690", func_80218440_5CEAD0); +ApiStatus func_80218440_5CEAD0(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; + s32 arr[10]; + s32 flags = evt_get_variable(script, *args++); + s32 count = 0; + s32 var_a2; + + if (!(flags & 2)) { + arr[count] = 2; + count++; + } + if (!(flags & 8)) { + arr[count] = 8; + count++; + } + if (!(flags & 0x20)) { + arr[count] = 0x20; + count++; + } + if (!(flags & 0x80)) { + arr[count] = 0x80; + count++; + } + if (!(flags & 0x200)) { + arr[count] = 0x200; + count++; + } + if (!(flags & 1)) { + arr[count] = 1; + count++; + } + if (!(flags & 4)) { + arr[count] = 4; + count++; + } + if (!(flags & 0x10)) { + arr[count] = 0x10; + count++; + } + + if (count == 0) { + if (!(flags & 0x100)) { + arr[count] = 0x100; + count++; + } + if (!(flags & 0x40)) { + arr[count] = 0x40; + count++; + } + } + + if (count == 0) { + var_a2 = -1; + } else { + var_a2 = arr[rand_int(count - 1)]; + } + + evt_set_variable(script, *args++, var_a2); + return ApiStatus_DONE2; +} ApiStatus func_802185D4_5CEC64(Evt* script, s32 isInitialCall) { s32* actorID = &script->owner1.actorID; diff --git a/src/battle/area_isk_part_1/actor/stone_chomp.c b/src/battle/area_isk_part_1/actor/stone_chomp.c index 699023ad4e..06fe9faff1 100644 --- a/src/battle/area_isk_part_1/actor/stone_chomp.c +++ b/src/battle/area_isk_part_1/actor/stone_chomp.c @@ -243,8 +243,112 @@ ActorBlueprint NAMESPACE = { #include "common/ChompChainUpdateHelperFunc2.inc.c" -ApiStatus b_area_isk_part_1_ChompChainUpdate(Evt* script, s32 isInitialCall); -INCLUDE_ASM(s32, "battle/area_isk_part_1/4E29B0", b_area_isk_part_1_ChompChainUpdate); +ApiStatus b_area_isk_part_1_ChompChainUpdate(Evt* script, s32 isInitialCall) { + f32 sp18; + Actor* actor; + ActorPart* part; + ChompChainAnimationState* animState; + f32 dist; + f32 angle; + f32 ax, ay; + s32 three; + s32 i; + + actor = get_actor(script->owner1.actorID); + if (actor == NULL) { + return ApiStatus_BLOCK; + } + + three = 3; + + animState = actor->state.unk_6C; + if (actor->debuff == STATUS_SHRINK) { + ax = actor->currentPos.x + 6.0; + ay = actor->currentPos.y + 2.5; + } else { + ax = actor->currentPos.x + 12.0; + ay = actor->currentPos.y + 5.0; + } + + for (i = 0; i < 8; i++, animState++) { + if (actor->debuff == STATUS_SHRINK) { + animState->scale.x = 3.5f; + animState->scale.z = 3.5f; + animState->scale.y = 3.5f; + } else { + animState->scale.x = 7.0f; + animState->scale.z = 7.0f; + animState->scale.y = 7.0f; + } + + animState->unk_18 -= animState->unk_14; + if (animState->unk_18 < 2.0f * -animState->unk_14) { + animState->unk_18 = 2.0f * -animState->unk_14; + if (actor->state.varTable[8] != 0 && i == 0) { + sfx_play_sound_at_position(SOUND_2063, 0, actor->currentPos.x, actor->currentPos.y, actor->currentPos.z); + } + } + animState->currentPos.y += animState->unk_18; + if (actor->debuff == STATUS_SHRINK) { + if (animState->currentPos.y < 2.5) { + animState->unk_18 = 0.0f; + animState->currentPos.y = 2.5f; + } + } else { + if (animState->currentPos.y < 5.0) { + animState->unk_18 = 0.0f; + animState->currentPos.y = 5.0f; + } + } + + dist = dist2D(ax, ay, animState->currentPos.x, animState->currentPos.y); + angle = atan2(ax, ay, animState->currentPos.x, animState->currentPos.y); + + if (animState->scale.z <= dist) { + b_area_isk_part_1_stone_chomp_ChompChainUpdateHelperFunc2(&sp18, dist - animState->scale.z, angle); + animState->unk_18 += sp18 * 0.5; + } + + if (animState->scale.y <= dist) { + f32 t; + + if (animState->scale.x <= dist) { + t = dist - animState->scale.x; + } else { + animState->unk_1C += animState->unk_20; + t = animState->unk_1C; + } + b_area_isk_part_1_stone_chomp_ChompChainUpdateHelperFunc(animState, t, angle); + } else { + animState->unk_1C -= animState->unk_20 * 0.2; + if (animState->unk_1C < 0.0) { + animState->unk_1C = 0.0f; + } + b_area_isk_part_1_stone_chomp_ChompChainUpdateHelperFunc(animState, animState->unk_1C, angle); + } + + if (animState->unk_1C > 4.0) { + animState->unk_1C = 4.0f; + } + part = get_actor_part(actor, three + i); + part->absolutePosition.x = animState->currentPos.x; + part->absolutePosition.y = animState->currentPos.y; + part->absolutePosition.z = animState->currentPos.z; + + if (actor->debuff == STATUS_SHRINK) { + part->scale.x = 0.5f; + part->scale.y = 0.5f; + part->scale.z = 1.0f; + } else { + part->scale.x = 1.0f; + part->scale.y = 1.0f; + part->scale.z = 1.0f; + } + ay = animState->currentPos.y; + ax = animState->currentPos.x; + } + return ApiStatus_DONE2; +} EvtScript N(80221794) = { EVT_CALL(SetAnimation, ACTOR_SELF, LW(0), LW(1)) diff --git a/src/battle/area_isk_part_2/actor/chain_chomp.c b/src/battle/area_isk_part_2/actor/chain_chomp.c index 761f1369ca..13850b544d 100644 --- a/src/battle/area_isk_part_2/actor/chain_chomp.c +++ b/src/battle/area_isk_part_2/actor/chain_chomp.c @@ -254,8 +254,119 @@ ActorBlueprint NAMESPACE = { #include "common/ChompChainUpdateHelperFunc2.inc.c" -ApiStatus N(ChompChainUpdate)(Evt* script, s32 isInitialCall); -INCLUDE_ASM(ApiStatus, "battle/area_isk_part_2/4EF4A0", b_area_isk_part_2_chain_chomp_ChompChainUpdate); +ApiStatus b_area_isk_part_2_chain_chomp_ChompChainUpdate(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; + f32 sp18; + Actor* actor; + ActorPart* part; + ChompChainAnimationState* animState; + f32 dist; + f32 angle; + f32 ax, ay; + s32 three; + s32 something; + s32 i; + + actor = get_actor(script->owner1.actorID); + if (actor == NULL) { + return ApiStatus_BLOCK; + } + + something = evt_get_variable(script, *args++); + + three = 3; + + animState = actor->state.unk_6C; + if (actor->debuff == STATUS_SHRINK) { + ax = actor->currentPos.x + 6.0; + ay = actor->currentPos.y + 2.5; + } else { + ax = actor->currentPos.x + 12.0; + ay = actor->currentPos.y + 5.0; + } + + for (i = 0; i < 8; i++, animState++) { + if (actor->debuff == STATUS_SHRINK) { + animState->scale.x = 3.5f; + animState->scale.z = 3.5f; + animState->scale.y = 3.5f; + } else { + animState->scale.x = 7.0f; + animState->scale.z = 7.0f; + animState->scale.y = 7.0f; + } + + animState->unk_18 -= animState->unk_14; + if (animState->unk_18 < 2.0f * -animState->unk_14) { + animState->unk_18 = 2.0f * -animState->unk_14; + if (actor->state.varTable[8] != 0 && i == 0) { + sfx_play_sound_at_position(SOUND_2063, 0, actor->currentPos.x, actor->currentPos.y, actor->currentPos.z); + } + } + animState->currentPos.y += animState->unk_18; + if (actor->debuff == STATUS_SHRINK) { + if (animState->currentPos.y < 2.5) { + animState->currentPos.y = 2.5f; + animState->unk_18 = 0.0f; + } + } else { + if (animState->currentPos.y < 5.0) { + animState->currentPos.y = 5.0f; + animState->unk_18 = 0.0f; + } + } + + dist = dist2D(ax, ay, animState->currentPos.x, animState->currentPos.y); + angle = atan2(ax, ay, animState->currentPos.x, animState->currentPos.y); + + if (animState->scale.z <= dist) { + b_area_isk_part_2_chain_chomp_ChompChainUpdateHelperFunc2(&sp18, dist - animState->scale.z, angle); + animState->unk_18 += sp18 * 0.5; + } + + if (animState->scale.y <= dist) { + f32 t; + + if (animState->scale.x <= dist) { + t = dist; + t = t - animState->scale.x; + } else { + animState->unk_1C += animState->unk_20; + t = animState->unk_1C; + } + b_area_isk_part_2_chain_chomp_ChompChainUpdateHelperFunc(animState, t, angle); + } else { + animState->unk_1C -= animState->unk_20 * 0.2; + if (animState->unk_1C < 0.0) { + animState->unk_1C = 0.0f; + } + b_area_isk_part_2_chain_chomp_ChompChainUpdateHelperFunc(animState, animState->unk_1C, angle); + } + + if (animState->unk_1C > 4.0) { + animState->unk_1C = 4.0f; + } + animState->currentPos.z = something; + part = get_actor_part(actor, three + i); + part->absolutePosition.x = animState->currentPos.x; + part->absolutePosition.y = animState->currentPos.y; + part->absolutePosition.z = animState->currentPos.z; + + if (actor->debuff == STATUS_SHRINK) { + part->scale.x = 0.5f; + part->scale.y = 0.5f; + part->scale.z = 1.0f; + } else { + part->scale.x = 1.0f; + part->scale.y = 1.0f; + part->scale.z = 1.0f; + } + ay = animState->currentPos.y; + ax = animState->currentPos.x; + } + + return ApiStatus_DONE2; +} ApiStatus func_8021866C_4EFB0C(Evt* script, s32 isInitialCall) { Bytecode* args = script->ptrReadPos; diff --git a/src/battle/area_kpa2/6A2B50.c b/src/battle/area_kpa2/6A2B50.c index 170b4faeef..17a9ed0e73 100644 --- a/src/battle/area_kpa2/6A2B50.c +++ b/src/battle/area_kpa2/6A2B50.c @@ -1,23 +1,72 @@ #include "common.h" #include "effects.h" #include "sprite.h" +#include "effects.h" #define NAMESPACE b_area_kpa2 -// typedef struct KpaStruct { -// /* 0x00 */ s32 unk_00; -// /* 0x04 */ s32 unk_04; -// /* 0x08 */ s32 unk_08; -// /* 0x0C */ s32 unk_0C; -// /* 0x10 */ s32 unk_10; -// /* 0x14 */ s32 unk_14; -// } KpaStruct; // size = 0x14 +typedef struct KpaStruct { + /* 0x00 */ s32 unk_00[6]; +} KpaStruct; // size = 0x14 -// extern KpaStruct D_80234810_6BBA10; +extern KpaStruct D_80234810_6BBA10; #include "common/StartRumbleWithParams.inc.c" +#ifdef NON_MATCHING +ApiStatus func_8021B9A8_6A2BA8(Evt* script, s32 isInitialCall) { + static KpaStruct D_80234810_6BBA10 = {90, 135, 225, 270, 315, 405}; + + Bytecode* args = script->ptrReadPos; + KpaStruct numbers = D_80234810_6BBA10; + Actor* actor = get_actor(script->owner1.actorID); + s32 temp_fp; + s32 temp_s5; + s32 temp_s6; + f32 temp_f24; + f32 temp_f20; + s32 temp_s0_4; + s32 temp_s1; + s32 temp_s2; + s32 temp_v0_2; + s32 t1; + EffectInstance* effect; + s32 asdf; + s32 i; + + if (actor == NULL) { + return ApiStatus_DONE2; + } + + temp_fp = evt_get_variable(script, *args++); + temp_s5 = evt_get_variable(script, *args++); + temp_s6 = evt_get_variable(script, *args++); + temp_f24 = evt_get_float_variable(script, *args++); + if (actor->debuff != 0xA) { + temp_s5 += temp_f24 * 36.0f; + } else { + temp_s5 += temp_f24 * 14.4; + } + + for (i = 0; i < ARRAY_COUNT(numbers.unk_00); i++) { + temp_f20 = numbers.unk_00[i] + rand_int(30) - 15; + temp_s0_4 = (sin_deg(temp_f20) * 200.0f) + temp_fp; + t1 = (cos_deg(temp_f20) * 200.0f) + temp_s5; + asdf = temp_s6 + 20; + effect = fx_lightning_bolt(1, temp_fp, temp_s5, temp_s6, temp_s0_4, t1, asdf, temp_f24, 11); + temp_s1 = rand_int(256); + temp_s2 = rand_int(256); + temp_v0_2 = rand_int(256); + effect->data.lightning->unk_30 = temp_s1; + effect->data.lightning->unk_34 = temp_s2; + effect->data.lightning->unk_38 = temp_v0_2; + } + + return ApiStatus_DONE2; +} +#else INCLUDE_ASM(s32, "battle/area_kpa2/6A2B50", func_8021B9A8_6A2BA8); +#endif INCLUDE_ASM(s32, "battle/area_kpa2/6A2B50", func_8021BC60_6A2E60); diff --git a/src/battle/battle.c b/src/battle/battle.c index bb5117c2c5..563df7c3fb 100644 --- a/src/battle/battle.c +++ b/src/battle/battle.c @@ -290,7 +290,7 @@ void reset_battle_status(void) { D_800DC064 = NULL; D_800DC060 = 0; D_800DC4EC = 0; - D_800DC4F4 = 0; + D_800DC4F4 = NULL; } void ALT_reset_battle_status(void) { @@ -315,7 +315,7 @@ void load_battle_section(void) { D_800DC064 = &(*battleArea->stages)[D_800DC4EC]; } - btl_set_state(1); + btl_set_state(BATTLE_STATE_NORMAL_START); D_800DC4D0 = 0; } @@ -331,8 +331,8 @@ void set_battle_stage(s32 arg0) { D_800DC4EC = arg0; } -void set_battle_formation(s32 arg0) { - D_800DC4F4 = arg0; +void set_battle_formation(Battle* battle) { + D_800DC4F4 = battle; } void func_80072CEC(f32 arg0, f32 arg1, f32 arg2) { @@ -467,7 +467,7 @@ void load_demo_battle(u32 index) { switch (mode) { case 0: - gCurrentEncounter.eFirstStrike = FIRST_STRIKE_NONE; + gCurrentEncounter.firstStrikeType = FIRST_STRIKE_NONE; gCurrentEncounter.hitType = ENCOUNTER_TRIGGER_NONE; gCurrentEncounter.hitTier = 0; gGameStatusPtr->demoFlags |= 0x10; @@ -475,24 +475,24 @@ void load_demo_battle(u32 index) { gGameStatusPtr->demoFlags |= 0x40; break; case 1: - gCurrentEncounter.eFirstStrike = FIRST_STRIKE_PLAYER; + gCurrentEncounter.firstStrikeType = FIRST_STRIKE_PLAYER; gCurrentEncounter.hitType = ENCOUNTER_TRIGGER_HAMMER; gCurrentEncounter.hitTier = playerData->hammerLevel; gGameStatusPtr->demoFlags |= 0x10; break; case 2: - gCurrentEncounter.eFirstStrike = FIRST_STRIKE_PLAYER; + gCurrentEncounter.firstStrikeType = FIRST_STRIKE_PLAYER; gCurrentEncounter.hitType = ENCOUNTER_TRIGGER_JUMP; gCurrentEncounter.hitTier = playerData->bootsLevel; gGameStatusPtr->demoFlags |= 0x10; break; case 3: - gCurrentEncounter.eFirstStrike = FIRST_STRIKE_PLAYER; + gCurrentEncounter.firstStrikeType = FIRST_STRIKE_PLAYER; gCurrentEncounter.hitType = ENCOUNTER_TRIGGER_PARTNER; gGameStatusPtr->demoFlags |= 0x20; break; case 4: - gCurrentEncounter.eFirstStrike = FIRST_STRIKE_ENEMY; + gCurrentEncounter.firstStrikeType = FIRST_STRIKE_ENEMY; gCurrentEncounter.hitType = ENCOUNTER_TRIGGER_NONE; gCurrentEncounter.hitTier = 0; gGameStatusPtr->demoFlags |= 0x40; diff --git a/src/battle/battle.h b/src/battle/battle.h index 354b7eee18..9c2f7ec243 100644 --- a/src/battle/battle.h +++ b/src/battle/battle.h @@ -275,6 +275,8 @@ typedef enum ActorType { ACTOR_TYPE_COUNT = 0xD4, } ActorType; +extern s32 bActorNames[]; + #define BTL_AREA(id) \ .dmaStart = battle_##id##_ROM_START, \ .dmaEnd = battle_##id##_ROM_END, \ @@ -321,12 +323,12 @@ typedef struct FormationRow { typedef FormationRow Formation[]; typedef struct Stage { - /* 0x00 */ const char* texture; + /* 0x00 */ char* texture; /* 0x04 */ const char* shape; /* 0x08 */ const char* hit; /* 0x0C */ EvtScript* preBattle; /* 0x10 */ EvtScript* postBattle; - /* 0x14 */ const char* bg; + /* 0x14 */ char* bg; /* 0x18 */ s32* foregroundModelList; /* 0x1C */ s32 specialFormationSize; /* 0x20 */ Formation* specialFormation; @@ -339,8 +341,8 @@ typedef struct Battle { /* 0x04 */ s32 formationSize; /* 0x08 */ Formation* formation; /* 0x0C */ Stage* stage; - /* 0x10 */ s32 unk_10; -} Battle; // size = 0x14 * n + /* 0x10 */ EvtScript* unk_10; +} Battle; // size = 0x14 typedef Battle BattleList[]; diff --git a/src/battle/star/refresh/78B600.c b/src/battle/star/refresh/78B600.c index e76e122875..03f7fe75a5 100644 --- a/src/battle/star/refresh/78B600.c +++ b/src/battle/star/refresh/78B600.c @@ -7,8 +7,72 @@ #include "common/StarPower.inc.c" -ApiStatus func_802A1518_78BB18(Evt* script, s32 isInitialCall); -INCLUDE_ASM(s32, "battle/star/refresh/78B600", func_802A1518_78BB18); +ApiStatus func_802A1518_78BB18(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; + Npc* npc; + + if (isInitialCall) { + script->functionTemp[0] = 0; + } + + npc = script->functionTempPtr[1]; + + switch (script->functionTemp[0]) { + case 0: + script->functionTempPtr[1] = npc = get_npc_unsafe(evt_get_variable(script, *args++)); + npc->planarFlyDist = 0; + npc->yaw = 0; + npc->duration = 0; + npc->jumpVelocity = -1.5f; + npc->jumpScale = 0.02f; + npc->moveSpeed = 1.0f; + npc->moveToPos.x = npc->pos.x; + npc->moveToPos.y = npc->pos.y; + npc->moveToPos.z = npc->pos.z; + script->functionTemp[0] = 1; + break; + case 1: + if (npc->jumpVelocity < 0.0f) { + npc->planarFlyDist += 3.0; + if (npc->planarFlyDist > 40.0f) { + npc->planarFlyDist = 40.0f; + } + } else { + npc->planarFlyDist -= 2.0; + if (npc->planarFlyDist < 20.0f) { + npc->planarFlyDist = 20.0f; + } + } + + npc->moveSpeed += 0.75; + npc->jumpVelocity += npc->jumpScale; + npc->pos.y += npc->jumpVelocity; + if (npc->moveSpeed > 33.0f) { + npc->moveSpeed = 33.0f; + } + + npc->yaw += npc->moveSpeed; + npc->pos.x = npc->moveToPos.x; + npc->pos.z = npc->moveToPos.z; + add_vec2D_polar(&npc->pos.x, &npc->pos.z, npc->planarFlyDist, npc->yaw); + if ((npc->duration % 14) == 0) { + fx_sparkles(0, npc->pos.x, npc->pos.y, npc->pos.z, 30.0f); + } + + npc->duration++; + if (npc->duration > 40) { + npc->jumpScale = 0.5f; + } + if (npc->pos.y > 200.0f) { + script->functionTemp[0] = 2; + } + break; + case 2: + return ApiStatus_DONE2; + } + + return ApiStatus_BLOCK; +} ApiStatus func_802A17D4_78BDD4(Evt* script, s32 isInitialCall) { Actor* actor = gBattleStatus.playerActor; diff --git a/src/common/ChompChainUpdateHelperFunc2.inc.c b/src/common/ChompChainUpdateHelperFunc2.inc.c index f7925fed81..2b03a2cd80 100644 --- a/src/common/ChompChainUpdateHelperFunc2.inc.c +++ b/src/common/ChompChainUpdateHelperFunc2.inc.c @@ -1,9 +1,9 @@ #include "common.h" -ApiStatus N(ChompChainUpdateHelperFunc2)(ChompChainAnimationState* script, f32 magnitude, f32 angleDeg) { +ApiStatus N(ChompChainUpdateHelperFunc2)(f32* x, f32 magnitude, f32 angleDeg) { f32 angle = (angleDeg * TAU) / 360.0f; f32 dirX = sin_rad(angle); f32 dirY = cos_rad(angle); - script->currentPos.x = magnitude * dirY; + *x = magnitude * dirY; } diff --git a/src/d0a70_len_4fe0.c b/src/d0a70_len_4fe0.c index d65dfc0e3b..6109b4b4d7 100644 --- a/src/d0a70_len_4fe0.c +++ b/src/d0a70_len_4fe0.c @@ -1187,7 +1187,7 @@ void func_8013CFA8(FoldState* state, Matrix4f mtx) { gSP2Triangles(gMasterGfxPos++, 0, 2, 1, 0, 1, 2, 3, 0); gDPPipeSync(gMasterGfxPos++); } - render_shaded_sprite(mtx, uls, ult, lrs, lrt, alpha, state->unk_78); + create_shading_palette(mtx, uls, ult, lrs, lrt, alpha, state->unk_78); } else { gDPScrollTextureTile_4b(gMasterGfxPos++, fold_currentImage->raster, G_IM_FMT_CI, diff --git a/src/de740_len_23f0.c b/src/de740_len_23f0.c index 142f6d005e..5ccf6f54d0 100644 --- a/src/de740_len_23f0.c +++ b/src/de740_len_23f0.c @@ -6,8 +6,20 @@ extern SpriteShadingProfile D_801595C0; extern SpriteShadingProfile D_80159670; extern SpriteShadingProfile D_80159720; extern SpriteShadingProfile D_801597D0; +extern s8 D_80159880[0x20]; + +extern int ENVIRONMENT; +extern int COMBINED; +extern int COMBINED_ALPHA; +extern int SHADE; +extern int TEXEL0_ALPHA; void init_sprite_shading_data(void); +void appendGfx_shading_palette(Matrix4f mtx, s32 uls, s32 ult, s32 lrs, s32 lrt, s32 alpha, + f32 shadowX, f32 shadowY, f32 shadowZ, + s32 shadowR, s32 shadowG, s32 shadowB, + s32 highlightR, s32 highlightG, s32 highlightB, + s32 ambientPower, s32 otherModeLBits); void clear_sprite_shading_data(void) { s32 i; @@ -55,9 +67,353 @@ void sprite_shading_set_light_source(u32 idx, s8 flags, f32 x, f32 y, f32 z, u8 } } -INCLUDE_ASM(s32, "de740_len_23f0", render_shaded_sprite); +void create_shading_palette(Matrix4f mtx, s32 uls, s32 ult, s32 lrs, s32 lrt, s32 alpha, s32 otherModeLBits) { + Camera* camera = &gCameras[gCurrentCameraID]; + SpriteShadingLightSource* lightSource; + f32 shadowX, shadowY, shadowZ; + f32 sp54, sp58, sp5C; + f32 sp60; + f32 sp64, var_f30, sp68; + f32 shadowR, shadowG, shadowB; + f32 sp78, sp7C, sp80; + f32 sp84, sp88, sp8C; + f32 sp90, sp94, sp98; + f32 temp_f10; + f32 temp_f12; + f32 temp_f16; + f32 temp_f20; + f32 temp_f26, temp_f24, temp_f22; + f32 temp_f6; + f32 var_f0_2; + f32 var_f2; + f32 var_f8; + f32 temp3; + f32 qx, qy, qz; + f32 wx, wy, wz; + f32 ex, ey, ez; + s32 i; -INCLUDE_ASM(s32, "de740_len_23f0", appendGfx_shaded_sprite); + shadowX = 0.0f; + shadowY = 0.0f; + shadowZ = 0.0f; + + sp54 = mtx[3][0]; + sp58 = mtx[3][1]; + sp5C = mtx[3][2]; + + sp78 = 0.0f; + sp7C = 0.0f; + sp80 = 0.0f; + + sp84 = 0.0f; + sp88 = 0.0f; + sp8C = 0.0f; + + sp64 = mtx[0][2]; + var_f30 = mtx[1][2]; + sp68 = mtx[2][2]; + + sp90 = 0.0f; + sp94 = 0.0f; + sp98 = 0.0f; + + shadowR = D_80151328->ambientColor.r; + shadowG = D_80151328->ambientColor.g; + shadowB = D_80151328->ambientColor.b; + + if (((-sp64 * camera->perspectiveMatrix[0][2]) + (sp68 * camera->perspectiveMatrix[2][2])) < 0.0f) { + sp60 = 1.0f; + } else { + sp60 = -1.0f; + } + + for (i = 0; i < ARRAY_COUNT(D_80151328->sources); i++) { + lightSource = &D_80151328->sources[i]; + if (lightSource->flags & 1) { + temp_f26 = sp54 - lightSource->pos.x; + temp_f24 = sp58 - lightSource->pos.y; + temp_f22 = sp5C - lightSource->pos.z; + + temp_f20 = SQ(temp_f26) + SQ(temp_f24) + SQ(temp_f22); + + if (temp_f20 != 0.0f) { + var_f2 = sqrtf(temp_f20); + var_f0_2 = 1.0f / var_f2; + } else { + var_f2 = 0.0f; + var_f0_2 = 0.0f; + } + + temp_f26 *= var_f0_2; + temp_f24 *= var_f0_2; + temp_f22 *= var_f0_2; + + if ((lightSource->flags & 4)) { + if ((var_f2 == 0.0f) && (lightSource->falloff == 0.0f)) { + var_f8 = 1.0f; + } else { + var_f8 = 1.0f / (var_f2 * lightSource->falloff); + temp_f26 *= var_f8; + temp_f24 *= var_f8; + temp_f22 *= var_f8; + } + } else { + if ((lightSource->flags & 8) && (temp_f20 != 0.0f || lightSource->falloff != 0.0f)) { + var_f8 = 1.0f / (temp_f20 * lightSource->falloff); + temp_f26 *= var_f8; + temp_f24 *= var_f8; + temp_f22 *= var_f8; + } else { + var_f8 = 1.0f; + } + } + + if (var_f8 > 1.0f) { + var_f8 = 1.0f; + } + shadowX += temp_f26; + shadowY += temp_f24; + shadowZ += temp_f22; + + if (sp60 < 0.0f) { + ex = sp64; + ey = var_f30; + ez = -sp68; + } else { + ex = -sp64; + ey = var_f30; + ez = sp68; + } + temp_f10 = ex * temp_f26 + ey * temp_f24 + ez * temp_f22; + + if (sp60 < 0.0f) { + wx = sp68; + wy = var_f30; + wz = sp64; + } else { + wx = -sp68; + wy = var_f30; + wz = -sp64; + } + temp3 = wx * temp_f26 + wy * temp_f24 + wz * temp_f22; + + temp_f16 = temp3; + temp_f12 = var_f8 * fabsf(temp_f10); + temp_f6 = var_f8 * fabsf(temp_f16); + if (temp_f10 > 0.0f) { + sp78 += lightSource->rgb.r * temp_f12; + sp7C += lightSource->rgb.g * temp_f12; + sp80 += lightSource->rgb.b * temp_f12; + if (temp_f16 > 0.0f) { + sp84 += lightSource->rgb.r * temp_f6; + sp88 += lightSource->rgb.g * temp_f6; + sp8C += lightSource->rgb.b * temp_f6; + } else { + sp90 += lightSource->rgb.r * temp_f6; + sp94 += lightSource->rgb.g * temp_f6; + sp98 += lightSource->rgb.b * temp_f6; + } + } else { + shadowR += lightSource->rgb.r * temp_f12; + shadowG += lightSource->rgb.g * temp_f12; + shadowB += lightSource->rgb.b * temp_f12; + if (temp_f16 > 0.0f) { + sp84 += lightSource->rgb.r * temp_f6; + sp88 += lightSource->rgb.g * temp_f6; + sp8C += lightSource->rgb.b * temp_f6; + } else { + sp90 += lightSource->rgb.r * temp_f6; + sp94 += lightSource->rgb.g * temp_f6; + sp98 += lightSource->rgb.b * temp_f6; + } + } + } + } + + if (sp60 < 0.0f) { + qx = sp68; + qy = var_f30; + qz = sp64; + } else { + qx = -sp68; + qy = var_f30; + qz = -sp64; + } + + if (qx * shadowX + qy * shadowY + qz * shadowZ > 0.0f) { + appendGfx_shading_palette( + mtx, + uls, ult, lrs, lrt, + alpha, + shadowX, shadowY, shadowZ, + shadowR, shadowG, shadowB, + D_80151328->ambientColor.r + sp78 + sp84, + D_80151328->ambientColor.g + sp7C + sp88, + D_80151328->ambientColor.b + sp80 + sp8C, + D_80151328->ambientPower, otherModeLBits + ); + } else { + appendGfx_shading_palette( + mtx, + uls, ult, lrs, lrt, + alpha, + shadowX, shadowY, shadowZ, + shadowR, shadowG, shadowB, + D_80151328->ambientColor.r + sp78 + sp90, + D_80151328->ambientColor.g + sp7C + sp94, + D_80151328->ambientColor.b + sp80 + sp98, + D_80151328->ambientPower, otherModeLBits + ); + } +} + +// float regalloc +#ifdef NON_MATCHING +void appendGfx_shading_palette( + Matrix4f mtx, + s32 uls, s32 ult, s32 lrs, s32 lrt, + s32 alpha, + f32 shadowX, f32 shadowY, f32 shadowZ, + s32 shadowR, s32 shadowG, s32 shadowB, + s32 highlightR, s32 highlightG, s32 highlightB, + s32 ambientPower, s32 renderMode) +{ + Camera* camera = &gCameras[gCurrentCameraID]; + f32 temp_f0; + f32 asdasdasd; + f32 temp_f2; + f32 var_f26; + f32 temp_f28 = 0; + f32 temp_f6; + f32 temp_f6_2; + f32 var_f12; + f32 var_f12_2; + f32 var_f20; + f32 var_f2; + f32 var_f30; + f32 var_f8; + f32 abc; + f32 ex, ey, ez; + + var_f12 = (shadowX * shadowX) + (shadowY * shadowY) + (shadowZ * shadowZ); + + if (var_f12 < 1.0) { + ambientPower *= var_f12; + } + if (var_f12 != 0.0f) { + var_f12 = 1.0f / sqrtf(var_f12); + } + shadowX *= var_f12; + shadowY *= var_f12; + shadowZ *= var_f12; + + if ((-mtx[0][2] * camera->perspectiveMatrix[0][2]) + (mtx[2][2] * camera->perspectiveMatrix[2][2]) < 0.0f) { + var_f30 = 1.0f; + } else { + var_f30 = -1.0f; + } + + if (var_f30 < 0.0f) { + ex = mtx[0][2]; + ey = mtx[1][2]; + ez = -mtx[2][2]; + } else { + ex = -mtx[0][2]; + ey = mtx[1][2]; + ez = mtx[2][2]; + } + + temp_f6_2 = (shadowX * -camera->perspectiveMatrix[2][2]) + (shadowZ * camera->perspectiveMatrix[0][2]); + if ((ex * shadowX) + (ey * shadowY) + (ez * shadowZ) > 0.0f) { + var_f26 = ambientPower * temp_f6_2; + } else { + var_f26 = ambientPower; + var_f26 = ambientPower * temp_f6_2; + } + var_f20 = SQ(shadowX) + SQ(shadowZ); + if (var_f20 != 0.0f) { + var_f20 = sqrtf(var_f20); + } + temp_f0 = -mtx[0][1]; + asdasdasd = mtx[1][1]; + temp_f2 = mtx[2][1]; + var_f12_2 = SQ(temp_f0) + SQ(temp_f2); + if (var_f12_2 != 0.0f) { + var_f12_2 = sqrtf(var_f12_2); + } + temp_f28 = -((var_f20 * var_f12_2) + (shadowY * asdasdasd)) * ambientPower; + if (shadowR > 255) { + shadowR = 255; + } + if (shadowG > 255) { + shadowG = 255; + } + if (shadowB > 255) { + shadowB = 255; + } + if (highlightR > 255) { + highlightR = 255; + } + if (highlightG > 255) { + highlightG = 255; + } + if (highlightB > 255) { + highlightB = 255; + } + + gDPSetPrimColor(gMasterGfxPos++, 0, 0, shadowR, shadowG, shadowB, alpha); + gDPSetCombineLERP(gMasterGfxPos++, TEXEL1, 0, PRIMITIVE, 0, 0, 0, 0, TEXEL0, COMBINED, TEXEL0, COMBINED_ALPHA, + TEXEL0, PRIMITIVE, 0, TEXEL0, 0); + gDPSetColorImage(gMasterGfxPos++, G_IM_FMT_RGBA, G_IM_SIZ_16b, SCREEN_WIDTH, D_80159880); + gDPSetScissor(gMasterGfxPos++, G_SC_NON_INTERLACE, 0, 0, 16, 1); + + gSPSetOtherMode(gMasterGfxPos++, G_SETOTHERMODE_H, 4, 18, + G_AD_DISABLE | G_CD_DISABLE | G_CK_NONE | G_TC_FILT | G_TF_POINT | G_TT_NONE | G_TL_TILE | + G_TD_CLAMP | G_TP_NONE | G_CYC_1CYCLE | G_PM_NPRIMITIVE); + + gDPSetRenderMode(gMasterGfxPos++, G_RM_OPA_SURF, G_RM_OPA_SURF2); + + gDPSetPrimColor(gMasterGfxPos++, 0, 0, shadowR, shadowG, shadowB, alpha); + gDPSetEnvColor(gMasterGfxPos++, highlightR, highlightG, highlightB, 0); + gDPSetCombineLERP(gMasterGfxPos++, PRIMITIVE, ENVIRONMENT, TEXEL0_ALPHA, ENVIRONMENT, 0, 0, 0, 1, + PRIMITIVE, ENVIRONMENT, TEXEL0_ALPHA, ENVIRONMENT, 0, 0, 0, 1); + gSPTextureRectangle(gMasterGfxPos++, 0, 0, 16 << 2, 1 << 2, 2, 0, 0, 4 << 10, 1 << 10); + gDPPipeSync(gMasterGfxPos++); + gDPSetColorImage(gMasterGfxPos++, G_IM_FMT_RGBA, G_IM_SIZ_16b, SCREEN_WIDTH, osVirtualToPhysical(nuGfxCfb_ptr)); + + gDPSetScissor( + gMasterGfxPos++, 0, + camera->viewportStartX, + camera->viewportStartY, + camera->viewportStartX + camera->viewportW, + camera->viewportStartY + camera->viewportH + ); + + gDPLoadTLUT_pal16(gMasterGfxPos++, 1, D_80159880); + + gSPSetOtherMode(gMasterGfxPos++, G_SETOTHERMODE_H, 4, 18, + G_AD_DISABLE | G_CD_MAGICSQ | G_CK_NONE | G_TC_FILT | G_TF_BILERP | G_TT_RGBA16 | G_TL_TILE | + G_TD_CLAMP | G_TP_PERSP | G_CYC_2CYCLE | G_PM_NPRIMITIVE); + + gDPSetRenderMode(gMasterGfxPos++, G_RM_PASS, renderMode); + gDPSetEnvColor(gMasterGfxPos++, 100, 100, 100, 255); + + if (alpha == 255) { + gDPSetCombineLERP(gMasterGfxPos++, TEXEL0, 0, TEXEL1, 0, 0, 0, 0, TEXEL1, SHADE, ENVIRONMENT, COMBINED, + COMBINED, 0, 0, 0, COMBINED); + } else { + gDPSetCombineLERP(gMasterGfxPos++, TEXEL0, 0, TEXEL1, 0, PRIMITIVE, 0, TEXEL1, 0, SHADE, ENVIRONMENT, COMBINED, + COMBINED, 0, 0, 0, COMBINED); + } + + // abc = var_f30 * var_f26; + abc = var_f26; + abc = var_f30 * abc; + gDPSetTileSize(gMasterGfxPos++, 0, ((uls + 0x100) << 2) + (s32)abc, ((ult + 0x100) << 2) + (s32)temp_f28, ((lrs + 0x100 - 1) << 2) + (s32)abc, ((lrt + 0x100 - 1) << 2) + (s32)temp_f28); +} +#else +INCLUDE_ASM(s32, "de740_len_23f0", appendGfx_shading_palette); +#endif void func_801491E4(s32 arg0, s32 arg1, s32 arg2, s32 arg3, s32 arg4, s32 alpha) { gDPSetPrimColor(gMasterGfxPos++, 0, 0, 0, 0, 0, alpha); diff --git a/src/encounter_api.c b/src/encounter_api.c index 2a34a6dbb8..10dbd225e2 100644 --- a/src/encounter_api.c +++ b/src/encounter_api.c @@ -192,7 +192,7 @@ void start_battle(Evt* script, s32 songID) { enemy->encountered = TRUE; currentEncounter->currentEnemy = enemy; currentEncounter->currentEncounter = currentEncounter->encounterList[enemy->encounterIndex]; - currentEncounter->eFirstStrike = 0; + currentEncounter->firstStrikeType = FIRST_STRIKE_NONE; currentEncounter->allowFleeing = 0; currentEncounter->songID = songID; currentEncounter->unk_18 = -1; @@ -260,7 +260,7 @@ ApiStatus StartBossBattle(Evt* script, s32 isInitialCall) { enemy->encountered = TRUE; currentEncounter->currentEnemy = enemy; currentEncounter->currentEncounter = currentEncounter->encounterList[enemy->encounterIndex]; - currentEncounter->eFirstStrike = FIRST_STRIKE_NONE; + currentEncounter->firstStrikeType = FIRST_STRIKE_NONE; currentEncounter->allowFleeing = TRUE; currentEncounter->songID = songID; currentEncounter->unk_18 = -1; diff --git a/src/entity/Chest.c b/src/entity/Chest.c index b458342e1d..ce22f1b3cc 100644 --- a/src/entity/Chest.c +++ b/src/entity/Chest.c @@ -150,7 +150,7 @@ void entity_Chest_begin_opening(Entity* entity) { data->lidAngle = 0.0f; data->openState = 0; data->giveItemTimer = 40; - sfx_play_sound(467); + sfx_play_sound(SOUND_1D3); } void entity_Chest_open(Entity* entity) { diff --git a/src/entity/HeartBlock.c b/src/entity/HeartBlock.c index b48bef184a..c9427489d9 100644 --- a/src/entity/HeartBlock.c +++ b/src/entity/HeartBlock.c @@ -158,7 +158,7 @@ void entity_HeartBlockContent_anim_idle(Entity* entity, s32 arg1) { disable_player_input(); gPlayerStatus.currentSpeed = 0; gPlayerStatus.animFlags |= PLAYER_STATUS_ANIM_FLAGS_RAISED_ARMS; - set_time_freeze_mode(1); + set_time_freeze_mode(TIME_FREEZE_PARTIAL); gOverrideFlags |= GLOBAL_OVERRIDES_40; } } @@ -277,7 +277,7 @@ void entity_HeartBlockContent__anim_heal(Entity* entity, s32 arg1) { case 5: playerStatus->animFlags &= ~PLAYER_STATUS_ANIM_FLAGS_RAISED_ARMS; enable_player_input(); - set_time_freeze_mode(0); + set_time_freeze_mode(TIME_FREEZE_NORMAL); gOverrideFlags &= ~GLOBAL_OVERRIDES_40; exec_entity_commandlist(entity); break; diff --git a/src/entity/jan_iwa/Plants1.c b/src/entity/jan_iwa/Plants1.c index 552f8d3de4..b034397f04 100644 --- a/src/entity/jan_iwa/Plants1.c +++ b/src/entity/jan_iwa/Plants1.c @@ -284,7 +284,7 @@ void entity_CymbalPlant_idle(Entity* entity) { disable_player_input(); set_action_state(0); play_model_animation(entity->virtualModelIndex, Entity_CymbalPlant_AnimationGrab); - sfx_play_sound(242); + sfx_play_sound(SOUND_F2); func_802BB8D4_E2E204(entity); } else { data->unk_01 = 0; diff --git a/src/hud_element.c b/src/hud_element.c index d95b236bca..0c26998cd9 100644 --- a/src/hud_element.c +++ b/src/hud_element.c @@ -11,11 +11,6 @@ typedef struct HudElementSize { s16 size; } HudElementSize; -typedef struct HudCacheEntry { - /* 0x00 */ s32 id; - /* 0x04 */ u8* data; -} HudCacheEntry; // size = 0x08; - u8* gHudElementAuxCache = NULL; s32 gHudElementCacheCapacity = 0x11000; diff --git a/src/hud_element.h b/src/hud_element.h index 8111b516e0..5098b38137 100644 --- a/src/hud_element.h +++ b/src/hud_element.h @@ -108,6 +108,11 @@ enum { HUD_ELEMENT_DRAW_FIRST_WITHOUT_CLIPPING = 2, }; +typedef struct HudCacheEntry { + /* 0x00 */ s32 id; + /* 0x04 */ u8* data; +} HudCacheEntry; // size = 0x08; + typedef struct PopupMenu { /* 0x000 */ HudScript* ptrIcon[32]; /* 0x080 */ char unk_80[0x4]; diff --git a/src/npc.c b/src/npc.c index d27f3cd7e3..6117c60d38 100644 --- a/src/npc.c +++ b/src/npc.c @@ -1791,7 +1791,7 @@ void init_encounter_status(void) { currentEncounter->flags = ENCOUNTER_STATUS_FLAGS_0; currentEncounter->numEncounters = 0; - currentEncounter->eFirstStrike = 0; + currentEncounter->firstStrikeType = FIRST_STRIKE_NONE; currentEncounter->hitType = 0; currentEncounter->battleTriggerCooldown = 0; currentEncounter->npcGroupList = 0; @@ -1837,7 +1837,7 @@ void clear_encounter_status(void) { } currentEncounter->numEncounters = 0; - currentEncounter->eFirstStrike = 0; + currentEncounter->firstStrikeType = FIRST_STRIKE_NONE; currentEncounter->hitType = 0; currentEncounter->battleTriggerCooldown = 0; currentEncounter->currentAreaIndex = gGameStatusPtr->areaID; diff --git a/src/pause/pause_main.c b/src/pause/pause_main.c index 3014303ecd..4fa452a7a2 100644 --- a/src/pause/pause_main.c +++ b/src/pause/pause_main.c @@ -644,7 +644,7 @@ void pause_tutorial_input(s32 *pressed, s32 *held) { gPauseTutorialInputState = 1; } if (pressedOld && pressedNew == 0) { - sfx_play_sound(541); + sfx_play_sound(SOUND_MENU_ERROR); } if (gPauseTutorialState == 0) { pressedNew = 0; @@ -710,7 +710,7 @@ void pause_handle_input(s32 pressed, s32 held) { if ((gPausePressedButtons & BUTTON_START) || (gPauseMenuCurrentTab == 0) && (gPausePressedButtons & BUTTON_B)) { enforce_hpfp_limits(); - sfx_play_sound(198); + sfx_play_sound(SOUND_MENU_CLOSE); set_game_mode(GAME_MODE_UNPAUSE); return; } diff --git a/src/sprite.h b/src/sprite.h index 5b1d3a88b9..332b5d10ad 100644 --- a/src/sprite.h +++ b/src/sprite.h @@ -152,7 +152,7 @@ PAL_PTR* spr_get_npc_palettes(s32 npcSpriteID); s32 spr_get_npc_color_variations(s32 npcSpriteID); -void render_shaded_sprite(Matrix4f mtx, s32 uls, s32 ult, s32 lrs, s32 lrt, s32 alpha, s32); +void create_shading_palette(Matrix4f mtx, s32 uls, s32 ult, s32 lrs, s32 lrt, s32 alpha, s32); SpriteAnimData* spr_load_sprite(s32 idx, s32 arg1, s32 arg2); diff --git a/src/state_file_select.c b/src/state_file_select.c index 3596b0cb5e..497b0cbe15 100644 --- a/src/state_file_select.c +++ b/src/state_file_select.c @@ -308,7 +308,7 @@ void state_step_exit_language_select(void) { calculate_model_sizes(); npc_reload_all(); func_800E98C4(); - set_time_freeze_mode(1); + set_time_freeze_mode(TIME_FREEZE_PARTIAL); } set_windows_visible(WINDOW_GROUP_ALL); D_800A0931 = 3; @@ -341,7 +341,7 @@ void state_step_exit_language_select(void) { } break; case 4: - set_time_freeze_mode(0); + set_time_freeze_mode(TIME_FREEZE_NORMAL); update_player(); update_npcs(); update_encounters(); @@ -384,7 +384,7 @@ void state_step_exit_file_select(void) { set_windows_visible(WINDOW_GROUP_ALL); D_800A0931 = 3; case 3: - set_time_freeze_mode(0); + set_time_freeze_mode(TIME_FREEZE_NORMAL); if (temp_s0 == 0) { set_game_mode(GAME_MODE_TITLE_SCREEN); gOverrideFlags &= ~GLOBAL_OVERRIDES_WINDOWS_IN_FRONT_OF_CURTAINS; diff --git a/src/world/actions.c b/src/world/actions.c index e03fece04e..cefbb56c33 100644 --- a/src/world/actions.c +++ b/src/world/actions.c @@ -29,7 +29,13 @@ s32 D_800F7B4C = 0; f32 GravityParamsStartJump[] = { 15.7566404343f, -7.38624f, 3.44693994522f, -0.75f }; f32 GravityParamsStartFall[] = { 0.154342994094f, -0.350080013275f, -0.182262003422f, 0.0115200001746f }; -f32 DefaultMoveSpeeds[] = { 2.0f, 4.0f, 32.0f, -32.0f }; // walk, run, max jump, ??? + + // default move speeds +f32 D_800F7B70 = 2.0f; // walk +f32 D_800F7B74 = 4.0f; // run +f32 D_800F7B78 = 32.0f; // max jump +f32 D_800F7B7C = -32.0f; // ??? + s16 D_800F7B80 = 0; s32 D_800F7B84[] = { 0, 0, 0}; f32 D_800F7B90 = 0.0; diff --git a/src/world/area_hos/hos_05/A2A240.c b/src/world/area_hos/hos_05/A2A240.c index 1e9e47666c..85e0776bda 100644 --- a/src/world/area_hos/hos_05/A2A240.c +++ b/src/world/area_hos/hos_05/A2A240.c @@ -10,7 +10,7 @@ static char* N(exit_str_1) = ""; ApiStatus N(AwaitScriptComplete)(Evt* script, s32 isInitialCall) { Bytecode* args = script->ptrReadPos; s32 waitingScriptID = evt_get_variable(script, *args++); - + if (!does_script_exist(waitingScriptID)) { return ApiStatus_DONE2; } else { diff --git a/src/world/area_hos/hos_06/A397F0.c b/src/world/area_hos/hos_06/A397F0.c index 3687a7002c..15f9e5cba1 100644 --- a/src/world/area_hos/hos_06/A397F0.c +++ b/src/world/area_hos/hos_06/A397F0.c @@ -72,7 +72,7 @@ ApiStatus Merlow_ShopBadgesPopup(Evt* script, s32 isInitialCall) { create_popup_menu(menu); script->functionTemp[0] = 0; } - + menu = script->functionTempPtr[2]; if (script->functionTemp[0] == 0) { script->functionTemp[1] = menu->result; @@ -86,7 +86,7 @@ ApiStatus Merlow_ShopBadgesPopup(Evt* script, s32 isInitialCall) { if (script->functionTemp[0] < 20) { return ApiStatus_BLOCK; } - + destroy_popup_menu(); selected = script->functionTemp[1]; if (selected != 0xFF) { @@ -101,7 +101,7 @@ ApiStatus Merlow_ShopBadgesPopup(Evt* script, s32 isInitialCall) { } else { script->varTable[0] = -1; } - + heap_free(script->functionTempPtr[2]); return ApiStatus_DONE2; } diff --git a/src/world/area_hos/hos_10/A3F740.c b/src/world/area_hos/hos_10/A3F740.c index b5ac55e895..de2644050c 100644 --- a/src/world/area_hos/hos_10/A3F740.c +++ b/src/world/area_hos/hos_10/A3F740.c @@ -3,6 +3,5 @@ static char* N(exit_str_0) = "kmr_21"; static char* N(exit_str_1) = "osr_02"; static char* N(exit_str_2) = "kmr_20"; -static char* N(exit_str_3) = ""; #include "world/common/SetPlayerSpriteSet2.inc.c" diff --git a/src/world/area_isk/isk_11/98AA10.c b/src/world/area_isk/isk_11/98AA10.c index d3efc0f43c..9f5eff722c 100644 --- a/src/world/area_isk/isk_11/98AA10.c +++ b/src/world/area_isk/isk_11/98AA10.c @@ -12,7 +12,7 @@ ApiStatus func_80240000_98AA10(Evt* script, s32 isInitialCall) { f32 posY = evt_get_float_variable(script, *args++); f32 posZ = evt_get_float_variable(script, *args++); s32 duration = evt_get_variable(script, *args++); - + fx_lens_flare(0, posX, posY, posZ, duration); return ApiStatus_DONE2; } diff --git a/src/world/area_jan/jan_05/B4ADC0.c b/src/world/area_jan/jan_05/B4ADC0.c index 759408e51f..0d23063317 100644 --- a/src/world/area_jan/jan_05/B4ADC0.c +++ b/src/world/area_jan/jan_05/B4ADC0.c @@ -1,3 +1,3 @@ #include "jan_05.h" -INCLUDE_ASM(s32, "world/area_jan/jan_05/B4ADC0", func_80240350_B4ADC0); +#include "world/common/UnkShadowFunc001.inc.c" diff --git a/src/world/area_jan/jan_06/B52BE0.c b/src/world/area_jan/jan_06/B52BE0.c index 3d6a958967..ed0f38afdf 100644 --- a/src/world/area_jan/jan_06/B52BE0.c +++ b/src/world/area_jan/jan_06/B52BE0.c @@ -1,3 +1,3 @@ #include "jan_06.h" -INCLUDE_ASM(s32, "world/area_jan/jan_06/B52BE0", func_802403B0_B52BE0); +#include "world/common/UnkShadowFunc001.inc.c" diff --git a/src/world/area_jan/jan_10/B6D4C0.c b/src/world/area_jan/jan_10/B6D4C0.c index af5879dd99..52242824fb 100644 --- a/src/world/area_jan/jan_10/B6D4C0.c +++ b/src/world/area_jan/jan_10/B6D4C0.c @@ -1,3 +1,3 @@ #include "jan_10.h" -INCLUDE_ASM(s32, "world/area_jan/jan_10/B6D4C0", func_80241130_B6D4C0); +#include "world/common/UnkShadowFunc001.inc.c" diff --git a/src/world/area_kpa/kpa_08/A4CA20.c b/src/world/area_kpa/kpa_08/A4CA20.c index 35cd18c0c7..ded7bb0712 100644 --- a/src/world/area_kpa/kpa_08/A4CA20.c +++ b/src/world/area_kpa/kpa_08/A4CA20.c @@ -5,4 +5,14 @@ static char* N(exit_str_1) = "kpa_100"; #include "world/common/UnsetCamera0MoveFlag1.inc.c" -INCLUDE_ASM(s32, "world/area_kpa/kpa_08/A4CA20", func_8024001C_A4CA3C); +ApiStatus func_8024001C_A4CA3C(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; + s32 floor = evt_get_variable(script, *args++); + s32 yOffset = evt_get_variable(script, *args++); + PlayerStatus* playerStatus = &gPlayerStatus; + + if (floor == gCollisionStatus.currentFloor) { + playerStatus->position.y = script->varTable[0] + yOffset; + } + return ApiStatus_DONE2; +} diff --git a/src/world/area_kpa/kpa_09/A4F000.c b/src/world/area_kpa/kpa_09/A4F000.c index 06abf5ca3b..6a064610c0 100644 --- a/src/world/area_kpa/kpa_09/A4F000.c +++ b/src/world/area_kpa/kpa_09/A4F000.c @@ -5,4 +5,14 @@ static char* N(exit_str_1) = "kpa_33"; #include "world/common/UnsetCamera0MoveFlag1.inc.c" -INCLUDE_ASM(s32, "world/area_kpa/kpa_09/A4F000", func_8024001C_A4F01C); +ApiStatus func_8024001C_A4F01C(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; + s32 floor = evt_get_variable(script, *args++); + s32 yOffset = evt_get_variable(script, *args++); + PlayerStatus* playerStatus = &gPlayerStatus; + + if (floor == gCollisionStatus.currentFloor) { + playerStatus->position.y = script->varTable[0] + yOffset; + } + return ApiStatus_DONE2; +} diff --git a/src/world/area_kpa/kpa_100/A93160.c b/src/world/area_kpa/kpa_100/A93160.c index 48b8b28356..7263ab199a 100644 --- a/src/world/area_kpa/kpa_100/A93160.c +++ b/src/world/area_kpa/kpa_100/A93160.c @@ -1,3 +1,9 @@ #include "kpa_100.h" -INCLUDE_ASM(s32, "world/area_kpa/kpa_100/A93160", func_80240000_A93160); +ApiStatus func_80240000_A93160(Evt* script, s32 isInitialCall) { + sprintf(wMapShapeName, "kpa_117_shape"); + sprintf(wMapHitName, "kpa_117_hit"); + return ApiStatus_BLOCK; +} + +const char* N(exit_str_0) = "kpa_08"; diff --git a/src/world/area_kpa/kpa_101/A93440.c b/src/world/area_kpa/kpa_101/A93440.c index 5f642c8e8f..2f9552e0c6 100644 --- a/src/world/area_kpa/kpa_101/A93440.c +++ b/src/world/area_kpa/kpa_101/A93440.c @@ -1,3 +1,9 @@ #include "kpa_101.h" -INCLUDE_ASM(s32, "world/area_kpa/kpa_101/A93440", func_80240000_A93440); +ApiStatus func_80240000_A93440(Evt* script, s32 isInitialCall) { + sprintf(wMapShapeName, "kpa_119_shape"); + sprintf(wMapHitName, "kpa_119_hit"); + return ApiStatus_BLOCK; +} + +const char* N(exit_str_0) = "kpa_09"; diff --git a/src/world/area_kpa/kpa_12/A54950.c b/src/world/area_kpa/kpa_12/A54950.c index a7a82dce33..3d350859fe 100644 --- a/src/world/area_kpa/kpa_12/A54950.c +++ b/src/world/area_kpa/kpa_12/A54950.c @@ -3,6 +3,11 @@ static char* N(exit_str_0) = "kpa_10"; static char* N(exit_str_1) = "kpa_11"; static char* N(exit_str_2) = "kpa_13"; -static char* N(exit_str_3) = ""; -INCLUDE_ASM(s32, "world/area_kpa/kpa_12/A54950", func_80240000_A54950); +s32 func_80240000_A54950(void) { + if (evt_get_variable(NULL, GSWF(1556)) == 0) { + return 0x190160; + } else { + return 0x190161; + } +} diff --git a/src/world/area_kpa/kpa_12/A54CA0.c b/src/world/area_kpa/kpa_12/A54CA0.c index 687157bb96..8e5b5b8195 100644 --- a/src/world/area_kpa/kpa_12/A54CA0.c +++ b/src/world/area_kpa/kpa_12/A54CA0.c @@ -7,7 +7,25 @@ ApiStatus N(func_80240350_A54CA0)(Evt* script, s32 isInitialCall) { return ApiStatus_DONE2; } -INCLUDE_ASM(s32, "world/area_kpa/kpa_12/A54CA0", func_8024037C_A54CCC); +ApiStatus func_8024037C_A54CCC(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; + s32 velocity = evt_get_variable(script, *args++); + s32 floor = evt_get_variable(script, *args++); + PlayerStatus* playerStatus = &gPlayerStatus; + + if (gCollisionStatus.currentFloor == floor || gCollisionStatus.lastTouchedFloor == floor) { + playerStatus->extraVelocity.x = velocity; + } + + if (gPlayerData.currentPartner != PARTNER_NONE) { + Npc* partner = get_npc_unsafe(NPC_PARTNER); + + if (partner->currentFloor == floor) { + partner->pos.x += velocity; + } + } + return ApiStatus_DONE2; +} ApiStatus N(IsPartnerLakilester)(Evt* script, s32 isInitialCall) { if (gPartnerActionStatus.actingPartner == PARTNER_LAKILESTER) { diff --git a/src/world/area_kpa/kpa_13/A55F20.c b/src/world/area_kpa/kpa_13/A55F20.c index 481a096021..a884a1ab69 100644 --- a/src/world/area_kpa/kpa_13/A55F20.c +++ b/src/world/area_kpa/kpa_13/A55F20.c @@ -3,6 +3,11 @@ static char* N(exit_str_0) = "kpa_12"; static char* N(exit_str_1) = "kpa_15"; static char* N(exit_str_2) = "kpa_14"; -static char* N(exit_str_3) = ""; -INCLUDE_ASM(s32, "world/area_kpa/kpa_13/A55F20", func_80240000_A55F20); +s32 func_80240000_A55F20(void) { + if (evt_get_variable(NULL, GSWF(1556)) == 0) { + return 0x190162; + } else { + return 0x190163; + } +} diff --git a/src/world/area_kpa/kpa_13/A56270.c b/src/world/area_kpa/kpa_13/A56270.c index 55202ca334..3a069c7ef6 100644 --- a/src/world/area_kpa/kpa_13/A56270.c +++ b/src/world/area_kpa/kpa_13/A56270.c @@ -1,13 +1,32 @@ #include "kpa_13.h" ApiStatus N(func_80240350_A56270)(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; CollisionStatus* collisionStatus = &gCollisionStatus; - evt_set_variable(script, *script->ptrReadPos, collisionStatus->floorBelow); + evt_set_variable(script, *args++, collisionStatus->floorBelow); return ApiStatus_DONE2; } -INCLUDE_ASM(s32, "world/area_kpa/kpa_13/A56270", func_8024037C_A5629C); +ApiStatus func_8024037C_A5629C(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; + s32 velocity = evt_get_variable(script, *args++); + s32 floor = evt_get_variable(script, *args++); + PlayerStatus* playerStatus = &gPlayerStatus; + + if (gCollisionStatus.currentFloor == floor || gCollisionStatus.lastTouchedFloor == floor) { + playerStatus->extraVelocity.x = velocity; + } + + if (gPlayerData.currentPartner != PARTNER_NONE) { + Npc* partner = get_npc_unsafe(NPC_PARTNER); + + if (partner->currentFloor == floor) { + partner->pos.x += velocity; + } + } + return ApiStatus_DONE2; +} ApiStatus N(IsPartnerLakilester)(Evt* script, s32 isInitialCall) { if (gPartnerActionStatus.actingPartner == PARTNER_LAKILESTER) { diff --git a/src/world/area_kpa/kpa_133/AA7790.c b/src/world/area_kpa/kpa_133/AA7790.c index 55fffe1982..8b3aab712b 100644 --- a/src/world/area_kpa/kpa_133/AA7790.c +++ b/src/world/area_kpa/kpa_133/AA7790.c @@ -1,5 +1,21 @@ #include "kpa_133.h" -INCLUDE_ASM(s32, "world/area_kpa/kpa_133/AA7790", func_80240310_AA7790); +ApiStatus func_80240310_AA7790(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; + Entity* entity = get_entity_by_index(evt_get_variable(NULL, -50000000)); -INCLUDE_ASM(s32, "world/area_kpa/kpa_133/AA7790", func_802403C0_AA7840); + entity->rotation.x = evt_get_variable(script, *args++); + entity->rotation.y = evt_get_variable(script, *args++); + entity->rotation.z = evt_get_variable(script, *args++); + return ApiStatus_DONE2; +} + +ApiStatus func_802403C0_AA7840(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; + Entity* entity = get_entity_by_index(evt_get_variable(NULL, -50000000)); + + entity->position.x = evt_get_variable(script, *args++); + entity->position.y = evt_get_variable(script, *args++); + entity->position.z = evt_get_variable(script, *args++); + return ApiStatus_DONE2; +} diff --git a/src/world/area_kpa/kpa_14/A574B0.c b/src/world/area_kpa/kpa_14/A574B0.c index 6afd8a05af..e2c2fa84f5 100644 --- a/src/world/area_kpa/kpa_14/A574B0.c +++ b/src/world/area_kpa/kpa_14/A574B0.c @@ -3,6 +3,11 @@ static char* N(exit_str_0) = "kpa_13"; static char* N(exit_str_1) = "kpa_01"; static char* N(exit_str_2) = "kpa_16"; -static char* N(exit_str_3) = ""; -INCLUDE_ASM(s32, "world/area_kpa/kpa_14/A574B0", func_80240000_A574B0); +s32 func_80240000_A574B0(void) { + if (evt_get_variable(NULL, GSWF(1556)) == 0) { + return 0x190164; + } else { + return 0x190165; + } +} diff --git a/src/world/area_kpa/kpa_14/A57830.c b/src/world/area_kpa/kpa_14/A57830.c index a705adccab..a354f76004 100644 --- a/src/world/area_kpa/kpa_14/A57830.c +++ b/src/world/area_kpa/kpa_14/A57830.c @@ -13,13 +13,37 @@ #include "world/common/GetEntityPosition.inc.c" ApiStatus N(func_80240710_A57BC0)(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; CollisionStatus* collisionStatus = &gCollisionStatus; - evt_set_variable(script, *script->ptrReadPos, collisionStatus->floorBelow); + evt_set_variable(script, *args++, collisionStatus->floorBelow); return ApiStatus_DONE2; } -INCLUDE_ASM(s32, "world/area_kpa/kpa_14/A57830", func_8024073C_A57BEC); +ApiStatus func_8024073C_A57BEC(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; + s32 xVel = evt_get_variable(script, *args++); + s32 floor = evt_get_variable(script, *args++); + s32 temp_a0 = evt_get_variable(script, *args++); + PlayerStatus* playerStatus = &gPlayerStatus; + + if (gCollisionStatus.currentFloor == floor || gCollisionStatus.lastTouchedFloor == floor) { + if (playerStatus->actionState != ACTION_STATE_ULTRA_JUMP && + playerStatus->actionState != ACTION_STATE_SPIN_JUMP && + temp_a0 == 0) + { + playerStatus->extraVelocity.x = xVel; + } + } + if (gPlayerData.currentPartner != PARTNER_NONE) { + Npc* partner = get_npc_unsafe(NPC_PARTNER); + + if (partner->currentFloor == floor) { + partner->pos.x += xVel; + } + } + return ApiStatus_DONE2; +} ApiStatus N(IsPartnerLakilester)(Evt* script, s32 isInitialCall) { if (gPartnerActionStatus.actingPartner == PARTNER_LAKILESTER) { diff --git a/src/world/area_kpa/kpa_51/A64090.c b/src/world/area_kpa/kpa_51/A64090.c index 5b312cf7a9..98fefb0584 100644 --- a/src/world/area_kpa/kpa_51/A64090.c +++ b/src/world/area_kpa/kpa_51/A64090.c @@ -1,3 +1,10 @@ #include "kpa_51.h" -INCLUDE_ASM(s32, "world/area_kpa/kpa_51/A64090", func_80240000_A64090); +ApiStatus func_80240000_A64090(Evt* script, s32 isInitialCall) { + sprintf(wMapShapeName, "kpa_50_shape"); + sprintf(wMapHitName, "kpa_50_hit"); + return ApiStatus_BLOCK; +} + +const char* N(exit_str_0) = "kpa_32"; +const char* N(exit_str_1) = "kpa_133"; diff --git a/src/world/area_kpa/kpa_53/A6ACA0.c b/src/world/area_kpa/kpa_53/A6ACA0.c index 81fd01bce3..ae52d8dc64 100644 --- a/src/world/area_kpa/kpa_53/A6ACA0.c +++ b/src/world/area_kpa/kpa_53/A6ACA0.c @@ -1,5 +1,36 @@ #include "kpa_53.h" -INCLUDE_ASM(s32, "world/area_kpa/kpa_53/A6ACA0", func_80240000_A6ACA0); +ApiStatus func_80240000_A6ACA0(Evt* script, s32 isInitialCall) { + gGameStatusPtr->playerSpriteSet = 2; + sprintf(wMapShapeName, "kpa_50_shape"); + sprintf(wMapHitName, "kpa_50_hit"); + return ApiStatus_BLOCK; +} -INCLUDE_ASM(s32, "world/area_kpa/kpa_53/A6ACA0", func_80240050_A6ACF0); +const char* N(exit_str_0) = "kpa_102"; +const char* N(exit_str_1) = "kpa_83"; + +ApiStatus func_80240050_A6ACF0(Evt* script, s32 isInitialCall) { + PlayerStatus* playerStatus = &gPlayerStatus; + Bytecode* args = script->ptrReadPos; + s32 npcID = evt_get_variable(script, *args++); + s32 outVar = *args++; + Npc* npc = resolve_npc(script, npcID); + u32 animID; + + if (npc == NULL) { + return ApiStatus_DONE2; + } + + npc->pos.x = (s32)(((s32)playerStatus->position.x - 700) * 0.85) + 765; + if (playerStatus->currentSpeed == 0.0f) { + animID = 0xA0001; + } else if (playerStatus->currentSpeed < 2.0f) { + animID = 0xA0002; + } else { + animID = 0xA0003; + } + npc->currentAnim.w = animID; + evt_set_variable(script, outVar, playerStatus->targetYaw); + return ApiStatus_DONE2; +} diff --git a/src/world/area_kpa/kpa_63/A735B0.c b/src/world/area_kpa/kpa_63/A735B0.c index 111a70257a..f5e4fb8ea8 100644 --- a/src/world/area_kpa/kpa_63/A735B0.c +++ b/src/world/area_kpa/kpa_63/A735B0.c @@ -3,4 +3,52 @@ static char* N(exit_str_0) = "kpa_62"; static char* N(exit_str_1) = "kpa_60"; -INCLUDE_ASM(s32, "world/area_kpa/kpa_63/A735B0", func_80240000_A735B0); +ApiStatus func_80240000_A735B0(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; + Npc* partner; + f32 x, y, z; + f32 yBase; + f32 angle; + f32 var_f20; + + if (isInitialCall) { + script->functionTemp[0] = evt_get_variable(script, *args++); + yBase = evt_get_variable(script, *args++); + angle = evt_get_variable(script, *args++); + switch (script->functionTemp[0]) { + case 0: + var_f20 = 0.0f; + break; + case 1: + var_f20 = 5.0f; + break; + } + } + + x = (sin_deg(angle) * var_f20) + -120.0f; + y = yBase - 11.0f; + z = (cos_deg(angle) * var_f20) + 225.0f; + + switch (script->functionTemp[0]) { + case 0: + gPlayerStatus.position.x = x; + gPlayerStatus.position.y = y; + gPlayerStatus.position.z = z; + break; + case 1: + partner = get_npc_safe(NPC_PARTNER); + if (partner != NULL) { + partner->pos.x = x; + partner->pos.y = y; + partner->pos.z = z; + partner->colliderPos.x = partner->pos.x; + partner->colliderPos.y = partner->pos.y; + partner->colliderPos.z = partner->pos.z; + partner->flags |= 0x10000; + } + break; + default: + return ApiStatus_DONE2; + } + return ApiStatus_DONE2; +} diff --git a/src/world/area_kpa/kpa_81/A784C0.c b/src/world/area_kpa/kpa_81/A784C0.c index a965a4eb36..b8c3f94c19 100644 --- a/src/world/area_kpa/kpa_81/A784C0.c +++ b/src/world/area_kpa/kpa_81/A784C0.c @@ -1,3 +1,12 @@ #include "kpa_81.h" -INCLUDE_ASM(s32, "world/area_kpa/kpa_81/A784C0", func_80240000_A784C0); +ApiStatus func_80240000_A784C0(Evt* script, s32 isInitialCall) { + sprintf(wMapShapeName, "kpa_80_shape"); + sprintf(wMapHitName, "kpa_80_hit"); + return ApiStatus_BLOCK; +} + +const char* N(exit_str_0) = "kpa_50"; +const char* N(exit_str_1) = "kpa_32"; +const char* N(exit_str_2) = "kpa_04"; +const char* N(exit_str_3) = "kpa_17"; diff --git a/src/world/area_kpa/kpa_82/A7A500.c b/src/world/area_kpa/kpa_82/A7A500.c index c7ade8abc6..51eb50d996 100644 --- a/src/world/area_kpa/kpa_82/A7A500.c +++ b/src/world/area_kpa/kpa_82/A7A500.c @@ -1,3 +1,10 @@ #include "kpa_82.h" -INCLUDE_ASM(s32, "world/area_kpa/kpa_82/A7A500", func_80240000_A7A500); +ApiStatus func_80240000_A7A500(Evt* script, s32 isInitialCall) { + sprintf(wMapShapeName, "kpa_80_shape"); + sprintf(wMapHitName, "kpa_80_hit"); + return ApiStatus_BLOCK; +} + +const char* N(exit_str_0) = "kpa_113"; +const char* N(exit_str_1) = "kpa_61"; diff --git a/src/world/area_kpa/kpa_83/A83490.c b/src/world/area_kpa/kpa_83/A83490.c index eb5e97279c..51e4ec98da 100644 --- a/src/world/area_kpa/kpa_83/A83490.c +++ b/src/world/area_kpa/kpa_83/A83490.c @@ -1,3 +1,10 @@ #include "kpa_83.h" -INCLUDE_ASM(s32, "world/area_kpa/kpa_83/A83490", func_80240000_A83490); +ApiStatus func_80240000_A83490(Evt* script, s32 isInitialCall) { + sprintf(wMapShapeName, "kpa_80_shape"); + sprintf(wMapHitName, "kpa_80_hit"); + return ApiStatus_BLOCK; +} + +const char* N(exit_str_0) = "kpa_53"; +const char* N(exit_str_1) = "kpa_121"; diff --git a/src/world/common/UnkShadowFunc001.inc.c b/src/world/common/UnkShadowFunc001.inc.c new file mode 100644 index 0000000000..4f86de0ec8 --- /dev/null +++ b/src/world/common/UnkShadowFunc001.inc.c @@ -0,0 +1,43 @@ +#include "common.h" +#include "model.h" + +ApiStatus N(UnkShadowFunc001)(Evt* script, s32 isInitialCall) { + Bytecode* args = script->ptrReadPos; + f32 x, y, z; + f32 sp24; + f32 sp28; + f32 sp2C; + Shadow* shadow; + Model* model; + + if (isInitialCall) { + s32 treeIndex = evt_get_variable(script, *args++); + + script->functionTemp[3] = *args++; + script->functionTempPtr[1] = model = get_model_from_list_index(get_model_list_index_from_tree_index(treeIndex)); + script->functionTemp[2] = create_shadow_type(0, model->center.x, 0.0f, model->center.z); + evt_set_variable(script, script->functionTemp[3], 0); + } + + if (evt_get_variable(script, script->functionTemp[3]) != 0) { + delete_shadow(script->functionTemp[2]); + return ApiStatus_DONE2; + } + + model = script->functionTempPtr[1]; + shadow = get_shadow_by_index(script->functionTemp[2]); + x = model->center.x; + y = model->center.y; + z = model->center.z; + entity_raycast_down(&x, &y, &z, &sp24, &sp28, &sp2C); + set_standard_shadow_scale(shadow, sp2C); + shadow->rotation.y = 0.0f; + shadow->position.x = x; + shadow->position.y = y; + shadow->position.z = z; + shadow->rotation.x = sp24; + shadow->rotation.z = sp28; + shadow->scale.x *= 2.0f; + shadow->scale.z *= 2.0f; + return ApiStatus_BLOCK; +} diff --git a/src/world/partner/bombette.c b/src/world/partner/bombette.c index f7ebc72d5e..71750acb52 100644 --- a/src/world/partner/bombette.c +++ b/src/world/partner/bombette.c @@ -1,5 +1,6 @@ #include "common.h" -#include "../src/world/partners.h" +#include "world/partners.h" +#include "effects.h" BSS s32 D_802BE920; BSS s32 D_802BE924; @@ -193,7 +194,367 @@ s32 world_bombette_can_player_pause(Npc* npc) { } ApiStatus func_802BD758_3184A8(Evt* evt, s32 isInitialCall); +// control flol +#ifdef NON_MATCHING +ApiStatus func_802BD758_3184A8(Evt* evt, s32 isInitialCall) { + PlayerStatus* playerStatus = &gPlayerStatus; + CollisionStatus* collisionStatus = &gCollisionStatus; + PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus; + Camera* camera = &gCameras[CAM_DEFAULT]; + f32 x, y, z, hitDepth; + Npc* npc = evt->owner2.npc; + f32* zPtr; + f32* xPtr; + + f32 temp_f0; + f32 temp_f0_2; + f32 temp_f0_5; + s32 var_v0_5; + f32 temp1; + + if (gCurrentEncounter.unk_08 != 0) { + return 0; + } + if (isInitialCall) { + func_802BD6DC_31842C(npc); + evt->functionTemp[0] = 20; + } + + switch (evt->functionTemp[0]) { + case 20: + if ((playerStatus->inputEnabledCounter != 0) || (playerStatus->flags & 2) || !(npc->flags & 0x1000)) { + return ApiStatus_DONE2; + } + disable_player_input(); + evt->functionTemp[3] = playerStatus->inputEnabledCounter; + D_802BE92C = 1; + D_802BE928 = 0; + D_802BE930 = 0; + D_802BE934 = 0; + npc->flags &= ~0xA48; + partnerActionStatus->partnerActionState = 1; + partnerActionStatus->actingPartner = 3; + D_802BE920 = func_800EF4E0(); + enable_npc_blur(npc); + npc->duration = 4; + npc->yaw = atan2(npc->pos.x, npc->pos.z, playerStatus->position.x, playerStatus->position.z); + suggest_player_anim_clearUnkFlag(0x10002); + evt->functionTemp[0] = 21; + case 21: + if (playerStatus->actionState == 0x15 || playerStatus->actionState == 0x16) { + disable_npc_blur(npc); + evt->functionTemp[0] = 7; + break; + } + + if ((playerStatus->flags & 2)) { + evt->functionTemp[0] = 7; + break; + } + + npc->moveToPos.x = playerStatus->position.x; + npc->moveToPos.y = playerStatus->position.y; + npc->moveToPos.z = playerStatus->position.z; + npc->currentAnim.w = 0x30007; + add_vec2D_polar(&npc->moveToPos.x, &npc->moveToPos.z, 0.0f, playerStatus->targetYaw); + + temp_f0 = clamp_angle(playerStatus->targetYaw + ((D_802BE920 != 0) ? -90.0f : 90.0f)); + add_vec2D_polar(&npc->moveToPos.x, &npc->moveToPos.z, playerStatus->colliderDiameter / 4, temp_f0); + npc->pos.x += (npc->moveToPos.x - npc->pos.x) / npc->duration; + npc->pos.y += (npc->moveToPos.y - npc->pos.y) / npc->duration; + npc->pos.z += (npc->moveToPos.z - npc->pos.z) / npc->duration; + npc->duration--; + + if (npc->duration != 0) { + break; + } + + if (evt->functionTemp[3] < playerStatus->inputEnabledCounter) { + disable_npc_blur(npc); + evt->functionTemp[0] = 7; + } else { + npc->pos.x = npc->moveToPos.x; + npc->pos.y = npc->moveToPos.y; + npc->pos.z = npc->moveToPos.z; + disable_npc_blur(npc); + suggest_player_anim_clearUnkFlag(0x6000C); + npc->yaw = playerStatus->targetYaw; + npc->currentAnim.w = 0x30005; + evt->functionTemp[0] = 1; + evt->functionTemp[1] = 10; + } + case 1: + if (!(playerStatus->actionState == 0x15 || playerStatus->actionState == 0x16)) { + npc->pos.y = playerStatus->position.y + playerStatus->colliderHeight; + npc->yaw = playerStatus->targetYaw; + if (evt->functionTemp[1] == 1) { + suggest_player_anim_clearUnkFlag(0x60006); + } + + if (evt->functionTemp[1] != 0) { + evt->functionTemp[1]--; + break; + } + + sfx_play_sound_at_npc(0x80000000, 0, -4); + D_802BE924 = 1; + add_vec2D_polar(&npc->pos.x, &npc->pos.z, 0.0f, npc->yaw); + npc->currentAnim.w = 0x30006; + npc->jumpVelocity = 0.0f; + D_802BE938 = 0; + npc->flags = (npc->flags | 0x200) & ~0x100; + npc->moveSpeed = 1.0f; + evt->functionTemp[0] = 2; + evt->functionTemp[1] = 50; + } else { + evt->functionTemp[1] = 7; + break; + } + case 2: + if ((playerStatus->animFlags & 4) || (playerStatus->actionState == 0x15 || playerStatus->actionState == 0x16)) { + evt->functionTemp[0] = 7; + break; + } + + if (evt->functionTemp[1] < 45) { + if (!(npc->flags & 0x2000) && (D_802BE938 == 0)) { + npc_move_heading(npc, npc->moveSpeed, npc->yaw); + func_8003D660(npc, 0); + } else { + D_802BE938 = 1; + } + } + + x = npc->pos.x; + y = npc->pos.y + 14.0f; + z = npc->pos.z; + hitDepth = 16.0f; + if ((npc_raycast_down_around(0x10000, &x, &y, &z, &hitDepth, npc->yaw, npc->collisionRadius) != 0) && ((u32) ((get_collider_type_by_id(D_8010C978) & 0xFF) - 2) < 2U)) { + if (playerStatus->actionState == 0) { + suggest_player_anim_clearUnkFlag(0x10002); + } + npc->currentAnim.w = 0x30010; + npc->flags &= ~0x200; + evt->functionTemp[1] = 2; + evt->functionTemp[0] = 3; + if (D_802BE92C != 0) { + D_802BE92C = 0; + enable_player_input(); + } + } else { + if (!(evt->functionTemp[1] & 3)) { + if (gGameStatusPtr->frameCounter & 1) { + sfx_play_sound_at_npc(0x141, 0, -4); + } else { + sfx_play_sound_at_npc(0x142, 0, -4); + } + } + if (evt->functionTemp[1] == 40) { + if (playerStatus->actionState == 0) { + suggest_player_anim_clearUnkFlag(0x10002); + } + enable_player_input(); + D_802BE92C = 0; + } + npc_do_other_npc_collision(npc); + + if (npc->flags & 0x02000000) { + if (D_802BE92C != 0) { + D_802BE92C = 0; + enable_player_input(); + } + } else { + if (D_802BE934 == 0) { + if (evt->functionTemp[1] != 0) { + evt->functionTemp[1]--; + break; + } + } + } + + npc->currentAnim.w = 0x30000 | 0x10; + evt->functionTemp[1] = 0x14; + evt->functionTemp[0] = 3; + if (playerStatus->actionState == 0) { + suggest_player_anim_clearUnkFlag(0x10002); + } + } + } + + switch (evt->functionTemp[0]) { + case 3: + if (evt->functionTemp[1] != 0) { + evt->functionTemp[1]--; + break; + } + + if (D_802BE924 != 0) { + D_802BE924 = 0; + sfx_stop_sound(0x80000000); + } + fx_explosion(gPlayerData.partners[gPlayerData.currentPartner].level, npc->pos.x, npc->pos.y + (npc->collisionHeight * 0.5f), npc->pos.z); + + switch (gPlayerData.partners[gPlayerData.currentPartner].level) { + case 0: + sfx_play_sound_at_npc(0x2016, 0, -4); + break; + case 1: + sfx_play_sound_at_npc(0x2017, 0, -4); + break; + case 2: + sfx_play_sound_at_npc(0x2018, 0, -4); + break; + } + + exec_ShakeCam1(0, 0, 0x14); + func_8003D660(npc, 2); + collisionStatus->bombetteExploded = 0; + collisionStatus->bombetteExplosionPos.x = npc->pos.x; + collisionStatus->bombetteExplosionPos.y = npc->pos.y; + collisionStatus->bombetteExplosionPos.z = npc->pos.z; + func_802BD100_317E50(npc); + D_802BE928 = 1; + partnerActionStatus->partnerActionState = 2; + evt->functionTemp[1] = 3; + evt->functionTemp[0]++; + break; + case 4: + if (evt->functionTemp[1] != 0) { + evt->functionTemp[1]--; + break; + } + + partnerActionStatus->partnerActionState = 3; + D_802BE928 = 0; + npc->jumpVelocity = ((playerStatus->position.y - npc->pos.y) / 20.0f) + 30.0; + npc->moveSpeed = 0.8f; + npc->yaw = rand_int(360); + npc->jumpScale = 0.8f; + npc->pos.y += 10.0f; + npc->moveToPos.y = npc->pos.y ; + collisionStatus->bombetteExploded = -1; + collisionStatus->bombetteExplosionPos.x = npc->pos.x; + collisionStatus->bombetteExplosionPos.y = npc->pos.y; + collisionStatus->bombetteExplosionPos.z = npc->pos.z; + npc->currentAnim.w = 0x30011; + temp1 = atan2(npc->pos.x, npc->pos.z, playerStatus->position.x, playerStatus->position.z); + if (!(get_clamped_angle_diff(camera->currentYaw, temp1) < 0.0f)) { + evt->functionTemp[2] = 1; + } else { + evt->functionTemp[2] = -1; + } + evt->functionTemp[1] = 10; + evt->functionTemp[0] = 5; + break; + case 5: + npc->pos.y += npc->jumpVelocity; + npc->jumpVelocity -= npc->jumpScale; + npc->rotation.z -= ((evt->functionTemp[2] * 0x4F) / 2); + npc->rotation.x -= ((evt->functionTemp[2] * 0x43) / 2); + if (evt->functionTemp[1] != 0) { + evt->functionTemp[1]--; + break; + } + + if (D_802BE930 == 0) { + npc->pos.x = playerStatus->position.x; + npc->pos.z = playerStatus->position.z; + } + npc->yaw = clamp_angle(gCameras[CAM_DEFAULT].currentYaw + playerStatus->spriteFacingAngle); + add_vec2D_polar(&npc->pos.x, &npc->pos.z, 10.0f, npc->yaw); + npc->jumpVelocity = 0.0f; + npc->currentAnim.w = 0x30011; + npc->flags |= 0x800; + evt->functionTemp[0] = 6; + break; + case 6: + if (npc->pos.y + 10.0f < playerStatus->position.y + playerStatus->colliderHeight) { + npc->flags &= ~0x800; + if (fabsf(playerStatus->position.y - npc->pos.y) < 500.0) { + evt->functionTemp[0] = 8; + break; + } else if (func_800397E8(npc, npc->jumpVelocity)) { + evt->functionTemp[0] = 7; + break; + } + } + npc->pos.y += npc->jumpVelocity; + npc->jumpVelocity -= npc->jumpScale; + if (npc->jumpVelocity < -8.0) { + npc->jumpVelocity = -8.0f; + } + npc->rotation.z -= ((evt->functionTemp[2] * 0x4F) / 2); + npc->rotation.x -= ((evt->functionTemp[2] * 0x43) / 2); + break; + } + + + switch (evt->functionTemp[0]) { + case 7: + if (playerStatus->actionState == 0) { + suggest_player_anim_clearUnkFlag(0x10002); + } + if (D_802BE92C != 0) { + D_802BE92C = 0; + enable_player_input(); + } + partnerActionStatus->partnerActionState = 0; + partnerActionStatus->actingPartner = 0; + npc->jumpVelocity = 0.0f; + D_802BE928 = 0; + D_802BE934 = 0; + npc->pos.y = playerStatus->position.y; + npc->rotation.x = 0.0f; + npc->rotation.z = 0.0f; + npc->currentAnim.w = 0x30003; + partner_clear_player_tracking(npc); + if (D_802BE924 == 0) { + return ApiStatus_DONE2; + } + D_802BE924 = 0; + sfx_stop_sound(0x80000000); + return ApiStatus_DONE2; + case 8: + if (D_802BE92C != 0) { + D_802BE92C = 0; + enable_player_input(); + } + partnerActionStatus->partnerActionState = 0; + partnerActionStatus->actingPartner = 0; + npc->jumpVelocity = 0.0f; + npc->pos.y = playerStatus->position.y; + npc->rotation.x = 0.0f; + npc->rotation.z = 0.0f; + npc->currentAnim.w = 0x30003; + npc->pos.x = playerStatus->position.x; + npc->pos.y = playerStatus->position.y; + npc->pos.z = playerStatus->position.z; + D_802BE928 = 0; + D_802BE934 = 0; + xPtr = &npc->pos.x; + zPtr = &npc->pos.z; + if (D_802BE920 == 0) { + temp_f0_5 = clamp_angle(playerStatus->targetYaw + 90.0f); + } else { + temp_f0_5 = clamp_angle(playerStatus->targetYaw - 90.0f); + } + + add_vec2D_polar(xPtr, zPtr, playerStatus->colliderDiameter / 4, temp_f0_5); + npc->jumpVelocity = 0.0f; + partner_clear_player_tracking(npc); + if (D_802BE924 == 0) { + return ApiStatus_DONE2; + } + D_802BE924 = 0; + sfx_stop_sound(0x80000000); + break; + } + + return ApiStatus_BLOCK; +} +#else INCLUDE_ASM(s32, "world/partner/bombette", func_802BD758_3184A8); +#endif EvtScript world_bombette_use_ability = { EVT_CALL(func_802BD758_3184A8) diff --git a/src/world/partner/bow.c b/src/world/partner/bow.c index 108f2b5d7a..da0091f4a1 100644 --- a/src/world/partner/bow.c +++ b/src/world/partner/bow.c @@ -170,7 +170,7 @@ ApiStatus BowUseAbility(Evt* script, s32 isInitialCall) { if (isInitialCall) { func_802BD4FC_323E4C(bow); if (!(playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_100000)) { - if (func_800EA52C(9) != 0) { + if (func_800EA52C(9)) { if (playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_200000) { playerStatus->animFlags &= ~PLAYER_STATUS_ANIM_FLAGS_200000; script->functionTemp[2] = disable_player_input(); @@ -200,7 +200,7 @@ ApiStatus BowUseAbility(Evt* script, s32 isInitialCall) { script->functionTemp[0]++; break; case 41: - if ((func_800EA52C(9) == 0 || is_starting_conversation()) && + if ((!func_800EA52C(9) || is_starting_conversation()) && script->functionTemp[2] < playerStatus->inputEnabledCounter && D_802BE0C4) { diff --git a/src/world/partner/goombario.c b/src/world/partner/goombario.c index ffda1172fb..e95d224f41 100644 --- a/src/world/partner/goombario.c +++ b/src/world/partner/goombario.c @@ -3,9 +3,11 @@ #include "goombario.h" #include "../src/world/partners.h" +extern s32* D_802B79A8_E21858; + BSS s32 D_802BDF30; BSS s32 D_802BDF34; -BSS s32 D_802BDF38; +BSS Npc* D_802BDF38; BSS s32 D_802BDF3C; BSS TweesterPhysics GoombarioTweesterPhysics; BSS s32 D_802BDF5C; @@ -177,14 +179,13 @@ s32 world_goombario_can_pause(Npc* goombario) { } // get message for tattle routine -// has big jumptable at rodata 802BDE88 ApiStatus func_802BD5D8_3174F8(Evt* script, s32 isInitialCall); INCLUDE_ASM(ApiStatus, "world/partner/goombario", func_802BD5D8_3174F8, Evt* script, s32 isInitialCall); ApiStatus func_802BDB30_317A50(Evt* script, s32 isInitialCall) { PartnerActionStatus* goombarioActionStatus = &gPartnerActionStatus; - set_time_freeze_mode(0); + set_time_freeze_mode(TIME_FREEZE_NORMAL); if (D_802BDF64 != 0) { D_802BDF64 = 0; diff --git a/src/world/partner/parakarry.c b/src/world/partner/parakarry.c index 5354e77f00..d334cb5763 100644 --- a/src/world/partner/parakarry.c +++ b/src/world/partner/parakarry.c @@ -179,7 +179,7 @@ ApiStatus func_802BD660_319BD0(Evt* evt, s32 isInitialCall) { func_802BD514_319A84(parakarry); if (!(playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_100000)) { if (partnerActionStatus->partnerAction_unk_1 == 0) { - if (func_800EA52C(4) == 0) { + if (!func_800EA52C(4)) { return ApiStatus_DONE2; } D_802BEBC0_31CBE0 = 0x28; @@ -214,7 +214,7 @@ ApiStatus func_802BD660_319BD0(Evt* evt, s32 isInitialCall) { case 0x29: if (D_802BEBC4 == 0) { if (evt->functionTemp[2] >= playerStatus->inputEnabledCounter) { - if (func_800EA52C(4) != 0) { + if (func_800EA52C(4)) { D_802BEBC0_31CBE0 = 0x1E; break; } diff --git a/src/world/partner/watt.c b/src/world/partner/watt.c index f83cd44db0..fdbc60034f 100644 --- a/src/world/partner/watt.c +++ b/src/world/partner/watt.c @@ -4,8 +4,9 @@ #include "npc.h" void force_player_anim(s32 arg0); -void func_802BE070_31DBE0(void); -void partner_kill_ability_script(void); +void func_802BE014_31DB84(void); + +s32 D_802BE250_31DDC0[] = {24, 6}; BSS s32 D_802BE300; BSS s32 D_802BE304; @@ -15,10 +16,6 @@ BSS EffectInstance* WattStaticEffect; BSS s32 D_802BE314; BSS TweesterPhysics WattTweesterPhysics; -s32 D_802BE250_31DDC0 = 0x18; - -s32 D_802BE254_31DDC4 = 6; - void func_802BD100_31CC70(Npc* npc) { if (!(npc->flags & NPC_FLAG_2)) { if (WattStaticEffect == NULL) { @@ -35,8 +32,22 @@ s32 world_watt_dispose_static_effect(void) { } } -void func_802BD1AC_31CD1C(s32 arg0); -INCLUDE_ASM(s32, "world/partner/watt", func_802BD1AC_31CD1C); +void func_802BD1AC_31CD1C(s32 arg0) { + EffectInstance* effect = WattStaticEffect; + StaticStatusFXData* data = effect->data.staticStatus; + f32 tmp; + s32 parts; + s32 i; + + data->unk_00 = arg0; + tmp = D_802BE250_31DDC0[arg0] * 0.5f; + parts = effect->numParts - 1; + + data++; + for (i = 1; i < parts; i++, data++) { + data->unk_20 = -1.0f - (tmp * (i & 1)); + } +} void world_watt_init(Npc* npc) { npc->collisionHeight = 24; @@ -76,8 +87,8 @@ ApiStatus WattUpdate(Evt* script, s32 isInitialCall) { PlayerData* playerData = &gPlayerData; Npc* watt = script->owner2.npc; f32 sinAngle, cosAngle, liftoffVelocity; - Entity* entity; - + Entity* entity; + if (gPartnerActionStatus.partnerAction_unk_1 == 0) { if (isInitialCall) { partner_flying_enable(watt, 1); @@ -112,7 +123,7 @@ ApiStatus WattUpdate(Evt* script, s32 isInitialCall) { return 0; } - + switch (WattTweesterPhysicsPtr->state) { case 0: WattTweesterPhysicsPtr->state = 1; @@ -143,7 +154,7 @@ ApiStatus WattUpdate(Evt* script, s32 isInitialCall) { if (WattTweesterPhysicsPtr->liftoffVelocityPhase > 150.0f) { WattTweesterPhysicsPtr->liftoffVelocityPhase = 150.0f; } - + watt->pos.y += liftoffVelocity; watt->renderYaw = clamp_angle(360.0f - WattTweesterPhysicsPtr->angle); WattTweesterPhysicsPtr->angularVelocity += 0.8; @@ -195,8 +206,176 @@ void func_802BD710_31D280(Npc* watt) { } } -s32 func_802BD754_31D2C4(void); -INCLUDE_ASM(s32, "world/partner/watt", func_802BD754_31D2C4); +ApiStatus func_802BD754_31D2C4(Evt* script, s32 isInitialCall) { + PlayerStatus* playerStatus = &gPlayerStatus; + PartnerActionStatus* partnerActionStatus = &gPartnerActionStatus; + Npc* npc = script->owner2.npc; + + if (isInitialCall) { + func_802BD710_31D280(npc); + if (!(playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_100000)) { + if (partnerActionStatus->partnerAction_unk_1 == 0) { + if ((partnerActionStatus->partnerActionState != ACTION_STATE_IDLE) || + (func_800EA52C(6) && !is_starting_conversation())) + { + if (gGameStatusPtr->keepUsingPartnerOnMapChange) { + if (playerStatus->animFlags & (PLAYER_STATUS_ANIM_FLAGS_2 | 1)) { + D_802BE304 = 20; + } else { + D_802BE304 = 40; + } + } else if (playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_HOLDING_WATT) { + D_802BE304 = 2; + } else { + D_802BE304 = 40; + } + } else { + return ApiStatus_DONE2; + } + } else { + partnerActionStatus->partnerAction_unk_1 = 0; + playerStatus->animFlags |= PLAYER_STATUS_ANIM_FLAGS_2 | PLAYER_STATUS_ANIM_FLAGS_HOLDING_WATT; + func_802BE014_31DB84(); + npc->currentAnim.w = 0x60001; + D_802BE304 = 1; + script->functionTemp[1] = 2; + } + } else { + return ApiStatus_DONE2; + } + } + + switch (D_802BE304) { + case 40: + if (playerStatus->inputEnabledCounter != 0) { + return ApiStatus_DONE2; + } + script->functionTemp[1] = 3; + D_802BE304 = 41; + script->functionTemp[2] = playerStatus->inputEnabledCounter; + break; + case 41: + if (script->functionTemp[1] == 0) { + if (script->functionTemp[2] >= playerStatus->inputEnabledCounter) { + if (!(playerStatus->animFlags & PLAYER_STATUS_ANIM_FLAGS_100000)) { + if (func_800EA52C(6)) { + if (!is_starting_conversation()) { + D_802BE304 = 20; + break; + } + } + } + } + return ApiStatus_DONE2; + } + script->functionTemp[1]--; + break; + } + + switch (D_802BE304) { + case 20: + if (gGameStatusPtr->keepUsingPartnerOnMapChange) { + playerStatus->animFlags |= PLAYER_STATUS_ANIM_FLAGS_HOLDING_WATT; + D_802BE30C = 1; + npc->flags |= NPC_FLAG_100 | NPC_FLAG_ENABLE_HIT_SCRIPT; + npc->flags &= ~(NPC_FLAG_JUMPING | NPC_FLAG_GRAVITY); + gGameStatusPtr->keepUsingPartnerOnMapChange = 0; + partnerActionStatus->partnerActionState = PARTNER_ACTION_USE; + partnerActionStatus->actingPartner = PARTNER_WATT; + npc->moveToPos.x = playerStatus->position.x; + npc->moveToPos.y = playerStatus->position.y + 5.0f; + npc->moveToPos.z = playerStatus->position.z; + npc->currentAnim.w = 0x60002; + add_vec2D_polar(&npc->moveToPos.x, &npc->moveToPos.z, 15.0f, playerStatus->targetYaw); + npc->yaw = playerStatus->targetYaw; + npc->currentAnim.w = 0x60001; + playerStatus->animFlags |= PLAYER_STATUS_ANIM_FLAGS_2; + func_802BE014_31DB84(); + npc_set_palswap_mode_A(npc, 1); + script->functionTemp[1] = 2; + D_802BE304 = 1; + } else { + playerStatus->animFlags |= PLAYER_STATUS_ANIM_FLAGS_HOLDING_WATT; + D_802BE30C = 1; + npc->flags &= ~(NPC_FLAG_JUMPING | NPC_FLAG_GRAVITY); + gGameStatusPtr->keepUsingPartnerOnMapChange = 0; + partnerActionStatus->partnerActionState = PARTNER_ACTION_USE; + partnerActionStatus->actingPartner = PARTNER_WATT; + func_800EF4E0(); + npc->moveToPos.x = playerStatus->position.x; + npc->moveToPos.y = playerStatus->position.y + 5.0f; + npc->moveToPos.z = playerStatus->position.z; + npc->currentAnim.w = 0x60002; + add_vec2D_polar(&npc->moveToPos.x, &npc->moveToPos.z, 15.0f, playerStatus->targetYaw); + npc->duration = 8; + npc->yaw = atan2(npc->pos.x, npc->pos.z, playerStatus->position.x, playerStatus->position.z); + D_802BE304++; + } + break; + case 21: + npc->pos.x += (npc->moveToPos.x - npc->pos.x) / npc->duration; + npc->pos.y += (npc->moveToPos.y - npc->pos.y) / npc->duration; + npc->pos.z += (npc->moveToPos.z - npc->pos.z) / npc->duration; + npc->duration--; + if (npc->duration == 0) { + npc->yaw = playerStatus->targetYaw; + npc->currentAnim.w = 0x60001; + partnerActionStatus->actingPartner = PARTNER_WATT; + playerStatus->animFlags |= PLAYER_STATUS_ANIM_FLAGS_2; + func_802BE014_31DB84(); + script->functionTemp[1] = 2; + D_802BE304 = 1; + } + break; + case 1: + func_802BE070_31DBE0(); + if ((playerStatus->flags & PLAYER_STATUS_FLAGS_800)) { + D_802BE304 = 2; + } else { + s32 actionState = playerStatus->actionState; + + if (actionState != ACTION_STATE_USE_SPINNING_FLOWER) { + if (script->functionTemp[1] != 0) { + script->functionTemp[1]--; + } else if ( + actionState == ACTION_STATE_IDLE || + actionState == ACTION_STATE_WALK || + actionState == ACTION_STATE_RUN || + actionState == ACTION_STATE_LAND) + { + if (partnerActionStatus->pressedButtons & B_BUTTON) { + D_802BE304 = 2; + } + } + } + } + break; + } + + if (D_802BE304 == 2) { + playerStatus->animFlags &= ~(PLAYER_STATUS_ANIM_FLAGS_2 | PLAYER_STATUS_ANIM_FLAGS_HOLDING_WATT); + npc->currentAnim.w = 0x60001; + partner_clear_player_tracking(npc); + D_802BE30C = 0; + partnerActionStatus->actingPartner = PARTNER_NONE; + partnerActionStatus->partnerActionState = PARTNER_ACTION_NONE; + gGameStatusPtr->keepUsingPartnerOnMapChange = FALSE; + D_802BE304 = 20; + npc_set_palswap_mode_A(npc, 0); + if (!(playerStatus->flags & 0x800)) { + set_action_state(0); + } + return ApiStatus_DONE1; + } + + if (WattStaticEffect != NULL) { + WattStaticEffect->data.staticStatus->unk_04 = npc->pos.x; + WattStaticEffect->data.staticStatus->unk_08 = npc->pos.y + 13.0f; + WattStaticEffect->data.staticStatus->unk_0C = npc->pos.z; + } + + return ApiStatus_BLOCK; +} EvtScript world_watt_use_ability = { EVT_CALL(func_802BD754_31D2C4) @@ -325,7 +504,7 @@ void func_802BE070_31DBE0(void) { f32 temp, angle; f32 spriteFacingAngle; s32 phi_v1; - + if (gPartnerActionStatus.partnerActionState != PARTNER_ACTION_NONE) { spriteFacingAngle = gPlayerStatusPtr->spriteFacingAngle; if ((spriteFacingAngle < 90.0f) || (spriteFacingAngle > 270.0f)) { @@ -356,7 +535,7 @@ void func_802BE070_31DBE0(void) { playerStatus = gPlayerStatusPtr; partnerNPC = new_var2; partnerNPC->pos.z = playerStatus->position.z - (cos_rad(angle) * gPlayerStatusPtr->colliderDiameter * temp); - + wPartnerNpc->yaw = gPlayerStatusPtr->targetYaw; wPartnerNpc->pos.y = gPlayerStatusPtr->position.y + 5.0f; } diff --git a/src/world/partners.c b/src/world/partners.c index c14d0f9fe0..aebb9963f7 100644 --- a/src/world/partners.c +++ b/src/world/partners.c @@ -219,7 +219,8 @@ s32 wPartnerMoveGoalX = 0; s32 wPartnerMoveGoalZ = 0; s32 wPartnerMoveTime = 0; f32 wPartnerMoveSpeed = 0.0f; -s8 D_800F8034[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; +f32 D_800F8034 = 0.0f; +s16 D_800F8038 = 0; s16 D_800F803A = 0; WorldPartner wPartners[12] = { @@ -617,13 +618,13 @@ void _use_partner_ability(void) { wPartnerCurrentScriptID = wPartnerCurrentScript->id; wPartnerCurrentScript->groupFlags = EVT_GROUP_08 | EVT_GROUP_02; D_8010CD34 += 1; - set_time_freeze_mode(1); + set_time_freeze_mode(TIME_FREEZE_PARTIAL); break; case 1: if (does_script_exist(wPartnerCurrentScriptID)) { break; } - set_time_freeze_mode(0); + set_time_freeze_mode(TIME_FREEZE_NORMAL); partner_free_npc(); playerData->currentPartner = D_8010CFD8 = D_8010CFE4; partner_create_npc(); @@ -636,7 +637,7 @@ void _use_partner_ability(void) { wPartnerCurrentScriptID = wPartnerCurrentScript->id; wPartnerCurrentScript->groupFlags = EVT_GROUP_08 | EVT_GROUP_02; D_8010CD34 += 1; - set_time_freeze_mode(1); + set_time_freeze_mode(TIME_FREEZE_PARTIAL); break; case 3: if (does_script_exist(wPartnerCurrentScriptID)) { @@ -648,7 +649,7 @@ void _use_partner_ability(void) { wPartnerCurrentScript->groupFlags = EVT_GROUP_08 | EVT_GROUP_02; D_8010CD30 = 1; enable_player_input(); - set_time_freeze_mode(0); + set_time_freeze_mode(TIME_FREEZE_NORMAL); break; } break; @@ -766,7 +767,7 @@ void _use_partner_ability(void) { wPartnerCurrentScriptID = wPartnerCurrentScript->id; wPartnerCurrentScript->groupFlags = EVT_GROUP_08 | EVT_GROUP_02; D_8010CD30 = 1; - wPartnerNpc->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[4]; + wPartnerNpc->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[PARTNER_ANIM_INDEX_FLY]; enable_player_input(); break; } @@ -1101,7 +1102,7 @@ void partner_walking_enable(Npc* partner, s32 val) { D_8010CFCC = 0; wPartnerMoveTime = 16; wPartnerTetherDistance = 40.0f; - partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[5]; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[PARTNER_ANIM_INDEX_IDLE]; func_800EA5B8(&partner->flags); partner->collisionChannel = 0x10000; partner->jumpVelocity = 0.0f; @@ -1205,7 +1206,7 @@ void partner_flying_enable(Npc* partner, s32 val) { D_8010CFCC = 0; wPartnerMoveTime = 16; wPartnerTetherDistance = 40.0f; - partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[5]; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[PARTNER_ANIM_INDEX_IDLE]; func_800EA5B8(&partner->flags); partner->collisionChannel = 0x10000; partner->flags |= NPC_FLAG_100; @@ -1320,7 +1321,334 @@ void partner_flying_update_motion(Npc* partner) { } } +// backwards jump hall of shame + more work required +#ifdef NON_EQUIVALENT +void partner_flying_follow_player(Npc* partner) { + PlayerStatus* playerStatus = &gPlayerStatus; + Camera* camera = &gCameras[CAM_DEFAULT]; + f32 x, y, z; + f32 temp; + f32 yaw; + + f32 temp_a3; + f32 var_f0_2; + f32 temp_f0_15; + + f32 temp_f20; + f32 temp_f2_3; + f32 var_f12; + f32 moveHistoryX, moveHistoryY, moveHistoryZ; + + u16 temp_v0_3; + + switch (D_8010CFC8) { + case 0: + var_f12 = 0.0f; + x = partner->pos.x; + y = partner->pos.y; + z = partner->pos.z; + wSavedPartnerPosX = x; + wSavedPartnerPosY = y; + wSavedPartnerPosZ = z; + moveHistoryX = gPlayerMoveHistory[D_8010CFBC].pos.x; + moveHistoryY = gPlayerMoveHistory[D_8010CFBC].pos.y; + moveHistoryZ = gPlayerMoveHistory[D_8010CFBC].pos.z; + if (wPartnerTetherDistance < 20.0f) { + var_f12 = (20.0f - wPartnerTetherDistance) * 0.5f; + } + partner->pos.y = y + (((moveHistoryY + 20.0f + var_f12) - y) * 0.125f); + partner->moveSpeed = 3.0f; + y = partner->pos.y; + temp = dist2D(partner->pos.x, partner->pos.z, playerStatus->position.x, playerStatus->position.z); + if (temp >= 50.0) { + if (playerStatus->position.y <= partner->pos.y) { + partner->moveSpeed = temp * 0.25f; + } else { + partner->moveSpeed = 8.0f; + } + } + if (wPartnerTetherDistance < 20.0f) { + partner->moveSpeed = 4.0f; + } + + while (TRUE) { + yaw = atan2(x, z, moveHistoryX, moveHistoryZ); + temp = dist2D(x, z, moveHistoryX, moveHistoryZ); + if (partner->moveSpeed < temp) { + if (!(playerStatus->position.y <= partner->pos.y)) { + if (!(partner->moveSpeed > 6.0)) { + partner->moveSpeed += 1.0; + } else { + partner->moveSpeed = 6.0f; + } + } else { + if (partner->moveSpeed >= temp * 0.25f) { + partner->moveSpeed = temp * 0.25f; + } else { + partner->moveSpeed += temp * 0.0625f; + } + } + } else if (D_8010CFBC != gPlayerMoveHistoryIndex) { + temp = dist2D(partner->pos.x, partner->pos.z, playerStatus->position.x, playerStatus->position.z); + if (!(temp <= wPartnerTetherDistance)) { + D_8010CFBC++; + if (D_8010CFBC >= 40) { + D_8010CFBC = 0; + } + moveHistoryX = gPlayerMoveHistory[D_8010CFBC].pos.x; + moveHistoryZ = gPlayerMoveHistory[D_8010CFBC].pos.z; + continue; + } + D_8010CFC8 = 5; + yaw = partner->yaw; + partner->moveSpeed = 0.0f; + partner->jumpScale = 0.0f; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[5]; + } else { + yaw = partner->yaw; + partner->moveSpeed = 0.0f; + partner->jumpScale = 0.0f; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[5]; + } + break; + } + partner->yaw = yaw; + npc_move_heading(partner, partner->moveSpeed, yaw); + if (partner->flags & 0x4000) { + D_8010CFC8 = 1; + return; + } + break; + case 1: + case 3: + if (D_8010CFBC != gPlayerMoveHistoryIndex) { + D_8010CFBC++; + if (D_8010CFBC >= 40) { + D_8010CFBC = 0; + } + partner->duration = 0; + partner->jumpScale = 1.3f; + partner->moveToPos.x = gPlayerMoveHistory[D_8010CFBC].pos.x; + partner->moveToPos.y = gPlayerMoveHistory[D_8010CFBC].pos.y; + partner->moveToPos.z = gPlayerMoveHistory[D_8010CFBC].pos.z; + if (D_8010CFC8 == 1) { + partner->moveSpeed = 6.0f; + } + partner->planarFlyDist = dist2D(partner->pos.x, partner->pos.z, partner->moveToPos.x, partner->moveToPos.z); + partner->yaw = atan2(partner->pos.x, partner->pos.z, partner->moveToPos.x, partner->moveToPos.z); + if (partner->planarFlyDist > 50.0) { + partner->planarFlyDist = 50.0f; + } + temp = partner->planarFlyDist; + y = partner->moveToPos.y - partner->pos.y; + if (partner->planarFlyDist < y) { + temp = y; + } + if (D_8010CFC8 == 1) { + if (temp < wPartnerTetherDistance) { + partner->jumpVelocity = 0.0f; + partner->yaw = atan2(partner->pos.x, partner->pos.z, playerStatus->position.x, playerStatus->position.z); + D_8010CFC8 = 5; + return; + } + partner->duration = temp / partner->moveSpeed; + if (partner->duration < 10) { + partner->duration = 10; + } + partner->moveSpeed = partner->planarFlyDist / partner->duration; + } else { + partner->duration = 0xA; + } + + partner->jumpVelocity = (y + (partner->jumpScale * partner->duration * partner->duration * 0.5f)) / partner->duration; + if (partner->jumpVelocity > 20.0) { + partner->jumpVelocity = 20.0f; + } + D_8010CFC8 = 2; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[2]; + partner->moveToPos.x = partner->pos.x; + partner->moveToPos.y = partner->pos.y; + partner->moveToPos.z = partner->pos.z; + } + break; + case 2: + partner->jumpVelocity -= partner->jumpScale; + partner->pos.y += partner->jumpVelocity; + if (partner->jumpVelocity <= 0.0f) { + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[3]; + } + npc_move_heading(partner, partner->moveSpeed, partner->yaw); + if (partner->jumpVelocity <= 0.0f) { + if (partner->pos.y < partner->moveToPos.y) { + partner->jumpVelocity = 0.0f; + partner->pos.y = partner->moveToPos.y; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[4]; + partner->yaw = atan2(partner->pos.x, partner->pos.z, playerStatus->position.x, playerStatus->position.z); + D_8010CFC8 = 0; + temp = dist2D(partner->pos.x, partner->pos.z, partner->moveToPos.x, partner->moveToPos.z); + if (temp < wPartnerTetherDistance) { + D_8010CFC8 = 0xF; + } + } + } + break; + case 5: + x = partner->pos.x; + y = partner->pos.y; + z = partner->pos.z; + moveHistoryX = gPlayerMoveHistory[D_8010CFBC].pos.x; + moveHistoryZ = gPlayerMoveHistory[D_8010CFBC].pos.z; + temp = dist2D(x, z, playerStatus->position.x, playerStatus->position.z); + if (temp <= wPartnerTetherDistance) { + if (D_8010CFCA == 0) { + temp_v0_3 = partner->collisionHeight; + partner->moveSpeed = 0.0f; + partner->jumpScale = 0.0f; + temp_f2_3 = (y + (((playerStatus->position.y + (playerStatus->colliderHeight - ((s32) ((s16) temp_v0_3 + ((u32) (temp_v0_3 << 0x10) >> 0x1F)) >> 1))) - partner->pos.y) * 0.03125)); + partner->pos.y = temp_f2_3; + y = temp_f2_3; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[5]; + if (playerStatus->actionState == 0xC) { + D_8010CFCA = 0; + } + } else { + if (playerStatus->spriteFacingAngle < 180.0f) { + var_f0_2 = 90.0f; + temp_a3 = clamp_angle(camera->currentYaw + 90.0f); + } else { + var_f0_2 = -90.0f; + temp_a3 = clamp_angle(camera->currentYaw + -90.0f); + } + partner->moveToPos.x = playerStatus->position.x; + partner->moveToPos.y = playerStatus->position.y; + partner->moveToPos.z = playerStatus->position.z; + add_vec2D_polar(&partner->moveToPos.x, &partner->moveToPos.z, wPartnerTetherDistance - 10.0f, temp_a3); + yaw = atan2(partner->pos.x, partner->pos.z, partner->moveToPos.x, partner->moveToPos.z); + temp = dist2D(partner->pos.x, partner->pos.z, partner->moveToPos.x, partner->moveToPos.z); + partner->moveSpeed = 2.0f; + if (temp > 2.0f) { + partner->yaw = yaw; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[6]; + if (!(partner->flags & 0x4000)) { + D_800F803A = 0; + } else { + D_800F803A++; + if (D_800F803A > 10) { + yaw = playerStatus->targetYaw; + partner->moveSpeed = 0.0f; + partner->jumpScale = 0.0f; + partner->renderYaw = yaw; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[5]; + if (D_8010CFCA == 2 || playerStatus->actionState == 0xC) { + D_8010CFCA = 0; + } + } + } + } else { + yaw = atan2(partner->pos.x, partner->pos.z, playerStatus->position.x, playerStatus->position.z); + partner->yaw = yaw; + partner->moveSpeed = 0.0f; + partner->jumpScale = 0.0f; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[5]; + if (D_8010CFCA == 2 || playerStatus->actionState == 0xC) { + D_8010CFCA = 0; + } + } + partner->yaw = yaw; + npc_move_heading(partner, partner->moveSpeed, yaw); + return; + } + } + + temp = dist2D(partner->pos.x, partner->pos.z, playerStatus->position.x, playerStatus->position.z); + if (!(temp <= wPartnerTetherDistance)) { + while (TRUE) { + if (!gPlayerMoveHistory[D_8010CFBC].isJumping) { + temp_f20 = atan2(partner->pos.x, partner->pos.z, moveHistoryX, moveHistoryZ); + if (!(fabsf(get_clamped_angle_diff(temp_f20, atan2(partner->pos.x, partner->pos.z, playerStatus->position.x, playerStatus->position.z))) < 90.0f)) { + if (D_8010CFBC != gPlayerMoveHistoryIndex) { + D_8010CFBC++; + if (D_8010CFBC >= 40) { + D_8010CFBC = 0; + } + moveHistoryX = gPlayerMoveHistory[D_8010CFBC].pos.x; + moveHistoryZ = gPlayerMoveHistory[D_8010CFBC].pos.z; + continue; + } + } + } + break; + } + D_8010CFC8 = 0; + } + break; + case 15: + if (!(playerStatus->animFlags & 0x100000)) { + switch (D_8010CFCE) { + case 0: + temp_f0_15 = clamp_angle(func_800E5348() + 180.0f); + partner->moveToPos.x = playerStatus->position.x; + partner->moveToPos.y = playerStatus->position.y; + partner->moveToPos.z = playerStatus->position.z; + add_vec2D_polar(&partner->moveToPos.x, &partner->moveToPos.z, playerStatus->colliderDiameter, temp_f0_15); + temp = dist2D(partner->pos.x, partner->pos.z, partner->moveToPos.x, partner->moveToPos.z); + partner->moveSpeed = wPartnerMoveSpeed = temp / wPartnerMoveTime; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[(partner->moveSpeed < 4.0) ? 1 : 6]; + D_800F8034 = atan2(partner->pos.x, partner->pos.z, partner->moveToPos.x, partner->moveToPos.z); + partner->yaw = D_800F8034; + D_8010CFCE++; + /* fallthrough */ + case 1: + if (wPartnerMoveTime != 0) { + z = partner->pos.z; + x = partner->pos.x; + y = partner->pos.y + partner->collisionHeight; + temp = partner->collisionHeight + 1; + wPartnerMoveTime--; + if (npc_raycast_down_around(0x10000, &x, &y, &z, &temp, partner->yaw, partner->collisionRadius) == 0) { + if ((partner->collisionHeight + 5) < fabs((partner->pos.y - playerStatus->position.y))) { + partner->pos.y += (playerStatus->position.y - partner->pos.y) / 10.0f; + } + } else { + partner->pos.y += (((playerStatus->position.y + playerStatus->colliderHeight) - partner->pos.y) * 0.125f); + } + partner->moveSpeed = wPartnerMoveSpeed; + partner->yaw = D_800F8034; + x = partner->pos.x; + y = partner->pos.y; + z = partner->pos.z; + if (npc_test_move_taller_with_slipping(0, &x, &y, &z, partner->moveSpeed, partner->yaw, partner->collisionHeight, partner->collisionRadius) != 0) { + partner->pos.x += (x - partner->pos.x) / 5.0f; + partner->pos.z += (z - partner->pos.z) / 5.0f; + } else { + npc_move_heading(partner, partner->moveSpeed, partner->yaw); + } + return; + } + partner_clear_player_tracking(partner); + partner->moveSpeed = 0.0f; + partner->jumpScale = 0.0f; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[5]; + D_8010CFC8 = 0; + D_8010CFCA = 0; + D_8010CFCE = 0; + partner->yaw = clamp_angle((camera->currentYaw + 270.0f) - playerStatus->spriteFacingAngle); + } + } + break; + case 20: + partner_move_to_goal(partner, 1); + break; + case 40: + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[5]; + break; + case 50: + break; + } +} +#else INCLUDE_ASM(s32, "world/partners", partner_flying_follow_player); +#endif s32 partner_init_put_away(Npc* partner) { partner->collisionChannel = 0x10000; @@ -1365,7 +1693,7 @@ s32 partner_put_away(Npc* partner) { partner->moveSpeed = partner->planarFlyDist / divisor; tempMoveToY = tempPosY - tempMoveToY; partner->jumpVelocity = (tempMoveToY + partner->jumpScale * partner->duration * partner->duration * 0.5f) / partner->duration; - partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[2]; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[PARTNER_ANIM_INDEX_JUMP]; enable_npc_blur(partner); D_8010CFC8 = 1; break; @@ -1373,7 +1701,7 @@ s32 partner_put_away(Npc* partner) { partner->jumpVelocity -= partner->jumpScale; partner->pos.y += partner->jumpVelocity; if (partner->jumpVelocity <= 0.0f) { - partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[3]; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[PARTNER_ANIM_INDEX_FALL]; } npc_move_heading(partner, partner->moveSpeed, partner->yaw); tempDuration = partner->duration; @@ -1389,7 +1717,7 @@ s32 partner_put_away(Npc* partner) { } break; case 2: - partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[4]; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[PARTNER_ANIM_INDEX_FLY]; partner->jumpVelocity = 0.0f; partner->pos.y = partner->moveToPos.y; disable_npc_blur(partner); @@ -1405,7 +1733,127 @@ s32 partner_init_get_out(Npc* npc) { return D_8010CFC8; } -INCLUDE_ASM(s32, "world/partners", partner_get_out); +s32 partner_get_out(Npc* partner) { + PlayerStatus* playerStatus = &gPlayerStatus; + Camera* camera = &gCameras[gCurrentCameraID]; + f32 x, y, z, hitDepth; + f32 var_f0; + + f32 moveToX, moveToY, moveToZ; + + switch (D_8010CFC8) { + case 0: + if (clamp_angle(playerStatus->spriteFacingAngle) < 180.0f) { + partner->yaw = clamp_angle(camera->currentYaw + 90.0f); + } else { + partner->yaw = clamp_angle(camera->currentYaw - 90.0f); + } + partner->moveToPos.x = playerStatus->position.x; + partner->moveToPos.y = playerStatus->position.y; + if (wPartner->isFlying) { + partner->moveToPos.y = playerStatus->position.y; + } + partner->moveToPos.z = playerStatus->position.z; + add_vec2D_polar(&partner->moveToPos.x, &partner->moveToPos.z, playerStatus->colliderDiameter, partner->yaw); + moveToX = partner->moveToPos.x; + moveToY = partner->moveToPos.y; + moveToZ = partner->moveToPos.z; + if (!wPartner->isFlying) { + x = moveToX; + y = moveToY + partner->collisionHeight; + z = moveToZ; + add_vec2D_polar(&x, &z, 2.0f, gCameras[gCurrentCameraID].currentYaw); + hitDepth = 1000.0f; + if (npc_raycast_down_around(0x10000, &x, &y, &z, &hitDepth, partner->yaw, partner->collisionRadius)) { + s32 colliderType = get_collider_type_by_id(D_8010C978); + + if ((colliderType == 2 || colliderType == 3) || (hitDepth > 100.0f)) { + moveToX = playerStatus->position.x; + moveToY = playerStatus->position.y; + moveToZ = playerStatus->position.z; + add_vec2D_polar(&x, &z, 2.0f, gCameras[gCurrentCameraID].currentYaw); + } + } else { + moveToX = playerStatus->position.x; + moveToY = playerStatus->position.y; + moveToZ = playerStatus->position.z; + add_vec2D_polar(&x, &z, 2.0f, gCameras[gCurrentCameraID].currentYaw); + } + } + + x = partner->pos.x = playerStatus->position.x; + y = partner->pos.y = playerStatus->position.y + (playerStatus->colliderHeight / 2); + z = partner->pos.z = playerStatus->position.z; + + partner->moveSpeed = 4.0f; + partner->jumpScale = 1.2f; + partner->planarFlyDist = dist2D(x, z, moveToX, moveToZ); + partner->yaw = atan2(x, z, moveToX, moveToZ); + partner->duration = partner->planarFlyDist / partner->moveSpeed; + if (partner->duration < 10) { + partner->duration = 10; + partner->moveSpeed = partner->planarFlyDist / partner->duration; + } + partner->jumpVelocity = (moveToY - y + (partner->jumpScale * partner->duration * partner->duration * 0.5f)) / + partner->duration; + D_8010CFC8 = 1; + y = moveToY - y; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[2]; + break; + case 1: + if (partner->jumpVelocity < 0.0f && func_800397E8(partner, fabsf(partner->jumpVelocity))) { + D_8010CFC8 = 2; + break; + } + partner->jumpVelocity -= partner->jumpScale; + partner->pos.y += partner->jumpVelocity; + if (partner->jumpVelocity <= 0.0f) { + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[3]; + } + npc_move_heading(partner, partner->moveSpeed, partner->yaw); + npc_do_world_collision(partner); + var_f0 = partner->duration; + if (var_f0 > 10.0f) { + var_f0 = 10.0f; + } + + partner->scale.x = (10.0f - var_f0) / 10.0f; + partner->scale.y = partner->scale.x; + partner->scale.z = partner->scale.x; + + partner->duration--; + if (partner->duration < 0) { + D_8010CFC8 = 2; + } + break; + case 2: + partner->pos.y = partner->moveToPos.y; + partner->jumpVelocity = 0.0f; + partner->scale.x = 1.0f; + partner->scale.y = 1.0f; + partner->scale.z = 1.0f; + partner->moveToPos.x = partner->pos.x; + partner->moveToPos.y = partner->pos.y; + partner->moveToPos.z = partner->pos.z; + partner->pos.x = partner->pos.x; + partner->pos.y = playerStatus->position.y; + if (wPartner->isFlying) { + partner->pos.y = playerStatus->position.y; + } + partner->pos.z = partner->pos.z; + partner_clear_player_tracking(partner); + partner->pos.x = partner->moveToPos.x; + partner->pos.y = partner->moveToPos.y; + partner->pos.z = partner->moveToPos.z; + if (partner->flags & 0x1000) { + if (!wPartner->isFlying) { + func_8003D660(partner, 2); + } + } + return TRUE; + } + return FALSE; +} void func_800EF300(void) { D_8010CFC8 = 40; @@ -1527,15 +1975,103 @@ void partner_do_player_collision(Npc* partner) { f32 partnerScreenZ; f32 W; - transform_point(gCameras[CAM_DEFAULT].perspectiveMatrix, playerStatus->position.x, playerStatus->position.y, playerStatus->position.z, 1.0f, &playerScreenX, &playerScreenY, &playerScreenZ, &W); - transform_point(gCameras[CAM_DEFAULT].perspectiveMatrix, partner->pos.x, partner->pos.y, partner->pos.z, 1.0f, &partnerScreenX, &partnerScreenY, &partnerScreenZ, &W); + transform_point(gCameras[CAM_DEFAULT].perspectiveMatrix, + playerStatus->position.x, playerStatus->position.y, playerStatus->position.z, 1.0f, + &playerScreenX, &playerScreenY, &playerScreenZ, &W); + transform_point(gCameras[CAM_DEFAULT].perspectiveMatrix, partner->pos.x, partner->pos.y, partner->pos.z, 1.0f, + &partnerScreenX, &partnerScreenY, &partnerScreenZ, &W); playerScreenX = fabsf(playerScreenX - partnerScreenX); playerScreenY = fabsf(playerScreenY - partnerScreenY); playerScreenZ = fabsf(playerScreenZ - partnerScreenZ); - if (playerScreenX <= (partner->collisionRadius + playerStatus->colliderDiameter) * 0.9f && playerScreenY <= partner->collisionHeight + playerStatus->colliderHeight && playerScreenZ <= 4.0) { - npc_move_heading(partner, 1.0f, atan2(playerStatus->position.x, playerStatus->position.z, partner->pos.x, partner->pos.z)); + if (playerScreenX <= (partner->collisionRadius + playerStatus->colliderDiameter) * 0.9f && + playerScreenY <= partner->collisionHeight + playerStatus->colliderHeight && playerScreenZ <= 4.0) + { + npc_move_heading(partner, 1.0f, + atan2(playerStatus->position.x, playerStatus->position.z, partner->pos.x, partner->pos.z)); add_vec2D_polar(&partner->pos.x, &partner->pos.z, 2.0f, gCameras[gCurrentCameraID].currentYaw); } } -INCLUDE_ASM(s32, "world/partners", partner_move_to_goal); +void partner_move_to_goal(Npc* partner, s32 arg1) { + PlayerStatus* playerStatus = &gPlayerStatus; + f32 x, y, z, temp; + s32 var_a1; + + switch (D_8010CFCE) { + case 0: + D_8010CFCE++; + partner->moveToPos.y = playerStatus->position.y; + partner->moveToPos.x = wPartnerMoveGoalX; + partner->moveToPos.z = wPartnerMoveGoalZ; + D_800F8034 = atan2(partner->pos.x, partner->pos.z, partner->moveToPos.x, partner->moveToPos.z); + partner->yaw = D_800F8034; + add_vec2D_polar(&partner->moveToPos.x, &partner->moveToPos.z, 5.0f, D_800F8034); + wPartnerMoveTime = 18; + temp = dist2D(partner->pos.x, partner->pos.z, partner->moveToPos.x, partner->moveToPos.z); + partner->moveSpeed = wPartnerMoveSpeed = temp / wPartnerMoveTime; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[ + (partner->moveSpeed >= 4.0) ? PARTNER_ANIM_INDEX_RUN : PARTNER_ANIM_INDEX_WALK]; + case 1: + if (wPartnerMoveTime != 0) { + wPartnerMoveTime--; + if (arg1 == 0) { + if (!(partner->flags & NPC_FLAG_1000)) { + partner->pos.y = playerStatus->position.y; + } + if (partner->jumpVelocity != 0.0f) { + partner->jumpVelocity -= partner->jumpScale; + partner->pos.y += partner->jumpVelocity; + if (partner->jumpVelocity <= 0.0f) { + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[PARTNER_ANIM_INDEX_FALL]; + } + + if (partner->jumpVelocity <= 0.0f) { + temp = fabsf(partner->jumpVelocity) + partner->collisionHeight; + y = partner->pos.y + partner->collisionHeight; + x = partner->pos.x; + z = partner->pos.z; + + if (npc_raycast_down_around(partner->collisionChannel, &x, &y, &z, &temp, + partner->yaw, partner->collisionRadius) && + (temp <= fabsf(partner->jumpVelocity) + 22.0f)) + { + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[ + (partner->moveSpeed >= 4.0) ? PARTNER_ANIM_INDEX_RUN : PARTNER_ANIM_INDEX_WALK]; + partner->jumpScale = 0.0f; + partner->jumpVelocity = 0.0f; + partner->pos.y = y; + partner->flags &= ~NPC_FLAG_JUMPING; + } + } + } + partner->moveSpeed = wPartnerMoveSpeed; + partner->yaw = D_800F8034; + npc_move_heading(partner, partner->moveSpeed, partner->yaw); + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[ + (partner->moveSpeed >= 4.0) ? PARTNER_ANIM_INDEX_RUN : PARTNER_ANIM_INDEX_WALK]; + npc_do_world_collision(partner); + } else { + if (fabs(partner->pos.y - playerStatus->position.y) > 5.0) { + partner->pos.y += (playerStatus->position.y - partner->pos.y) * 0.5f; + } + partner->moveSpeed = wPartnerMoveSpeed; + partner->yaw = D_800F8034; + npc_move_heading(partner, partner->moveSpeed, partner->yaw); + } + + if (partner->moveSpeed < 4.0) { + var_a1 = 0; + } else { + var_a1 = 1; + } + func_8003D660(partner, var_a1); + } else { + partner->flags &= ~NPC_FLAG_40; + partner->currentAnim.w = gPartnerAnimations[D_8010CFD8].anims[PARTNER_ANIM_INDEX_IDLE]; + D_8010CFCE++; + } + break; + case 2: + break; + } +} diff --git a/ver/us/asm/data/world/area_jan/jan_05/B4D7A0.data.s b/ver/us/asm/data/world/area_jan/jan_05/B4D7A0.data.s index f5068d44e1..7c2a45d0ac 100644 --- a/ver/us/asm/data/world/area_jan/jan_05/B4D7A0.data.s +++ b/ver/us/asm/data/world/area_jan/jan_05/B4D7A0.data.s @@ -9,7 +9,7 @@ dlabel D_80242F00_B4D970 .word 0x00000043, 0x00000004, PlaySoundAtCollider, 0x0000004C, 0x00000165, 0x00000000, 0x00000043, 0x00000005, MakeLerp, 0xFFFFFF10, 0xFFFFFEFD, 0x00000005, 0x00000006, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x0000006F, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x00000072, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000002, 0x00000000, 0x00000001, 0x00000000 dlabel D_80242FC8_B4DA38 -.word 0x00000056, 0x00000000, 0x00000008, 0x00000001, 0x00000011, 0x00000043, 0x00000002, SetPlayerAnimation, 0x0001002A, 0x00000043, 0x00000003, func_80240350_B4ADC0, 0x0000006E, 0xFAA2B58B, 0x00000057, 0x00000000, 0x00000043, 0x00000004, ModifyColliderFlags, 0x00000000, 0x0000004C, 0x7FFFFE00, 0x00000043, 0x00000005, MakeLerp, 0xFFFFFEFD, 0x0000003C, 0x0000001E, 0x00000004, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x0000006F, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x00000072, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x00000043, 0x00000005, MakeLerp, 0x0000003C, 0x00000000, 0x0000001E, 0x00000002, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x0000006F, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x00000072, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000043, 0x00000002, SetPlayerAnimation, 0x00010002, 0x00000043, 0x00000004, PlaySoundAtCollider, 0x0000004C, 0x0000209D, 0x00000000, 0x00000043, 0x0000000F, PlayEffect, 0x00000006, 0x00000004, 0xFFFFFF47, 0x00000000, 0x00000140, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000043, 0x00000005, ShakeCam, 0x00000000, 0x00000002, 0x00000003, 0x00000001, 0x00000002, 0x00000000, 0x00000001, 0x00000000 +.word 0x00000056, 0x00000000, 0x00000008, 0x00000001, 0x00000011, 0x00000043, 0x00000002, SetPlayerAnimation, 0x0001002A, 0x00000043, 0x00000003, jan_05_UnkShadowFunc001, 0x0000006E, 0xFAA2B58B, 0x00000057, 0x00000000, 0x00000043, 0x00000004, ModifyColliderFlags, 0x00000000, 0x0000004C, 0x7FFFFE00, 0x00000043, 0x00000005, MakeLerp, 0xFFFFFEFD, 0x0000003C, 0x0000001E, 0x00000004, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x0000006F, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x00000072, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x00000043, 0x00000005, MakeLerp, 0x0000003C, 0x00000000, 0x0000001E, 0x00000002, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x0000006F, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x00000072, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000043, 0x00000002, SetPlayerAnimation, 0x00010002, 0x00000043, 0x00000004, PlaySoundAtCollider, 0x0000004C, 0x0000209D, 0x00000000, 0x00000043, 0x0000000F, PlayEffect, 0x00000006, 0x00000004, 0xFFFFFF47, 0x00000000, 0x00000140, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000043, 0x00000005, ShakeCam, 0x00000000, 0x00000002, 0x00000003, 0x00000001, 0x00000002, 0x00000000, 0x00000001, 0x00000000 dlabel D_80243204_B4DC74 .word 0x00000056, 0x00000000, 0x00000008, 0x00000001, 0x00000032, 0x00000024, 0x00000002, 0xFAA2B58B, 0x00000001, 0x00000057, 0x00000000, 0x00000043, 0x00000005, MakeLerp, 0x00000000, 0xFFFFFFA6, 0x0000003C, 0x00000002, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x0000006F, 0x00000000, 0x00000000, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x00000072, 0x00000000, 0x00000000, 0x00000000, 0x00000043, 0x00000006, RotateGroup, 0x0000006F, 0xFE363C80, 0x00000000, 0x00000000, 0x00000001, 0x00000043, 0x00000006, RotateGroup, 0x00000072, 0xFE363C80, 0x00000000, 0x00000000, 0x00000001, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000056, 0x00000000, 0x00000043, 0x00000005, ShakeCam, 0x00000000, 0x00000002, 0x00000003, 0x00000001, 0x00000057, 0x00000000, 0x00000002, 0x00000000, 0x00000001, 0x00000000 diff --git a/ver/us/asm/data/world/area_jan/jan_06/B55F40.data.s b/ver/us/asm/data/world/area_jan/jan_06/B55F40.data.s index 5d2f00a592..817572fea4 100644 --- a/ver/us/asm/data/world/area_jan/jan_06/B55F40.data.s +++ b/ver/us/asm/data/world/area_jan/jan_06/B55F40.data.s @@ -9,7 +9,7 @@ dlabel D_802438E0_B56110 .word 0x00000043, 0x00000004, PlaySoundAtCollider, 0x0000005A, 0x00000165, 0x00000000, 0x00000043, 0x00000005, MakeLerp, 0xFFFFFF6A, 0xFFFFFF57, 0x00000005, 0x00000006, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x00000083, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x00000086, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000002, 0x00000000, 0x00000001, 0x00000000 dlabel D_802439A8_B561D8 -.word 0x00000056, 0x00000000, 0x00000008, 0x00000001, 0x00000011, 0x00000043, 0x00000002, SetPlayerAnimation, 0x0001002A, 0x00000043, 0x00000003, func_802403B0_B52BE0, 0x00000082, 0xFAA2B58B, 0x00000057, 0x00000000, 0x00000043, 0x00000004, ModifyColliderFlags, 0x00000000, 0x0000005A, 0x7FFFFE00, 0x00000043, 0x00000005, MakeLerp, 0xFFFFFF57, 0x0000003C, 0x0000001E, 0x00000004, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x00000083, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x00000086, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x00000043, 0x00000005, MakeLerp, 0x0000003C, 0x00000000, 0x0000001E, 0x00000002, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x00000083, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x00000086, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000043, 0x00000002, SetPlayerAnimation, 0x00010002, 0x00000043, 0x00000004, PlaySoundAtCollider, 0x0000005A, 0x0000209D, 0x00000000, 0x00000043, 0x0000000F, PlayEffect, 0x00000006, 0x00000004, 0xFFFFFF9C, 0x00000000, 0x0000003C, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000043, 0x00000005, ShakeCam, 0x00000000, 0x00000002, 0x00000003, 0x00000001, 0x00000002, 0x00000000, 0x00000001, 0x00000000 +.word 0x00000056, 0x00000000, 0x00000008, 0x00000001, 0x00000011, 0x00000043, 0x00000002, SetPlayerAnimation, 0x0001002A, 0x00000043, 0x00000003, jan_06_UnkShadowFunc001, 0x00000082, 0xFAA2B58B, 0x00000057, 0x00000000, 0x00000043, 0x00000004, ModifyColliderFlags, 0x00000000, 0x0000005A, 0x7FFFFE00, 0x00000043, 0x00000005, MakeLerp, 0xFFFFFF57, 0x0000003C, 0x0000001E, 0x00000004, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x00000083, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x00000086, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x00000043, 0x00000005, MakeLerp, 0x0000003C, 0x00000000, 0x0000001E, 0x00000002, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x00000083, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x00000086, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000043, 0x00000002, SetPlayerAnimation, 0x00010002, 0x00000043, 0x00000004, PlaySoundAtCollider, 0x0000005A, 0x0000209D, 0x00000000, 0x00000043, 0x0000000F, PlayEffect, 0x00000006, 0x00000004, 0xFFFFFF9C, 0x00000000, 0x0000003C, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000043, 0x00000005, ShakeCam, 0x00000000, 0x00000002, 0x00000003, 0x00000001, 0x00000002, 0x00000000, 0x00000001, 0x00000000 dlabel D_80243BE4_B56414 .word 0x00000056, 0x00000000, 0x00000008, 0x00000001, 0x00000032, 0x00000024, 0x00000002, 0xFAA2B58B, 0x00000001, 0x00000057, 0x00000000, 0x00000043, 0x00000005, MakeLerp, 0x00000000, 0xFFFFFFA6, 0x0000003C, 0x00000002, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x00000083, 0x00000000, 0x00000000, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x00000086, 0x00000000, 0x00000000, 0x00000000, 0x00000043, 0x00000006, RotateGroup, 0x00000083, 0xFE363C80, 0x00000000, 0x00000000, 0x00000001, 0x00000043, 0x00000006, RotateGroup, 0x00000086, 0xFE363C80, 0x00000000, 0x00000000, 0x00000001, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000056, 0x00000000, 0x00000043, 0x00000005, ShakeCam, 0x00000000, 0x00000002, 0x00000003, 0x00000001, 0x00000057, 0x00000000, 0x00000002, 0x00000000, 0x00000001, 0x00000000 diff --git a/ver/us/asm/data/world/area_jan/jan_10/B6DB60.data.s b/ver/us/asm/data/world/area_jan/jan_10/B6DB60.data.s index f01ecfd76f..f4443d6e1d 100644 --- a/ver/us/asm/data/world/area_jan/jan_10/B6DB60.data.s +++ b/ver/us/asm/data/world/area_jan/jan_10/B6DB60.data.s @@ -54,7 +54,7 @@ dlabel D_80242760_B6EAF0 .word 0x00000043, 0x00000004, PlaySoundAtCollider, 0x0000001C, 0x00000165, 0x00000000, 0x00000043, 0x00000005, MakeLerp, 0xFFFFFF5B, 0xFFFFFF48, 0x00000005, 0x00000006, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x00000040, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x0000003D, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000002, 0x00000000, 0x00000001, 0x00000000 dlabel D_80242828_B6EBB8 -.word 0x00000056, 0x00000000, 0x00000008, 0x00000001, 0x00000011, 0x00000043, 0x00000002, SetPlayerAnimation, 0x0001002A, 0x00000043, 0x00000003, func_80241130_B6D4C0, 0x0000003F, 0xFAA2B58A, 0x00000057, 0x00000000, 0x00000043, 0x00000004, ModifyColliderFlags, 0x00000000, 0x0000001C, 0x7FFFFE00, 0x00000043, 0x00000005, MakeLerp, 0xFFFFFF48, 0x0000003C, 0x0000001E, 0x00000004, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x00000040, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x0000003D, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x00000043, 0x00000005, MakeLerp, 0x0000003C, 0x00000000, 0x0000001E, 0x00000002, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x00000040, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x0000003D, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000043, 0x00000002, SetPlayerAnimation, 0x00010002, 0x00000043, 0x00000004, PlaySoundAtCollider, 0x0000001C, 0x0000209D, 0x00000000, 0x00000043, 0x0000000F, PlayEffect, 0x00000006, 0x00000004, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000043, 0x00000005, ShakeCam, 0x00000000, 0x00000002, 0x00000003, 0x00000001, 0x00000002, 0x00000000, 0x00000001, 0x00000000 +.word 0x00000056, 0x00000000, 0x00000008, 0x00000001, 0x00000011, 0x00000043, 0x00000002, SetPlayerAnimation, 0x0001002A, 0x00000043, 0x00000003, jan_10_UnkShadowFunc001, 0x0000003F, 0xFAA2B58A, 0x00000057, 0x00000000, 0x00000043, 0x00000004, ModifyColliderFlags, 0x00000000, 0x0000001C, 0x7FFFFE00, 0x00000043, 0x00000005, MakeLerp, 0xFFFFFF48, 0x0000003C, 0x0000001E, 0x00000004, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x00000040, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x0000003D, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x00000043, 0x00000005, MakeLerp, 0x0000003C, 0x00000000, 0x0000001E, 0x00000002, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x00000040, 0x00000000, 0xFE363C80, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x0000003D, 0x00000000, 0xFE363C80, 0x00000000, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000043, 0x00000002, SetPlayerAnimation, 0x00010002, 0x00000043, 0x00000004, PlaySoundAtCollider, 0x0000001C, 0x0000209D, 0x00000000, 0x00000043, 0x0000000F, PlayEffect, 0x00000006, 0x00000004, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000043, 0x00000005, ShakeCam, 0x00000000, 0x00000002, 0x00000003, 0x00000001, 0x00000002, 0x00000000, 0x00000001, 0x00000000 dlabel D_80242A64_B6EDF4 .word 0x00000056, 0x00000000, 0x00000008, 0x00000001, 0x00000032, 0x00000024, 0x00000002, 0xFAA2B58A, 0x00000001, 0x00000057, 0x00000000, 0x00000043, 0x00000005, MakeLerp, 0x00000000, 0x0000005A, 0x0000003C, 0x00000002, 0x00000005, 0x00000001, 0x00000000, 0x00000043, 0x00000001, UpdateLerp, 0x00000043, 0x00000005, TranslateGroup, 0x00000040, 0x00000000, 0x00000000, 0x00000000, 0x00000043, 0x00000005, TranslateGroup, 0x0000003D, 0x00000000, 0x00000000, 0x00000000, 0x00000043, 0x00000006, RotateGroup, 0x00000040, 0xFE363C80, 0x00000000, 0x00000000, 0x00000001, 0x00000043, 0x00000006, RotateGroup, 0x0000003D, 0xFE363C80, 0x00000000, 0x00000000, 0x00000001, 0x00000008, 0x00000001, 0x00000001, 0x0000000A, 0x00000002, 0xFE363C81, 0x00000000, 0x00000007, 0x00000000, 0x00000013, 0x00000000, 0x00000006, 0x00000000, 0x00000056, 0x00000000, 0x00000043, 0x00000005, ShakeCam, 0x00000000, 0x00000002, 0x00000003, 0x00000001, 0x00000057, 0x00000000, 0x00000002, 0x00000000, 0x00000001, 0x00000000 diff --git a/ver/us/asm/nonmatchings/16F740/btl_state_update_end_turn.s b/ver/us/asm/nonmatchings/16F740/btl_state_update_end_turn.s deleted file mode 100644 index e23639ea63..0000000000 --- a/ver/us/asm/nonmatchings/16F740/btl_state_update_end_turn.s +++ /dev/null @@ -1,417 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel btl_state_update_end_turn -/* 1722B8 802439D8 27BDFFB0 */ addiu $sp, $sp, -0x50 -/* 1722BC 802439DC AFB60028 */ sw $s6, 0x28($sp) -/* 1722C0 802439E0 3C16800E */ lui $s6, %hi(gBattleStatus) -/* 1722C4 802439E4 26D6C070 */ addiu $s6, $s6, %lo(gBattleStatus) -/* 1722C8 802439E8 AFB7002C */ sw $s7, 0x2c($sp) -/* 1722CC 802439EC 3C178011 */ lui $s7, %hi(gPlayerData) -/* 1722D0 802439F0 26F7F290 */ addiu $s7, $s7, %lo(gPlayerData) -/* 1722D4 802439F4 AFBF0030 */ sw $ra, 0x30($sp) -/* 1722D8 802439F8 AFB50024 */ sw $s5, 0x24($sp) -/* 1722DC 802439FC AFB40020 */ sw $s4, 0x20($sp) -/* 1722E0 80243A00 AFB3001C */ sw $s3, 0x1c($sp) -/* 1722E4 80243A04 AFB20018 */ sw $s2, 0x18($sp) -/* 1722E8 80243A08 AFB10014 */ sw $s1, 0x14($sp) -/* 1722EC 80243A0C AFB00010 */ sw $s0, 0x10($sp) -/* 1722F0 80243A10 F7B80048 */ sdc1 $f24, 0x48($sp) -/* 1722F4 80243A14 F7B60040 */ sdc1 $f22, 0x40($sp) -/* 1722F8 80243A18 F7B40038 */ sdc1 $f20, 0x38($sp) -/* 1722FC 80243A1C 8ED500D8 */ lw $s5, 0xd8($s6) -/* 172300 80243A20 3C02800E */ lui $v0, %hi(gBattleState2) -/* 172304 80243A24 8C42C4DC */ lw $v0, %lo(gBattleState2)($v0) -/* 172308 80243A28 8ED300DC */ lw $s3, 0xdc($s6) -/* 17230C 80243A2C 1440002E */ bnez $v0, .L80243AE8 -/* 172310 80243A30 0000A02D */ daddu $s4, $zero, $zero -/* 172314 80243A34 0280882D */ daddu $s1, $s4, $zero -/* 172318 80243A38 02C0902D */ daddu $s2, $s6, $zero -.L80243A3C: -/* 17231C 80243A3C 8E5000E0 */ lw $s0, 0xe0($s2) -/* 172320 80243A40 5200000B */ beql $s0, $zero, .L80243A70 -/* 172324 80243A44 26310001 */ addiu $s1, $s1, 1 -/* 172328 80243A48 8E0201D8 */ lw $v0, 0x1d8($s0) -/* 17232C 80243A4C 50400008 */ beql $v0, $zero, .L80243A70 -/* 172330 80243A50 26310001 */ addiu $s1, $s1, 1 -/* 172334 80243A54 8E0401E8 */ lw $a0, 0x1e8($s0) -/* 172338 80243A58 0C0B1059 */ jal does_script_exist -/* 17233C 80243A5C 00000000 */ nop -/* 172340 80243A60 50400002 */ beql $v0, $zero, .L80243A6C -/* 172344 80243A64 AE0001D8 */ sw $zero, 0x1d8($s0) -/* 172348 80243A68 24140001 */ addiu $s4, $zero, 1 -.L80243A6C: -/* 17234C 80243A6C 26310001 */ addiu $s1, $s1, 1 -.L80243A70: -/* 172350 80243A70 2A220018 */ slti $v0, $s1, 0x18 -/* 172354 80243A74 1440FFF1 */ bnez $v0, .L80243A3C -/* 172358 80243A78 26520004 */ addiu $s2, $s2, 4 -/* 17235C 80243A7C 1680001A */ bnez $s4, .L80243AE8 -/* 172360 80243A80 00000000 */ nop -/* 172364 80243A84 0000882D */ daddu $s1, $zero, $zero -/* 172368 80243A88 02C0902D */ daddu $s2, $s6, $zero -.L80243A8C: -/* 17236C 80243A8C 8E5000E0 */ lw $s0, 0xe0($s2) -/* 172370 80243A90 5200000B */ beql $s0, $zero, .L80243AC0 -/* 172374 80243A94 26310001 */ addiu $s1, $s1, 1 -/* 172378 80243A98 8E0201D4 */ lw $v0, 0x1d4($s0) -/* 17237C 80243A9C 50400008 */ beql $v0, $zero, .L80243AC0 -/* 172380 80243AA0 26310001 */ addiu $s1, $s1, 1 -/* 172384 80243AA4 8E0401E4 */ lw $a0, 0x1e4($s0) -/* 172388 80243AA8 0C0B1059 */ jal does_script_exist -/* 17238C 80243AAC 00000000 */ nop -/* 172390 80243AB0 50400002 */ beql $v0, $zero, .L80243ABC -/* 172394 80243AB4 AE0001D4 */ sw $zero, 0x1d4($s0) -/* 172398 80243AB8 24140001 */ addiu $s4, $zero, 1 -.L80243ABC: -/* 17239C 80243ABC 26310001 */ addiu $s1, $s1, 1 -.L80243AC0: -/* 1723A0 80243AC0 2A220018 */ slti $v0, $s1, 0x18 -/* 1723A4 80243AC4 1440FFF1 */ bnez $v0, .L80243A8C -/* 1723A8 80243AC8 26520004 */ addiu $s2, $s2, 4 -/* 1723AC 80243ACC 16800006 */ bnez $s4, .L80243AE8 -/* 1723B0 80243AD0 00000000 */ nop -/* 1723B4 80243AD4 0C093903 */ jal btl_cam_use_preset -/* 1723B8 80243AD8 24040002 */ addiu $a0, $zero, 2 -/* 1723BC 80243ADC 24020001 */ addiu $v0, $zero, 1 -/* 1723C0 80243AE0 3C01800E */ lui $at, %hi(gBattleState2) -/* 1723C4 80243AE4 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -.L80243AE8: -/* 1723C8 80243AE8 3C04800E */ lui $a0, %hi(gBattleState2) -/* 1723CC 80243AEC 2484C4DC */ addiu $a0, $a0, %lo(gBattleState2) -/* 1723D0 80243AF0 8C830000 */ lw $v1, ($a0) -/* 1723D4 80243AF4 24020001 */ addiu $v0, $zero, 1 -/* 1723D8 80243AF8 1462002A */ bne $v1, $v0, .L80243BA4 -/* 1723DC 80243AFC 00000000 */ nop -/* 1723E0 80243B00 3C03800E */ lui $v1, %hi(gBattleStatus) -/* 1723E4 80243B04 2463C070 */ addiu $v1, $v1, %lo(gBattleStatus) -/* 1723E8 80243B08 8C620004 */ lw $v0, 4($v1) -/* 1723EC 80243B0C 30420040 */ andi $v0, $v0, 0x40 -/* 1723F0 80243B10 14400007 */ bnez $v0, .L80243B30 -/* 1723F4 80243B14 2402000C */ addiu $v0, $zero, 0xc -/* 1723F8 80243B18 8C620000 */ lw $v0, ($v1) -/* 1723FC 80243B1C 3C030010 */ lui $v1, 0x10 -/* 172400 80243B20 00431024 */ and $v0, $v0, $v1 -/* 172404 80243B24 14400004 */ bnez $v0, .L80243B38 -/* 172408 80243B28 3C03F7FF */ lui $v1, 0xf7ff -/* 17240C 80243B2C 2402000C */ addiu $v0, $zero, 0xc -.L80243B30: -/* 172410 80243B30 08090EE9 */ j .L80243BA4 -/* 172414 80243B34 AC820000 */ sw $v0, ($a0) -.L80243B38: -/* 172418 80243B38 8EA20000 */ lw $v0, ($s5) -/* 17241C 80243B3C 3463FFFF */ ori $v1, $v1, 0xffff -/* 172420 80243B40 00431024 */ and $v0, $v0, $v1 -/* 172424 80243B44 AEA20000 */ sw $v0, ($s5) -/* 172428 80243B48 8E620000 */ lw $v0, ($s3) -/* 17242C 80243B4C 00431024 */ and $v0, $v0, $v1 -/* 172430 80243B50 AE620000 */ sw $v0, ($s3) -/* 172434 80243B54 8EA20000 */ lw $v0, ($s5) -/* 172438 80243B58 3C030400 */ lui $v1, 0x400 -/* 17243C 80243B5C 00431025 */ or $v0, $v0, $v1 -/* 172440 80243B60 AEA20000 */ sw $v0, ($s5) -/* 172444 80243B64 8E620000 */ lw $v0, ($s3) -/* 172448 80243B68 C6600138 */ lwc1 $f0, 0x138($s3) -/* 17244C 80243B6C C6620140 */ lwc1 $f2, 0x140($s3) -/* 172450 80243B70 00431025 */ or $v0, $v0, $v1 -/* 172454 80243B74 AE620000 */ sw $v0, ($s3) -/* 172458 80243B78 E660000C */ swc1 $f0, 0xc($s3) -/* 17245C 80243B7C E6620014 */ swc1 $f2, 0x14($s3) -/* 172460 80243B80 C6A00138 */ lwc1 $f0, 0x138($s5) -/* 172464 80243B84 2402000B */ addiu $v0, $zero, 0xb -/* 172468 80243B88 AC820000 */ sw $v0, ($a0) -/* 17246C 80243B8C E6600018 */ swc1 $f0, 0x18($s3) -/* 172470 80243B90 C6A00140 */ lwc1 $f0, 0x140($s5) -/* 172474 80243B94 24020004 */ addiu $v0, $zero, 4 -/* 172478 80243B98 A6620070 */ sh $v0, 0x70($s3) -/* 17247C 80243B9C AE600054 */ sw $zero, 0x54($s3) -/* 172480 80243BA0 E6600020 */ swc1 $f0, 0x20($s3) -.L80243BA4: -/* 172484 80243BA4 3C03800E */ lui $v1, %hi(gBattleState2) -/* 172488 80243BA8 8C63C4DC */ lw $v1, %lo(gBattleState2)($v1) -/* 17248C 80243BAC 2402000B */ addiu $v0, $zero, 0xb -/* 172490 80243BB0 1462007D */ bne $v1, $v0, .L80243DA8 -/* 172494 80243BB4 2402000C */ addiu $v0, $zero, 0xc -/* 172498 80243BB8 86620070 */ lh $v0, 0x70($s3) -/* 17249C 80243BBC 10400022 */ beqz $v0, .L80243C48 -/* 1724A0 80243BC0 00000000 */ nop -/* 1724A4 80243BC4 C6600018 */ lwc1 $f0, 0x18($s3) -/* 1724A8 80243BC8 C6680144 */ lwc1 $f8, 0x144($s3) -/* 1724AC 80243BCC C6620020 */ lwc1 $f2, 0x20($s3) -/* 1724B0 80243BD0 46080001 */ sub.s $f0, $f0, $f8 -/* 1724B4 80243BD4 C664014C */ lwc1 $f4, 0x14c($s3) -/* 1724B8 80243BD8 46041081 */ sub.s $f2, $f2, $f4 -/* 1724BC 80243BDC 44823000 */ mtc1 $v0, $f6 -/* 1724C0 80243BE0 00000000 */ nop -/* 1724C4 80243BE4 468031A0 */ cvt.s.w $f6, $f6 -/* 1724C8 80243BE8 46060003 */ div.s $f0, $f0, $f6 -/* 1724CC 80243BEC 46004200 */ add.s $f8, $f8, $f0 -/* 1724D0 80243BF0 46003006 */ mov.s $f0, $f6 -/* 1724D4 80243BF4 46061083 */ div.s $f2, $f2, $f6 -/* 1724D8 80243BF8 C660000C */ lwc1 $f0, 0xc($s3) -/* 1724DC 80243BFC 46022100 */ add.s $f4, $f4, $f2 -/* 1724E0 80243C00 E6680144 */ swc1 $f8, 0x144($s3) -/* 1724E4 80243C04 E664014C */ swc1 $f4, 0x14c($s3) -/* 1724E8 80243C08 C6A40144 */ lwc1 $f4, 0x144($s5) -/* 1724EC 80243C0C 46040001 */ sub.s $f0, $f0, $f4 -/* 1724F0 80243C10 46003086 */ mov.s $f2, $f6 -/* 1724F4 80243C14 46060003 */ div.s $f0, $f0, $f6 -/* 1724F8 80243C18 46002100 */ add.s $f4, $f4, $f0 -/* 1724FC 80243C1C E6A40144 */ swc1 $f4, 0x144($s5) -/* 172500 80243C20 C6600014 */ lwc1 $f0, 0x14($s3) -/* 172504 80243C24 C6A4014C */ lwc1 $f4, 0x14c($s5) -/* 172508 80243C28 86620070 */ lh $v0, 0x70($s3) -/* 17250C 80243C2C 46040001 */ sub.s $f0, $f0, $f4 -/* 172510 80243C30 44821000 */ mtc1 $v0, $f2 -/* 172514 80243C34 00000000 */ nop -/* 172518 80243C38 468010A0 */ cvt.s.w $f2, $f2 -/* 17251C 80243C3C 46020003 */ div.s $f0, $f0, $f2 -/* 172520 80243C40 46002100 */ add.s $f4, $f4, $f0 -/* 172524 80243C44 E6A4014C */ swc1 $f4, 0x14c($s5) -.L80243C48: -/* 172528 80243C48 C66C0054 */ lwc1 $f12, 0x54($s3) -/* 17252C 80243C4C 3C0140C9 */ lui $at, 0x40c9 -/* 172530 80243C50 34210FD0 */ ori $at, $at, 0xfd0 -/* 172534 80243C54 4481B000 */ mtc1 $at, $f22 -/* 172538 80243C58 00000000 */ nop -/* 17253C 80243C5C 46166302 */ mul.s $f12, $f12, $f22 -/* 172540 80243C60 00000000 */ nop -/* 172544 80243C64 3C0143B4 */ lui $at, 0x43b4 -/* 172548 80243C68 4481C000 */ mtc1 $at, $f24 -/* 17254C 80243C6C 3C014180 */ lui $at, 0x4180 -/* 172550 80243C70 4481A000 */ mtc1 $at, $f20 -/* 172554 80243C74 0C00A85B */ jal sin_rad -/* 172558 80243C78 46186303 */ div.s $f12, $f12, $f24 -/* 17255C 80243C7C 46140002 */ mul.s $f0, $f0, $f20 -/* 172560 80243C80 00000000 */ nop -/* 172564 80243C84 C662014C */ lwc1 $f2, 0x14c($s3) -/* 172568 80243C88 46001081 */ sub.s $f2, $f2, $f0 -/* 17256C 80243C8C C66C0054 */ lwc1 $f12, 0x54($s3) -/* 172570 80243C90 0C00A6C9 */ jal clamp_angle -/* 172574 80243C94 E662014C */ swc1 $f2, 0x14c($s3) -/* 172578 80243C98 C66C0054 */ lwc1 $f12, 0x54($s3) -/* 17257C 80243C9C 46166302 */ mul.s $f12, $f12, $f22 -/* 172580 80243CA0 00000000 */ nop -/* 172584 80243CA4 E660018C */ swc1 $f0, 0x18c($s3) -/* 172588 80243CA8 0C00A85B */ jal sin_rad -/* 17258C 80243CAC 46186303 */ div.s $f12, $f12, $f24 -/* 172590 80243CB0 46140002 */ mul.s $f0, $f0, $f20 -/* 172594 80243CB4 00000000 */ nop -/* 172598 80243CB8 C6A2014C */ lwc1 $f2, 0x14c($s5) -/* 17259C 80243CBC 46001080 */ add.s $f2, $f2, $f0 -/* 1725A0 80243CC0 E6A2014C */ swc1 $f2, 0x14c($s5) -/* 1725A4 80243CC4 0C00A6C9 */ jal clamp_angle -/* 1725A8 80243CC8 C66C0054 */ lwc1 $f12, 0x54($s3) -/* 1725AC 80243CCC E6A0018C */ swc1 $f0, 0x18c($s5) -/* 1725B0 80243CD0 C6600054 */ lwc1 $f0, 0x54($s3) -/* 1725B4 80243CD4 3C0142B4 */ lui $at, 0x42b4 -/* 1725B8 80243CD8 44811000 */ mtc1 $at, $f2 -/* 1725BC 80243CDC 86620070 */ lh $v0, 0x70($s3) -/* 1725C0 80243CE0 46020000 */ add.s $f0, $f0, $f2 -/* 1725C4 80243CE4 96630070 */ lhu $v1, 0x70($s3) -/* 1725C8 80243CE8 10400004 */ beqz $v0, .L80243CFC -/* 1725CC 80243CEC E6600054 */ swc1 $f0, 0x54($s3) -/* 1725D0 80243CF0 2462FFFF */ addiu $v0, $v1, -1 -/* 1725D4 80243CF4 08090F67 */ j .L80243D9C -/* 1725D8 80243CF8 A6620070 */ sh $v0, 0x70($s3) -.L80243CFC: -/* 1725DC 80243CFC C6600018 */ lwc1 $f0, 0x18($s3) -/* 1725E0 80243D00 C6620020 */ lwc1 $f2, 0x20($s3) -/* 1725E4 80243D04 C664000C */ lwc1 $f4, 0xc($s3) -/* 1725E8 80243D08 E6600144 */ swc1 $f0, 0x144($s3) -/* 1725EC 80243D0C E662014C */ swc1 $f2, 0x14c($s3) -/* 1725F0 80243D10 E6A40144 */ swc1 $f4, 0x144($s5) -/* 1725F4 80243D14 C6600014 */ lwc1 $f0, 0x14($s3) -/* 1725F8 80243D18 E6A0014C */ swc1 $f0, 0x14c($s5) -/* 1725FC 80243D1C C6600144 */ lwc1 $f0, 0x144($s3) -/* 172600 80243D20 C662014C */ lwc1 $f2, 0x14c($s3) -/* 172604 80243D24 3C030800 */ lui $v1, 0x800 -/* 172608 80243D28 E6600138 */ swc1 $f0, 0x138($s3) -/* 17260C 80243D2C E6620140 */ swc1 $f2, 0x140($s3) -/* 172610 80243D30 C6A00144 */ lwc1 $f0, 0x144($s5) -/* 172614 80243D34 8EA20000 */ lw $v0, ($s5) -/* 172618 80243D38 C6A2014C */ lwc1 $f2, 0x14c($s5) -/* 17261C 80243D3C 00431025 */ or $v0, $v0, $v1 -/* 172620 80243D40 E6A00138 */ swc1 $f0, 0x138($s5) -/* 172624 80243D44 E6A20140 */ swc1 $f2, 0x140($s5) -/* 172628 80243D48 AEA20000 */ sw $v0, ($s5) -/* 17262C 80243D4C 8E620000 */ lw $v0, ($s3) -/* 172630 80243D50 3C04800E */ lui $a0, %hi(gBattleStatus) -/* 172634 80243D54 2484C070 */ addiu $a0, $a0, %lo(gBattleStatus) -/* 172638 80243D58 00431025 */ or $v0, $v0, $v1 -/* 17263C 80243D5C AE620000 */ sw $v0, ($s3) -/* 172640 80243D60 8C820004 */ lw $v0, 4($a0) -/* 172644 80243D64 30420040 */ andi $v0, $v0, 0x40 -/* 172648 80243D68 10400004 */ beqz $v0, .L80243D7C -/* 17264C 80243D6C 3C030010 */ lui $v1, 0x10 -/* 172650 80243D70 8C820000 */ lw $v0, ($a0) -/* 172654 80243D74 08090F63 */ j .L80243D8C -/* 172658 80243D78 00431025 */ or $v0, $v0, $v1 -.L80243D7C: -/* 17265C 80243D7C 3C03FFEF */ lui $v1, 0xffef -/* 172660 80243D80 8C820000 */ lw $v0, ($a0) -/* 172664 80243D84 3463FFFF */ ori $v1, $v1, 0xffff -/* 172668 80243D88 00431024 */ and $v0, $v0, $v1 -.L80243D8C: -/* 17266C 80243D8C AC820000 */ sw $v0, ($a0) -/* 172670 80243D90 2402000C */ addiu $v0, $zero, 0xc -/* 172674 80243D94 3C01800E */ lui $at, %hi(gBattleState2) -/* 172678 80243D98 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -.L80243D9C: -/* 17267C 80243D9C 3C03800E */ lui $v1, %hi(gBattleState2) -/* 172680 80243DA0 8C63C4DC */ lw $v1, %lo(gBattleState2)($v1) -/* 172684 80243DA4 2402000C */ addiu $v0, $zero, 0xc -.L80243DA8: -/* 172688 80243DA8 1462004C */ bne $v1, $v0, .L80243EDC -/* 17268C 80243DAC 3C02FFFE */ lui $v0, 0xfffe -/* 172690 80243DB0 3C10800E */ lui $s0, %hi(gBattleStatus) -/* 172694 80243DB4 2610C070 */ addiu $s0, $s0, %lo(gBattleStatus) -/* 172698 80243DB8 8E030004 */ lw $v1, 4($s0) -/* 17269C 80243DBC 3442FFFF */ ori $v0, $v0, 0xffff -/* 1726A0 80243DC0 00621824 */ and $v1, $v1, $v0 -/* 1726A4 80243DC4 AE030004 */ sw $v1, 4($s0) -/* 1726A8 80243DC8 8EA20000 */ lw $v0, ($s5) -/* 1726AC 80243DCC 3C030C00 */ lui $v1, 0xc00 -/* 1726B0 80243DD0 A2A0021D */ sb $zero, 0x21d($s5) -/* 1726B4 80243DD4 00431025 */ or $v0, $v0, $v1 -/* 1726B8 80243DD8 12600004 */ beqz $s3, .L80243DEC -/* 1726BC 80243DDC AEA20000 */ sw $v0, ($s5) -/* 1726C0 80243DE0 00431025 */ or $v0, $v0, $v1 -/* 1726C4 80243DE4 AEA20000 */ sw $v0, ($s5) -/* 1726C8 80243DE8 A260021D */ sb $zero, 0x21d($s3) -.L80243DEC: -/* 1726CC 80243DEC 0C098298 */ jal func_80260A60 -/* 1726D0 80243DF0 00000000 */ nop -/* 1726D4 80243DF4 3C04FFBF */ lui $a0, 0xffbf -/* 1726D8 80243DF8 3484FFFF */ ori $a0, $a0, 0xffff -/* 1726DC 80243DFC 8E030000 */ lw $v1, ($s0) -/* 1726E0 80243E00 96E20290 */ lhu $v0, 0x290($s7) -/* 1726E4 80243E04 00641824 */ and $v1, $v1, $a0 -/* 1726E8 80243E08 24420020 */ addiu $v0, $v0, 0x20 -/* 1726EC 80243E0C AE030000 */ sw $v1, ($s0) -/* 1726F0 80243E10 A6E20290 */ sh $v0, 0x290($s7) -/* 1726F4 80243E14 00021400 */ sll $v0, $v0, 0x10 -/* 1726F8 80243E18 82E3028E */ lb $v1, 0x28e($s7) -/* 1726FC 80243E1C 00021403 */ sra $v0, $v0, 0x10 -/* 172700 80243E20 00031A00 */ sll $v1, $v1, 8 -/* 172704 80243E24 0062102A */ slt $v0, $v1, $v0 -/* 172708 80243E28 54400001 */ bnel $v0, $zero, .L80243E30 -/* 17270C 80243E2C A6E30290 */ sh $v1, 0x290($s7) -.L80243E30: -/* 172710 80243E30 0000882D */ daddu $s1, $zero, $zero -/* 172714 80243E34 2414000B */ addiu $s4, $zero, 0xb -/* 172718 80243E38 02C0902D */ daddu $s2, $s6, $zero -.L80243E3C: -/* 17271C 80243E3C 8E5000E0 */ lw $s0, 0xe0($s2) -/* 172720 80243E40 52000010 */ beql $s0, $zero, .L80243E84 -/* 172724 80243E44 26310001 */ addiu $s1, $s1, 1 -/* 172728 80243E48 8E0201CC */ lw $v0, 0x1cc($s0) -/* 17272C 80243E4C 5040000D */ beql $v0, $zero, .L80243E84 -/* 172730 80243E50 26310001 */ addiu $s1, $s1, 1 -/* 172734 80243E54 2405000A */ addiu $a1, $zero, 0xa -/* 172738 80243E58 A2D401A7 */ sb $s4, 0x1a7($s6) -/* 17273C 80243E5C 8E0401CC */ lw $a0, 0x1cc($s0) -/* 172740 80243E60 0C0B0CF8 */ jal start_script -/* 172744 80243E64 0000302D */ daddu $a2, $zero, $zero -/* 172748 80243E68 0040182D */ daddu $v1, $v0, $zero -/* 17274C 80243E6C AE0301DC */ sw $v1, 0x1dc($s0) -/* 172750 80243E70 8C620144 */ lw $v0, 0x144($v1) -/* 172754 80243E74 AE0201EC */ sw $v0, 0x1ec($s0) -/* 172758 80243E78 36220200 */ ori $v0, $s1, 0x200 -/* 17275C 80243E7C AC620148 */ sw $v0, 0x148($v1) -/* 172760 80243E80 26310001 */ addiu $s1, $s1, 1 -.L80243E84: -/* 172764 80243E84 2A220018 */ slti $v0, $s1, 0x18 -/* 172768 80243E88 1440FFEC */ bnez $v0, .L80243E3C -/* 17276C 80243E8C 26520004 */ addiu $s2, $s2, 4 -/* 172770 80243E90 12600010 */ beqz $s3, .L80243ED4 -/* 172774 80243E94 24020002 */ addiu $v0, $zero, 2 -/* 172778 80243E98 8E6201CC */ lw $v0, 0x1cc($s3) -/* 17277C 80243E9C 1040000C */ beqz $v0, .L80243ED0 -/* 172780 80243EA0 2405000A */ addiu $a1, $zero, 0xa -/* 172784 80243EA4 2402000B */ addiu $v0, $zero, 0xb -/* 172788 80243EA8 A2C201A7 */ sb $v0, 0x1a7($s6) -/* 17278C 80243EAC 8E6401CC */ lw $a0, 0x1cc($s3) -/* 172790 80243EB0 0C0B0CF8 */ jal start_script -/* 172794 80243EB4 0000302D */ daddu $a2, $zero, $zero -/* 172798 80243EB8 0040182D */ daddu $v1, $v0, $zero -/* 17279C 80243EBC AE6301DC */ sw $v1, 0x1dc($s3) -/* 1727A0 80243EC0 8C620144 */ lw $v0, 0x144($v1) -/* 1727A4 80243EC4 AE6201EC */ sw $v0, 0x1ec($s3) -/* 1727A8 80243EC8 24020100 */ addiu $v0, $zero, 0x100 -/* 1727AC 80243ECC AC620148 */ sw $v0, 0x148($v1) -.L80243ED0: -/* 1727B0 80243ED0 24020002 */ addiu $v0, $zero, 2 -.L80243ED4: -/* 1727B4 80243ED4 3C01800E */ lui $at, %hi(gBattleState2) -/* 1727B8 80243ED8 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -.L80243EDC: -/* 1727BC 80243EDC 3C03800E */ lui $v1, %hi(gBattleState2) -/* 1727C0 80243EE0 8C63C4DC */ lw $v1, %lo(gBattleState2)($v1) -/* 1727C4 80243EE4 24020002 */ addiu $v0, $zero, 2 -/* 1727C8 80243EE8 14620026 */ bne $v1, $v0, .L80243F84 -/* 1727CC 80243EEC 28620005 */ slti $v0, $v1, 5 -/* 1727D0 80243EF0 0000A02D */ daddu $s4, $zero, $zero -/* 1727D4 80243EF4 0280882D */ daddu $s1, $s4, $zero -/* 1727D8 80243EF8 02C0902D */ daddu $s2, $s6, $zero -.L80243EFC: -/* 1727DC 80243EFC 8E5000E0 */ lw $s0, 0xe0($s2) -/* 1727E0 80243F00 5200000A */ beql $s0, $zero, .L80243F2C -/* 1727E4 80243F04 26310001 */ addiu $s1, $s1, 1 -/* 1727E8 80243F08 8E0201CC */ lw $v0, 0x1cc($s0) -/* 1727EC 80243F0C 50400007 */ beql $v0, $zero, .L80243F2C -/* 1727F0 80243F10 26310001 */ addiu $s1, $s1, 1 -/* 1727F4 80243F14 8E0401EC */ lw $a0, 0x1ec($s0) -/* 1727F8 80243F18 0C0B1059 */ jal does_script_exist -/* 1727FC 80243F1C 00000000 */ nop -/* 172800 80243F20 54400001 */ bnel $v0, $zero, .L80243F28 -/* 172804 80243F24 24140001 */ addiu $s4, $zero, 1 -.L80243F28: -/* 172808 80243F28 26310001 */ addiu $s1, $s1, 1 -.L80243F2C: -/* 17280C 80243F2C 2A220018 */ slti $v0, $s1, 0x18 -/* 172810 80243F30 1440FFF2 */ bnez $v0, .L80243EFC -/* 172814 80243F34 26520004 */ addiu $s2, $s2, 4 -/* 172818 80243F38 12600008 */ beqz $s3, .L80243F5C -/* 17281C 80243F3C 00000000 */ nop -/* 172820 80243F40 8E6201CC */ lw $v0, 0x1cc($s3) -/* 172824 80243F44 10400005 */ beqz $v0, .L80243F5C -/* 172828 80243F48 00000000 */ nop -/* 17282C 80243F4C 0C0B1059 */ jal does_script_exist -/* 172830 80243F50 8E6401EC */ lw $a0, 0x1ec($s3) -/* 172834 80243F54 54400001 */ bnel $v0, $zero, .L80243F5C -/* 172838 80243F58 24140001 */ addiu $s4, $zero, 1 -.L80243F5C: -/* 17283C 80243F5C 16800006 */ bnez $s4, .L80243F78 -/* 172840 80243F60 00000000 */ nop -/* 172844 80243F64 0C093903 */ jal btl_cam_use_preset -/* 172848 80243F68 24040002 */ addiu $a0, $zero, 2 -/* 17284C 80243F6C 24020003 */ addiu $v0, $zero, 3 -/* 172850 80243F70 3C01800E */ lui $at, %hi(gBattleState2) -/* 172854 80243F74 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -.L80243F78: -/* 172858 80243F78 3C03800E */ lui $v1, %hi(gBattleState2) -/* 17285C 80243F7C 8C63C4DC */ lw $v1, %lo(gBattleState2)($v1) -/* 172860 80243F80 28620005 */ slti $v0, $v1, 5 -.L80243F84: -/* 172864 80243F84 10400005 */ beqz $v0, .L80243F9C -/* 172868 80243F88 28620003 */ slti $v0, $v1, 3 -/* 17286C 80243F8C 14400003 */ bnez $v0, .L80243F9C -/* 172870 80243F90 00000000 */ nop -/* 172874 80243F94 0C090464 */ jal btl_set_state -/* 172878 80243F98 24040005 */ addiu $a0, $zero, 5 -.L80243F9C: -/* 17287C 80243F9C 8FBF0030 */ lw $ra, 0x30($sp) -/* 172880 80243FA0 8FB7002C */ lw $s7, 0x2c($sp) -/* 172884 80243FA4 8FB60028 */ lw $s6, 0x28($sp) -/* 172888 80243FA8 8FB50024 */ lw $s5, 0x24($sp) -/* 17288C 80243FAC 8FB40020 */ lw $s4, 0x20($sp) -/* 172890 80243FB0 8FB3001C */ lw $s3, 0x1c($sp) -/* 172894 80243FB4 8FB20018 */ lw $s2, 0x18($sp) -/* 172898 80243FB8 8FB10014 */ lw $s1, 0x14($sp) -/* 17289C 80243FBC 8FB00010 */ lw $s0, 0x10($sp) -/* 1728A0 80243FC0 D7B80048 */ ldc1 $f24, 0x48($sp) -/* 1728A4 80243FC4 D7B60040 */ ldc1 $f22, 0x40($sp) -/* 1728A8 80243FC8 D7B40038 */ ldc1 $f20, 0x38($sp) -/* 1728AC 80243FCC 03E00008 */ jr $ra -/* 1728B0 80243FD0 27BD0050 */ addiu $sp, $sp, 0x50 diff --git a/ver/us/asm/nonmatchings/16F740/btl_state_update_enemy_striking_first.s b/ver/us/asm/nonmatchings/16F740/btl_state_update_enemy_striking_first.s deleted file mode 100644 index e6167245fa..0000000000 --- a/ver/us/asm/nonmatchings/16F740/btl_state_update_enemy_striking_first.s +++ /dev/null @@ -1,306 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel btl_state_update_enemy_striking_first -/* 176F40 80248660 27BDFFD8 */ addiu $sp, $sp, -0x28 -/* 176F44 80248664 3C058011 */ lui $a1, %hi(gPlayerData) -/* 176F48 80248668 24A5F290 */ addiu $a1, $a1, %lo(gPlayerData) -/* 176F4C 8024866C AFB3001C */ sw $s3, 0x1c($sp) -/* 176F50 80248670 3C13800E */ lui $s3, %hi(gBattleStatus) -/* 176F54 80248674 2673C070 */ addiu $s3, $s3, %lo(gBattleStatus) -/* 176F58 80248678 AFBF0024 */ sw $ra, 0x24($sp) -/* 176F5C 8024867C AFB40020 */ sw $s4, 0x20($sp) -/* 176F60 80248680 AFB20018 */ sw $s2, 0x18($sp) -/* 176F64 80248684 AFB10014 */ sw $s1, 0x14($sp) -/* 176F68 80248688 AFB00010 */ sw $s0, 0x10($sp) -/* 176F6C 8024868C 8E7200D8 */ lw $s2, 0xd8($s3) -/* 176F70 80248690 3C03800E */ lui $v1, %hi(gBattleState2) -/* 176F74 80248694 8C63C4DC */ lw $v1, %lo(gBattleState2)($v1) -/* 176F78 80248698 8E7100DC */ lw $s1, 0xdc($s3) -/* 176F7C 8024869C 10600005 */ beqz $v1, .L802486B4 -/* 176F80 802486A0 24020002 */ addiu $v0, $zero, 2 -/* 176F84 802486A4 1062008A */ beq $v1, $v0, .L802488D0 -/* 176F88 802486A8 00000000 */ nop -/* 176F8C 802486AC 080922A1 */ j .L80248A84 -/* 176F90 802486B0 00000000 */ nop -.L802486B4: -/* 176F94 802486B4 94A2029E */ lhu $v0, 0x29e($a1) -/* 176F98 802486B8 3C04F7FF */ lui $a0, 0xf7ff -/* 176F9C 802486BC A260008C */ sb $zero, 0x8c($s3) -/* 176FA0 802486C0 A6600180 */ sh $zero, 0x180($s3) -/* 176FA4 802486C4 A260019A */ sb $zero, 0x19a($s3) -/* 176FA8 802486C8 24420001 */ addiu $v0, $v0, 1 -/* 176FAC 802486CC A4A2029E */ sh $v0, 0x29e($a1) -/* 176FB0 802486D0 8E620000 */ lw $v0, ($s3) -/* 176FB4 802486D4 2403FFFD */ addiu $v1, $zero, -3 -/* 176FB8 802486D8 00431024 */ and $v0, $v0, $v1 -/* 176FBC 802486DC AE620000 */ sw $v0, ($s3) -/* 176FC0 802486E0 8E420000 */ lw $v0, ($s2) -/* 176FC4 802486E4 3484FFFF */ ori $a0, $a0, 0xffff -/* 176FC8 802486E8 3C01802A */ lui $at, %hi(D_8029F254) -/* 176FCC 802486EC AC20F254 */ sw $zero, %lo(D_8029F254)($at) -/* 176FD0 802486F0 00441024 */ and $v0, $v0, $a0 -/* 176FD4 802486F4 12200004 */ beqz $s1, .L80248708 -/* 176FD8 802486F8 AE420000 */ sw $v0, ($s2) -/* 176FDC 802486FC 8E220000 */ lw $v0, ($s1) -/* 176FE0 80248700 00441024 */ and $v0, $v0, $a0 -/* 176FE4 80248704 AE220000 */ sw $v0, ($s1) -.L80248708: -/* 176FE8 80248708 3C030100 */ lui $v1, 0x100 -/* 176FEC 8024870C 34634000 */ ori $v1, $v1, 0x4000 -/* 176FF0 80248710 0000502D */ daddu $t2, $zero, $zero -/* 176FF4 80248714 0140882D */ daddu $s1, $t2, $zero -/* 176FF8 80248718 0260282D */ daddu $a1, $s3, $zero -/* 176FFC 8024871C 8E620004 */ lw $v0, 4($s3) -/* 177000 80248720 0260202D */ daddu $a0, $s3, $zero -/* 177004 80248724 00431025 */ or $v0, $v0, $v1 -/* 177008 80248728 AE620004 */ sw $v0, 4($s3) -.L8024872C: -/* 17700C 8024872C 8CB000E0 */ lw $s0, 0xe0($a1) -/* 177010 80248730 52000006 */ beql $s0, $zero, .L8024874C -/* 177014 80248734 26310001 */ addiu $s1, $s1, 1 -/* 177018 80248738 36220200 */ ori $v0, $s1, 0x200 -/* 17701C 8024873C A4820140 */ sh $v0, 0x140($a0) -/* 177020 80248740 24840002 */ addiu $a0, $a0, 2 -/* 177024 80248744 254A0001 */ addiu $t2, $t2, 1 -/* 177028 80248748 26310001 */ addiu $s1, $s1, 1 -.L8024874C: -/* 17702C 8024874C 2A220018 */ slti $v0, $s1, 0x18 -/* 177030 80248750 1440FFF6 */ bnez $v0, .L8024872C -/* 177034 80248754 24A50004 */ addiu $a1, $a1, 4 -/* 177038 80248758 A26A0171 */ sb $t2, 0x171($s3) -/* 17703C 8024875C 0000882D */ daddu $s1, $zero, $zero -/* 177040 80248760 2542FFFF */ addiu $v0, $t2, -1 -/* 177044 80248764 18400022 */ blez $v0, .L802487F0 -/* 177048 80248768 266C0140 */ addiu $t4, $s3, 0x140 -/* 17704C 8024876C 0040682D */ daddu $t5, $v0, $zero -/* 177050 80248770 0180582D */ daddu $t3, $t4, $zero -.L80248774: -/* 177054 80248774 26270001 */ addiu $a3, $s1, 1 -/* 177058 80248778 00EA102A */ slt $v0, $a3, $t2 -/* 17705C 8024877C 50400019 */ beql $v0, $zero, .L802487E4 -/* 177060 80248780 26310001 */ addiu $s1, $s1, 1 -/* 177064 80248784 0160482D */ daddu $t1, $t3, $zero -/* 177068 80248788 00071040 */ sll $v0, $a3, 1 -/* 17706C 8024878C 004C3021 */ addu $a2, $v0, $t4 -.L80248790: -/* 177070 80248790 95280000 */ lhu $t0, ($t1) -/* 177074 80248794 94C50000 */ lhu $a1, ($a2) -/* 177078 80248798 310300FF */ andi $v1, $t0, 0xff -/* 17707C 8024879C 00031880 */ sll $v1, $v1, 2 -/* 177080 802487A0 02631821 */ addu $v1, $s3, $v1 -/* 177084 802487A4 30A200FF */ andi $v0, $a1, 0xff -/* 177088 802487A8 00021080 */ sll $v0, $v0, 2 -/* 17708C 802487AC 02621021 */ addu $v0, $s3, $v0 -/* 177090 802487B0 8C6300E0 */ lw $v1, 0xe0($v1) -/* 177094 802487B4 8C4400E0 */ lw $a0, 0xe0($v0) -/* 177098 802487B8 806201F1 */ lb $v0, 0x1f1($v1) -/* 17709C 802487BC 808301F1 */ lb $v1, 0x1f1($a0) -/* 1770A0 802487C0 0043102A */ slt $v0, $v0, $v1 -/* 1770A4 802487C4 10400003 */ beqz $v0, .L802487D4 -/* 1770A8 802487C8 24E70001 */ addiu $a3, $a3, 1 -/* 1770AC 802487CC A5250000 */ sh $a1, ($t1) -/* 1770B0 802487D0 A4C80000 */ sh $t0, ($a2) -.L802487D4: -/* 1770B4 802487D4 00EA102A */ slt $v0, $a3, $t2 -/* 1770B8 802487D8 1440FFED */ bnez $v0, .L80248790 -/* 1770BC 802487DC 24C60002 */ addiu $a2, $a2, 2 -/* 1770C0 802487E0 26310001 */ addiu $s1, $s1, 1 -.L802487E4: -/* 1770C4 802487E4 022D102A */ slt $v0, $s1, $t5 -/* 1770C8 802487E8 1440FFE2 */ bnez $v0, .L80248774 -/* 1770CC 802487EC 256B0002 */ addiu $t3, $t3, 2 -.L802487F0: -/* 1770D0 802487F0 A2600170 */ sb $zero, 0x170($s3) -/* 1770D4 802487F4 0000282D */ daddu $a1, $zero, $zero -/* 1770D8 802487F8 3C030020 */ lui $v1, 0x20 -/* 1770DC 802487FC 34634000 */ ori $v1, $v1, 0x4000 -.L80248800: -/* 1770E0 80248800 00051040 */ sll $v0, $a1, 1 -.L80248804: -/* 1770E4 80248804 02621021 */ addu $v0, $s3, $v0 -/* 1770E8 80248808 90420141 */ lbu $v0, 0x141($v0) -/* 1770EC 8024880C 00021080 */ sll $v0, $v0, 2 -/* 1770F0 80248810 02621021 */ addu $v0, $s3, $v0 -/* 1770F4 80248814 8C5000E0 */ lw $s0, 0xe0($v0) -/* 1770F8 80248818 12000005 */ beqz $s0, .L80248830 -/* 1770FC 8024881C 00000000 */ nop -/* 177100 80248820 8E020000 */ lw $v0, ($s0) -/* 177104 80248824 00431024 */ and $v0, $v0, $v1 -/* 177108 80248828 10400008 */ beqz $v0, .L8024884C -/* 17710C 8024882C 00051040 */ sll $v0, $a1, 1 -.L80248830: -/* 177110 80248830 82620171 */ lb $v0, 0x171($s3) -/* 177114 80248834 24A50001 */ addiu $a1, $a1, 1 -/* 177118 80248838 00A2102A */ slt $v0, $a1, $v0 -/* 17711C 8024883C 5040FFF0 */ beql $v0, $zero, .L80248800 -/* 177120 80248840 0000282D */ daddu $a1, $zero, $zero -/* 177124 80248844 08092201 */ j .L80248804 -/* 177128 80248848 00051040 */ sll $v0, $a1, 1 -.L8024884C: -/* 17712C 8024884C 02621021 */ addu $v0, $s3, $v0 -/* 177130 80248850 94430140 */ lhu $v1, 0x140($v0) -/* 177134 80248854 82620171 */ lb $v0, 0x171($s3) -/* 177138 80248858 24A50001 */ addiu $a1, $a1, 1 -/* 17713C 8024885C AE700174 */ sw $s0, 0x174($s3) -/* 177140 80248860 00A2102A */ slt $v0, $a1, $v0 -/* 177144 80248864 14400002 */ bnez $v0, .L80248870 -/* 177148 80248868 A6630172 */ sh $v1, 0x172($s3) -/* 17714C 8024886C 0000282D */ daddu $a1, $zero, $zero -.L80248870: -/* 177150 80248870 86640172 */ lh $a0, 0x172($s3) -/* 177154 80248874 0C09390F */ jal btl_cam_target_actor -/* 177158 80248878 A2650170 */ sb $a1, 0x170($s3) -/* 17715C 8024887C 8E700174 */ lw $s0, 0x174($s3) -/* 177160 80248880 0C098F18 */ jal reset_actor_turn_info -/* 177164 80248884 00000000 */ nop -/* 177168 80248888 24020001 */ addiu $v0, $zero, 1 -/* 17716C 8024888C 2405000A */ addiu $a1, $zero, 0xa -/* 177170 80248890 A26201A7 */ sb $v0, 0x1a7($s3) -/* 177174 80248894 8E0401C4 */ lw $a0, 0x1c4($s0) -/* 177178 80248898 0C0B0CF8 */ jal start_script -/* 17717C 8024889C 0000302D */ daddu $a2, $zero, $zero -/* 177180 802488A0 AE0201D4 */ sw $v0, 0x1d4($s0) -/* 177184 802488A4 8C440144 */ lw $a0, 0x144($v0) -/* 177188 802488A8 24030003 */ addiu $v1, $zero, 3 -/* 17718C 802488AC 3C01802A */ lui $at, %hi(D_8029F248) -/* 177190 802488B0 AC23F248 */ sw $v1, %lo(D_8029F248)($at) -/* 177194 802488B4 AE0401E4 */ sw $a0, 0x1e4($s0) -/* 177198 802488B8 86640172 */ lh $a0, 0x172($s3) -/* 17719C 802488BC 24030002 */ addiu $v1, $zero, 2 -/* 1771A0 802488C0 3C01800E */ lui $at, %hi(gBattleState2) -/* 1771A4 802488C4 AC23C4DC */ sw $v1, %lo(gBattleState2)($at) -/* 1771A8 802488C8 080922A1 */ j .L80248A84 -/* 1771AC 802488CC AC440148 */ sw $a0, 0x148($v0) -.L802488D0: -/* 1771B0 802488D0 3C03802A */ lui $v1, %hi(D_8029F248) -/* 1771B4 802488D4 2463F248 */ addiu $v1, $v1, %lo(D_8029F248) -/* 1771B8 802488D8 8C620000 */ lw $v0, ($v1) -/* 1771BC 802488DC 10400003 */ beqz $v0, .L802488EC -/* 1771C0 802488E0 2442FFFF */ addiu $v0, $v0, -1 -/* 1771C4 802488E4 0809223E */ j .L802488F8 -/* 1771C8 802488E8 AC620000 */ sw $v0, ($v1) -.L802488EC: -/* 1771CC 802488EC 24020001 */ addiu $v0, $zero, 1 -/* 1771D0 802488F0 3C01802A */ lui $at, %hi(D_8029F254) -/* 1771D4 802488F4 AC22F254 */ sw $v0, %lo(D_8029F254)($at) -.L802488F8: -/* 1771D8 802488F8 8E700174 */ lw $s0, 0x174($s3) -/* 1771DC 802488FC 8E0201D4 */ lw $v0, 0x1d4($s0) -/* 1771E0 80248900 50400007 */ beql $v0, $zero, .L80248920 -/* 1771E4 80248904 AE0001D4 */ sw $zero, 0x1d4($s0) -/* 1771E8 80248908 8E0401E4 */ lw $a0, 0x1e4($s0) -/* 1771EC 8024890C 0C0B1059 */ jal does_script_exist -/* 1771F0 80248910 00000000 */ nop -/* 1771F4 80248914 1440005B */ bnez $v0, .L80248A84 -/* 1771F8 80248918 00000000 */ nop -/* 1771FC 8024891C AE0001D4 */ sw $zero, 0x1d4($s0) -.L80248920: -/* 177200 80248920 8E4201D8 */ lw $v0, 0x1d8($s2) -/* 177204 80248924 10400005 */ beqz $v0, .L8024893C -/* 177208 80248928 00000000 */ nop -/* 17720C 8024892C 0C0B1059 */ jal does_script_exist -/* 177210 80248930 8E4401E8 */ lw $a0, 0x1e8($s2) -/* 177214 80248934 14400053 */ bnez $v0, .L80248A84 -/* 177218 80248938 00000000 */ nop -.L8024893C: -/* 17721C 8024893C 1220000A */ beqz $s1, .L80248968 -/* 177220 80248940 AE4001D8 */ sw $zero, 0x1d8($s2) -/* 177224 80248944 8E2201D8 */ lw $v0, 0x1d8($s1) -/* 177228 80248948 50400007 */ beql $v0, $zero, .L80248968 -/* 17722C 8024894C AE2001D8 */ sw $zero, 0x1d8($s1) -/* 177230 80248950 8E2401E8 */ lw $a0, 0x1e8($s1) -/* 177234 80248954 0C0B1059 */ jal does_script_exist -/* 177238 80248958 00000000 */ nop -/* 17723C 8024895C 14400049 */ bnez $v0, .L80248A84 -/* 177240 80248960 00000000 */ nop -/* 177244 80248964 AE2001D8 */ sw $zero, 0x1d8($s1) -.L80248968: -/* 177248 80248968 0000A02D */ daddu $s4, $zero, $zero -/* 17724C 8024896C 0280882D */ daddu $s1, $s4, $zero -/* 177250 80248970 0260902D */ daddu $s2, $s3, $zero -.L80248974: -/* 177254 80248974 8E5000E0 */ lw $s0, 0xe0($s2) -/* 177258 80248978 5200000B */ beql $s0, $zero, .L802489A8 -/* 17725C 8024897C 26310001 */ addiu $s1, $s1, 1 -/* 177260 80248980 8E0201D4 */ lw $v0, 0x1d4($s0) -/* 177264 80248984 50400008 */ beql $v0, $zero, .L802489A8 -/* 177268 80248988 26310001 */ addiu $s1, $s1, 1 -/* 17726C 8024898C 8E0401E4 */ lw $a0, 0x1e4($s0) -/* 177270 80248990 0C0B1059 */ jal does_script_exist -/* 177274 80248994 00000000 */ nop -/* 177278 80248998 50400002 */ beql $v0, $zero, .L802489A4 -/* 17727C 8024899C AE0001D4 */ sw $zero, 0x1d4($s0) -/* 177280 802489A0 24140001 */ addiu $s4, $zero, 1 -.L802489A4: -/* 177284 802489A4 26310001 */ addiu $s1, $s1, 1 -.L802489A8: -/* 177288 802489A8 2A220018 */ slti $v0, $s1, 0x18 -/* 17728C 802489AC 1440FFF1 */ bnez $v0, .L80248974 -/* 177290 802489B0 26520004 */ addiu $s2, $s2, 4 -/* 177294 802489B4 16800033 */ bnez $s4, .L80248A84 -/* 177298 802489B8 0000882D */ daddu $s1, $zero, $zero -/* 17729C 802489BC 0260902D */ daddu $s2, $s3, $zero -.L802489C0: -/* 1772A0 802489C0 8E5000E0 */ lw $s0, 0xe0($s2) -/* 1772A4 802489C4 5200000B */ beql $s0, $zero, .L802489F4 -/* 1772A8 802489C8 26310001 */ addiu $s1, $s1, 1 -/* 1772AC 802489CC 8E0201D8 */ lw $v0, 0x1d8($s0) -/* 1772B0 802489D0 50400008 */ beql $v0, $zero, .L802489F4 -/* 1772B4 802489D4 26310001 */ addiu $s1, $s1, 1 -/* 1772B8 802489D8 8E0401E8 */ lw $a0, 0x1e8($s0) -/* 1772BC 802489DC 0C0B1059 */ jal does_script_exist -/* 1772C0 802489E0 00000000 */ nop -/* 1772C4 802489E4 50400002 */ beql $v0, $zero, .L802489F0 -/* 1772C8 802489E8 AE0001D8 */ sw $zero, 0x1d8($s0) -/* 1772CC 802489EC 24140001 */ addiu $s4, $zero, 1 -.L802489F0: -/* 1772D0 802489F0 26310001 */ addiu $s1, $s1, 1 -.L802489F4: -/* 1772D4 802489F4 2A220018 */ slti $v0, $s1, 0x18 -/* 1772D8 802489F8 1440FFF1 */ bnez $v0, .L802489C0 -/* 1772DC 802489FC 26520004 */ addiu $s2, $s2, 4 -/* 1772E0 80248A00 16800020 */ bnez $s4, .L80248A84 -/* 1772E4 80248A04 0000882D */ daddu $s1, $zero, $zero -/* 1772E8 80248A08 3C06FFF7 */ lui $a2, 0xfff7 -/* 1772EC 80248A0C 34C6FFFF */ ori $a2, $a2, 0xffff -/* 1772F0 80248A10 0260282D */ daddu $a1, $s3, $zero -/* 1772F4 80248A14 3C02800E */ lui $v0, %hi(gBattleStatus) -/* 1772F8 80248A18 2442C070 */ addiu $v0, $v0, %lo(gBattleStatus) -/* 1772FC 80248A1C 8C430004 */ lw $v1, 4($v0) -/* 177300 80248A20 2404BFFF */ addiu $a0, $zero, -0x4001 -/* 177304 80248A24 00641824 */ and $v1, $v1, $a0 -/* 177308 80248A28 AC430004 */ sw $v1, 4($v0) -.L80248A2C: -/* 17730C 80248A2C 8CB000E0 */ lw $s0, 0xe0($a1) -/* 177310 80248A30 12000004 */ beqz $s0, .L80248A44 -/* 177314 80248A34 26310001 */ addiu $s1, $s1, 1 -/* 177318 80248A38 8E020000 */ lw $v0, ($s0) -/* 17731C 80248A3C 00461024 */ and $v0, $v0, $a2 -/* 177320 80248A40 AE020000 */ sw $v0, ($s0) -.L80248A44: -/* 177324 80248A44 2A220018 */ slti $v0, $s1, 0x18 -/* 177328 80248A48 1440FFF8 */ bnez $v0, .L80248A2C -/* 17732C 80248A4C 24A50004 */ addiu $a1, $a1, 4 -/* 177330 80248A50 8262008C */ lb $v0, 0x8c($s3) -/* 177334 80248A54 1440000B */ bnez $v0, .L80248A84 -/* 177338 80248A58 00000000 */ nop -/* 17733C 80248A5C 0C098D19 */ jal btl_check_player_defeated -/* 177340 80248A60 00000000 */ nop -/* 177344 80248A64 14400007 */ bnez $v0, .L80248A84 -/* 177348 80248A68 00000000 */ nop -/* 17734C 80248A6C 0C098D0D */ jal btl_check_enemies_defeated -/* 177350 80248A70 00000000 */ nop -/* 177354 80248A74 14400003 */ bnez $v0, .L80248A84 -/* 177358 80248A78 00000000 */ nop -/* 17735C 80248A7C 0C090464 */ jal btl_set_state -/* 177360 80248A80 24040005 */ addiu $a0, $zero, 5 -.L80248A84: -/* 177364 80248A84 8FBF0024 */ lw $ra, 0x24($sp) -/* 177368 80248A88 8FB40020 */ lw $s4, 0x20($sp) -/* 17736C 80248A8C 8FB3001C */ lw $s3, 0x1c($sp) -/* 177370 80248A90 8FB20018 */ lw $s2, 0x18($sp) -/* 177374 80248A94 8FB10014 */ lw $s1, 0x14($sp) -/* 177378 80248A98 8FB00010 */ lw $s0, 0x10($sp) -/* 17737C 80248A9C 03E00008 */ jr $ra -/* 177380 80248AA0 27BD0028 */ addiu $sp, $sp, 0x28 diff --git a/ver/us/asm/nonmatchings/16F740/btl_state_update_normal_start.s b/ver/us/asm/nonmatchings/16F740/btl_state_update_normal_start.s deleted file mode 100644 index 83651cfddc..0000000000 --- a/ver/us/asm/nonmatchings/16F740/btl_state_update_normal_start.s +++ /dev/null @@ -1,613 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel jtbl_8029CA88 -.word .L802412B4_16FB94, .L80241590_16FE70, .L80241A88_170368, .L80241A88_170368, .L802417DC_1700BC, .L80241A88_170368, .L80241A88_170368, .L802419CC_1702AC, .L80241A64_170344 - -.section .text - -glabel btl_state_update_normal_start -/* 16FAF8 80241218 27BDFFB8 */ addiu $sp, $sp, -0x48 -/* 16FAFC 8024121C AFB60038 */ sw $s6, 0x38($sp) -/* 16FB00 80241220 3C16800E */ lui $s6, %hi(D_800DC4FC) -/* 16FB04 80241224 8ED6C4FC */ lw $s6, %lo(D_800DC4FC)($s6) -/* 16FB08 80241228 3C02800E */ lui $v0, %hi(D_800DC4F4) -/* 16FB0C 8024122C 8C42C4F4 */ lw $v0, %lo(D_800DC4F4)($v0) -/* 16FB10 80241230 AFB40030 */ sw $s4, 0x30($sp) -/* 16FB14 80241234 3C14800E */ lui $s4, %hi(gBattleStatus) -/* 16FB18 80241238 2694C070 */ addiu $s4, $s4, %lo(gBattleStatus) -/* 16FB1C 8024123C AFBE0040 */ sw $fp, 0x40($sp) -/* 16FB20 80241240 3C1E800B */ lui $fp, %hi(gCurrentEncounter) -/* 16FB24 80241244 27DE0F10 */ addiu $fp, $fp, %lo(gCurrentEncounter) -/* 16FB28 80241248 AFBF0044 */ sw $ra, 0x44($sp) -/* 16FB2C 8024124C AFB7003C */ sw $s7, 0x3c($sp) -/* 16FB30 80241250 AFB50034 */ sw $s5, 0x34($sp) -/* 16FB34 80241254 AFB3002C */ sw $s3, 0x2c($sp) -/* 16FB38 80241258 AFB20028 */ sw $s2, 0x28($sp) -/* 16FB3C 8024125C AFB10024 */ sw $s1, 0x24($sp) -/* 16FB40 80241260 10400002 */ beqz $v0, .L8024126C -/* 16FB44 80241264 AFB00020 */ sw $s0, 0x20($sp) -/* 16FB48 80241268 0040B02D */ daddu $s6, $v0, $zero -.L8024126C: -/* 16FB4C 8024126C 3C04800E */ lui $a0, %hi(D_800DC064) -/* 16FB50 80241270 8C84C064 */ lw $a0, %lo(D_800DC064)($a0) -/* 16FB54 80241274 14800003 */ bnez $a0, .L80241284 -/* 16FB58 80241278 00000000 */ nop -/* 16FB5C 8024127C 080904A2 */ j .L80241288 -/* 16FB60 80241280 8ED5000C */ lw $s5, 0xc($s6) -.L80241284: -/* 16FB64 80241284 8C950004 */ lw $s5, 4($a0) -.L80241288: -/* 16FB68 80241288 3C03800E */ lui $v1, %hi(gBattleState2) -/* 16FB6C 8024128C 8C63C4DC */ lw $v1, %lo(gBattleState2)($v1) -/* 16FB70 80241290 2C620009 */ sltiu $v0, $v1, 9 -/* 16FB74 80241294 104001FC */ beqz $v0, .L80241A88_170368 -/* 16FB78 80241298 AE950438 */ sw $s5, 0x438($s4) -/* 16FB7C 8024129C 00031080 */ sll $v0, $v1, 2 -/* 16FB80 802412A0 3C01802A */ lui $at, %hi(jtbl_8029CA88) -/* 16FB84 802412A4 00220821 */ addu $at, $at, $v0 -/* 16FB88 802412A8 8C22CA88 */ lw $v0, %lo(jtbl_8029CA88)($at) -/* 16FB8C 802412AC 00400008 */ jr $v0 -/* 16FB90 802412B0 00000000 */ nop -.L802412B4_16FB94: -/* 16FB94 802412B4 3C05BF80 */ lui $a1, 0xbf80 -/* 16FB98 802412B8 8EC20004 */ lw $v0, 4($s6) -/* 16FB9C 802412BC 3C01802A */ lui $at, %hi(D_8029F240) -/* 16FBA0 802412C0 AC22F240 */ sw $v0, %lo(D_8029F240)($at) -/* 16FBA4 802412C4 0C04DF69 */ jal set_screen_overlay_params_back -/* 16FBA8 802412C8 240400FF */ addiu $a0, $zero, 0xff -/* 16FBAC 802412CC 8EA40004 */ lw $a0, 4($s5) -/* 16FBB0 802412D0 0C016B3A */ jal load_asset_by_name -/* 16FBB4 802412D4 27A50018 */ addiu $a1, $sp, 0x18 -/* 16FBB8 802412D8 0040802D */ daddu $s0, $v0, $zero -/* 16FBBC 802412DC 3C058021 */ lui $a1, %hi(D_80210000) -/* 16FBC0 802412E0 24A50000 */ addiu $a1, $a1, %lo(D_80210000) -/* 16FBC4 802412E4 0C01BB7C */ jal decode_yay0 -/* 16FBC8 802412E8 0200202D */ daddu $a0, $s0, $zero -/* 16FBCC 802412EC 0C00AB1E */ jal general_heap_free -/* 16FBD0 802412F0 0200202D */ daddu $a0, $s0, $zero -/* 16FBD4 802412F4 8FA30018 */ lw $v1, 0x18($sp) -/* 16FBD8 802412F8 34028000 */ ori $v0, $zero, 0x8000 -/* 16FBDC 802412FC 0043102A */ slt $v0, $v0, $v1 -/* 16FBE0 80241300 10400003 */ beqz $v0, .L80241310 -/* 16FBE4 80241304 00000000 */ nop -.L80241308: -/* 16FBE8 80241308 080904C2 */ j .L80241308 -/* 16FBEC 8024130C 00000000 */ nop -.L80241310: -/* 16FBF0 80241310 8EA40000 */ lw $a0, ($s5) -/* 16FBF4 80241314 3C108021 */ lui $s0, 0x8021 -/* 16FBF8 80241318 8E100000 */ lw $s0, ($s0) -/* 16FBFC 8024131C 0C016B74 */ jal get_asset_offset -/* 16FC00 80241320 27A50018 */ addiu $a1, $sp, 0x18 -/* 16FC04 80241324 12000004 */ beqz $s0, .L80241338 -/* 16FC08 80241328 0200202D */ daddu $a0, $s0, $zero -/* 16FC0C 8024132C 8FA60018 */ lw $a2, 0x18($sp) -/* 16FC10 80241330 0C046B52 */ jal load_data_for_models -/* 16FC14 80241334 0040282D */ daddu $a1, $v0, $zero -.L80241338: -/* 16FC18 80241338 8EA40008 */ lw $a0, 8($s5) -/* 16FC1C 8024133C 0C016C68 */ jal load_battle_hit_asset -/* 16FC20 80241340 00000000 */ nop -/* 16FC24 80241344 8EA40014 */ lw $a0, 0x14($s5) -/* 16FC28 80241348 10800007 */ beqz $a0, .L80241368 -/* 16FC2C 8024134C 00000000 */ nop -/* 16FC30 80241350 0C05175C */ jal load_map_bg -/* 16FC34 80241354 00000000 */ nop -/* 16FC38 80241358 3C048020 */ lui $a0, %hi(func_80200000) -/* 16FC3C 8024135C 24840000 */ addiu $a0, $a0, %lo(func_80200000) -/* 16FC40 80241360 0C05178A */ jal read_background_size -/* 16FC44 80241364 00000000 */ nop -.L80241368: -/* 16FC48 80241368 3C028007 */ lui $v0, %hi(gGameStatusPtr) -/* 16FC4C 8024136C 8C42419C */ lw $v0, %lo(gGameStatusPtr)($v0) -/* 16FC50 80241370 904200AA */ lbu $v0, 0xaa($v0) -/* 16FC54 80241374 30420001 */ andi $v0, $v0, 1 -/* 16FC58 80241378 10400005 */ beqz $v0, .L80241390 -/* 16FC5C 8024137C 00000000 */ nop -/* 16FC60 80241380 3C013F80 */ lui $at, 0x3f80 -/* 16FC64 80241384 44816000 */ mtc1 $at, $f12 -/* 16FC68 80241388 0C00AFB7 */ jal set_curtain_scale_goal -/* 16FC6C 8024138C 00000000 */ nop -.L80241390: -/* 16FC70 80241390 3C05800B */ lui $a1, %hi(gCameras) -/* 16FC74 80241394 24A51D80 */ addiu $a1, $a1, %lo(gCameras) -/* 16FC78 80241398 94A20000 */ lhu $v0, ($a1) -/* 16FC7C 8024139C 24040006 */ addiu $a0, $zero, 6 -/* 16FC80 802413A0 AE8000BC */ sw $zero, 0xbc($s4) -/* 16FC84 802413A4 AE8000C4 */ sw $zero, 0xc4($s4) -/* 16FC88 802413A8 A6800090 */ sh $zero, 0x90($s4) -/* 16FC8C 802413AC AE8000B4 */ sw $zero, 0xb4($s4) -/* 16FC90 802413B0 AE8000B8 */ sw $zero, 0xb8($s4) -/* 16FC94 802413B4 A2800048 */ sb $zero, 0x48($s4) -/* 16FC98 802413B8 A2800049 */ sb $zero, 0x49($s4) -/* 16FC9C 802413BC A280004A */ sb $zero, 0x4a($s4) -/* 16FCA0 802413C0 A280004B */ sb $zero, 0x4b($s4) -/* 16FCA4 802413C4 A2800078 */ sb $zero, 0x78($s4) -/* 16FCA8 802413C8 A2800079 */ sb $zero, 0x79($s4) -/* 16FCAC 802413CC A280007A */ sb $zero, 0x7a($s4) -/* 16FCB0 802413D0 A280007B */ sb $zero, 0x7b($s4) -/* 16FCB4 802413D4 A280008A */ sb $zero, 0x8a($s4) -/* 16FCB8 802413D8 A2800083 */ sb $zero, 0x83($s4) -/* 16FCBC 802413DC 94A30AB0 */ lhu $v1, 0xab0($a1) -/* 16FCC0 802413E0 34420002 */ ori $v0, $v0, 2 -/* 16FCC4 802413E4 A4A20000 */ sh $v0, ($a1) -/* 16FCC8 802413E8 94A20558 */ lhu $v0, 0x558($a1) -/* 16FCCC 802413EC 34630002 */ ori $v1, $v1, 2 -/* 16FCD0 802413F0 A4A30AB0 */ sh $v1, 0xab0($a1) -/* 16FCD4 802413F4 34420002 */ ori $v0, $v0, 2 -/* 16FCD8 802413F8 0C03A752 */ jal is_ability_active -/* 16FCDC 802413FC A4A20558 */ sh $v0, 0x558($a1) -/* 16FCE0 80241400 10400002 */ beqz $v0, .L8024140C -/* 16FCE4 80241404 24020001 */ addiu $v0, $zero, 1 -/* 16FCE8 80241408 A2820083 */ sb $v0, 0x83($s4) -.L8024140C: -/* 16FCEC 8024140C 2405FFFF */ addiu $a1, $zero, -1 -/* 16FCF0 80241410 2402FFFF */ addiu $v0, $zero, -1 -/* 16FCF4 80241414 3C06800E */ lui $a2, %hi(gBattleStatus) -/* 16FCF8 80241418 24C6C070 */ addiu $a2, $a2, %lo(gBattleStatus) -/* 16FCFC 8024141C A2800081 */ sb $zero, 0x81($s4) -/* 16FD00 80241420 A2800082 */ sb $zero, 0x82($s4) -/* 16FD04 80241424 A6850070 */ sh $a1, 0x70($s4) -/* 16FD08 80241428 AE820074 */ sw $v0, 0x74($s4) -/* 16FD0C 8024142C A2800088 */ sb $zero, 0x88($s4) -/* 16FD10 80241430 A2800096 */ sb $zero, 0x96($s4) -/* 16FD14 80241434 A2800097 */ sb $zero, 0x97($s4) -/* 16FD18 80241438 A2800098 */ sb $zero, 0x98($s4) -/* 16FD1C 8024143C A2800089 */ sb $zero, 0x89($s4) -/* 16FD20 80241440 8CC20004 */ lw $v0, 4($a2) -/* 16FD24 80241444 83C30011 */ lb $v1, 0x11($fp) -/* 16FD28 80241448 34440020 */ ori $a0, $v0, 0x20 -/* 16FD2C 8024144C 10600004 */ beqz $v1, .L80241460 -/* 16FD30 80241450 ACC40004 */ sw $a0, 4($a2) -/* 16FD34 80241454 2402FFDF */ addiu $v0, $zero, -0x21 -/* 16FD38 80241458 00821024 */ and $v0, $a0, $v0 -/* 16FD3C 8024145C ACC20004 */ sw $v0, 4($a2) -.L80241460: -/* 16FD40 80241460 2411000F */ addiu $s1, $zero, 0xf -/* 16FD44 80241464 2684003C */ addiu $a0, $s4, 0x3c -/* 16FD48 80241468 2402000A */ addiu $v0, $zero, 0xa -/* 16FD4C 8024146C A282008D */ sb $v0, 0x8d($s4) -/* 16FD50 80241470 240200FF */ addiu $v0, $zero, 0xff -/* 16FD54 80241474 A2800095 */ sb $zero, 0x95($s4) -/* 16FD58 80241478 A28500AE */ sb $a1, 0xae($s4) -/* 16FD5C 8024147C A28500AF */ sb $a1, 0xaf($s4) -/* 16FD60 80241480 A28500B0 */ sb $a1, 0xb0($s4) -/* 16FD64 80241484 A280009A */ sb $zero, 0x9a($s4) -/* 16FD68 80241488 A280009D */ sb $zero, 0x9d($s4) -/* 16FD6C 8024148C A280009E */ sb $zero, 0x9e($s4) -/* 16FD70 80241490 AE8000A0 */ sw $zero, 0xa0($s4) -/* 16FD74 80241494 A28000A4 */ sb $zero, 0xa4($s4) -/* 16FD78 80241498 A28000A5 */ sb $zero, 0xa5($s4) -/* 16FD7C 8024149C AE8000A8 */ sw $zero, 0xa8($s4) -/* 16FD80 802414A0 A2800092 */ sb $zero, 0x92($s4) -/* 16FD84 802414A4 A280009B */ sb $zero, 0x9b($s4) -/* 16FD88 802414A8 A280009C */ sb $zero, 0x9c($s4) -/* 16FD8C 802414AC A280008C */ sb $zero, 0x8c($s4) -/* 16FD90 802414B0 A28000AC */ sb $zero, 0xac($s4) -/* 16FD94 802414B4 A28000AD */ sb $zero, 0xad($s4) -/* 16FD98 802414B8 A2800432 */ sb $zero, 0x432($s4) -/* 16FD9C 802414BC A2820433 */ sb $v0, 0x433($s4) -/* 16FDA0 802414C0 A280008B */ sb $zero, 0x8b($s4) -/* 16FDA4 802414C4 A2800093 */ sb $zero, 0x93($s4) -/* 16FDA8 802414C8 A2800094 */ sb $zero, 0x94($s4) -/* 16FDAC 802414CC 8CC20004 */ lw $v0, 4($a2) -/* 16FDB0 802414D0 2403FFFD */ addiu $v1, $zero, -3 -/* 16FDB4 802414D4 00431024 */ and $v0, $v0, $v1 -/* 16FDB8 802414D8 2403FFFB */ addiu $v1, $zero, -5 -/* 16FDBC 802414DC 00431024 */ and $v0, $v0, $v1 -/* 16FDC0 802414E0 2403FFF7 */ addiu $v1, $zero, -9 -/* 16FDC4 802414E4 00431024 */ and $v0, $v0, $v1 -/* 16FDC8 802414E8 2403FFEF */ addiu $v1, $zero, -0x11 -/* 16FDCC 802414EC 00431024 */ and $v0, $v0, $v1 -/* 16FDD0 802414F0 2403FEFF */ addiu $v1, $zero, -0x101 -/* 16FDD4 802414F4 00431024 */ and $v0, $v0, $v1 -/* 16FDD8 802414F8 2403FDFF */ addiu $v1, $zero, -0x201 -/* 16FDDC 802414FC 00431024 */ and $v0, $v0, $v1 -/* 16FDE0 80241500 ACC20004 */ sw $v0, 4($a2) -.L80241504: -/* 16FDE4 80241504 AC800008 */ sw $zero, 8($a0) -/* 16FDE8 80241508 2631FFFF */ addiu $s1, $s1, -1 -/* 16FDEC 8024150C 0621FFFD */ bgez $s1, .L80241504 -/* 16FDF0 80241510 2484FFFC */ addiu $a0, $a0, -4 -/* 16FDF4 80241514 3C03000F */ lui $v1, 0xf -/* 16FDF8 80241518 3463EF3F */ ori $v1, $v1, 0xef3f -/* 16FDFC 8024151C 44800000 */ mtc1 $zero, $f0 -/* 16FE00 80241520 0000202D */ daddu $a0, $zero, $zero -/* 16FE04 80241524 44050000 */ mfc1 $a1, $f0 -/* 16FE08 80241528 240200FF */ addiu $v0, $zero, 0xff -/* 16FE0C 8024152C 3C018028 */ lui $at, %hi(D_80280A30) -/* 16FE10 80241530 AC220A30 */ sw $v0, %lo(D_80280A30)($at) -/* 16FE14 80241534 AE830224 */ sw $v1, 0x224($s4) -/* 16FE18 80241538 AFA00014 */ sw $zero, 0x14($sp) -/* 16FE1C 8024153C 00A0302D */ daddu $a2, $a1, $zero -/* 16FE20 80241540 00A0382D */ daddu $a3, $a1, $zero -/* 16FE24 80241544 0C01CA0C */ jal fx_partner_buff -/* 16FE28 80241548 AFA50010 */ sw $a1, 0x10($sp) -/* 16FE2C 8024154C 0C03A604 */ jal func_800E9810 -/* 16FE30 80241550 AE82043C */ sw $v0, 0x43c($s4) -/* 16FE34 80241554 3C048028 */ lui $a0, %hi(D_80280EB8) -/* 16FE38 80241558 24840EB8 */ addiu $a0, $a0, %lo(D_80280EB8) -/* 16FE3C 8024155C 2405000A */ addiu $a1, $zero, 0xa -/* 16FE40 80241560 24100001 */ addiu $s0, $zero, 1 -/* 16FE44 80241564 3C018007 */ lui $at, %hi(gCurrentCameraID) -/* 16FE48 80241568 AC307410 */ sw $s0, %lo(gCurrentCameraID)($at) -/* 16FE4C 8024156C 0C0B0CF8 */ jal start_script -/* 16FE50 80241570 0000302D */ daddu $a2, $zero, $zero -/* 16FE54 80241574 0040182D */ daddu $v1, $v0, $zero -/* 16FE58 80241578 AE8300C4 */ sw $v1, 0xc4($s4) -/* 16FE5C 8024157C 8C620144 */ lw $v0, 0x144($v1) -/* 16FE60 80241580 3C01800E */ lui $at, %hi(gBattleState2) -/* 16FE64 80241584 AC30C4DC */ sw $s0, %lo(gBattleState2)($at) -/* 16FE68 80241588 080906A2 */ j .L80241A88_170368 -/* 16FE6C 8024158C AE8200C8 */ sw $v0, 0xc8($s4) -.L80241590_16FE70: -/* 16FE70 80241590 8E8400C8 */ lw $a0, 0xc8($s4) -/* 16FE74 80241594 0C0B1059 */ jal does_script_exist -/* 16FE78 80241598 00000000 */ nop -/* 16FE7C 8024159C 1440013A */ bnez $v0, .L80241A88_170368 -/* 16FE80 802415A0 00000000 */ nop -/* 16FE84 802415A4 8EA4000C */ lw $a0, 0xc($s5) -/* 16FE88 802415A8 10800009 */ beqz $a0, .L802415D0 -/* 16FE8C 802415AC 24110017 */ addiu $s1, $zero, 0x17 -/* 16FE90 802415B0 2405000A */ addiu $a1, $zero, 0xa -/* 16FE94 802415B4 0C0B0CF8 */ jal start_script -/* 16FE98 802415B8 0000302D */ daddu $a2, $zero, $zero -/* 16FE9C 802415BC 0040182D */ daddu $v1, $v0, $zero -/* 16FEA0 802415C0 AE8300BC */ sw $v1, 0xbc($s4) -/* 16FEA4 802415C4 8C620144 */ lw $v0, 0x144($v1) -/* 16FEA8 802415C8 AE8200C0 */ sw $v0, 0xc0($s4) -/* 16FEAC 802415CC 24110017 */ addiu $s1, $zero, 0x17 -.L802415D0: -/* 16FEB0 802415D0 3C04800E */ lui $a0, %hi(gBattleStatus) -/* 16FEB4 802415D4 2484C070 */ addiu $a0, $a0, %lo(gBattleStatus) -/* 16FEB8 802415D8 2685005C */ addiu $a1, $s4, 0x5c -/* 16FEBC 802415DC 8C830000 */ lw $v1, ($a0) -/* 16FEC0 802415E0 3C028011 */ lui $v0, %hi(gUIStatus) -/* 16FEC4 802415E4 2442EF58 */ addiu $v0, $v0, %lo(gUIStatus) -/* 16FEC8 802415E8 A040003A */ sb $zero, 0x3a($v0) -/* 16FECC 802415EC 34630001 */ ori $v1, $v1, 1 -/* 16FED0 802415F0 AC830000 */ sw $v1, ($a0) -.L802415F4: -/* 16FED4 802415F4 ACA000E0 */ sw $zero, 0xe0($a1) -/* 16FED8 802415F8 2631FFFF */ addiu $s1, $s1, -1 -/* 16FEDC 802415FC 0621FFFD */ bgez $s1, .L802415F4 -/* 16FEE0 80241600 24A5FFFC */ addiu $a1, $a1, -4 -/* 16FEE4 80241604 A280008E */ sb $zero, 0x8e($s4) -/* 16FEE8 80241608 3C02802A */ lui $v0, %hi(D_8029F240) -/* 16FEEC 8024160C 8C42F240 */ lw $v0, %lo(D_8029F240)($v0) -/* 16FEF0 80241610 18400029 */ blez $v0, .L802416B8 -/* 16FEF4 80241614 0000882D */ daddu $s1, $zero, $zero -/* 16FEF8 80241618 2417FFFF */ addiu $s7, $zero, -1 -/* 16FEFC 8024161C 0280982D */ daddu $s3, $s4, $zero -/* 16FF00 80241620 0220902D */ daddu $s2, $s1, $zero -.L80241624: -/* 16FF04 80241624 8EC40008 */ lw $a0, 8($s6) -/* 16FF08 80241628 0C0994E9 */ jal create_actor -/* 16FF0C 8024162C 00922021 */ addu $a0, $a0, $s2 -/* 16FF10 80241630 3C048028 */ lui $a0, %hi(D_80281454) -/* 16FF14 80241634 24841454 */ addiu $a0, $a0, %lo(D_80281454) -/* 16FF18 80241638 8E7000E0 */ lw $s0, 0xe0($s3) -.L8024163C: -/* 16FF1C 8024163C 8C830000 */ lw $v1, ($a0) -/* 16FF20 80241640 10770006 */ beq $v1, $s7, .L8024165C -/* 16FF24 80241644 00000000 */ nop -/* 16FF28 80241648 92020136 */ lbu $v0, 0x136($s0) -/* 16FF2C 8024164C 10430006 */ beq $v0, $v1, .L80241668 -/* 16FF30 80241650 24840004 */ addiu $a0, $a0, 4 -/* 16FF34 80241654 0809058F */ j .L8024163C -/* 16FF38 80241658 00000000 */ nop -.L8024165C: -/* 16FF3C 8024165C 9282008E */ lbu $v0, 0x8e($s4) -/* 16FF40 80241660 24420001 */ addiu $v0, $v0, 1 -/* 16FF44 80241664 A282008E */ sb $v0, 0x8e($s4) -.L80241668: -/* 16FF48 80241668 1620000C */ bnez $s1, .L8024169C -/* 16FF4C 8024166C A2000208 */ sb $zero, 0x208($s0) -/* 16FF50 80241670 93C20010 */ lbu $v0, 0x10($fp) -/* 16FF54 80241674 A2020208 */ sb $v0, 0x208($s0) -/* 16FF58 80241678 83C300A0 */ lb $v1, 0xa0($fp) -/* 16FF5C 8024167C 24020004 */ addiu $v0, $zero, 4 -/* 16FF60 80241680 54620007 */ bnel $v1, $v0, .L802416A0 -/* 16FF64 80241684 26730004 */ addiu $s3, $s3, 4 -/* 16FF68 80241688 0200202D */ daddu $a0, $s0, $zero -/* 16FF6C 8024168C 0040282D */ daddu $a1, $v0, $zero -/* 16FF70 80241690 87C700A2 */ lh $a3, 0xa2($fp) -/* 16FF74 80241694 0C099B3C */ jal inflict_status_set_duration -/* 16FF78 80241698 24060024 */ addiu $a2, $zero, 0x24 -.L8024169C: -/* 16FF7C 8024169C 26730004 */ addiu $s3, $s3, 4 -.L802416A0: -/* 16FF80 802416A0 3C02802A */ lui $v0, %hi(D_8029F240) -/* 16FF84 802416A4 8C42F240 */ lw $v0, %lo(D_8029F240)($v0) -/* 16FF88 802416A8 26310001 */ addiu $s1, $s1, 1 -/* 16FF8C 802416AC 0222102A */ slt $v0, $s1, $v0 -/* 16FF90 802416B0 1440FFDC */ bnez $v0, .L80241624 -/* 16FF94 802416B4 2652001C */ addiu $s2, $s2, 0x1c -.L802416B8: -/* 16FF98 802416B8 8EA2001C */ lw $v0, 0x1c($s5) -/* 16FF9C 802416BC 1040002C */ beqz $v0, .L80241770 -/* 16FFA0 802416C0 00000000 */ nop -/* 16FFA4 802416C4 8EA40024 */ lw $a0, 0x24($s5) -/* 16FFA8 802416C8 10800007 */ beqz $a0, .L802416E8 -/* 16FFAC 802416CC 00000000 */ nop -/* 16FFB0 802416D0 18800027 */ blez $a0, .L80241770 -/* 16FFB4 802416D4 00000000 */ nop -/* 16FFB8 802416D8 0C00A67F */ jal rand_int -/* 16FFBC 802416DC 00000000 */ nop -/* 16FFC0 802416E0 14400023 */ bnez $v0, .L80241770 -/* 16FFC4 802416E4 00000000 */ nop -.L802416E8: -/* 16FFC8 802416E8 3C02802A */ lui $v0, %hi(D_8029F240) -/* 16FFCC 802416EC 2442F240 */ addiu $v0, $v0, %lo(D_8029F240) -/* 16FFD0 802416F0 8C430000 */ lw $v1, ($v0) -/* 16FFD4 802416F4 8EA4001C */ lw $a0, 0x1c($s5) -/* 16FFD8 802416F8 00641821 */ addu $v1, $v1, $a0 -/* 16FFDC 802416FC AC430000 */ sw $v1, ($v0) -/* 16FFE0 80241700 0223182A */ slt $v1, $s1, $v1 -/* 16FFE4 80241704 1060001A */ beqz $v1, .L80241770 -/* 16FFE8 80241708 24160004 */ addiu $s6, $zero, 4 -/* 16FFEC 8024170C 0000982D */ daddu $s3, $zero, $zero -/* 16FFF0 80241710 00111080 */ sll $v0, $s1, 2 -/* 16FFF4 80241714 00549021 */ addu $s2, $v0, $s4 -.L80241718: -/* 16FFF8 80241718 8EA40020 */ lw $a0, 0x20($s5) -/* 16FFFC 8024171C 0C0994E9 */ jal create_actor -/* 170000 80241720 00932021 */ addu $a0, $a0, $s3 -/* 170004 80241724 8E5000E0 */ lw $s0, 0xe0($s2) -/* 170008 80241728 1620000A */ bnez $s1, .L80241754 -/* 17000C 8024172C A2000208 */ sb $zero, 0x208($s0) -/* 170010 80241730 A2000208 */ sb $zero, 0x208($s0) -/* 170014 80241734 83C200A0 */ lb $v0, 0xa0($fp) -/* 170018 80241738 54560007 */ bnel $v0, $s6, .L80241758 -/* 17001C 8024173C 26520004 */ addiu $s2, $s2, 4 -/* 170020 80241740 0200202D */ daddu $a0, $s0, $zero -/* 170024 80241744 24050004 */ addiu $a1, $zero, 4 -/* 170028 80241748 87C700A2 */ lh $a3, 0xa2($fp) -/* 17002C 8024174C 0C099B3C */ jal inflict_status_set_duration -/* 170030 80241750 24060024 */ addiu $a2, $zero, 0x24 -.L80241754: -/* 170034 80241754 26520004 */ addiu $s2, $s2, 4 -.L80241758: -/* 170038 80241758 26310001 */ addiu $s1, $s1, 1 -/* 17003C 8024175C 3C02802A */ lui $v0, %hi(D_8029F240) -/* 170040 80241760 8C42F240 */ lw $v0, %lo(D_8029F240)($v0) -/* 170044 80241764 0222102A */ slt $v0, $s1, $v0 -/* 170048 80241768 1440FFEB */ bnez $v0, .L80241718 -/* 17004C 8024176C 2673001C */ addiu $s3, $s3, 0x1c -.L80241770: -/* 170050 80241770 0C099129 */ jal load_player_actor -/* 170054 80241774 00000000 */ nop -/* 170058 80241778 3C02800E */ lui $v0, %hi(gBattleStatus+0x4) -/* 17005C 8024177C 8C42C074 */ lw $v0, %lo(gBattleStatus+0x4)($v0) -/* 170060 80241780 8E9000D8 */ lw $s0, 0xd8($s4) -/* 170064 80241784 30420040 */ andi $v0, $v0, 0x40 -/* 170068 80241788 3C048028 */ lui $a0, %hi(D_80284A20) -/* 17006C 8024178C 24844A20 */ addiu $a0, $a0, %lo(D_80284A20) -/* 170070 80241790 10400003 */ beqz $v0, .L802417A0 -/* 170074 80241794 2405000A */ addiu $a1, $zero, 0xa -/* 170078 80241798 3C048028 */ lui $a0, %hi(D_80284A30) -/* 17007C 8024179C 24844A30 */ addiu $a0, $a0, %lo(D_80284A30) -.L802417A0: -/* 170080 802417A0 0C0B0CF8 */ jal start_script -/* 170084 802417A4 0000302D */ daddu $a2, $zero, $zero -/* 170088 802417A8 0040182D */ daddu $v1, $v0, $zero -/* 17008C 802417AC AE0301D4 */ sw $v1, 0x1d4($s0) -/* 170090 802417B0 8C620144 */ lw $v0, 0x144($v1) -/* 170094 802417B4 AE0201E4 */ sw $v0, 0x1e4($s0) -/* 170098 802417B8 0C0992DD */ jal load_partner_actor -/* 17009C 802417BC AC600148 */ sw $zero, 0x148($v1) -/* 1700A0 802417C0 24020004 */ addiu $v0, $zero, 4 -/* 1700A4 802417C4 3C01800E */ lui $at, %hi(gBattleState2) -/* 1700A8 802417C8 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -/* 1700AC 802417CC 080906A2 */ j .L80241A88_170368 -/* 1700B0 802417D0 00000000 */ nop -.L802417D4: -/* 1700B4 802417D4 08090608 */ j .L80241820 -/* 1700B8 802417D8 24130001 */ addiu $s3, $zero, 1 -.L802417DC_1700BC: -/* 1700BC 802417DC 0000882D */ daddu $s1, $zero, $zero -/* 1700C0 802417E0 3C02802A */ lui $v0, %hi(D_8029F240) -/* 1700C4 802417E4 8C42F240 */ lw $v0, %lo(D_8029F240)($v0) -/* 1700C8 802417E8 1840000D */ blez $v0, .L80241820 -/* 1700CC 802417EC 0220982D */ daddu $s3, $s1, $zero -/* 1700D0 802417F0 0280902D */ daddu $s2, $s4, $zero -.L802417F4: -/* 1700D4 802417F4 8E5000E0 */ lw $s0, 0xe0($s2) -/* 1700D8 802417F8 0C0B1059 */ jal does_script_exist -/* 1700DC 802417FC 8E0401E4 */ lw $a0, 0x1e4($s0) -/* 1700E0 80241800 1440FFF4 */ bnez $v0, .L802417D4 -/* 1700E4 80241804 26520004 */ addiu $s2, $s2, 4 -/* 1700E8 80241808 3C02802A */ lui $v0, %hi(D_8029F240) -/* 1700EC 8024180C 8C42F240 */ lw $v0, %lo(D_8029F240)($v0) -/* 1700F0 80241810 26310001 */ addiu $s1, $s1, 1 -/* 1700F4 80241814 0222102A */ slt $v0, $s1, $v0 -/* 1700F8 80241818 1440FFF6 */ bnez $v0, .L802417F4 -/* 1700FC 8024181C AE0001D4 */ sw $zero, 0x1d4($s0) -.L80241820: -/* 170100 80241820 16600099 */ bnez $s3, .L80241A88_170368 -/* 170104 80241824 00000000 */ nop -/* 170108 80241828 8E9000D8 */ lw $s0, 0xd8($s4) -/* 17010C 8024182C 0C0B1059 */ jal does_script_exist -/* 170110 80241830 8E0401E4 */ lw $a0, 0x1e4($s0) -/* 170114 80241834 14400094 */ bnez $v0, .L80241A88_170368 -/* 170118 80241838 00000000 */ nop -/* 17011C 8024183C AE0001D4 */ sw $zero, 0x1d4($s0) -/* 170120 80241840 8E9000DC */ lw $s0, 0xdc($s4) -/* 170124 80241844 12000006 */ beqz $s0, .L80241860 -/* 170128 80241848 00000000 */ nop -/* 17012C 8024184C 0C0B1059 */ jal does_script_exist -/* 170130 80241850 8E0401E4 */ lw $a0, 0x1e4($s0) -/* 170134 80241854 1440008C */ bnez $v0, .L80241A88_170368 -/* 170138 80241858 00000000 */ nop -/* 17013C 8024185C AE0001D4 */ sw $zero, 0x1d4($s0) -.L80241860: -/* 170140 80241860 8EC40010 */ lw $a0, 0x10($s6) -/* 170144 80241864 10800007 */ beqz $a0, .L80241884 -/* 170148 80241868 2405000A */ addiu $a1, $zero, 0xa -/* 17014C 8024186C 0C0B0CF8 */ jal start_script -/* 170150 80241870 0000302D */ daddu $a2, $zero, $zero -/* 170154 80241874 0040182D */ daddu $v1, $v0, $zero -/* 170158 80241878 AE8300BC */ sw $v1, 0xbc($s4) -/* 17015C 8024187C 8C620144 */ lw $v0, 0x144($v1) -/* 170160 80241880 AE8200C0 */ sw $v0, 0xc0($s4) -.L80241884: -/* 170164 80241884 82820432 */ lb $v0, 0x432($s4) -/* 170168 80241888 18400008 */ blez $v0, .L802418AC -/* 17016C 8024188C 24040001 */ addiu $a0, $zero, 1 -/* 170170 80241890 0000282D */ daddu $a1, $zero, $zero -/* 170174 80241894 00A0302D */ daddu $a2, $a1, $zero -/* 170178 80241898 0C04DF84 */ jal set_screen_overlay_color -/* 17017C 8024189C 00A0382D */ daddu $a3, $a1, $zero -/* 170180 802418A0 3C054357 */ lui $a1, 0x4357 -/* 170184 802418A4 0C04DF69 */ jal set_screen_overlay_params_back -/* 170188 802418A8 0000202D */ daddu $a0, $zero, $zero -.L802418AC: -/* 17018C 802418AC 0C03A752 */ jal is_ability_active -/* 170190 802418B0 24040011 */ addiu $a0, $zero, 0x11 -/* 170194 802418B4 10400004 */ beqz $v0, .L802418C8 -/* 170198 802418B8 24020002 */ addiu $v0, $zero, 2 -/* 17019C 802418BC 83C30004 */ lb $v1, 4($fp) -/* 1701A0 802418C0 50620001 */ beql $v1, $v0, .L802418C8 -/* 1701A4 802418C4 A3C00004 */ sb $zero, 4($fp) -.L802418C8: -/* 1701A8 802418C8 83C30004 */ lb $v1, 4($fp) -/* 1701AC 802418CC 24020001 */ addiu $v0, $zero, 1 -/* 1701B0 802418D0 10620005 */ beq $v1, $v0, .L802418E8 -/* 1701B4 802418D4 24020002 */ addiu $v0, $zero, 2 -/* 1701B8 802418D8 10620069 */ beq $v1, $v0, .L80241A80 -/* 1701BC 802418DC 24040004 */ addiu $a0, $zero, 4 -/* 1701C0 802418E0 0809063C */ j .L802418F0 -/* 1701C4 802418E4 00000000 */ nop -.L802418E8: -/* 1701C8 802418E8 080906A0 */ j .L80241A80 -/* 1701CC 802418EC 24040002 */ addiu $a0, $zero, 2 -.L802418F0: -/* 1701D0 802418F0 3C028007 */ lui $v0, %hi(gGameStatusPtr) -/* 1701D4 802418F4 8C42419C */ lw $v0, %lo(gGameStatusPtr)($v0) -/* 1701D8 802418F8 904200AA */ lbu $v0, 0xaa($v0) -/* 1701DC 802418FC 30420001 */ andi $v0, $v0, 1 -/* 1701E0 80241900 14400012 */ bnez $v0, .L8024194C -/* 1701E4 80241904 00000000 */ nop -/* 1701E8 80241908 3C02800E */ lui $v0, %hi(gBattleStatus+0x4) -/* 1701EC 8024190C 8C42C074 */ lw $v0, %lo(gBattleStatus+0x4)($v0) -/* 1701F0 80241910 8E9000D8 */ lw $s0, 0xd8($s4) -/* 1701F4 80241914 30420040 */ andi $v0, $v0, 0x40 -/* 1701F8 80241918 3C048028 */ lui $a0, %hi(MarioEnterStage) -/* 1701FC 8024191C 24844A40 */ addiu $a0, $a0, %lo(MarioEnterStage) -/* 170200 80241920 10400003 */ beqz $v0, .L80241930 -/* 170204 80241924 2405000A */ addiu $a1, $zero, 0xa -/* 170208 80241928 3C048028 */ lui $a0, %hi(PeachEnterStage) -/* 17020C 8024192C 24844D04 */ addiu $a0, $a0, %lo(PeachEnterStage) -.L80241930: -/* 170210 80241930 0C0B0CF8 */ jal start_script -/* 170214 80241934 0000302D */ daddu $a2, $zero, $zero -/* 170218 80241938 0040182D */ daddu $v1, $v0, $zero -/* 17021C 8024193C AE0301D4 */ sw $v1, 0x1d4($s0) -/* 170220 80241940 8C620144 */ lw $v0, 0x144($v1) -/* 170224 80241944 AE0201E4 */ sw $v0, 0x1e4($s0) -/* 170228 80241948 AC600148 */ sw $zero, 0x148($v1) -.L8024194C: -/* 17022C 8024194C 8FC2008C */ lw $v0, 0x8c($fp) -/* 170230 80241950 50400015 */ beql $v0, $zero, .L802419A8 -/* 170234 80241954 24020131 */ addiu $v0, $zero, 0x131 -/* 170238 80241958 80430005 */ lb $v1, 5($v0) -/* 17023C 8024195C 24020003 */ addiu $v0, $zero, 3 -/* 170240 80241960 14620011 */ bne $v1, $v0, .L802419A8 -/* 170244 80241964 24020131 */ addiu $v0, $zero, 0x131 -/* 170248 80241968 0C03A752 */ jal is_ability_active -/* 17024C 8024196C 2404002D */ addiu $a0, $zero, 0x2d -/* 170250 80241970 1040000C */ beqz $v0, .L802419A4 -/* 170254 80241974 2405000A */ addiu $a1, $zero, 0xa -/* 170258 80241978 3C048029 */ lui $a0, %hi(DoDizzyAttack) -/* 17025C 8024197C 2484907C */ addiu $a0, $a0, %lo(DoDizzyAttack) -/* 170260 80241980 8E9000E0 */ lw $s0, 0xe0($s4) -/* 170264 80241984 0C0B0CF8 */ jal start_script -/* 170268 80241988 0000302D */ daddu $a2, $zero, $zero -/* 17026C 8024198C 0040182D */ daddu $v1, $v0, $zero -/* 170270 80241990 AE0301D4 */ sw $v1, 0x1d4($s0) -/* 170274 80241994 8C620144 */ lw $v0, 0x144($v1) -/* 170278 80241998 AE0201E4 */ sw $v0, 0x1e4($s0) -/* 17027C 8024199C 24020200 */ addiu $v0, $zero, 0x200 -/* 170280 802419A0 AC620148 */ sw $v0, 0x148($v1) -.L802419A4: -/* 170284 802419A4 24020131 */ addiu $v0, $zero, 0x131 -.L802419A8: -/* 170288 802419A8 3C018028 */ lui $at, %hi(D_80280A30) -/* 17028C 802419AC AC220A30 */ sw $v0, %lo(D_80280A30)($at) -/* 170290 802419B0 24020007 */ addiu $v0, $zero, 7 -/* 170294 802419B4 3C01802A */ lui $at, %hi(D_8029F248) -/* 170298 802419B8 AC20F248 */ sw $zero, %lo(D_8029F248)($at) -/* 17029C 802419BC 3C01800E */ lui $at, %hi(gBattleState2) -/* 1702A0 802419C0 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -/* 1702A4 802419C4 080906A2 */ j .L80241A88_170368 -/* 1702A8 802419C8 00000000 */ nop -.L802419CC_1702AC: -/* 1702AC 802419CC 3C108028 */ lui $s0, %hi(D_80280A30) -/* 1702B0 802419D0 26100A30 */ addiu $s0, $s0, %lo(D_80280A30) -/* 1702B4 802419D4 8E020000 */ lw $v0, ($s0) -/* 1702B8 802419D8 14400005 */ bnez $v0, .L802419F0 -/* 1702BC 802419DC 24020008 */ addiu $v0, $zero, 8 -/* 1702C0 802419E0 3C01800E */ lui $at, %hi(gBattleState2) -/* 1702C4 802419E4 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -/* 1702C8 802419E8 080906A2 */ j .L80241A88_170368 -/* 1702CC 802419EC 00000000 */ nop -.L802419F0: -/* 1702D0 802419F0 3C02802A */ lui $v0, %hi(D_8029F248) -/* 1702D4 802419F4 2442F248 */ addiu $v0, $v0, %lo(D_8029F248) -/* 1702D8 802419F8 8C430000 */ lw $v1, ($v0) -/* 1702DC 802419FC 24630001 */ addiu $v1, $v1, 1 -/* 1702E0 80241A00 AC430000 */ sw $v1, ($v0) -/* 1702E4 80241A04 2402000F */ addiu $v0, $zero, 0xf -/* 1702E8 80241A08 14620003 */ bne $v1, $v0, .L80241A18 -/* 1702EC 80241A0C 00000000 */ nop -/* 1702F0 80241A10 0C093903 */ jal btl_cam_use_preset -/* 1702F4 80241A14 24040002 */ addiu $a0, $zero, 2 -.L80241A18: -/* 1702F8 80241A18 3C028007 */ lui $v0, %hi(gGameStatusPtr) -/* 1702FC 80241A1C 8C42419C */ lw $v0, %lo(gGameStatusPtr)($v0) -/* 170300 80241A20 904200AA */ lbu $v0, 0xaa($v0) -/* 170304 80241A24 30420001 */ andi $v0, $v0, 1 -/* 170308 80241A28 14400004 */ bnez $v0, .L80241A3C -/* 17030C 80241A2C 00000000 */ nop -/* 170310 80241A30 8E020000 */ lw $v0, ($s0) -/* 170314 80241A34 08090691 */ j .L80241A44 -/* 170318 80241A38 2442FFF6 */ addiu $v0, $v0, -0xa -.L80241A3C: -/* 17031C 80241A3C 8E020000 */ lw $v0, ($s0) -/* 170320 80241A40 2442FFCE */ addiu $v0, $v0, -0x32 -.L80241A44: -/* 170324 80241A44 AE020000 */ sw $v0, ($s0) -/* 170328 80241A48 3C038028 */ lui $v1, %hi(D_80280A30) -/* 17032C 80241A4C 24630A30 */ addiu $v1, $v1, %lo(D_80280A30) -/* 170330 80241A50 8C620000 */ lw $v0, ($v1) -/* 170334 80241A54 0442000C */ bltzl $v0, .L80241A88_170368 -/* 170338 80241A58 AC600000 */ sw $zero, ($v1) -/* 17033C 80241A5C 080906A2 */ j .L80241A88_170368 -/* 170340 80241A60 00000000 */ nop -.L80241A64_170344: -/* 170344 80241A64 8282008C */ lb $v0, 0x8c($s4) -/* 170348 80241A68 14400007 */ bnez $v0, .L80241A88_170368 -/* 17034C 80241A6C 00000000 */ nop -/* 170350 80241A70 3C05BF80 */ lui $a1, 0xbf80 -/* 170354 80241A74 0C04DF62 */ jal set_screen_overlay_params_front -/* 170358 80241A78 240400FF */ addiu $a0, $zero, 0xff -/* 17035C 80241A7C 24040005 */ addiu $a0, $zero, 5 -.L80241A80: -/* 170360 80241A80 0C090464 */ jal btl_set_state -/* 170364 80241A84 00000000 */ nop -.L80241A88_170368: -/* 170368 80241A88 8FBF0044 */ lw $ra, 0x44($sp) -/* 17036C 80241A8C 8FBE0040 */ lw $fp, 0x40($sp) -/* 170370 80241A90 8FB7003C */ lw $s7, 0x3c($sp) -/* 170374 80241A94 8FB60038 */ lw $s6, 0x38($sp) -/* 170378 80241A98 8FB50034 */ lw $s5, 0x34($sp) -/* 17037C 80241A9C 8FB40030 */ lw $s4, 0x30($sp) -/* 170380 80241AA0 8FB3002C */ lw $s3, 0x2c($sp) -/* 170384 80241AA4 8FB20028 */ lw $s2, 0x28($sp) -/* 170388 80241AA8 8FB10024 */ lw $s1, 0x24($sp) -/* 17038C 80241AAC 8FB00020 */ lw $s0, 0x20($sp) -/* 170390 80241AB0 03E00008 */ jr $ra -/* 170394 80241AB4 27BD0048 */ addiu $sp, $sp, 0x48 diff --git a/ver/us/asm/nonmatchings/16F740/btl_state_update_player_move.s b/ver/us/asm/nonmatchings/16F740/btl_state_update_player_move.s deleted file mode 100644 index c7b6756a7b..0000000000 --- a/ver/us/asm/nonmatchings/16F740/btl_state_update_player_move.s +++ /dev/null @@ -1,697 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel jtbl_8029CAF0 -.word .L80246194_174A74, .L802461BC_174A9C, .L8024619C_174A7C, .L802461A4_174A84, .L802461CC_174AAC, .L802461AC_174A8C, .L802461B4_174A94, .L802461C4_174AA4 - -dlabel jtbl_8029CB10 -.word .L80246310_174BF0, .L80246338_174C18, .L80246318_174BF8, .L80246320_174C00, .L80246348_174C28, .L80246328_174C08, .L80246330_174C10, .L80246340_174C20 - -.section .text - -glabel btl_state_update_player_move -/* 1743B0 80245AD0 27BDFFD0 */ addiu $sp, $sp, -0x30 -/* 1743B4 80245AD4 AFB40020 */ sw $s4, 0x20($sp) -/* 1743B8 80245AD8 3C14800E */ lui $s4, %hi(gBattleStatus) -/* 1743BC 80245ADC 2694C070 */ addiu $s4, $s4, %lo(gBattleStatus) -/* 1743C0 80245AE0 AFBF0028 */ sw $ra, 0x28($sp) -/* 1743C4 80245AE4 AFB50024 */ sw $s5, 0x24($sp) -/* 1743C8 80245AE8 AFB3001C */ sw $s3, 0x1c($sp) -/* 1743CC 80245AEC AFB20018 */ sw $s2, 0x18($sp) -/* 1743D0 80245AF0 AFB10014 */ sw $s1, 0x14($sp) -/* 1743D4 80245AF4 AFB00010 */ sw $s0, 0x10($sp) -/* 1743D8 80245AF8 8E9500D8 */ lw $s5, 0xd8($s4) -/* 1743DC 80245AFC 3C02800E */ lui $v0, %hi(gBattleState2) -/* 1743E0 80245B00 8C42C4DC */ lw $v0, %lo(gBattleState2)($v0) -/* 1743E4 80245B04 8E9200DC */ lw $s2, 0xdc($s4) -/* 1743E8 80245B08 14400068 */ bnez $v0, .L80245CAC -/* 1743EC 80245B0C 2402007F */ addiu $v0, $zero, 0x7f -/* 1743F0 80245B10 A2820086 */ sb $v0, 0x86($s4) -/* 1743F4 80245B14 A2820087 */ sb $v0, 0x87($s4) -/* 1743F8 80245B18 8E820000 */ lw $v0, ($s4) -/* 1743FC 80245B1C 2403EFFF */ addiu $v1, $zero, -0x1001 -/* 174400 80245B20 A280008C */ sb $zero, 0x8c($s4) -/* 174404 80245B24 A6800180 */ sh $zero, 0x180($s4) -/* 174408 80245B28 A280019A */ sb $zero, 0x19a($s4) -/* 17440C 80245B2C 00431024 */ and $v0, $v0, $v1 -/* 174410 80245B30 2403FFFD */ addiu $v1, $zero, -3 -/* 174414 80245B34 00431024 */ and $v0, $v0, $v1 -/* 174418 80245B38 0C098F18 */ jal reset_actor_turn_info -/* 17441C 80245B3C AE820000 */ sw $v0, ($s4) -/* 174420 80245B40 3C03F7FF */ lui $v1, 0xf7ff -/* 174424 80245B44 8EA20000 */ lw $v0, ($s5) -/* 174428 80245B48 3463FFFF */ ori $v1, $v1, 0xffff -/* 17442C 80245B4C 00431024 */ and $v0, $v0, $v1 -/* 174430 80245B50 12400004 */ beqz $s2, .L80245B64 -/* 174434 80245B54 AEA20000 */ sw $v0, ($s5) -/* 174438 80245B58 8E420000 */ lw $v0, ($s2) -/* 17443C 80245B5C 00431024 */ and $v0, $v0, $v1 -/* 174440 80245B60 AE420000 */ sw $v0, ($s2) -.L80245B64: -/* 174444 80245B64 0C09390F */ jal btl_cam_target_actor -/* 174448 80245B68 0000202D */ daddu $a0, $zero, $zero -/* 17444C 80245B6C 3C04FFDF */ lui $a0, 0xffdf -/* 174450 80245B70 3484FFFF */ ori $a0, $a0, 0xffff -/* 174454 80245B74 0000882D */ daddu $s1, $zero, $zero -/* 174458 80245B78 0280282D */ daddu $a1, $s4, $zero -/* 17445C 80245B7C 8E820000 */ lw $v0, ($s4) -/* 174460 80245B80 2403FFF7 */ addiu $v1, $zero, -9 -/* 174464 80245B84 00431024 */ and $v0, $v0, $v1 -/* 174468 80245B88 AE820000 */ sw $v0, ($s4) -/* 17446C 80245B8C A2A0021C */ sb $zero, 0x21c($s5) -/* 174470 80245B90 8E820004 */ lw $v0, 4($s4) -/* 174474 80245B94 8E830000 */ lw $v1, ($s4) -/* 174478 80245B98 34420008 */ ori $v0, $v0, 8 -/* 17447C 80245B9C 00641824 */ and $v1, $v1, $a0 -/* 174480 80245BA0 AE820004 */ sw $v0, 4($s4) -/* 174484 80245BA4 AE830000 */ sw $v1, ($s4) -.L80245BA8: -/* 174488 80245BA8 8CB000E0 */ lw $s0, 0xe0($a1) -/* 17448C 80245BAC 56000001 */ bnel $s0, $zero, .L80245BB4 -/* 174490 80245BB0 A200021C */ sb $zero, 0x21c($s0) -.L80245BB4: -/* 174494 80245BB4 26310001 */ addiu $s1, $s1, 1 -/* 174498 80245BB8 2A220018 */ slti $v0, $s1, 0x18 -/* 17449C 80245BBC 1440FFFA */ bnez $v0, .L80245BA8 -/* 1744A0 80245BC0 24A50004 */ addiu $a1, $a1, 4 -/* 1744A4 80245BC4 0000882D */ daddu $s1, $zero, $zero -/* 1744A8 80245BC8 3C05FFF7 */ lui $a1, 0xfff7 -/* 1744AC 80245BCC 34A5FFFF */ ori $a1, $a1, 0xffff -/* 1744B0 80245BD0 3C04F7FF */ lui $a0, 0xf7ff -/* 1744B4 80245BD4 3484FFFF */ ori $a0, $a0, 0xffff -/* 1744B8 80245BD8 0280182D */ daddu $v1, $s4, $zero -.L80245BDC: -/* 1744BC 80245BDC 8C7000E0 */ lw $s0, 0xe0($v1) -/* 1744C0 80245BE0 12000005 */ beqz $s0, .L80245BF8 -/* 1744C4 80245BE4 26310001 */ addiu $s1, $s1, 1 -/* 1744C8 80245BE8 8E020000 */ lw $v0, ($s0) -/* 1744CC 80245BEC 00451024 */ and $v0, $v0, $a1 -/* 1744D0 80245BF0 00441024 */ and $v0, $v0, $a0 -/* 1744D4 80245BF4 AE020000 */ sw $v0, ($s0) -.L80245BF8: -/* 1744D8 80245BF8 2A220018 */ slti $v0, $s1, 0x18 -/* 1744DC 80245BFC 1440FFF7 */ bnez $v0, .L80245BDC -/* 1744E0 80245C00 24630004 */ addiu $v1, $v1, 4 -/* 1744E4 80245C04 92820178 */ lbu $v0, 0x178($s4) -/* 1744E8 80245C08 2C420002 */ sltiu $v0, $v0, 2 -/* 1744EC 80245C0C 1040001E */ beqz $v0, .L80245C88 -/* 1744F0 80245C10 24020001 */ addiu $v0, $zero, 1 -/* 1744F4 80245C14 8290008A */ lb $s0, 0x8a($s4) -/* 1744F8 80245C18 1602001C */ bne $s0, $v0, .L80245C8C -/* 1744FC 80245C1C 24020003 */ addiu $v0, $zero, 3 -/* 174500 80245C20 3C048028 */ lui $a0, %hi(PlayerScriptDispatcher) -/* 174504 80245C24 24844EBC */ addiu $a0, $a0, %lo(PlayerScriptDispatcher) -/* 174508 80245C28 2405000A */ addiu $a1, $zero, 0xa -/* 17450C 80245C2C 0000302D */ daddu $a2, $zero, $zero -/* 174510 80245C30 24020003 */ addiu $v0, $zero, 3 -/* 174514 80245C34 A28200AC */ sb $v0, 0xac($s4) -/* 174518 80245C38 24020014 */ addiu $v0, $zero, 0x14 -/* 17451C 80245C3C A280008A */ sb $zero, 0x8a($s4) -/* 174520 80245C40 0C0B0CF8 */ jal start_script -/* 174524 80245C44 A28201A7 */ sb $v0, 0x1a7($s4) -/* 174528 80245C48 0040202D */ daddu $a0, $v0, $zero -/* 17452C 80245C4C AEA401D4 */ sw $a0, 0x1d4($s5) -/* 174530 80245C50 8C820144 */ lw $v0, 0x144($a0) -/* 174534 80245C54 AEA201E4 */ sw $v0, 0x1e4($s5) -/* 174538 80245C58 AC800148 */ sw $zero, 0x148($a0) -/* 17453C 80245C5C 3C04800E */ lui $a0, %hi(gBattleStatus) -/* 174540 80245C60 2484C070 */ addiu $a0, $a0, %lo(gBattleStatus) -/* 174544 80245C64 8C820000 */ lw $v0, ($a0) -/* 174548 80245C68 3C030001 */ lui $v1, 1 -/* 17454C 80245C6C 00431025 */ or $v0, $v0, $v1 -/* 174550 80245C70 0C093EC3 */ jal close_action_command_instruction_popup -/* 174554 80245C74 AC820000 */ sw $v0, ($a0) -/* 174558 80245C78 3C01800E */ lui $at, %hi(gBattleState2) -/* 17455C 80245C7C AC30C4DC */ sw $s0, %lo(gBattleState2)($at) -/* 174560 80245C80 0809172B */ j .L80245CAC -/* 174564 80245C84 00000000 */ nop -.L80245C88: -/* 174568 80245C88 24020003 */ addiu $v0, $zero, 3 -.L80245C8C: -/* 17456C 80245C8C 3C04800E */ lui $a0, %hi(gBattleStatus) -/* 174570 80245C90 2484C070 */ addiu $a0, $a0, %lo(gBattleStatus) -/* 174574 80245C94 3C01800E */ lui $at, %hi(gBattleState2) -/* 174578 80245C98 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -/* 17457C 80245C9C 8C820000 */ lw $v0, ($a0) -/* 174580 80245CA0 2403FFFD */ addiu $v1, $zero, -3 -/* 174584 80245CA4 00431024 */ and $v0, $v0, $v1 -/* 174588 80245CA8 AC820000 */ sw $v0, ($a0) -.L80245CAC: -/* 17458C 80245CAC 3C04800E */ lui $a0, %hi(gBattleState2) -/* 174590 80245CB0 2484C4DC */ addiu $a0, $a0, %lo(gBattleState2) -/* 174594 80245CB4 8C830000 */ lw $v1, ($a0) -/* 174598 80245CB8 24020001 */ addiu $v0, $zero, 1 -/* 17459C 80245CBC 10620005 */ beq $v1, $v0, .L80245CD4 -/* 1745A0 80245CC0 24020002 */ addiu $v0, $zero, 2 -/* 1745A4 80245CC4 10620023 */ beq $v1, $v0, .L80245D54 -/* 1745A8 80245CC8 00000000 */ nop -/* 1745AC 80245CCC 0809175E */ j .L80245D78 -/* 1745B0 80245CD0 00000000 */ nop -.L80245CD4: -/* 1745B4 80245CD4 8EA201D4 */ lw $v0, 0x1d4($s5) -/* 1745B8 80245CD8 50400007 */ beql $v0, $zero, .L80245CF8 -/* 1745BC 80245CDC AEA001D4 */ sw $zero, 0x1d4($s5) -/* 1745C0 80245CE0 8EA401E4 */ lw $a0, 0x1e4($s5) -/* 1745C4 80245CE4 0C0B1059 */ jal does_script_exist -/* 1745C8 80245CE8 00000000 */ nop -/* 1745CC 80245CEC 14400022 */ bnez $v0, .L80245D78 -/* 1745D0 80245CF0 00000000 */ nop -/* 1745D4 80245CF4 AEA001D4 */ sw $zero, 0x1d4($s5) -.L80245CF8: -/* 1745D8 80245CF8 0C03A752 */ jal is_ability_active -/* 1745DC 80245CFC 24040015 */ addiu $a0, $zero, 0x15 -/* 1745E0 80245D00 1440000E */ bnez $v0, .L80245D3C -/* 1745E4 80245D04 24020002 */ addiu $v0, $zero, 2 -/* 1745E8 80245D08 8683017C */ lh $v1, 0x17c($s4) -/* 1745EC 80245D0C 1060000A */ beqz $v1, .L80245D38 -/* 1745F0 80245D10 00031080 */ sll $v0, $v1, 2 -/* 1745F4 80245D14 00431021 */ addu $v0, $v0, $v1 -/* 1745F8 80245D18 00021080 */ sll $v0, $v0, 2 -/* 1745FC 80245D1C 3C048009 */ lui $a0, %hi(gMoveTable+0x13) -/* 174600 80245D20 00822021 */ addu $a0, $a0, $v0 -/* 174604 80245D24 8084F073 */ lb $a0, %lo(gMoveTable+0x13)($a0) -/* 174608 80245D28 04800003 */ bltz $a0, .L80245D38 -/* 17460C 80245D2C 2484002E */ addiu $a0, $a0, 0x2e -/* 174610 80245D30 0C093E58 */ jal btl_show_battle_message -/* 174614 80245D34 2405003C */ addiu $a1, $zero, 0x3c -.L80245D38: -/* 174618 80245D38 24020002 */ addiu $v0, $zero, 2 -.L80245D3C: -/* 17461C 80245D3C 3C01802A */ lui $at, %hi(D_8029F248) -/* 174620 80245D40 AC22F248 */ sw $v0, %lo(D_8029F248)($at) -/* 174624 80245D44 3C01800E */ lui $at, %hi(gBattleState2) -/* 174628 80245D48 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -/* 17462C 80245D4C 0809175E */ j .L80245D78 -/* 174630 80245D50 00000000 */ nop -.L80245D54: -/* 174634 80245D54 3C03802A */ lui $v1, %hi(D_8029F248) -/* 174638 80245D58 2463F248 */ addiu $v1, $v1, %lo(D_8029F248) -/* 17463C 80245D5C 8C620000 */ lw $v0, ($v1) -/* 174640 80245D60 10400003 */ beqz $v0, .L80245D70 -/* 174644 80245D64 2442FFFF */ addiu $v0, $v0, -1 -/* 174648 80245D68 0809175E */ j .L80245D78 -/* 17464C 80245D6C AC620000 */ sw $v0, ($v1) -.L80245D70: -/* 174650 80245D70 24020003 */ addiu $v0, $zero, 3 -/* 174654 80245D74 AC820000 */ sw $v0, ($a0) -.L80245D78: -/* 174658 80245D78 3C10800E */ lui $s0, %hi(gBattleState2) -/* 17465C 80245D7C 2610C4DC */ addiu $s0, $s0, %lo(gBattleState2) -/* 174660 80245D80 8E030000 */ lw $v1, ($s0) -/* 174664 80245D84 24020004 */ addiu $v0, $zero, 4 -/* 174668 80245D88 10620031 */ beq $v1, $v0, .L80245E50 -/* 17466C 80245D8C 28620005 */ slti $v0, $v1, 5 -/* 174670 80245D90 10400005 */ beqz $v0, .L80245DA8 -/* 174674 80245D94 24020003 */ addiu $v0, $zero, 3 -/* 174678 80245D98 1062000A */ beq $v1, $v0, .L80245DC4 -/* 17467C 80245D9C 24020015 */ addiu $v0, $zero, 0x15 -/* 174680 80245DA0 080918A6 */ j .L80246298 -/* 174684 80245DA4 00000000 */ nop -.L80245DA8: -/* 174688 80245DA8 2402000B */ addiu $v0, $zero, 0xb -/* 17468C 80245DAC 10620120 */ beq $v1, $v0, .L80246230 -/* 174690 80245DB0 2402000C */ addiu $v0, $zero, 0xc -/* 174694 80245DB4 1062012B */ beq $v1, $v0, .L80246264 -/* 174698 80245DB8 00000000 */ nop -/* 17469C 80245DBC 080918A2 */ j .L80246288 -/* 1746A0 80245DC0 00000000 */ nop -.L80245DC4: -/* 1746A4 80245DC4 3C04FFFE */ lui $a0, 0xfffe -/* 1746A8 80245DC8 3484FFFF */ ori $a0, $a0, 0xffff -/* 1746AC 80245DCC 3C10800E */ lui $s0, %hi(gBattleStatus) -/* 1746B0 80245DD0 2610C070 */ addiu $s0, $s0, %lo(gBattleStatus) -/* 1746B4 80245DD4 8E020000 */ lw $v0, ($s0) -/* 1746B8 80245DD8 2403BFFF */ addiu $v1, $zero, -0x4001 -/* 1746BC 80245DDC 00431024 */ and $v0, $v0, $v1 -/* 1746C0 80245DE0 00441024 */ and $v0, $v0, $a0 -/* 1746C4 80245DE4 0C03A6D5 */ jal increment_status_menu_disabled -/* 1746C8 80245DE8 AE020000 */ sw $v0, ($s0) -/* 1746CC 80245DEC 8E020000 */ lw $v0, ($s0) -/* 1746D0 80245DF0 02A0202D */ daddu $a0, $s5, $zero -/* 1746D4 80245DF4 34420100 */ ori $v0, $v0, 0x100 -/* 1746D8 80245DF8 0C099EA7 */ jal reset_all_actor_sounds -/* 1746DC 80245DFC AE020000 */ sw $v0, ($s0) -/* 1746E0 80245E00 8E020004 */ lw $v0, 4($s0) -/* 1746E4 80245E04 30420040 */ andi $v0, $v0, 0x40 -/* 1746E8 80245E08 3C048028 */ lui $a0, %hi(PlayerScriptDispatcher) -/* 1746EC 80245E0C 24844EBC */ addiu $a0, $a0, %lo(PlayerScriptDispatcher) -/* 1746F0 80245E10 10400003 */ beqz $v0, .L80245E20 -/* 1746F4 80245E14 A28001A7 */ sb $zero, 0x1a7($s4) -/* 1746F8 80245E18 3C048028 */ lui $a0, %hi(PeachScriptDispatcher) -/* 1746FC 80245E1C 24845010 */ addiu $a0, $a0, %lo(PeachScriptDispatcher) -.L80245E20: -/* 174700 80245E20 2405000A */ addiu $a1, $zero, 0xa -/* 174704 80245E24 0C0B0CF8 */ jal start_script -/* 174708 80245E28 0000302D */ daddu $a2, $zero, $zero -/* 17470C 80245E2C 0040202D */ daddu $a0, $v0, $zero -/* 174710 80245E30 AEA401D4 */ sw $a0, 0x1d4($s5) -/* 174714 80245E34 8C830144 */ lw $v1, 0x144($a0) -/* 174718 80245E38 24020004 */ addiu $v0, $zero, 4 -/* 17471C 80245E3C 3C01800E */ lui $at, %hi(gBattleState2) -/* 174720 80245E40 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -/* 174724 80245E44 AEA301E4 */ sw $v1, 0x1e4($s5) -/* 174728 80245E48 080918A2 */ j .L80246288 -/* 17472C 80245E4C AC800148 */ sw $zero, 0x148($a0) -.L80245E50: -/* 174730 80245E50 3C02800E */ lui $v0, %hi(gBattleStatus) -/* 174734 80245E54 8C42C070 */ lw $v0, %lo(gBattleStatus)($v0) -/* 174738 80245E58 3C030020 */ lui $v1, 0x20 -/* 17473C 80245E5C 00431024 */ and $v0, $v0, $v1 -/* 174740 80245E60 1440000A */ bnez $v0, .L80245E8C -/* 174744 80245E64 00000000 */ nop -/* 174748 80245E68 8EA201D4 */ lw $v0, 0x1d4($s5) -/* 17474C 80245E6C 50400007 */ beql $v0, $zero, .L80245E8C -/* 174750 80245E70 AEA001D4 */ sw $zero, 0x1d4($s5) -/* 174754 80245E74 8EA401E4 */ lw $a0, 0x1e4($s5) -/* 174758 80245E78 0C0B1059 */ jal does_script_exist -/* 17475C 80245E7C 00000000 */ nop -/* 174760 80245E80 14400101 */ bnez $v0, .L80246288 -/* 174764 80245E84 00000000 */ nop -/* 174768 80245E88 AEA001D4 */ sw $zero, 0x1d4($s5) -.L80245E8C: -/* 17476C 80245E8C 3C04800E */ lui $a0, %hi(gBattleStatus) -/* 174770 80245E90 2484C070 */ addiu $a0, $a0, %lo(gBattleStatus) -/* 174774 80245E94 8C820000 */ lw $v0, ($a0) -/* 174778 80245E98 2403FEFF */ addiu $v1, $zero, -0x101 -/* 17477C 80245E9C 00431024 */ and $v0, $v0, $v1 -/* 174780 80245EA0 AC820000 */ sw $v0, ($a0) -/* 174784 80245EA4 8EA201D8 */ lw $v0, 0x1d8($s5) -/* 174788 80245EA8 10400005 */ beqz $v0, .L80245EC0 -/* 17478C 80245EAC 00000000 */ nop -/* 174790 80245EB0 0C0B1059 */ jal does_script_exist -/* 174794 80245EB4 8EA401E8 */ lw $a0, 0x1e8($s5) -/* 174798 80245EB8 144000F3 */ bnez $v0, .L80246288 -/* 17479C 80245EBC 00000000 */ nop -.L80245EC0: -/* 1747A0 80245EC0 1240000A */ beqz $s2, .L80245EEC -/* 1747A4 80245EC4 AEA001D8 */ sw $zero, 0x1d8($s5) -/* 1747A8 80245EC8 8E4201D8 */ lw $v0, 0x1d8($s2) -/* 1747AC 80245ECC 50400007 */ beql $v0, $zero, .L80245EEC -/* 1747B0 80245ED0 AE4001D8 */ sw $zero, 0x1d8($s2) -/* 1747B4 80245ED4 8E4401E8 */ lw $a0, 0x1e8($s2) -/* 1747B8 80245ED8 0C0B1059 */ jal does_script_exist -/* 1747BC 80245EDC 00000000 */ nop -/* 1747C0 80245EE0 144000E9 */ bnez $v0, .L80246288 -/* 1747C4 80245EE4 00000000 */ nop -/* 1747C8 80245EE8 AE4001D8 */ sw $zero, 0x1d8($s2) -.L80245EEC: -/* 1747CC 80245EEC 0000982D */ daddu $s3, $zero, $zero -/* 1747D0 80245EF0 0260882D */ daddu $s1, $s3, $zero -/* 1747D4 80245EF4 0280902D */ daddu $s2, $s4, $zero -.L80245EF8: -/* 1747D8 80245EF8 8E5000E0 */ lw $s0, 0xe0($s2) -/* 1747DC 80245EFC 5200000B */ beql $s0, $zero, .L80245F2C -/* 1747E0 80245F00 26310001 */ addiu $s1, $s1, 1 -/* 1747E4 80245F04 8E0201D4 */ lw $v0, 0x1d4($s0) -/* 1747E8 80245F08 50400008 */ beql $v0, $zero, .L80245F2C -/* 1747EC 80245F0C 26310001 */ addiu $s1, $s1, 1 -/* 1747F0 80245F10 8E0401E4 */ lw $a0, 0x1e4($s0) -/* 1747F4 80245F14 0C0B1059 */ jal does_script_exist -/* 1747F8 80245F18 00000000 */ nop -/* 1747FC 80245F1C 50400002 */ beql $v0, $zero, .L80245F28 -/* 174800 80245F20 AE0001D4 */ sw $zero, 0x1d4($s0) -/* 174804 80245F24 24130001 */ addiu $s3, $zero, 1 -.L80245F28: -/* 174808 80245F28 26310001 */ addiu $s1, $s1, 1 -.L80245F2C: -/* 17480C 80245F2C 2A220018 */ slti $v0, $s1, 0x18 -/* 174810 80245F30 1440FFF1 */ bnez $v0, .L80245EF8 -/* 174814 80245F34 26520004 */ addiu $s2, $s2, 4 -/* 174818 80245F38 166000D3 */ bnez $s3, .L80246288 -/* 17481C 80245F3C 0000882D */ daddu $s1, $zero, $zero -/* 174820 80245F40 0280902D */ daddu $s2, $s4, $zero -.L80245F44: -/* 174824 80245F44 8E5000E0 */ lw $s0, 0xe0($s2) -/* 174828 80245F48 5200000B */ beql $s0, $zero, .L80245F78 -/* 17482C 80245F4C 26310001 */ addiu $s1, $s1, 1 -/* 174830 80245F50 8E0201D8 */ lw $v0, 0x1d8($s0) -/* 174834 80245F54 50400008 */ beql $v0, $zero, .L80245F78 -/* 174838 80245F58 26310001 */ addiu $s1, $s1, 1 -/* 17483C 80245F5C 8E0401E8 */ lw $a0, 0x1e8($s0) -/* 174840 80245F60 0C0B1059 */ jal does_script_exist -/* 174844 80245F64 00000000 */ nop -/* 174848 80245F68 50400002 */ beql $v0, $zero, .L80245F74 -/* 17484C 80245F6C AE0001D8 */ sw $zero, 0x1d8($s0) -/* 174850 80245F70 24130001 */ addiu $s3, $zero, 1 -.L80245F74: -/* 174854 80245F74 26310001 */ addiu $s1, $s1, 1 -.L80245F78: -/* 174858 80245F78 2A220018 */ slti $v0, $s1, 0x18 -/* 17485C 80245F7C 1440FFF1 */ bnez $v0, .L80245F44 -/* 174860 80245F80 26520004 */ addiu $s2, $s2, 4 -/* 174864 80245F84 166000C0 */ bnez $s3, .L80246288 -/* 174868 80245F88 0000882D */ daddu $s1, $zero, $zero -/* 17486C 80245F8C 3C04FFF7 */ lui $a0, 0xfff7 -/* 174870 80245F90 3484FFFF */ ori $a0, $a0, 0xffff -/* 174874 80245F94 0280182D */ daddu $v1, $s4, $zero -.L80245F98: -/* 174878 80245F98 8C7000E0 */ lw $s0, 0xe0($v1) -/* 17487C 80245F9C 12000004 */ beqz $s0, .L80245FB0 -/* 174880 80245FA0 26310001 */ addiu $s1, $s1, 1 -/* 174884 80245FA4 8E020000 */ lw $v0, ($s0) -/* 174888 80245FA8 00441024 */ and $v0, $v0, $a0 -/* 17488C 80245FAC AE020000 */ sw $v0, ($s0) -.L80245FB0: -/* 174890 80245FB0 2A220018 */ slti $v0, $s1, 0x18 -/* 174894 80245FB4 1440FFF8 */ bnez $v0, .L80245F98 -/* 174898 80245FB8 24630004 */ addiu $v1, $v1, 4 -/* 17489C 80245FBC 8282008C */ lb $v0, 0x8c($s4) -/* 1748A0 80245FC0 144000B1 */ bnez $v0, .L80246288 -/* 1748A4 80245FC4 00000000 */ nop -/* 1748A8 80245FC8 3C028007 */ lui $v0, %hi(gGameStatusPtr) -/* 1748AC 80245FCC 8C42419C */ lw $v0, %lo(gGameStatusPtr)($v0) -/* 1748B0 80245FD0 904200AA */ lbu $v0, 0xaa($v0) -/* 1748B4 80245FD4 30420001 */ andi $v0, $v0, 1 -/* 1748B8 80245FD8 10400005 */ beqz $v0, .L80245FF0 -/* 1748BC 80245FDC 00000000 */ nop -/* 1748C0 80245FE0 0C090464 */ jal btl_set_state -/* 1748C4 80245FE4 24040023 */ addiu $a0, $zero, 0x23 -/* 1748C8 80245FE8 080918A2 */ j .L80246288 -/* 1748CC 80245FEC 00000000 */ nop -.L80245FF0: -/* 1748D0 80245FF0 0C03A6CC */ jal decrement_status_menu_disabled -/* 1748D4 80245FF4 00000000 */ nop -/* 1748D8 80245FF8 3C10800E */ lui $s0, %hi(gBattleStatus) -/* 1748DC 80245FFC 2610C070 */ addiu $s0, $s0, %lo(gBattleStatus) -/* 1748E0 80246000 8E020000 */ lw $v0, ($s0) -/* 1748E4 80246004 34420008 */ ori $v0, $v0, 8 -/* 1748E8 80246008 AE020000 */ sw $v0, ($s0) -/* 1748EC 8024600C 8E020004 */ lw $v0, 4($s0) -/* 1748F0 80246010 2403FFF7 */ addiu $v1, $zero, -9 -/* 1748F4 80246014 00431024 */ and $v0, $v0, $v1 -/* 1748F8 80246018 0C098D19 */ jal btl_check_player_defeated -/* 1748FC 8024601C AE020004 */ sw $v0, 4($s0) -/* 174900 80246020 14400100 */ bnez $v0, .L80246424 -/* 174904 80246024 24020001 */ addiu $v0, $zero, 1 -/* 174908 80246028 82830178 */ lb $v1, 0x178($s4) -/* 17490C 8024602C 1462000C */ bne $v1, $v0, .L80246060 -/* 174910 80246030 2402000B */ addiu $v0, $zero, 0xb -/* 174914 80246034 8683017C */ lh $v1, 0x17c($s4) -/* 174918 80246038 10620009 */ beq $v1, $v0, .L80246060 -/* 17491C 8024603C 2402000F */ addiu $v0, $zero, 0xf -/* 174920 80246040 10620007 */ beq $v1, $v0, .L80246060 -/* 174924 80246044 24020011 */ addiu $v0, $zero, 0x11 -/* 174928 80246048 10620005 */ beq $v1, $v0, .L80246060 -/* 17492C 8024604C 3C03EFFF */ lui $v1, 0xefff -/* 174930 80246050 8E020000 */ lw $v0, ($s0) -/* 174934 80246054 3463FFFF */ ori $v1, $v1, 0xffff -/* 174938 80246058 00431024 */ and $v0, $v0, $v1 -/* 17493C 8024605C AE020000 */ sw $v0, ($s0) -.L80246060: -/* 174940 80246060 82820178 */ lb $v0, 0x178($s4) -/* 174944 80246064 1440000E */ bnez $v0, .L802460A0 -/* 174948 80246068 24020023 */ addiu $v0, $zero, 0x23 -/* 17494C 8024606C 8683017C */ lh $v1, 0x17c($s4) -/* 174950 80246070 1062000B */ beq $v1, $v0, .L802460A0 -/* 174954 80246074 24020025 */ addiu $v0, $zero, 0x25 -/* 174958 80246078 10620009 */ beq $v1, $v0, .L802460A0 -/* 17495C 8024607C 24020027 */ addiu $v0, $zero, 0x27 -/* 174960 80246080 10620007 */ beq $v1, $v0, .L802460A0 -/* 174964 80246084 3C04DFFF */ lui $a0, 0xdfff -/* 174968 80246088 3C03800E */ lui $v1, %hi(gBattleStatus) -/* 17496C 8024608C 2463C070 */ addiu $v1, $v1, %lo(gBattleStatus) -/* 174970 80246090 8C620000 */ lw $v0, ($v1) -/* 174974 80246094 3484FFFF */ ori $a0, $a0, 0xffff -/* 174978 80246098 00441024 */ and $v0, $v0, $a0 -/* 17497C 8024609C AC620000 */ sw $v0, ($v1) -.L802460A0: -/* 174980 802460A0 3C04800E */ lui $a0, %hi(gBattleStatus) -/* 174984 802460A4 2484C070 */ addiu $a0, $a0, %lo(gBattleStatus) -/* 174988 802460A8 8C820000 */ lw $v0, ($a0) -/* 17498C 802460AC 3C032000 */ lui $v1, 0x2000 -/* 174990 802460B0 00431024 */ and $v0, $v0, $v1 -/* 174994 802460B4 50400001 */ beql $v0, $zero, .L802460BC -/* 174998 802460B8 A2800097 */ sb $zero, 0x97($s4) -.L802460BC: -/* 17499C 802460BC 8C820000 */ lw $v0, ($a0) -/* 1749A0 802460C0 3C031000 */ lui $v1, 0x1000 -/* 1749A4 802460C4 00431024 */ and $v0, $v0, $v1 -/* 1749A8 802460C8 50400001 */ beql $v0, $zero, .L802460D0 -/* 1749AC 802460CC A2800096 */ sb $zero, 0x96($s4) -.L802460D0: -/* 1749B0 802460D0 0000882D */ daddu $s1, $zero, $zero -/* 1749B4 802460D4 3C060040 */ lui $a2, 0x40 -/* 1749B8 802460D8 3C050C00 */ lui $a1, 0xc00 -/* 1749BC 802460DC 0280202D */ daddu $a0, $s4, $zero -.L802460E0: -/* 1749C0 802460E0 8C9000E0 */ lw $s0, 0xe0($a0) -/* 1749C4 802460E4 12000007 */ beqz $s0, .L80246104 -/* 1749C8 802460E8 26310001 */ addiu $s1, $s1, 1 -/* 1749CC 802460EC 8E030000 */ lw $v1, ($s0) -/* 1749D0 802460F0 00661024 */ and $v0, $v1, $a2 -/* 1749D4 802460F4 14400003 */ bnez $v0, .L80246104 -/* 1749D8 802460F8 00000000 */ nop -/* 1749DC 802460FC 00651025 */ or $v0, $v1, $a1 -/* 1749E0 80246100 AE020000 */ sw $v0, ($s0) -.L80246104: -/* 1749E4 80246104 2A220018 */ slti $v0, $s1, 0x18 -/* 1749E8 80246108 1440FFF5 */ bnez $v0, .L802460E0 -/* 1749EC 8024610C 24840004 */ addiu $a0, $a0, 4 -/* 1749F0 80246110 0C099DDF */ jal btl_update_ko_status -/* 1749F4 80246114 0000982D */ daddu $s3, $zero, $zero -/* 1749F8 80246118 0260882D */ daddu $s1, $s3, $zero -/* 1749FC 8024611C 0280182D */ daddu $v1, $s4, $zero -.L80246120: -/* 174A00 80246120 8C7000E0 */ lw $s0, 0xe0($v1) -/* 174A04 80246124 12000004 */ beqz $s0, .L80246138 -/* 174A08 80246128 26310001 */ addiu $s1, $s1, 1 -/* 174A0C 8024612C 8202021C */ lb $v0, 0x21c($s0) -/* 174A10 80246130 54400004 */ bnel $v0, $zero, .L80246144 -/* 174A14 80246134 24130001 */ addiu $s3, $zero, 1 -.L80246138: -/* 174A18 80246138 2A220018 */ slti $v0, $s1, 0x18 -/* 174A1C 8024613C 1440FFF8 */ bnez $v0, .L80246120 -/* 174A20 80246140 24630004 */ addiu $v1, $v1, 4 -.L80246144: -/* 174A24 80246144 16600005 */ bnez $s3, .L8024615C -/* 174A28 80246148 24020014 */ addiu $v0, $zero, 0x14 -/* 174A2C 8024614C 3C01800E */ lui $at, %hi(gBattleState2) -/* 174A30 80246150 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -/* 174A34 80246154 080918A2 */ j .L80246288 -/* 174A38 80246158 00000000 */ nop -.L8024615C: -/* 174A3C 8024615C 0C093903 */ jal btl_cam_use_preset -/* 174A40 80246160 24040003 */ addiu $a0, $zero, 3 -/* 174A44 80246164 9202021C */ lbu $v0, 0x21c($s0) -/* 174A48 80246168 2442FFFC */ addiu $v0, $v0, -4 -/* 174A4C 8024616C 00021600 */ sll $v0, $v0, 0x18 -/* 174A50 80246170 00021E03 */ sra $v1, $v0, 0x18 -/* 174A54 80246174 2C620008 */ sltiu $v0, $v1, 8 -/* 174A58 80246178 10400016 */ beqz $v0, .L802461D4 -/* 174A5C 8024617C 00031080 */ sll $v0, $v1, 2 -/* 174A60 80246180 3C01802A */ lui $at, %hi(jtbl_8029CAF0) -/* 174A64 80246184 00220821 */ addu $at, $at, $v0 -/* 174A68 80246188 8C22CAF0 */ lw $v0, %lo(jtbl_8029CAF0)($at) -/* 174A6C 8024618C 00400008 */ jr $v0 -/* 174A70 80246190 00000000 */ nop -.L80246194_174A74: -/* 174A74 80246194 08091879 */ j .L802461E4 -/* 174A78 80246198 24100012 */ addiu $s0, $zero, 0x12 -.L8024619C_174A7C: -/* 174A7C 8024619C 08091879 */ j .L802461E4 -/* 174A80 802461A0 24100013 */ addiu $s0, $zero, 0x13 -.L802461A4_174A84: -/* 174A84 802461A4 08091879 */ j .L802461E4 -/* 174A88 802461A8 24100014 */ addiu $s0, $zero, 0x14 -.L802461AC_174A8C: -/* 174A8C 802461AC 08091879 */ j .L802461E4 -/* 174A90 802461B0 24100015 */ addiu $s0, $zero, 0x15 -.L802461B4_174A94: -/* 174A94 802461B4 08091879 */ j .L802461E4 -/* 174A98 802461B8 24100016 */ addiu $s0, $zero, 0x16 -.L802461BC_174A9C: -/* 174A9C 802461BC 08091879 */ j .L802461E4 -/* 174AA0 802461C0 24100017 */ addiu $s0, $zero, 0x17 -.L802461C4_174AA4: -/* 174AA4 802461C4 08091879 */ j .L802461E4 -/* 174AA8 802461C8 24100018 */ addiu $s0, $zero, 0x18 -.L802461CC_174AAC: -/* 174AAC 802461CC 08091879 */ j .L802461E4 -/* 174AB0 802461D0 24100019 */ addiu $s0, $zero, 0x19 -.L802461D4: -/* 174AB4 802461D4 0000802D */ daddu $s0, $zero, $zero -/* 174AB8 802461D8 24020014 */ addiu $v0, $zero, 0x14 -/* 174ABC 802461DC 3C01800E */ lui $at, %hi(gBattleState2) -/* 174AC0 802461E0 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -.L802461E4: -/* 174AC4 802461E4 0C05272D */ jal sfx_play_sound -/* 174AC8 802461E8 24042107 */ addiu $a0, $zero, 0x2107 -/* 174ACC 802461EC 0200202D */ daddu $a0, $s0, $zero -/* 174AD0 802461F0 0C093E58 */ jal btl_show_battle_message -/* 174AD4 802461F4 2405003C */ addiu $a1, $zero, 0x3c -/* 174AD8 802461F8 0000882D */ daddu $s1, $zero, $zero -/* 174ADC 802461FC 0280182D */ daddu $v1, $s4, $zero -.L80246200: -/* 174AE0 80246200 8C7000E0 */ lw $s0, 0xe0($v1) -/* 174AE4 80246204 56000001 */ bnel $s0, $zero, .L8024620C -/* 174AE8 80246208 A200021C */ sb $zero, 0x21c($s0) -.L8024620C: -/* 174AEC 8024620C 26310001 */ addiu $s1, $s1, 1 -/* 174AF0 80246210 2A220018 */ slti $v0, $s1, 0x18 -/* 174AF4 80246214 1440FFFA */ bnez $v0, .L80246200 -/* 174AF8 80246218 24630004 */ addiu $v1, $v1, 4 -/* 174AFC 8024621C 2402000B */ addiu $v0, $zero, 0xb -/* 174B00 80246220 3C01800E */ lui $at, %hi(gBattleState2) -/* 174B04 80246224 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -/* 174B08 80246228 080918A2 */ j .L80246288 -/* 174B0C 8024622C 00000000 */ nop -.L80246230: -/* 174B10 80246230 0C093EAD */ jal btl_is_popup_displayed -/* 174B14 80246234 00000000 */ nop -/* 174B18 80246238 14400013 */ bnez $v0, .L80246288 -/* 174B1C 8024623C 00000000 */ nop -/* 174B20 80246240 0C093903 */ jal btl_cam_use_preset -/* 174B24 80246244 24040002 */ addiu $a0, $zero, 2 -/* 174B28 80246248 0C093936 */ jal btl_cam_move -/* 174B2C 8024624C 2404000F */ addiu $a0, $zero, 0xf -/* 174B30 80246250 2402000A */ addiu $v0, $zero, 0xa -/* 174B34 80246254 3C01802A */ lui $at, %hi(D_8029F248) -/* 174B38 80246258 AC22F248 */ sw $v0, %lo(D_8029F248)($at) -/* 174B3C 8024625C 080918A1 */ j .L80246284 -/* 174B40 80246260 2402000C */ addiu $v0, $zero, 0xc -.L80246264: -/* 174B44 80246264 3C03802A */ lui $v1, %hi(D_8029F248) -/* 174B48 80246268 2463F248 */ addiu $v1, $v1, %lo(D_8029F248) -/* 174B4C 8024626C 8C620000 */ lw $v0, ($v1) -/* 174B50 80246270 10400003 */ beqz $v0, .L80246280 -/* 174B54 80246274 2442FFFF */ addiu $v0, $v0, -1 -/* 174B58 80246278 080918A2 */ j .L80246288 -/* 174B5C 8024627C AC620000 */ sw $v0, ($v1) -.L80246280: -/* 174B60 80246280 24020014 */ addiu $v0, $zero, 0x14 -.L80246284: -/* 174B64 80246284 AE020000 */ sw $v0, ($s0) -.L80246288: -/* 174B68 80246288 3C10800E */ lui $s0, %hi(gBattleState2) -/* 174B6C 8024628C 2610C4DC */ addiu $s0, $s0, %lo(gBattleState2) -/* 174B70 80246290 8E030000 */ lw $v1, ($s0) -/* 174B74 80246294 24020015 */ addiu $v0, $zero, 0x15 -.L80246298: -/* 174B78 80246298 1062003C */ beq $v1, $v0, .L8024638C -/* 174B7C 8024629C 28620016 */ slti $v0, $v1, 0x16 -/* 174B80 802462A0 10400005 */ beqz $v0, .L802462B8 -/* 174B84 802462A4 24020014 */ addiu $v0, $zero, 0x14 -/* 174B88 802462A8 10620008 */ beq $v1, $v0, .L802462CC -/* 174B8C 802462AC 00000000 */ nop -/* 174B90 802462B0 080918F9 */ j .L802463E4 -/* 174B94 802462B4 00000000 */ nop -.L802462B8: -/* 174B98 802462B8 24020016 */ addiu $v0, $zero, 0x16 -/* 174B9C 802462BC 10620040 */ beq $v1, $v0, .L802463C0 -/* 174BA0 802462C0 00000000 */ nop -/* 174BA4 802462C4 080918F9 */ j .L802463E4 -/* 174BA8 802462C8 00000000 */ nop -.L802462CC: -/* 174BAC 802462CC 82A2021C */ lb $v0, 0x21c($s5) -/* 174BB0 802462D0 10400043 */ beqz $v0, .L802463E0 -/* 174BB4 802462D4 2402001E */ addiu $v0, $zero, 0x1e -/* 174BB8 802462D8 0C093903 */ jal btl_cam_use_preset -/* 174BBC 802462DC 24040021 */ addiu $a0, $zero, 0x21 -/* 174BC0 802462E0 92A2021C */ lbu $v0, 0x21c($s5) -/* 174BC4 802462E4 2442FFFC */ addiu $v0, $v0, -4 -/* 174BC8 802462E8 00021600 */ sll $v0, $v0, 0x18 -/* 174BCC 802462EC 00021E03 */ sra $v1, $v0, 0x18 -/* 174BD0 802462F0 2C620008 */ sltiu $v0, $v1, 8 -/* 174BD4 802462F4 10400014 */ beqz $v0, .L80246348_174C28 -/* 174BD8 802462F8 00031080 */ sll $v0, $v1, 2 -/* 174BDC 802462FC 3C01802A */ lui $at, %hi(jtbl_8029CB10) -/* 174BE0 80246300 00220821 */ addu $at, $at, $v0 -/* 174BE4 80246304 8C22CB10 */ lw $v0, %lo(jtbl_8029CB10)($at) -/* 174BE8 80246308 00400008 */ jr $v0 -/* 174BEC 8024630C 00000000 */ nop -.L80246310_174BF0: -/* 174BF0 80246310 080918D6 */ j .L80246358 -/* 174BF4 80246314 2410000A */ addiu $s0, $zero, 0xa -.L80246318_174BF8: -/* 174BF8 80246318 080918D6 */ j .L80246358 -/* 174BFC 8024631C 2410000B */ addiu $s0, $zero, 0xb -.L80246320_174C00: -/* 174C00 80246320 080918D6 */ j .L80246358 -/* 174C04 80246324 2410000C */ addiu $s0, $zero, 0xc -.L80246328_174C08: -/* 174C08 80246328 080918D6 */ j .L80246358 -/* 174C0C 8024632C 2410000D */ addiu $s0, $zero, 0xd -.L80246330_174C10: -/* 174C10 80246330 080918D6 */ j .L80246358 -/* 174C14 80246334 2410000E */ addiu $s0, $zero, 0xe -.L80246338_174C18: -/* 174C18 80246338 080918D6 */ j .L80246358 -/* 174C1C 8024633C 2410000F */ addiu $s0, $zero, 0xf -.L80246340_174C20: -/* 174C20 80246340 080918D6 */ j .L80246358 -/* 174C24 80246344 24100010 */ addiu $s0, $zero, 0x10 -.L80246348_174C28: -/* 174C28 80246348 0000802D */ daddu $s0, $zero, $zero -/* 174C2C 8024634C 2402001E */ addiu $v0, $zero, 0x1e -/* 174C30 80246350 3C01800E */ lui $at, %hi(gBattleState2) -/* 174C34 80246354 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -.L80246358: -/* 174C38 80246358 0200202D */ daddu $a0, $s0, $zero -/* 174C3C 8024635C 0C093E58 */ jal btl_show_battle_message -/* 174C40 80246360 2405003C */ addiu $a1, $zero, 0x3c -/* 174C44 80246364 24020015 */ addiu $v0, $zero, 0x15 -/* 174C48 80246368 A2A0021C */ sb $zero, 0x21c($s5) -/* 174C4C 8024636C A2A0021D */ sb $zero, 0x21d($s5) -/* 174C50 80246370 3C01800E */ lui $at, %hi(gBattleState2) -/* 174C54 80246374 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -/* 174C58 80246378 8EA20000 */ lw $v0, ($s5) -/* 174C5C 8024637C 3C030800 */ lui $v1, 0x800 -/* 174C60 80246380 00431025 */ or $v0, $v0, $v1 -/* 174C64 80246384 080918F9 */ j .L802463E4 -/* 174C68 80246388 AEA20000 */ sw $v0, ($s5) -.L8024638C: -/* 174C6C 8024638C 0C093EAD */ jal btl_is_popup_displayed -/* 174C70 80246390 00000000 */ nop -/* 174C74 80246394 14400013 */ bnez $v0, .L802463E4 -/* 174C78 80246398 00000000 */ nop -/* 174C7C 8024639C 0C093903 */ jal btl_cam_use_preset -/* 174C80 802463A0 24040002 */ addiu $a0, $zero, 2 -/* 174C84 802463A4 0C093936 */ jal btl_cam_move -/* 174C88 802463A8 2404000F */ addiu $a0, $zero, 0xf -/* 174C8C 802463AC 2402000A */ addiu $v0, $zero, 0xa -/* 174C90 802463B0 3C01802A */ lui $at, %hi(D_8029F248) -/* 174C94 802463B4 AC22F248 */ sw $v0, %lo(D_8029F248)($at) -/* 174C98 802463B8 080918F8 */ j .L802463E0 -/* 174C9C 802463BC 24020016 */ addiu $v0, $zero, 0x16 -.L802463C0: -/* 174CA0 802463C0 3C03802A */ lui $v1, %hi(D_8029F248) -/* 174CA4 802463C4 2463F248 */ addiu $v1, $v1, %lo(D_8029F248) -/* 174CA8 802463C8 8C620000 */ lw $v0, ($v1) -/* 174CAC 802463CC 10400003 */ beqz $v0, .L802463DC -/* 174CB0 802463D0 2442FFFF */ addiu $v0, $v0, -1 -/* 174CB4 802463D4 080918F9 */ j .L802463E4 -/* 174CB8 802463D8 AC620000 */ sw $v0, ($v1) -.L802463DC: -/* 174CBC 802463DC 2402001E */ addiu $v0, $zero, 0x1e -.L802463E0: -/* 174CC0 802463E0 AE020000 */ sw $v0, ($s0) -.L802463E4: -/* 174CC4 802463E4 3C03800E */ lui $v1, %hi(gBattleState2) -/* 174CC8 802463E8 8C63C4DC */ lw $v1, %lo(gBattleState2)($v1) -/* 174CCC 802463EC 2402001E */ addiu $v0, $zero, 0x1e -/* 174CD0 802463F0 1462000C */ bne $v1, $v0, .L80246424 -/* 174CD4 802463F4 00000000 */ nop -/* 174CD8 802463F8 8EA201D4 */ lw $v0, 0x1d4($s5) -/* 174CDC 802463FC 50400007 */ beql $v0, $zero, .L8024641C -/* 174CE0 80246400 AEA001D4 */ sw $zero, 0x1d4($s5) -/* 174CE4 80246404 8EA401E4 */ lw $a0, 0x1e4($s5) -/* 174CE8 80246408 0C0B1059 */ jal does_script_exist -/* 174CEC 8024640C 00000000 */ nop -/* 174CF0 80246410 14400004 */ bnez $v0, .L80246424 -/* 174CF4 80246414 00000000 */ nop -/* 174CF8 80246418 AEA001D4 */ sw $zero, 0x1d4($s5) -.L8024641C: -/* 174CFC 8024641C 0C090464 */ jal btl_set_state -/* 174D00 80246420 24040016 */ addiu $a0, $zero, 0x16 -.L80246424: -/* 174D04 80246424 8FBF0028 */ lw $ra, 0x28($sp) -/* 174D08 80246428 8FB50024 */ lw $s5, 0x24($sp) -/* 174D0C 8024642C 8FB40020 */ lw $s4, 0x20($sp) -/* 174D10 80246430 8FB3001C */ lw $s3, 0x1c($sp) -/* 174D14 80246434 8FB20018 */ lw $s2, 0x18($sp) -/* 174D18 80246438 8FB10014 */ lw $s1, 0x14($sp) -/* 174D1C 8024643C 8FB00010 */ lw $s0, 0x10($sp) -/* 174D20 80246440 03E00008 */ jr $ra -/* 174D24 80246444 27BD0030 */ addiu $sp, $sp, 0x30 diff --git a/ver/us/asm/nonmatchings/415D90/btl_state_draw_select_target.s b/ver/us/asm/nonmatchings/415D90/btl_state_draw_select_target.s deleted file mode 100644 index 50e8154cab..0000000000 --- a/ver/us/asm/nonmatchings/415D90/btl_state_draw_select_target.s +++ /dev/null @@ -1,440 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel btl_state_draw_select_target -/* 41FA68 802AACD8 27BDFF58 */ addiu $sp, $sp, -0xa8 -/* 41FA6C 802AACDC 3C02800E */ lui $v0, %hi(gBattleStatus) -/* 41FA70 802AACE0 8C42C070 */ lw $v0, %lo(gBattleStatus)($v0) -/* 41FA74 802AACE4 3C030008 */ lui $v1, 8 -/* 41FA78 802AACE8 AFBF008C */ sw $ra, 0x8c($sp) -/* 41FA7C 802AACEC AFBE0088 */ sw $fp, 0x88($sp) -/* 41FA80 802AACF0 AFB70084 */ sw $s7, 0x84($sp) -/* 41FA84 802AACF4 AFB60080 */ sw $s6, 0x80($sp) -/* 41FA88 802AACF8 AFB5007C */ sw $s5, 0x7c($sp) -/* 41FA8C 802AACFC AFB40078 */ sw $s4, 0x78($sp) -/* 41FA90 802AAD00 AFB30074 */ sw $s3, 0x74($sp) -/* 41FA94 802AAD04 AFB20070 */ sw $s2, 0x70($sp) -/* 41FA98 802AAD08 AFB1006C */ sw $s1, 0x6c($sp) -/* 41FA9C 802AAD0C AFB00068 */ sw $s0, 0x68($sp) -/* 41FAA0 802AAD10 F7B800A0 */ sdc1 $f24, 0xa0($sp) -/* 41FAA4 802AAD14 F7B60098 */ sdc1 $f22, 0x98($sp) -/* 41FAA8 802AAD18 F7B40090 */ sdc1 $f20, 0x90($sp) -/* 41FAAC 802AAD1C 00431024 */ and $v0, $v0, $v1 -/* 41FAB0 802AAD20 14400005 */ bnez $v0, .L802AAD38 -/* 41FAB4 802AAD24 00000000 */ nop -/* 41FAB8 802AAD28 3C16800E */ lui $s6, %hi(gBattleStatus+0xD8) -/* 41FABC 802AAD2C 8ED6C148 */ lw $s6, %lo(gBattleStatus+0xD8)($s6) -/* 41FAC0 802AAD30 080AAB50 */ j .L802AAD40 -/* 41FAC4 802AAD34 00000000 */ nop -.L802AAD38: -/* 41FAC8 802AAD38 3C16800E */ lui $s6, %hi(gBattleStatus+0xDC) -/* 41FACC 802AAD3C 8ED6C14C */ lw $s6, %lo(gBattleStatus+0xDC)($s6) -.L802AAD40: -/* 41FAD0 802AAD40 82C9040C */ lb $t1, 0x40c($s6) -/* 41FAD4 802AAD44 AFA9005C */ sw $t1, 0x5c($sp) -/* 41FAD8 802AAD48 82C90425 */ lb $t1, 0x425($s6) -/* 41FADC 802AAD4C 26D1022C */ addiu $s1, $s6, 0x22c -/* 41FAE0 802AAD50 AFA90060 */ sw $t1, 0x60($sp) -/* 41FAE4 802AAD54 8FA9005C */ lw $t1, 0x5c($sp) -/* 41FAE8 802AAD58 11200166 */ beqz $t1, .L802AB2F4 -/* 41FAEC 802AAD5C 26D7040D */ addiu $s7, $s6, 0x40d -/* 41FAF0 802AAD60 3C02800E */ lui $v0, %hi(gBattleStatus+0x184) -/* 41FAF4 802AAD64 8C42C1F4 */ lw $v0, %lo(gBattleStatus+0x184)($v0) -/* 41FAF8 802AAD68 30420001 */ andi $v0, $v0, 1 -/* 41FAFC 802AAD6C 10400045 */ beqz $v0, .L802AAE84 -/* 41FB00 802AAD70 00000000 */ nop -/* 41FB04 802AAD74 8FA90060 */ lw $t1, 0x60($sp) -/* 41FB08 802AAD78 02E91021 */ addu $v0, $s7, $t1 -/* 41FB0C 802AAD7C 80430000 */ lb $v1, ($v0) -/* 41FB10 802AAD80 00031080 */ sll $v0, $v1, 2 -/* 41FB14 802AAD84 00431021 */ addu $v0, $v0, $v1 -/* 41FB18 802AAD88 00021080 */ sll $v0, $v0, 2 -/* 41FB1C 802AAD8C 2442022C */ addiu $v0, $v0, 0x22c -/* 41FB20 802AAD90 02C28821 */ addu $s1, $s6, $v0 -/* 41FB24 802AAD94 0C09A75B */ jal get_actor -/* 41FB28 802AAD98 86240000 */ lh $a0, ($s1) -/* 41FB2C 802AAD9C 3C10802B */ lui $s0, %hi(D_802ACC70) -/* 41FB30 802AADA0 8E10CC70 */ lw $s0, %lo(D_802ACC70)($s0) -/* 41FB34 802AADA4 86230004 */ lh $v1, 4($s1) -/* 41FB38 802AADA8 86240006 */ lh $a0, 6($s1) -/* 41FB3C 802AADAC 8C420000 */ lw $v0, ($v0) -/* 41FB40 802AADB0 4483B000 */ mtc1 $v1, $f22 -/* 41FB44 802AADB4 00000000 */ nop -/* 41FB48 802AADB8 4680B5A0 */ cvt.s.w $f22, $f22 -/* 41FB4C 802AADBC 4484C000 */ mtc1 $a0, $f24 -/* 41FB50 802AADC0 00000000 */ nop -/* 41FB54 802AADC4 4680C620 */ cvt.s.w $f24, $f24 -/* 41FB58 802AADC8 86230008 */ lh $v1, 8($s1) -/* 41FB5C 802AADCC 30420800 */ andi $v0, $v0, 0x800 -/* 41FB60 802AADD0 4483A000 */ mtc1 $v1, $f20 -/* 41FB64 802AADD4 00000000 */ nop -/* 41FB68 802AADD8 4680A520 */ cvt.s.w $f20, $f20 -/* 41FB6C 802AADDC 10400008 */ beqz $v0, .L802AAE00 -/* 41FB70 802AADE0 24140010 */ addiu $s4, $zero, 0x10 -/* 41FB74 802AADE4 24130002 */ addiu $s3, $zero, 2 -/* 41FB78 802AADE8 0C05122C */ jal hud_element_get_script -/* 41FB7C 802AADEC 0200202D */ daddu $a0, $s0, $zero -/* 41FB80 802AADF0 3C058008 */ lui $a1, %hi(HES_HandPointLeftLoop) -/* 41FB84 802AADF4 24A50208 */ addiu $a1, $a1, %lo(HES_HandPointLeftLoop) -/* 41FB88 802AADF8 080AAB86 */ j .L802AAE18 -/* 41FB8C 802AADFC 00000000 */ nop -.L802AAE00: -/* 41FB90 802AAE00 24140005 */ addiu $s4, $zero, 5 -/* 41FB94 802AAE04 2413FFF5 */ addiu $s3, $zero, -0xb -/* 41FB98 802AAE08 0C05122C */ jal hud_element_get_script -/* 41FB9C 802AAE0C 0200202D */ daddu $a0, $s0, $zero -/* 41FBA0 802AAE10 3C058008 */ lui $a1, %hi(HES_HandPointDownLoop) -/* 41FBA4 802AAE14 24A5FF20 */ addiu $a1, $a1, %lo(HES_HandPointDownLoop) -.L802AAE18: -/* 41FBA8 802AAE18 50450004 */ beql $v0, $a1, .L802AAE2C -/* 41FBAC 802AAE1C 24040001 */ addiu $a0, $zero, 1 -/* 41FBB0 802AAE20 0C0511FF */ jal hud_element_set_script -/* 41FBB4 802AAE24 0200202D */ daddu $a0, $s0, $zero -/* 41FBB8 802AAE28 24040001 */ addiu $a0, $zero, 1 -.L802AAE2C: -/* 41FBBC 802AAE2C 4405B000 */ mfc1 $a1, $f22 -/* 41FBC0 802AAE30 4406C000 */ mfc1 $a2, $f24 -/* 41FBC4 802AAE34 4407A000 */ mfc1 $a3, $f20 -/* 41FBC8 802AAE38 27A20050 */ addiu $v0, $sp, 0x50 -/* 41FBCC 802AAE3C AFA20010 */ sw $v0, 0x10($sp) -/* 41FBD0 802AAE40 27A20054 */ addiu $v0, $sp, 0x54 -/* 41FBD4 802AAE44 AFA20014 */ sw $v0, 0x14($sp) -/* 41FBD8 802AAE48 27A20058 */ addiu $v0, $sp, 0x58 -/* 41FBDC 802AAE4C 0C00B94E */ jal get_screen_coords -/* 41FBE0 802AAE50 AFA20018 */ sw $v0, 0x18($sp) -/* 41FBE4 802AAE54 0200202D */ daddu $a0, $s0, $zero -/* 41FBE8 802AAE58 8FA50050 */ lw $a1, 0x50($sp) -/* 41FBEC 802AAE5C 8FA60054 */ lw $a2, 0x54($sp) -/* 41FBF0 802AAE60 00B42821 */ addu $a1, $a1, $s4 -/* 41FBF4 802AAE64 0C051261 */ jal hud_element_set_render_pos -/* 41FBF8 802AAE68 00D33021 */ addu $a2, $a2, $s3 -/* 41FBFC 802AAE6C 3C05802B */ lui $a1, %hi(D_802ACC64) -/* 41FC00 802AAE70 8CA5CC64 */ lw $a1, %lo(D_802ACC64)($a1) -/* 41FC04 802AAE74 0C0513AC */ jal hud_element_set_alpha -/* 41FC08 802AAE78 0200202D */ daddu $a0, $s0, $zero -/* 41FC0C 802AAE7C 080AABED */ j .L802AAFB4 -/* 41FC10 802AAE80 00000000 */ nop -.L802AAE84: -/* 41FC14 802AAE84 1920004B */ blez $t1, .L802AAFB4 -/* 41FC18 802AAE88 0000902D */ daddu $s2, $zero, $zero -/* 41FC1C 802AAE8C 3C1E8008 */ lui $fp, %hi(HES_HandPointDownLoop) -/* 41FC20 802AAE90 27DEFF20 */ addiu $fp, $fp, %lo(HES_HandPointDownLoop) -/* 41FC24 802AAE94 3C15802B */ lui $s5, %hi(D_802ACC70) -/* 41FC28 802AAE98 26B5CC70 */ addiu $s5, $s5, %lo(D_802ACC70) -.L802AAE9C: -/* 41FC2C 802AAE9C 02F21021 */ addu $v0, $s7, $s2 -/* 41FC30 802AAEA0 80430000 */ lb $v1, ($v0) -/* 41FC34 802AAEA4 00031080 */ sll $v0, $v1, 2 -/* 41FC38 802AAEA8 00431021 */ addu $v0, $v0, $v1 -/* 41FC3C 802AAEAC 00021080 */ sll $v0, $v0, 2 -/* 41FC40 802AAEB0 2442022C */ addiu $v0, $v0, 0x22c -/* 41FC44 802AAEB4 02C28821 */ addu $s1, $s6, $v0 -/* 41FC48 802AAEB8 0C09A75B */ jal get_actor -/* 41FC4C 802AAEBC 86240000 */ lh $a0, ($s1) -/* 41FC50 802AAEC0 8EB00000 */ lw $s0, ($s5) -/* 41FC54 802AAEC4 86230004 */ lh $v1, 4($s1) -/* 41FC58 802AAEC8 86240006 */ lh $a0, 6($s1) -/* 41FC5C 802AAECC 8C420000 */ lw $v0, ($v0) -/* 41FC60 802AAED0 4483B000 */ mtc1 $v1, $f22 -/* 41FC64 802AAED4 00000000 */ nop -/* 41FC68 802AAED8 4680B5A0 */ cvt.s.w $f22, $f22 -/* 41FC6C 802AAEDC 4484C000 */ mtc1 $a0, $f24 -/* 41FC70 802AAEE0 00000000 */ nop -/* 41FC74 802AAEE4 4680C620 */ cvt.s.w $f24, $f24 -/* 41FC78 802AAEE8 86230008 */ lh $v1, 8($s1) -/* 41FC7C 802AAEEC 30420800 */ andi $v0, $v0, 0x800 -/* 41FC80 802AAEF0 4483A000 */ mtc1 $v1, $f20 -/* 41FC84 802AAEF4 00000000 */ nop -/* 41FC88 802AAEF8 4680A520 */ cvt.s.w $f20, $f20 -/* 41FC8C 802AAEFC 1040000A */ beqz $v0, .L802AAF28 -/* 41FC90 802AAF00 24140010 */ addiu $s4, $zero, 0x10 -/* 41FC94 802AAF04 24130002 */ addiu $s3, $zero, 2 -/* 41FC98 802AAF08 0C05122C */ jal hud_element_get_script -/* 41FC9C 802AAF0C 0200202D */ daddu $a0, $s0, $zero -/* 41FCA0 802AAF10 3C098008 */ lui $t1, %hi(HES_HandPointLeftLoop) -/* 41FCA4 802AAF14 25290208 */ addiu $t1, $t1, %lo(HES_HandPointLeftLoop) -/* 41FCA8 802AAF18 1049000C */ beq $v0, $t1, .L802AAF4C -/* 41FCAC 802AAF1C 0120282D */ daddu $a1, $t1, $zero -/* 41FCB0 802AAF20 080AABD1 */ j .L802AAF44 -/* 41FCB4 802AAF24 0200202D */ daddu $a0, $s0, $zero -.L802AAF28: -/* 41FCB8 802AAF28 24140005 */ addiu $s4, $zero, 5 -/* 41FCBC 802AAF2C 2413FFF5 */ addiu $s3, $zero, -0xb -/* 41FCC0 802AAF30 0C05122C */ jal hud_element_get_script -/* 41FCC4 802AAF34 0200202D */ daddu $a0, $s0, $zero -/* 41FCC8 802AAF38 105E0004 */ beq $v0, $fp, .L802AAF4C -/* 41FCCC 802AAF3C 03C0282D */ daddu $a1, $fp, $zero -/* 41FCD0 802AAF40 0200202D */ daddu $a0, $s0, $zero -.L802AAF44: -/* 41FCD4 802AAF44 0C0511FF */ jal hud_element_set_script -/* 41FCD8 802AAF48 00000000 */ nop -.L802AAF4C: -/* 41FCDC 802AAF4C 24040001 */ addiu $a0, $zero, 1 -/* 41FCE0 802AAF50 02449021 */ addu $s2, $s2, $a0 -/* 41FCE4 802AAF54 4405B000 */ mfc1 $a1, $f22 -/* 41FCE8 802AAF58 4406C000 */ mfc1 $a2, $f24 -/* 41FCEC 802AAF5C 4407A000 */ mfc1 $a3, $f20 -/* 41FCF0 802AAF60 27A20050 */ addiu $v0, $sp, 0x50 -/* 41FCF4 802AAF64 AFA20010 */ sw $v0, 0x10($sp) -/* 41FCF8 802AAF68 27A20054 */ addiu $v0, $sp, 0x54 -/* 41FCFC 802AAF6C AFA20014 */ sw $v0, 0x14($sp) -/* 41FD00 802AAF70 27A20058 */ addiu $v0, $sp, 0x58 -/* 41FD04 802AAF74 0C00B94E */ jal get_screen_coords -/* 41FD08 802AAF78 AFA20018 */ sw $v0, 0x18($sp) -/* 41FD0C 802AAF7C 0200202D */ daddu $a0, $s0, $zero -/* 41FD10 802AAF80 8FA50050 */ lw $a1, 0x50($sp) -/* 41FD14 802AAF84 8FA60054 */ lw $a2, 0x54($sp) -/* 41FD18 802AAF88 00B42821 */ addu $a1, $a1, $s4 -/* 41FD1C 802AAF8C 0C051261 */ jal hud_element_set_render_pos -/* 41FD20 802AAF90 00D33021 */ addu $a2, $a2, $s3 -/* 41FD24 802AAF94 3C05802B */ lui $a1, %hi(D_802ACC64) -/* 41FD28 802AAF98 8CA5CC64 */ lw $a1, %lo(D_802ACC64)($a1) -/* 41FD2C 802AAF9C 0C0513AC */ jal hud_element_set_alpha -/* 41FD30 802AAFA0 0200202D */ daddu $a0, $s0, $zero -/* 41FD34 802AAFA4 8FA9005C */ lw $t1, 0x5c($sp) -/* 41FD38 802AAFA8 0249102A */ slt $v0, $s2, $t1 -/* 41FD3C 802AAFAC 1440FFBB */ bnez $v0, .L802AAE9C -/* 41FD40 802AAFB0 26B50004 */ addiu $s5, $s5, 4 -.L802AAFB4: -/* 41FD44 802AAFB4 3C028011 */ lui $v0, %hi(gPlayerData) -/* 41FD48 802AAFB8 2442F290 */ addiu $v0, $v0, %lo(gPlayerData) -/* 41FD4C 802AAFBC 80520012 */ lb $s2, 0x12($v0) -/* 41FD50 802AAFC0 24020034 */ addiu $v0, $zero, 0x34 -/* 41FD54 802AAFC4 AFA20050 */ sw $v0, 0x50($sp) -/* 41FD58 802AAFC8 3C02800E */ lui $v0, %hi(gBattleStatus+0x4) -/* 41FD5C 802AAFCC 8C42C074 */ lw $v0, %lo(gBattleStatus+0x4)($v0) -/* 41FD60 802AAFD0 24030040 */ addiu $v1, $zero, 0x40 -/* 41FD64 802AAFD4 00431024 */ and $v0, $v0, $v1 -/* 41FD68 802AAFD8 10400002 */ beqz $v0, .L802AAFE4 -/* 41FD6C 802AAFDC AFA30054 */ sw $v1, 0x54($sp) -/* 41FD70 802AAFE0 2412000B */ addiu $s2, $zero, 0xb -.L802AAFE4: -/* 41FD74 802AAFE4 3C02800E */ lui $v0, %hi(gBattleStatus+0x184) -/* 41FD78 802AAFE8 8C42C1F4 */ lw $v0, %lo(gBattleStatus+0x184)($v0) -/* 41FD7C 802AAFEC 30420001 */ andi $v0, $v0, 1 -/* 41FD80 802AAFF0 14400004 */ bnez $v0, .L802AB004 -/* 41FD84 802AAFF4 24020001 */ addiu $v0, $zero, 1 -/* 41FD88 802AAFF8 8FA9005C */ lw $t1, 0x5c($sp) -/* 41FD8C 802AAFFC 15220026 */ bne $t1, $v0, .L802AB098 -/* 41FD90 802AB000 00000000 */ nop -.L802AB004: -/* 41FD94 802AB004 86230000 */ lh $v1, ($s1) -/* 41FD98 802AB008 14600004 */ bnez $v1, .L802AB01C -/* 41FD9C 802AB00C 24020100 */ addiu $v0, $zero, 0x100 -/* 41FDA0 802AB010 3C04001D */ lui $a0, 0x1d -/* 41FDA4 802AB014 080AAC3C */ j .L802AB0F0 -/* 41FDA8 802AB018 348400C4 */ ori $a0, $a0, 0xc4 -.L802AB01C: -/* 41FDAC 802AB01C 14620005 */ bne $v1, $v0, .L802AB034 -/* 41FDB0 802AB020 00121080 */ sll $v0, $s2, 2 -/* 41FDB4 802AB024 3C04802B */ lui $a0, %hi(D_802AB738) -/* 41FDB8 802AB028 00822021 */ addu $a0, $a0, $v0 -/* 41FDBC 802AB02C 080AAC3C */ j .L802AB0F0 -/* 41FDC0 802AB030 8C84B738 */ lw $a0, %lo(D_802AB738)($a0) -.L802AB034: -/* 41FDC4 802AB034 8FA90060 */ lw $t1, 0x60($sp) -/* 41FDC8 802AB038 02E91021 */ addu $v0, $s7, $t1 -/* 41FDCC 802AB03C 80430000 */ lb $v1, ($v0) -/* 41FDD0 802AB040 00031080 */ sll $v0, $v1, 2 -/* 41FDD4 802AB044 00431021 */ addu $v0, $v0, $v1 -/* 41FDD8 802AB048 00021080 */ sll $v0, $v0, 2 -/* 41FDDC 802AB04C 2442022C */ addiu $v0, $v0, 0x22c -/* 41FDE0 802AB050 02C28821 */ addu $s1, $s6, $v0 -/* 41FDE4 802AB054 0C09A75B */ jal get_actor -/* 41FDE8 802AB058 86240000 */ lh $a0, ($s1) -/* 41FDEC 802AB05C 0040802D */ daddu $s0, $v0, $zero -/* 41FDF0 802AB060 86250002 */ lh $a1, 2($s1) -/* 41FDF4 802AB064 0C099117 */ jal get_actor_part -/* 41FDF8 802AB068 0200202D */ daddu $a0, $s0, $zero -/* 41FDFC 802AB06C 8C420008 */ lw $v0, 8($v0) -/* 41FE00 802AB070 8C440020 */ lw $a0, 0x20($v0) -/* 41FE04 802AB074 1480001E */ bnez $a0, .L802AB0F0 -/* 41FE08 802AB078 00000000 */ nop -/* 41FE0C 802AB07C 92020136 */ lbu $v0, 0x136($s0) -/* 41FE10 802AB080 00021080 */ sll $v0, $v0, 2 -/* 41FE14 802AB084 3C048028 */ lui $a0, %hi(bActorNames) -/* 41FE18 802AB088 00822021 */ addu $a0, $a0, $v0 -/* 41FE1C 802AB08C 8C841104 */ lw $a0, %lo(bActorNames)($a0) -/* 41FE20 802AB090 080AAC3C */ j .L802AB0F0 -/* 41FE24 802AB094 00000000 */ nop -.L802AB098: -/* 41FE28 802AB098 8FA90060 */ lw $t1, 0x60($sp) -/* 41FE2C 802AB09C 02E91021 */ addu $v0, $s7, $t1 -/* 41FE30 802AB0A0 80430000 */ lb $v1, ($v0) -/* 41FE34 802AB0A4 00031080 */ sll $v0, $v1, 2 -/* 41FE38 802AB0A8 00431021 */ addu $v0, $v0, $v1 -/* 41FE3C 802AB0AC 00021080 */ sll $v0, $v0, 2 -/* 41FE40 802AB0B0 2442022C */ addiu $v0, $v0, 0x22c -/* 41FE44 802AB0B4 02C28821 */ addu $s1, $s6, $v0 -/* 41FE48 802AB0B8 86230000 */ lh $v1, ($s1) -/* 41FE4C 802AB0BC 14600004 */ bnez $v1, .L802AB0D0 -/* 41FE50 802AB0C0 24020100 */ addiu $v0, $zero, 0x100 -/* 41FE54 802AB0C4 3C04001D */ lui $a0, 0x1d -/* 41FE58 802AB0C8 080AAC3C */ j .L802AB0F0 -/* 41FE5C 802AB0CC 348400C4 */ ori $a0, $a0, 0xc4 -.L802AB0D0: -/* 41FE60 802AB0D0 14620006 */ bne $v1, $v0, .L802AB0EC -/* 41FE64 802AB0D4 3C04001D */ lui $a0, 0x1d -/* 41FE68 802AB0D8 00121080 */ sll $v0, $s2, 2 -/* 41FE6C 802AB0DC 3C04802B */ lui $a0, %hi(D_802AB738) -/* 41FE70 802AB0E0 00822021 */ addu $a0, $a0, $v0 -/* 41FE74 802AB0E4 080AAC3C */ j .L802AB0F0 -/* 41FE78 802AB0E8 8C84B738 */ lw $a0, %lo(D_802AB738)($a0) -.L802AB0EC: -/* 41FE7C 802AB0EC 348400C5 */ ori $a0, $a0, 0xc5 -.L802AB0F0: -/* 41FE80 802AB0F0 0C04991D */ jal get_msg_width -/* 41FE84 802AB0F4 0000282D */ daddu $a1, $zero, $zero -/* 41FE88 802AB0F8 2442000A */ addiu $v0, $v0, 0xa -/* 41FE8C 802AB0FC 0000202D */ daddu $a0, $zero, $zero -/* 41FE90 802AB100 8FA30050 */ lw $v1, 0x50($sp) -/* 41FE94 802AB104 8FA70054 */ lw $a3, 0x54($sp) -/* 41FE98 802AB108 24050004 */ addiu $a1, $zero, 4 -/* 41FE9C 802AB10C AFA20014 */ sw $v0, 0x14($sp) -/* 41FEA0 802AB110 24020014 */ addiu $v0, $zero, 0x14 -/* 41FEA4 802AB114 AFA20018 */ sw $v0, 0x18($sp) -/* 41FEA8 802AB118 240200FF */ addiu $v0, $zero, 0xff -/* 41FEAC 802AB11C AFA2001C */ sw $v0, 0x1c($sp) -/* 41FEB0 802AB120 24020140 */ addiu $v0, $zero, 0x140 -/* 41FEB4 802AB124 3C10802B */ lui $s0, %hi(D_802ACC68) -/* 41FEB8 802AB128 2610CC68 */ addiu $s0, $s0, %lo(D_802ACC68) -/* 41FEBC 802AB12C AFA00010 */ sw $zero, 0x10($sp) -/* 41FEC0 802AB130 AFA00020 */ sw $zero, 0x20($sp) -/* 41FEC4 802AB134 AFA00024 */ sw $zero, 0x24($sp) -/* 41FEC8 802AB138 AFA00028 */ sw $zero, 0x28($sp) -/* 41FECC 802AB13C AFA0002C */ sw $zero, 0x2c($sp) -/* 41FED0 802AB140 AFA00030 */ sw $zero, 0x30($sp) -/* 41FED4 802AB144 AFA00034 */ sw $zero, 0x34($sp) -/* 41FED8 802AB148 AFA00038 */ sw $zero, 0x38($sp) -/* 41FEDC 802AB14C AFA0003C */ sw $zero, 0x3c($sp) -/* 41FEE0 802AB150 AFA00040 */ sw $zero, 0x40($sp) -/* 41FEE4 802AB154 AFA20044 */ sw $v0, 0x44($sp) -/* 41FEE8 802AB158 8E060000 */ lw $a2, ($s0) -/* 41FEEC 802AB15C 240200F0 */ addiu $v0, $zero, 0xf0 -/* 41FEF0 802AB160 AFA20048 */ sw $v0, 0x48($sp) -/* 41FEF4 802AB164 AFA0004C */ sw $zero, 0x4c($sp) -/* 41FEF8 802AB168 0C03D4B8 */ jal draw_box -/* 41FEFC 802AB16C 00663021 */ addu $a2, $v1, $a2 -/* 41FF00 802AB170 8FA20050 */ lw $v0, 0x50($sp) -/* 41FF04 802AB174 8FA30054 */ lw $v1, 0x54($sp) -/* 41FF08 802AB178 24480004 */ addiu $t0, $v0, 4 -/* 41FF0C 802AB17C 3C02800E */ lui $v0, %hi(gBattleStatus+0x184) -/* 41FF10 802AB180 8C42C1F4 */ lw $v0, %lo(gBattleStatus+0x184)($v0) -/* 41FF14 802AB184 24660002 */ addiu $a2, $v1, 2 -/* 41FF18 802AB188 AFA80050 */ sw $t0, 0x50($sp) -/* 41FF1C 802AB18C 30420001 */ andi $v0, $v0, 1 -/* 41FF20 802AB190 14400005 */ bnez $v0, .L802AB1A8 -/* 41FF24 802AB194 AFA60054 */ sw $a2, 0x54($sp) -/* 41FF28 802AB198 8FA9005C */ lw $t1, 0x5c($sp) -/* 41FF2C 802AB19C 24020001 */ addiu $v0, $zero, 1 -/* 41FF30 802AB1A0 15220032 */ bne $t1, $v0, .L802AB26C -/* 41FF34 802AB1A4 00000000 */ nop -.L802AB1A8: -/* 41FF38 802AB1A8 86230000 */ lh $v1, ($s1) -/* 41FF3C 802AB1AC 14600004 */ bnez $v1, .L802AB1C0 -/* 41FF40 802AB1B0 24020100 */ addiu $v0, $zero, 0x100 -/* 41FF44 802AB1B4 3C04001D */ lui $a0, 0x1d -/* 41FF48 802AB1B8 080AACB5 */ j .L802AB2D4 -/* 41FF4C 802AB1BC 348400C4 */ ori $a0, $a0, 0xc4 -.L802AB1C0: -/* 41FF50 802AB1C0 1462000A */ bne $v1, $v0, .L802AB1EC -/* 41FF54 802AB1C4 24020036 */ addiu $v0, $zero, 0x36 -/* 41FF58 802AB1C8 AFA20010 */ sw $v0, 0x10($sp) -/* 41FF5C 802AB1CC 00121080 */ sll $v0, $s2, 2 -/* 41FF60 802AB1D0 AFA00014 */ sw $zero, 0x14($sp) -/* 41FF64 802AB1D4 8E050000 */ lw $a1, ($s0) -/* 41FF68 802AB1D8 3C04802B */ lui $a0, %hi(D_802AB738) -/* 41FF6C 802AB1DC 00822021 */ addu $a0, $a0, $v0 -/* 41FF70 802AB1E0 8C84B738 */ lw $a0, %lo(D_802AB738)($a0) -/* 41FF74 802AB1E4 080AACBA */ j .L802AB2E8 -/* 41FF78 802AB1E8 240700FF */ addiu $a3, $zero, 0xff -.L802AB1EC: -/* 41FF7C 802AB1EC 8FA90060 */ lw $t1, 0x60($sp) -/* 41FF80 802AB1F0 02E91021 */ addu $v0, $s7, $t1 -/* 41FF84 802AB1F4 80430000 */ lb $v1, ($v0) -/* 41FF88 802AB1F8 00031080 */ sll $v0, $v1, 2 -/* 41FF8C 802AB1FC 00431021 */ addu $v0, $v0, $v1 -/* 41FF90 802AB200 00021080 */ sll $v0, $v0, 2 -/* 41FF94 802AB204 2442022C */ addiu $v0, $v0, 0x22c -/* 41FF98 802AB208 02C28821 */ addu $s1, $s6, $v0 -/* 41FF9C 802AB20C 0C09A75B */ jal get_actor -/* 41FFA0 802AB210 86240000 */ lh $a0, ($s1) -/* 41FFA4 802AB214 0040802D */ daddu $s0, $v0, $zero -/* 41FFA8 802AB218 86250002 */ lh $a1, 2($s1) -/* 41FFAC 802AB21C 0C099117 */ jal get_actor_part -/* 41FFB0 802AB220 0200202D */ daddu $a0, $s0, $zero -/* 41FFB4 802AB224 8C420008 */ lw $v0, 8($v0) -/* 41FFB8 802AB228 8C440020 */ lw $a0, 0x20($v0) -/* 41FFBC 802AB22C 14800006 */ bnez $a0, .L802AB248 -/* 41FFC0 802AB230 240700FF */ addiu $a3, $zero, 0xff -/* 41FFC4 802AB234 92020136 */ lbu $v0, 0x136($s0) -/* 41FFC8 802AB238 00021080 */ sll $v0, $v0, 2 -/* 41FFCC 802AB23C 3C048028 */ lui $a0, %hi(bActorNames) -/* 41FFD0 802AB240 00822021 */ addu $a0, $a0, $v0 -/* 41FFD4 802AB244 8C841104 */ lw $a0, %lo(bActorNames)($a0) -.L802AB248: -/* 41FFD8 802AB248 8FA30050 */ lw $v1, 0x50($sp) -/* 41FFDC 802AB24C 3C05802B */ lui $a1, %hi(D_802ACC68) -/* 41FFE0 802AB250 8CA5CC68 */ lw $a1, %lo(D_802ACC68)($a1) -/* 41FFE4 802AB254 8FA60054 */ lw $a2, 0x54($sp) -/* 41FFE8 802AB258 24020036 */ addiu $v0, $zero, 0x36 -/* 41FFEC 802AB25C AFA20010 */ sw $v0, 0x10($sp) -/* 41FFF0 802AB260 AFA00014 */ sw $zero, 0x14($sp) -/* 41FFF4 802AB264 080AACBB */ j .L802AB2EC -/* 41FFF8 802AB268 00652821 */ addu $a1, $v1, $a1 -.L802AB26C: -/* 41FFFC 802AB26C 8FA90060 */ lw $t1, 0x60($sp) -/* 420000 802AB270 02E91021 */ addu $v0, $s7, $t1 -/* 420004 802AB274 80430000 */ lb $v1, ($v0) -/* 420008 802AB278 00031080 */ sll $v0, $v1, 2 -/* 42000C 802AB27C 00431021 */ addu $v0, $v0, $v1 -/* 420010 802AB280 00021080 */ sll $v0, $v0, 2 -/* 420014 802AB284 00568821 */ addu $s1, $v0, $s6 -/* 420018 802AB288 8623022C */ lh $v1, 0x22c($s1) -/* 42001C 802AB28C 14600004 */ bnez $v1, .L802AB2A0 -/* 420020 802AB290 24020100 */ addiu $v0, $zero, 0x100 -/* 420024 802AB294 3C04001D */ lui $a0, 0x1d -/* 420028 802AB298 080AACB5 */ j .L802AB2D4 -/* 42002C 802AB29C 348400C4 */ ori $a0, $a0, 0xc4 -.L802AB2A0: -/* 420030 802AB2A0 1462000B */ bne $v1, $v0, .L802AB2D0 -/* 420034 802AB2A4 3C04001D */ lui $a0, 0x1d -/* 420038 802AB2A8 24020036 */ addiu $v0, $zero, 0x36 -/* 42003C 802AB2AC AFA20010 */ sw $v0, 0x10($sp) -/* 420040 802AB2B0 00121080 */ sll $v0, $s2, 2 -/* 420044 802AB2B4 AFA00014 */ sw $zero, 0x14($sp) -/* 420048 802AB2B8 8E050000 */ lw $a1, ($s0) -/* 42004C 802AB2BC 3C04802B */ lui $a0, %hi(D_802AB738) -/* 420050 802AB2C0 00822021 */ addu $a0, $a0, $v0 -/* 420054 802AB2C4 8C84B738 */ lw $a0, %lo(D_802AB738)($a0) -/* 420058 802AB2C8 080AACBA */ j .L802AB2E8 -/* 42005C 802AB2CC 240700FF */ addiu $a3, $zero, 0xff -.L802AB2D0: -/* 420060 802AB2D0 348400C5 */ ori $a0, $a0, 0xc5 -.L802AB2D4: -/* 420064 802AB2D4 240700FF */ addiu $a3, $zero, 0xff -/* 420068 802AB2D8 8E050000 */ lw $a1, ($s0) -/* 42006C 802AB2DC 24020036 */ addiu $v0, $zero, 0x36 -/* 420070 802AB2E0 AFA20010 */ sw $v0, 0x10($sp) -/* 420074 802AB2E4 AFA00014 */ sw $zero, 0x14($sp) -.L802AB2E8: -/* 420078 802AB2E8 01052821 */ addu $a1, $t0, $a1 -.L802AB2EC: -/* 42007C 802AB2EC 0C04993B */ jal draw_msg -/* 420080 802AB2F0 00000000 */ nop -.L802AB2F4: -/* 420084 802AB2F4 8FBF008C */ lw $ra, 0x8c($sp) -/* 420088 802AB2F8 8FBE0088 */ lw $fp, 0x88($sp) -/* 42008C 802AB2FC 8FB70084 */ lw $s7, 0x84($sp) -/* 420090 802AB300 8FB60080 */ lw $s6, 0x80($sp) -/* 420094 802AB304 8FB5007C */ lw $s5, 0x7c($sp) -/* 420098 802AB308 8FB40078 */ lw $s4, 0x78($sp) -/* 42009C 802AB30C 8FB30074 */ lw $s3, 0x74($sp) -/* 4200A0 802AB310 8FB20070 */ lw $s2, 0x70($sp) -/* 4200A4 802AB314 8FB1006C */ lw $s1, 0x6c($sp) -/* 4200A8 802AB318 8FB00068 */ lw $s0, 0x68($sp) -/* 4200AC 802AB31C D7B800A0 */ ldc1 $f24, 0xa0($sp) -/* 4200B0 802AB320 D7B60098 */ ldc1 $f22, 0x98($sp) -/* 4200B4 802AB324 D7B40090 */ ldc1 $f20, 0x90($sp) -/* 4200B8 802AB328 03E00008 */ jr $ra -/* 4200BC 802AB32C 27BD00A8 */ addiu $sp, $sp, 0xa8 diff --git a/ver/us/asm/nonmatchings/415D90/btl_state_update_select_target.s b/ver/us/asm/nonmatchings/415D90/btl_state_update_select_target.s deleted file mode 100644 index df2a38d4a2..0000000000 --- a/ver/us/asm/nonmatchings/415D90/btl_state_update_select_target.s +++ /dev/null @@ -1,452 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel btl_state_update_select_target -/* 41F418 802AA688 27BDFFD0 */ addiu $sp, $sp, -0x30 -/* 41F41C 802AA68C AFB40020 */ sw $s4, 0x20($sp) -/* 41F420 802AA690 3C14800E */ lui $s4, %hi(gBattleStatus) -/* 41F424 802AA694 2694C070 */ addiu $s4, $s4, %lo(gBattleStatus) -/* 41F428 802AA698 AFBF0028 */ sw $ra, 0x28($sp) -/* 41F42C 802AA69C AFB50024 */ sw $s5, 0x24($sp) -/* 41F430 802AA6A0 AFB3001C */ sw $s3, 0x1c($sp) -/* 41F434 802AA6A4 AFB20018 */ sw $s2, 0x18($sp) -/* 41F438 802AA6A8 AFB10014 */ sw $s1, 0x14($sp) -/* 41F43C 802AA6AC AFB00010 */ sw $s0, 0x10($sp) -/* 41F440 802AA6B0 8E820000 */ lw $v0, ($s4) -/* 41F444 802AA6B4 3C030008 */ lui $v1, 8 -/* 41F448 802AA6B8 00431024 */ and $v0, $v0, $v1 -/* 41F44C 802AA6BC 14400004 */ bnez $v0, .L802AA6D0 -/* 41F450 802AA6C0 3C02F7FF */ lui $v0, 0xf7ff -/* 41F454 802AA6C4 8E9200D8 */ lw $s2, 0xd8($s4) -/* 41F458 802AA6C8 080AA9B6 */ j .L802AA6D8 -/* 41F45C 802AA6CC 3442FFFF */ ori $v0, $v0, 0xffff -.L802AA6D0: -/* 41F460 802AA6D0 8E9200DC */ lw $s2, 0xdc($s4) -/* 41F464 802AA6D4 3442FFFF */ ori $v0, $v0, 0xffff -.L802AA6D8: -/* 41F468 802AA6D8 8253040C */ lb $s3, 0x40c($s2) -/* 41F46C 802AA6DC 8E430000 */ lw $v1, ($s2) -/* 41F470 802AA6E0 82500425 */ lb $s0, 0x425($s2) -/* 41F474 802AA6E4 00621824 */ and $v1, $v1, $v0 -/* 41F478 802AA6E8 AE430000 */ sw $v1, ($s2) -/* 41F47C 802AA6EC 3C03800E */ lui $v1, %hi(gBattleState2) -/* 41F480 802AA6F0 8C63C4DC */ lw $v1, %lo(gBattleState2)($v1) -/* 41F484 802AA6F4 24020001 */ addiu $v0, $zero, 1 -/* 41F488 802AA6F8 10620085 */ beq $v1, $v0, .L802AA910 -/* 41F48C 802AA6FC 2655040D */ addiu $s5, $s2, 0x40d -/* 41F490 802AA700 28620002 */ slti $v0, $v1, 2 -/* 41F494 802AA704 50400005 */ beql $v0, $zero, .L802AA71C -/* 41F498 802AA708 24020002 */ addiu $v0, $zero, 2 -/* 41F49C 802AA70C 10600009 */ beqz $v1, .L802AA734 -/* 41F4A0 802AA710 24040015 */ addiu $a0, $zero, 0x15 -/* 41F4A4 802AA714 080AAB2D */ j .L802AACB4 -/* 41F4A8 802AA718 00000000 */ nop -.L802AA71C: -/* 41F4AC 802AA71C 106200D7 */ beq $v1, $v0, .L802AAA7C -/* 41F4B0 802AA720 2402000A */ addiu $v0, $zero, 0xa -/* 41F4B4 802AA724 1062011B */ beq $v1, $v0, .L802AAB94 -/* 41F4B8 802AA728 00000000 */ nop -/* 41F4BC 802AA72C 080AAB2D */ j .L802AACB4 -/* 41F4C0 802AA730 00000000 */ nop -.L802AA734: -/* 41F4C4 802AA734 240200FF */ addiu $v0, $zero, 0xff -/* 41F4C8 802AA738 3C01802B */ lui $at, %hi(D_802ACC64) -/* 41F4CC 802AA73C AC22CC64 */ sw $v0, %lo(D_802ACC64)($at) -/* 41F4D0 802AA740 2402FF9C */ addiu $v0, $zero, -0x64 -/* 41F4D4 802AA744 3C10800E */ lui $s0, %hi(gBattleStatus) -/* 41F4D8 802AA748 2610C070 */ addiu $s0, $s0, %lo(gBattleStatus) -/* 41F4DC 802AA74C 3C01802B */ lui $at, %hi(D_802ACC68) -/* 41F4E0 802AA750 AC22CC68 */ sw $v0, %lo(D_802ACC68)($at) -/* 41F4E4 802AA754 8E020000 */ lw $v0, ($s0) -/* 41F4E8 802AA758 2403FFFD */ addiu $v1, $zero, -3 -/* 41F4EC 802AA75C 00431024 */ and $v0, $v0, $v1 -/* 41F4F0 802AA760 0C03A752 */ jal is_ability_active -/* 41F4F4 802AA764 AE020000 */ sw $v0, ($s0) -/* 41F4F8 802AA768 10400005 */ beqz $v0, .L802AA780 -/* 41F4FC 802AA76C 3C030008 */ lui $v1, 8 -/* 41F500 802AA770 8E020000 */ lw $v0, ($s0) -/* 41F504 802AA774 00431024 */ and $v0, $v0, $v1 -/* 41F508 802AA778 1040000D */ beqz $v0, .L802AA7B0 -/* 41F50C 802AA77C 00000000 */ nop -.L802AA780: -/* 41F510 802AA780 8683017C */ lh $v1, 0x17c($s4) -/* 41F514 802AA784 1060000A */ beqz $v1, .L802AA7B0 -/* 41F518 802AA788 00031080 */ sll $v0, $v1, 2 -/* 41F51C 802AA78C 00431021 */ addu $v0, $v0, $v1 -/* 41F520 802AA790 00021080 */ sll $v0, $v0, 2 -/* 41F524 802AA794 3C048009 */ lui $a0, %hi(gMoveTable+0x13) -/* 41F528 802AA798 00822021 */ addu $a0, $a0, $v0 -/* 41F52C 802AA79C 8084F073 */ lb $a0, %lo(gMoveTable+0x13)($a0) -/* 41F530 802AA7A0 04800003 */ bltz $a0, .L802AA7B0 -/* 41F534 802AA7A4 2484002E */ addiu $a0, $a0, 0x2e -/* 41F538 802AA7A8 0C093E58 */ jal btl_show_battle_message -/* 41F53C 802AA7AC 2405003C */ addiu $a1, $zero, 0x3c -.L802AA7B0: -/* 41F540 802AA7B0 0C098C0B */ jal player_create_target_list -/* 41F544 802AA7B4 0240202D */ daddu $a0, $s2, $zero -/* 41F548 802AA7B8 8E820184 */ lw $v0, 0x184($s4) -/* 41F54C 802AA7BC 8253040C */ lb $s3, 0x40c($s2) -/* 41F550 802AA7C0 30420001 */ andi $v0, $v0, 1 -/* 41F554 802AA7C4 10400018 */ beqz $v0, .L802AA828 -/* 41F558 802AA7C8 00000000 */ nop -/* 41F55C 802AA7CC 2655040D */ addiu $s5, $s2, 0x40d -/* 41F560 802AA7D0 1A600015 */ blez $s3, .L802AA828 -/* 41F564 802AA7D4 0000802D */ daddu $s0, $zero, $zero -/* 41F568 802AA7D8 02B01021 */ addu $v0, $s5, $s0 -.L802AA7DC: -/* 41F56C 802AA7DC 80430000 */ lb $v1, ($v0) -/* 41F570 802AA7E0 00031080 */ sll $v0, $v1, 2 -/* 41F574 802AA7E4 00431021 */ addu $v0, $v0, $v1 -/* 41F578 802AA7E8 00021080 */ sll $v0, $v0, 2 -/* 41F57C 802AA7EC 2442022C */ addiu $v0, $v0, 0x22c -/* 41F580 802AA7F0 02428821 */ addu $s1, $s2, $v0 -/* 41F584 802AA7F4 0C09A75B */ jal get_actor -/* 41F588 802AA7F8 86240000 */ lh $a0, ($s1) -/* 41F58C 802AA7FC 86250002 */ lh $a1, 2($s1) -/* 41F590 802AA800 0C099117 */ jal get_actor_part -/* 41F594 802AA804 0040202D */ daddu $a0, $v0, $zero -/* 41F598 802AA808 8C420000 */ lw $v0, ($v0) -/* 41F59C 802AA80C 30420008 */ andi $v0, $v0, 8 -/* 41F5A0 802AA810 54400005 */ bnel $v0, $zero, .L802AA828 -/* 41F5A4 802AA814 A2500425 */ sb $s0, 0x425($s2) -/* 41F5A8 802AA818 26100001 */ addiu $s0, $s0, 1 -/* 41F5AC 802AA81C 0213102A */ slt $v0, $s0, $s3 -/* 41F5B0 802AA820 1440FFEE */ bnez $v0, .L802AA7DC -/* 41F5B4 802AA824 02B01021 */ addu $v0, $s5, $s0 -.L802AA828: -/* 41F5B8 802AA828 8E820184 */ lw $v0, 0x184($s4) -/* 41F5BC 802AA82C 04410015 */ bgez $v0, .L802AA884 -/* 41F5C0 802AA830 3C030008 */ lui $v1, 8 -/* 41F5C4 802AA834 3C04800E */ lui $a0, %hi(gBattleStatus) -/* 41F5C8 802AA838 2484C070 */ addiu $a0, $a0, %lo(gBattleStatus) -/* 41F5CC 802AA83C 8C820000 */ lw $v0, ($a0) -/* 41F5D0 802AA840 00431024 */ and $v0, $v0, $v1 -/* 41F5D4 802AA844 14400006 */ bnez $v0, .L802AA860 -/* 41F5D8 802AA848 00000000 */ nop -.L802AA84C: -/* 41F5DC 802AA84C 8683006E */ lh $v1, 0x6e($s4) -/* 41F5E0 802AA850 3C01800E */ lui $at, %hi(gBattleState2) -/* 41F5E4 802AA854 AC23C4DC */ sw $v1, %lo(gBattleState2)($at) -/* 41F5E8 802AA858 080AAACE */ j .L802AAB38 -/* 41F5EC 802AA85C 00000000 */ nop -.L802AA860: -/* 41F5F0 802AA860 8C820004 */ lw $v0, 4($a0) -/* 41F5F4 802AA864 8683006E */ lh $v1, 0x6e($s4) -/* 41F5F8 802AA868 30420040 */ andi $v0, $v0, 0x40 -/* 41F5FC 802AA86C 3C01800E */ lui $at, %hi(gBattleState2) -/* 41F600 802AA870 AC23C4DC */ sw $v1, %lo(gBattleState2)($at) -/* 41F604 802AA874 104000C1 */ beqz $v0, .L802AAB7C -/* 41F608 802AA878 00000000 */ nop -/* 41F60C 802AA87C 080AAADB */ j .L802AAB6C -/* 41F610 802AA880 00000000 */ nop -.L802AA884: -/* 41F614 802AA884 16600009 */ bnez $s3, .L802AA8AC -/* 41F618 802AA888 00000000 */ nop -/* 41F61C 802AA88C 3C04800E */ lui $a0, %hi(gBattleStatus) -/* 41F620 802AA890 2484C070 */ addiu $a0, $a0, %lo(gBattleStatus) -/* 41F624 802AA894 8C820000 */ lw $v0, ($a0) -/* 41F628 802AA898 00431024 */ and $v0, $v0, $v1 -/* 41F62C 802AA89C 1040FFEB */ beqz $v0, .L802AA84C -/* 41F630 802AA8A0 00000000 */ nop -/* 41F634 802AA8A4 080AAA18 */ j .L802AA860 -/* 41F638 802AA8A8 00000000 */ nop -.L802AA8AC: -/* 41F63C 802AA8AC 1A600013 */ blez $s3, .L802AA8FC -/* 41F640 802AA8B0 0000802D */ daddu $s0, $zero, $zero -/* 41F644 802AA8B4 3C12802B */ lui $s2, %hi(D_802ACC70) -/* 41F648 802AA8B8 2652CC70 */ addiu $s2, $s2, %lo(D_802ACC70) -.L802AA8BC: -/* 41F64C 802AA8BC 3C048008 */ lui $a0, %hi(HES_HandPointDownLoop) -/* 41F650 802AA8C0 2484FF20 */ addiu $a0, $a0, %lo(HES_HandPointDownLoop) -/* 41F654 802AA8C4 0C050529 */ jal hud_element_create -/* 41F658 802AA8C8 26100001 */ addiu $s0, $s0, 1 -/* 41F65C 802AA8CC 0040882D */ daddu $s1, $v0, $zero -/* 41F660 802AA8D0 AE510000 */ sw $s1, ($s2) -/* 41F664 802AA8D4 0220202D */ daddu $a0, $s1, $zero -/* 41F668 802AA8D8 0C051277 */ jal hud_element_set_render_depth -/* 41F66C 802AA8DC 0000282D */ daddu $a1, $zero, $zero -/* 41F670 802AA8E0 0220202D */ daddu $a0, $s1, $zero -/* 41F674 802AA8E4 0000282D */ daddu $a1, $zero, $zero -/* 41F678 802AA8E8 0C051261 */ jal hud_element_set_render_pos -/* 41F67C 802AA8EC 2406FF9C */ addiu $a2, $zero, -0x64 -/* 41F680 802AA8F0 0213102A */ slt $v0, $s0, $s3 -/* 41F684 802AA8F4 1440FFF1 */ bnez $v0, .L802AA8BC -/* 41F688 802AA8F8 26520004 */ addiu $s2, $s2, 4 -.L802AA8FC: -/* 41F68C 802AA8FC 24020001 */ addiu $v0, $zero, 1 -/* 41F690 802AA900 3C01800E */ lui $at, %hi(gBattleState2) -/* 41F694 802AA904 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -/* 41F698 802AA908 080AAB2D */ j .L802AACB4 -/* 41F69C 802AA90C 00000000 */ nop -.L802AA910: -/* 41F6A0 802AA910 3C03802B */ lui $v1, %hi(D_802ACC68) -/* 41F6A4 802AA914 2463CC68 */ addiu $v1, $v1, %lo(D_802ACC68) -/* 41F6A8 802AA918 8C620000 */ lw $v0, ($v1) -/* 41F6AC 802AA91C 04410004 */ bgez $v0, .L802AA930 -/* 41F6B0 802AA920 24420014 */ addiu $v0, $v0, 0x14 -/* 41F6B4 802AA924 18400002 */ blez $v0, .L802AA930 -/* 41F6B8 802AA928 AC620000 */ sw $v0, ($v1) -/* 41F6BC 802AA92C AC600000 */ sw $zero, ($v1) -.L802AA930: -/* 41F6C0 802AA930 8E830214 */ lw $v1, 0x214($s4) -/* 41F6C4 802AA934 30624000 */ andi $v0, $v1, 0x4000 -/* 41F6C8 802AA938 10400008 */ beqz $v0, .L802AA95C -/* 41F6CC 802AA93C 30628000 */ andi $v0, $v1, 0x8000 -/* 41F6D0 802AA940 0C05272D */ jal sfx_play_sound -/* 41F6D4 802AA944 240400CA */ addiu $a0, $zero, 0xca -/* 41F6D8 802AA948 2402000A */ addiu $v0, $zero, 0xa -/* 41F6DC 802AA94C 3C01800E */ lui $at, %hi(gBattleState2) -/* 41F6E0 802AA950 AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -/* 41F6E4 802AA954 080AAB2D */ j .L802AACB4 -/* 41F6E8 802AA958 00000000 */ nop -.L802AA95C: -/* 41F6EC 802AA95C 1040000E */ beqz $v0, .L802AA998 -/* 41F6F0 802AA960 00000000 */ nop -/* 41F6F4 802AA964 0C05272D */ jal sfx_play_sound -/* 41F6F8 802AA968 240400C9 */ addiu $a0, $zero, 0xc9 -/* 41F6FC 802AA96C 24020008 */ addiu $v0, $zero, 8 -/* 41F700 802AA970 3C01802B */ lui $at, %hi(D_802ACC60) -/* 41F704 802AA974 AC22CC60 */ sw $v0, %lo(D_802ACC60)($at) -/* 41F708 802AA978 24020004 */ addiu $v0, $zero, 4 -/* 41F70C 802AA97C 3C01802B */ lui $at, %hi(D_802ACC6C) -/* 41F710 802AA980 AC22CC6C */ sw $v0, %lo(D_802ACC6C)($at) -/* 41F714 802AA984 24020002 */ addiu $v0, $zero, 2 -/* 41F718 802AA988 3C01800E */ lui $at, %hi(gBattleState2) -/* 41F71C 802AA98C AC22C4DC */ sw $v0, %lo(gBattleState2)($at) -/* 41F720 802AA990 080AAB2D */ j .L802AACB4 -/* 41F724 802AA994 00000000 */ nop -.L802AA998: -/* 41F728 802AA998 3C04800E */ lui $a0, %hi(gBattleStatus) -/* 41F72C 802AA99C 2484C070 */ addiu $a0, $a0, %lo(gBattleStatus) -/* 41F730 802AA9A0 8C830000 */ lw $v1, ($a0) -/* 41F734 802AA9A4 8E820210 */ lw $v0, 0x210($s4) -/* 41F738 802AA9A8 34630002 */ ori $v1, $v1, 2 -/* 41F73C 802AA9AC 30422010 */ andi $v0, $v0, 0x2010 -/* 41F740 802AA9B0 10400005 */ beqz $v0, .L802AA9C8 -/* 41F744 802AA9B4 AC830000 */ sw $v1, ($a0) -/* 41F748 802AA9B8 2402FFFD */ addiu $v0, $zero, -3 -/* 41F74C 802AA9BC 00621024 */ and $v0, $v1, $v0 -/* 41F750 802AA9C0 080AAB2D */ j .L802AACB4 -/* 41F754 802AA9C4 AC820000 */ sw $v0, ($a0) -.L802AA9C8: -/* 41F758 802AA9C8 8E820184 */ lw $v0, 0x184($s4) -/* 41F75C 802AA9CC 30420001 */ andi $v0, $v0, 1 -/* 41F760 802AA9D0 104000B8 */ beqz $v0, .L802AACB4 -/* 41F764 802AA9D4 3C020004 */ lui $v0, 4 -/* 41F768 802AA9D8 8E830218 */ lw $v1, 0x218($s4) -/* 41F76C 802AA9DC 00621024 */ and $v0, $v1, $v0 -/* 41F770 802AA9E0 10400002 */ beqz $v0, .L802AA9EC -/* 41F774 802AA9E4 0200202D */ daddu $a0, $s0, $zero -/* 41F778 802AA9E8 2610FFFF */ addiu $s0, $s0, -1 -.L802AA9EC: -/* 41F77C 802AA9EC 3C020008 */ lui $v0, 8 -/* 41F780 802AA9F0 00621024 */ and $v0, $v1, $v0 -/* 41F784 802AA9F4 54400001 */ bnel $v0, $zero, .L802AA9FC -/* 41F788 802AA9F8 26100001 */ addiu $s0, $s0, 1 -.L802AA9FC: -/* 41F78C 802AA9FC 06020001 */ bltzl $s0, .L802AAA04 -/* 41F790 802AAA00 2670FFFF */ addiu $s0, $s3, -1 -.L802AAA04: -/* 41F794 802AAA04 0213102A */ slt $v0, $s0, $s3 -/* 41F798 802AAA08 50400001 */ beql $v0, $zero, .L802AAA10 -/* 41F79C 802AAA0C 0000802D */ daddu $s0, $zero, $zero -.L802AAA10: -/* 41F7A0 802AAA10 12040018 */ beq $s0, $a0, .L802AAA74 -/* 41F7A4 802AAA14 02B01021 */ addu $v0, $s5, $s0 -/* 41F7A8 802AAA18 80430000 */ lb $v1, ($v0) -/* 41F7AC 802AAA1C 00031080 */ sll $v0, $v1, 2 -/* 41F7B0 802AAA20 00431021 */ addu $v0, $v0, $v1 -/* 41F7B4 802AAA24 00021080 */ sll $v0, $v0, 2 -/* 41F7B8 802AAA28 00528821 */ addu $s1, $v0, $s2 -/* 41F7BC 802AAA2C 0C09A75B */ jal get_actor -/* 41F7C0 802AAA30 8624022C */ lh $a0, 0x22c($s1) -/* 41F7C4 802AAA34 8C420000 */ lw $v0, ($v0) -/* 41F7C8 802AAA38 3C11802B */ lui $s1, %hi(D_802ACC70) -/* 41F7CC 802AAA3C 8E31CC70 */ lw $s1, %lo(D_802ACC70)($s1) -/* 41F7D0 802AAA40 30420800 */ andi $v0, $v0, 0x800 -/* 41F7D4 802AAA44 10400005 */ beqz $v0, .L802AAA5C -/* 41F7D8 802AAA48 0220202D */ daddu $a0, $s1, $zero -/* 41F7DC 802AAA4C 3C058008 */ lui $a1, %hi(HES_HandPointLeftLoop) -/* 41F7E0 802AAA50 24A50208 */ addiu $a1, $a1, %lo(HES_HandPointLeftLoop) -/* 41F7E4 802AAA54 080AAA99 */ j .L802AAA64 -/* 41F7E8 802AAA58 00000000 */ nop -.L802AAA5C: -/* 41F7EC 802AAA5C 3C058008 */ lui $a1, %hi(HES_HandPointDownLoop) -/* 41F7F0 802AAA60 24A5FF20 */ addiu $a1, $a1, %lo(HES_HandPointDownLoop) -.L802AAA64: -/* 41F7F4 802AAA64 0C0511FF */ jal hud_element_set_script -/* 41F7F8 802AAA68 00000000 */ nop -/* 41F7FC 802AAA6C 0C05272D */ jal sfx_play_sound -/* 41F800 802AAA70 240400C7 */ addiu $a0, $zero, 0xc7 -.L802AAA74: -/* 41F804 802AAA74 080AAB2D */ j .L802AACB4 -/* 41F808 802AAA78 A2500425 */ sb $s0, 0x425($s2) -.L802AAA7C: -/* 41F80C 802AAA7C 3C04800E */ lui $a0, %hi(gBattleStatus) -/* 41F810 802AAA80 2484C070 */ addiu $a0, $a0, %lo(gBattleStatus) -/* 41F814 802AAA84 8C820000 */ lw $v0, ($a0) -/* 41F818 802AAA88 2403FFFD */ addiu $v1, $zero, -3 -/* 41F81C 802AAA8C 00431024 */ and $v0, $v0, $v1 -/* 41F820 802AAA90 AC820000 */ sw $v0, ($a0) -/* 41F824 802AAA94 82420425 */ lb $v0, 0x425($s2) -/* 41F828 802AAA98 02A21021 */ addu $v0, $s5, $v0 -/* 41F82C 802AAA9C 80430000 */ lb $v1, ($v0) -/* 41F830 802AAAA0 00031080 */ sll $v0, $v1, 2 -/* 41F834 802AAAA4 00431021 */ addu $v0, $v0, $v1 -/* 41F838 802AAAA8 00021080 */ sll $v0, $v0, 2 -/* 41F83C 802AAAAC 2442022C */ addiu $v0, $v0, 0x22c -/* 41F840 802AAAB0 02428821 */ addu $s1, $s2, $v0 -/* 41F844 802AAAB4 96220000 */ lhu $v0, ($s1) -/* 41F848 802AAAB8 A6420428 */ sh $v0, 0x428($s2) -/* 41F84C 802AAABC 92220003 */ lbu $v0, 3($s1) -/* 41F850 802AAAC0 0000802D */ daddu $s0, $zero, $zero -/* 41F854 802AAAC4 1A60000C */ blez $s3, .L802AAAF8 -/* 41F858 802AAAC8 A2420426 */ sb $v0, 0x426($s2) -/* 41F85C 802AAACC 3C11802B */ lui $s1, %hi(D_802ACC70) -/* 41F860 802AAAD0 2631CC70 */ addiu $s1, $s1, %lo(D_802ACC70) -.L802AAAD4: -/* 41F864 802AAAD4 8E240000 */ lw $a0, ($s1) -/* 41F868 802AAAD8 26310004 */ addiu $s1, $s1, 4 -/* 41F86C 802AAADC 0C05123D */ jal hud_element_free -/* 41F870 802AAAE0 26100001 */ addiu $s0, $s0, 1 -/* 41F874 802AAAE4 0213102A */ slt $v0, $s0, $s3 -/* 41F878 802AAAE8 1440FFFA */ bnez $v0, .L802AAAD4 -/* 41F87C 802AAAEC 00000000 */ nop -/* 41F880 802AAAF0 3C04800E */ lui $a0, %hi(gBattleStatus) -/* 41F884 802AAAF4 2484C070 */ addiu $a0, $a0, %lo(gBattleStatus) -.L802AAAF8: -/* 41F888 802AAAF8 8C820000 */ lw $v0, ($a0) -/* 41F88C 802AAAFC 3C030008 */ lui $v1, 8 -/* 41F890 802AAB00 00431024 */ and $v0, $v0, $v1 -/* 41F894 802AAB04 14400012 */ bnez $v0, .L802AAB50 -/* 41F898 802AAB08 00000000 */ nop -/* 41F89C 802AAB0C 8C820004 */ lw $v0, 4($a0) -/* 41F8A0 802AAB10 8683006E */ lh $v1, 0x6e($s4) -/* 41F8A4 802AAB14 30420040 */ andi $v0, $v0, 0x40 -/* 41F8A8 802AAB18 3C01800E */ lui $at, %hi(gBattleState2) -/* 41F8AC 802AAB1C AC23C4DC */ sw $v1, %lo(gBattleState2)($at) -/* 41F8B0 802AAB20 10400005 */ beqz $v0, .L802AAB38 -/* 41F8B4 802AAB24 00000000 */ nop -/* 41F8B8 802AAB28 0C0AA6D1 */ jal btl_state_update_peach_menu -/* 41F8BC 802AAB2C 00000000 */ nop -/* 41F8C0 802AAB30 080AAAD0 */ j .L802AAB40 -/* 41F8C4 802AAB34 00000000 */ nop -.L802AAB38: -/* 41F8C8 802AAB38 0C0A9662 */ jal btl_state_update_player_menu -/* 41F8CC 802AAB3C 00000000 */ nop -.L802AAB40: -/* 41F8D0 802AAB40 0C090464 */ jal btl_set_state -/* 41F8D4 802AAB44 24040012 */ addiu $a0, $zero, 0x12 -/* 41F8D8 802AAB48 080AAB2D */ j .L802AACB4 -/* 41F8DC 802AAB4C 00000000 */ nop -.L802AAB50: -/* 41F8E0 802AAB50 8C820004 */ lw $v0, 4($a0) -/* 41F8E4 802AAB54 8683006E */ lh $v1, 0x6e($s4) -/* 41F8E8 802AAB58 30420040 */ andi $v0, $v0, 0x40 -/* 41F8EC 802AAB5C 3C01800E */ lui $at, %hi(gBattleState2) -/* 41F8F0 802AAB60 AC23C4DC */ sw $v1, %lo(gBattleState2)($at) -/* 41F8F4 802AAB64 10400005 */ beqz $v0, .L802AAB7C -/* 41F8F8 802AAB68 00000000 */ nop -.L802AAB6C: -/* 41F8FC 802AAB6C 0C0AA82E */ jal btl_state_update_twink_menu -/* 41F900 802AAB70 00000000 */ nop -/* 41F904 802AAB74 080AAAE1 */ j .L802AAB84 -/* 41F908 802AAB78 00000000 */ nop -.L802AAB7C: -/* 41F90C 802AAB7C 0C0AA072 */ jal btl_state_update_partner_menu -/* 41F910 802AAB80 00000000 */ nop -.L802AAB84: -/* 41F914 802AAB84 0C090464 */ jal btl_set_state -/* 41F918 802AAB88 24040013 */ addiu $a0, $zero, 0x13 -/* 41F91C 802AAB8C 080AAB2D */ j .L802AACB4 -/* 41F920 802AAB90 00000000 */ nop -.L802AAB94: -/* 41F924 802AAB94 1A60000A */ blez $s3, .L802AABC0 -/* 41F928 802AAB98 0000802D */ daddu $s0, $zero, $zero -/* 41F92C 802AAB9C 3C11802B */ lui $s1, %hi(D_802ACC70) -/* 41F930 802AABA0 2631CC70 */ addiu $s1, $s1, %lo(D_802ACC70) -.L802AABA4: -/* 41F934 802AABA4 8E240000 */ lw $a0, ($s1) -/* 41F938 802AABA8 26310004 */ addiu $s1, $s1, 4 -/* 41F93C 802AABAC 0C05123D */ jal hud_element_free -/* 41F940 802AABB0 26100001 */ addiu $s0, $s0, 1 -/* 41F944 802AABB4 0213102A */ slt $v0, $s0, $s3 -/* 41F948 802AABB8 1440FFFA */ bnez $v0, .L802AABA4 -/* 41F94C 802AABBC 00000000 */ nop -.L802AABC0: -/* 41F950 802AABC0 3C030001 */ lui $v1, 1 -/* 41F954 802AABC4 3C10800E */ lui $s0, %hi(gBattleStatus) -/* 41F958 802AABC8 2610C070 */ addiu $s0, $s0, %lo(gBattleStatus) -/* 41F95C 802AABCC 8E020000 */ lw $v0, ($s0) -/* 41F960 802AABD0 34630002 */ ori $v1, $v1, 2 -/* 41F964 802AABD4 00431025 */ or $v0, $v0, $v1 -/* 41F968 802AABD8 AE020000 */ sw $v0, ($s0) -/* 41F96C 802AABDC 8E420000 */ lw $v0, ($s2) -/* 41F970 802AABE0 3C030800 */ lui $v1, 0x800 -/* 41F974 802AABE4 00431025 */ or $v0, $v0, $v1 -/* 41F978 802AABE8 AE420000 */ sw $v0, ($s2) -/* 41F97C 802AABEC 82820088 */ lb $v0, 0x88($s4) -/* 41F980 802AABF0 1040000C */ beqz $v0, .L802AAC24 -/* 41F984 802AABF4 3C030008 */ lui $v1, 8 -/* 41F988 802AABF8 0C090464 */ jal btl_set_state -/* 41F98C 802AABFC 2404000D */ addiu $a0, $zero, 0xd -/* 41F990 802AAC00 8E020004 */ lw $v0, 4($s0) -/* 41F994 802AAC04 8683006C */ lh $v1, 0x6c($s4) -/* 41F998 802AAC08 30420040 */ andi $v0, $v0, 0x40 -/* 41F99C 802AAC0C 3C01800E */ lui $at, %hi(gBattleState2) -/* 41F9A0 802AAC10 AC23C4DC */ sw $v1, %lo(gBattleState2)($at) -/* 41F9A4 802AAC14 10400014 */ beqz $v0, .L802AAC68 -/* 41F9A8 802AAC18 00000000 */ nop -/* 41F9AC 802AAC1C 080AAB16 */ j .L802AAC58 -/* 41F9B0 802AAC20 00000000 */ nop -.L802AAC24: -/* 41F9B4 802AAC24 8E020000 */ lw $v0, ($s0) -/* 41F9B8 802AAC28 00431024 */ and $v0, $v0, $v1 -/* 41F9BC 802AAC2C 14400012 */ bnez $v0, .L802AAC78 -/* 41F9C0 802AAC30 00000000 */ nop -/* 41F9C4 802AAC34 0C090464 */ jal btl_set_state -/* 41F9C8 802AAC38 2404000D */ addiu $a0, $zero, 0xd -/* 41F9CC 802AAC3C 8E020004 */ lw $v0, 4($s0) -/* 41F9D0 802AAC40 8683006C */ lh $v1, 0x6c($s4) -/* 41F9D4 802AAC44 30420040 */ andi $v0, $v0, 0x40 -/* 41F9D8 802AAC48 3C01800E */ lui $at, %hi(gBattleState2) -/* 41F9DC 802AAC4C AC23C4DC */ sw $v1, %lo(gBattleState2)($at) -/* 41F9E0 802AAC50 10400005 */ beqz $v0, .L802AAC68 -/* 41F9E4 802AAC54 00000000 */ nop -.L802AAC58: -/* 41F9E8 802AAC58 0C0AA6D1 */ jal btl_state_update_peach_menu -/* 41F9EC 802AAC5C 00000000 */ nop -/* 41F9F0 802AAC60 080AAB2D */ j .L802AACB4 -/* 41F9F4 802AAC64 00000000 */ nop -.L802AAC68: -/* 41F9F8 802AAC68 0C0A9662 */ jal btl_state_update_player_menu -/* 41F9FC 802AAC6C 00000000 */ nop -/* 41FA00 802AAC70 080AAB2D */ j .L802AACB4 -/* 41FA04 802AAC74 00000000 */ nop -.L802AAC78: -/* 41FA08 802AAC78 0C090464 */ jal btl_set_state -/* 41FA0C 802AAC7C 2404000E */ addiu $a0, $zero, 0xe -/* 41FA10 802AAC80 8E020004 */ lw $v0, 4($s0) -/* 41FA14 802AAC84 8683006C */ lh $v1, 0x6c($s4) -/* 41FA18 802AAC88 30420040 */ andi $v0, $v0, 0x40 -/* 41FA1C 802AAC8C 3C01800E */ lui $at, %hi(gBattleState2) -/* 41FA20 802AAC90 AC23C4DC */ sw $v1, %lo(gBattleState2)($at) -/* 41FA24 802AAC94 10400005 */ beqz $v0, .L802AACAC -/* 41FA28 802AAC98 00000000 */ nop -/* 41FA2C 802AAC9C 0C0AA82E */ jal btl_state_update_twink_menu -/* 41FA30 802AACA0 00000000 */ nop -/* 41FA34 802AACA4 080AAB2D */ j .L802AACB4 -/* 41FA38 802AACA8 00000000 */ nop -.L802AACAC: -/* 41FA3C 802AACAC 0C0AA072 */ jal btl_state_update_partner_menu -/* 41FA40 802AACB0 00000000 */ nop -.L802AACB4: -/* 41FA44 802AACB4 8FBF0028 */ lw $ra, 0x28($sp) -/* 41FA48 802AACB8 8FB50024 */ lw $s5, 0x24($sp) -/* 41FA4C 802AACBC 8FB40020 */ lw $s4, 0x20($sp) -/* 41FA50 802AACC0 8FB3001C */ lw $s3, 0x1c($sp) -/* 41FA54 802AACC4 8FB20018 */ lw $s2, 0x18($sp) -/* 41FA58 802AACC8 8FB10014 */ lw $s1, 0x14($sp) -/* 41FA5C 802AACCC 8FB00010 */ lw $s0, 0x10($sp) -/* 41FA60 802AACD0 03E00008 */ jr $ra -/* 41FA64 802AACD4 27BD0030 */ addiu $sp, $sp, 0x30 diff --git a/ver/us/asm/nonmatchings/415D90/func_802A2C84.s b/ver/us/asm/nonmatchings/415D90/func_802A2C84.s deleted file mode 100644 index 6cd8a0403f..0000000000 --- a/ver/us/asm/nonmatchings/415D90/func_802A2C84.s +++ /dev/null @@ -1,1120 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel jtbl_802AB808 -.word .L802A38AC_41863C, .L802A3718_4184A8, .L802A2CE4_417A74, .L802A3490_418220, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A38DC_41866C, .L802A3974_418704, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A399C_41872C, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3A20_4187B0, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3C6C_4189FC, .L802A3A78_418808, .L802A3A9C_41882C, .L802A3BC0_418950, 0 - -.section .text - -glabel func_802A2C84 -/* 417A14 802A2C84 3C02802B */ lui $v0, %hi(battle_menu_moveState) -/* 417A18 802A2C88 9042D108 */ lbu $v0, %lo(battle_menu_moveState)($v0) -/* 417A1C 802A2C8C 27BDFFB8 */ addiu $sp, $sp, -0x48 -/* 417A20 802A2C90 AFB1002C */ sw $s1, 0x2c($sp) -/* 417A24 802A2C94 3C11800E */ lui $s1, %hi(gBattleStatus) -/* 417A28 802A2C98 2631C070 */ addiu $s1, $s1, %lo(gBattleStatus) -/* 417A2C 802A2C9C AFBF0044 */ sw $ra, 0x44($sp) -/* 417A30 802A2CA0 AFB60040 */ sw $s6, 0x40($sp) -/* 417A34 802A2CA4 AFB5003C */ sw $s5, 0x3c($sp) -/* 417A38 802A2CA8 AFB40038 */ sw $s4, 0x38($sp) -/* 417A3C 802A2CAC AFB30034 */ sw $s3, 0x34($sp) -/* 417A40 802A2CB0 AFB20030 */ sw $s2, 0x30($sp) -/* 417A44 802A2CB4 24420002 */ addiu $v0, $v0, 2 -/* 417A48 802A2CB8 00021600 */ sll $v0, $v0, 0x18 -/* 417A4C 802A2CBC 00021E03 */ sra $v1, $v0, 0x18 -/* 417A50 802A2CC0 2C62002D */ sltiu $v0, $v1, 0x2d -/* 417A54 802A2CC4 104003E9 */ beqz $v0, .L802A3C6C_4189FC -/* 417A58 802A2CC8 AFB00028 */ sw $s0, 0x28($sp) -/* 417A5C 802A2CCC 00031080 */ sll $v0, $v1, 2 -/* 417A60 802A2CD0 3C01802B */ lui $at, %hi(jtbl_802AB808) -/* 417A64 802A2CD4 00220821 */ addu $at, $at, $v0 -/* 417A68 802A2CD8 8C22B808 */ lw $v0, %lo(jtbl_802AB808)($at) -/* 417A6C 802A2CDC 00400008 */ jr $v0 -/* 417A70 802A2CE0 00000000 */ nop -.L802A2CE4_417A74: -/* 417A74 802A2CE4 3C05802B */ lui $a1, %hi(battle_menu_moveScrollLine) -/* 417A78 802A2CE8 80A5D10C */ lb $a1, %lo(battle_menu_moveScrollLine)($a1) -/* 417A7C 802A2CEC 3C04802B */ lui $a0, %hi(battle_menu_moveCursorPos) -/* 417A80 802A2CF0 8084D109 */ lb $a0, %lo(battle_menu_moveCursorPos)($a0) -/* 417A84 802A2CF4 24020014 */ addiu $v0, $zero, 0x14 -/* 417A88 802A2CF8 3C01802B */ lui $at, %hi(battle_menu_moveX) -/* 417A8C 802A2CFC A422D1F0 */ sh $v0, %lo(battle_menu_moveX)($at) -/* 417A90 802A2D00 24020044 */ addiu $v0, $zero, 0x44 -/* 417A94 802A2D04 3C01802B */ lui $at, %hi(battle_menu_moveY) -/* 417A98 802A2D08 A422D1F2 */ sh $v0, %lo(battle_menu_moveY)($at) -/* 417A9C 802A2D0C 00051823 */ negu $v1, $a1 -/* 417AA0 802A2D10 00031040 */ sll $v0, $v1, 1 -/* 417AA4 802A2D14 00431021 */ addu $v0, $v0, $v1 -/* 417AA8 802A2D18 00021080 */ sll $v0, $v0, 2 -/* 417AAC 802A2D1C 00431021 */ addu $v0, $v0, $v1 -/* 417AB0 802A2D20 00852023 */ subu $a0, $a0, $a1 -/* 417AB4 802A2D24 3C01802B */ lui $at, %hi(battle_menu_moveScrollOffset) -/* 417AB8 802A2D28 A422D110 */ sh $v0, %lo(battle_menu_moveScrollOffset)($at) -/* 417ABC 802A2D2C 00041040 */ sll $v0, $a0, 1 -/* 417AC0 802A2D30 00441021 */ addu $v0, $v0, $a0 -/* 417AC4 802A2D34 00021080 */ sll $v0, $v0, 2 -/* 417AC8 802A2D38 3C05802B */ lui $a1, %hi(battle_menu_moveOptionCount) -/* 417ACC 802A2D3C 24A5D4A4 */ addiu $a1, $a1, %lo(battle_menu_moveOptionCount) -/* 417AD0 802A2D40 8CA30000 */ lw $v1, ($a1) -/* 417AD4 802A2D44 00441021 */ addu $v0, $v0, $a0 -/* 417AD8 802A2D48 3C01802B */ lui $at, %hi(D_802AD112) -/* 417ADC 802A2D4C A422D112 */ sh $v0, %lo(D_802AD112)($at) -/* 417AE0 802A2D50 18600009 */ blez $v1, .L802A2D78 -/* 417AE4 802A2D54 0000802D */ daddu $s0, $zero, $zero -/* 417AE8 802A2D58 3C03802B */ lui $v1, %hi(battle_menu_moveOptionIndexMap) -/* 417AEC 802A2D5C 2463D1F8 */ addiu $v1, $v1, %lo(battle_menu_moveOptionIndexMap) -.L802A2D60: -/* 417AF0 802A2D60 AC700000 */ sw $s0, ($v1) -/* 417AF4 802A2D64 8CA20000 */ lw $v0, ($a1) -/* 417AF8 802A2D68 26100001 */ addiu $s0, $s0, 1 -/* 417AFC 802A2D6C 0202102A */ slt $v0, $s0, $v0 -/* 417B00 802A2D70 1440FFFB */ bnez $v0, .L802A2D60 -/* 417B04 802A2D74 24630004 */ addiu $v1, $v1, 4 -.L802A2D78: -/* 417B08 802A2D78 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 417B0C 802A2D7C 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 417B10 802A2D80 14400042 */ bnez $v0, .L802A2E8C -/* 417B14 802A2D84 00000000 */ nop -/* 417B18 802A2D88 3C03802B */ lui $v1, %hi(battle_menu_moveOptionCount) -/* 417B1C 802A2D8C 8C63D4A4 */ lw $v1, %lo(battle_menu_moveOptionCount)($v1) -/* 417B20 802A2D90 2462FFFF */ addiu $v0, $v1, -1 -/* 417B24 802A2D94 1840003D */ blez $v0, .L802A2E8C -/* 417B28 802A2D98 0000802D */ daddu $s0, $zero, $zero -/* 417B2C 802A2D9C 0060882D */ daddu $s1, $v1, $zero -/* 417B30 802A2DA0 3C0E802B */ lui $t6, %hi(battle_menu_moveOptionSortPriorities) -/* 417B34 802A2DA4 25CED5D0 */ addiu $t6, $t6, %lo(battle_menu_moveOptionSortPriorities) -/* 417B38 802A2DA8 3C0D802B */ lui $t5, %hi(battle_menu_moveOptionDisplayCosts) -/* 417B3C 802A2DAC 25ADD320 */ addiu $t5, $t5, %lo(battle_menu_moveOptionDisplayCosts) -/* 417B40 802A2DB0 3C0C802B */ lui $t4, %hi(battle_menu_moveOptionBPCosts) -/* 417B44 802A2DB4 258CD440 */ addiu $t4, $t4, %lo(battle_menu_moveOptionBPCosts) -/* 417B48 802A2DB8 3C0F802B */ lui $t7, %hi(battle_menu_moveOptionIndexMap) -/* 417B4C 802A2DBC 25EFD1F8 */ addiu $t7, $t7, %lo(battle_menu_moveOptionIndexMap) -/* 417B50 802A2DC0 01E0502D */ daddu $t2, $t7, $zero -.L802A2DC4: -/* 417B54 802A2DC4 26090001 */ addiu $t1, $s0, 1 -/* 417B58 802A2DC8 0131102A */ slt $v0, $t1, $s1 -/* 417B5C 802A2DCC 10400028 */ beqz $v0, .L802A2E70 -/* 417B60 802A2DD0 00091080 */ sll $v0, $t1, 2 -/* 417B64 802A2DD4 0140402D */ daddu $t0, $t2, $zero -/* 417B68 802A2DD8 3C0B802B */ lui $t3, %hi(battle_menu_moveOptionCount) -/* 417B6C 802A2DDC 8D6BD4A4 */ lw $t3, %lo(battle_menu_moveOptionCount)($t3) -/* 417B70 802A2DE0 004F3821 */ addu $a3, $v0, $t7 -.L802A2DE4: -/* 417B74 802A2DE4 8D060000 */ lw $a2, ($t0) -/* 417B78 802A2DE8 8CE40000 */ lw $a0, ($a3) -/* 417B7C 802A2DEC 00CE1021 */ addu $v0, $a2, $t6 -/* 417B80 802A2DF0 008E1821 */ addu $v1, $a0, $t6 -/* 417B84 802A2DF4 80450000 */ lb $a1, ($v0) -/* 417B88 802A2DF8 80630000 */ lb $v1, ($v1) -/* 417B8C 802A2DFC 00A3102A */ slt $v0, $a1, $v1 -/* 417B90 802A2E00 54400018 */ bnel $v0, $zero, .L802A2E64 -/* 417B94 802A2E04 25290001 */ addiu $t1, $t1, 1 -/* 417B98 802A2E08 14A30011 */ bne $a1, $v1, .L802A2E50 -/* 417B9C 802A2E0C 00063080 */ sll $a2, $a2, 2 -/* 417BA0 802A2E10 00CD1821 */ addu $v1, $a2, $t5 -/* 417BA4 802A2E14 00042080 */ sll $a0, $a0, 2 -/* 417BA8 802A2E18 008D1021 */ addu $v0, $a0, $t5 -/* 417BAC 802A2E1C 8C630000 */ lw $v1, ($v1) -/* 417BB0 802A2E20 8C450000 */ lw $a1, ($v0) -/* 417BB4 802A2E24 0065102A */ slt $v0, $v1, $a1 -/* 417BB8 802A2E28 5440000E */ bnel $v0, $zero, .L802A2E64 -/* 417BBC 802A2E2C 25290001 */ addiu $t1, $t1, 1 -/* 417BC0 802A2E30 14650007 */ bne $v1, $a1, .L802A2E50 -/* 417BC4 802A2E34 00CC1021 */ addu $v0, $a2, $t4 -/* 417BC8 802A2E38 008C2021 */ addu $a0, $a0, $t4 -/* 417BCC 802A2E3C 8C430000 */ lw $v1, ($v0) -/* 417BD0 802A2E40 8C820000 */ lw $v0, ($a0) -/* 417BD4 802A2E44 0062182A */ slt $v1, $v1, $v0 -/* 417BD8 802A2E48 54600006 */ bnel $v1, $zero, .L802A2E64 -/* 417BDC 802A2E4C 25290001 */ addiu $t1, $t1, 1 -.L802A2E50: -/* 417BE0 802A2E50 8CE20000 */ lw $v0, ($a3) -/* 417BE4 802A2E54 8D030000 */ lw $v1, ($t0) -/* 417BE8 802A2E58 AD020000 */ sw $v0, ($t0) -/* 417BEC 802A2E5C ACE30000 */ sw $v1, ($a3) -/* 417BF0 802A2E60 25290001 */ addiu $t1, $t1, 1 -.L802A2E64: -/* 417BF4 802A2E64 012B102A */ slt $v0, $t1, $t3 -/* 417BF8 802A2E68 1440FFDE */ bnez $v0, .L802A2DE4 -/* 417BFC 802A2E6C 24E70004 */ addiu $a3, $a3, 4 -.L802A2E70: -/* 417C00 802A2E70 3C02802B */ lui $v0, %hi(battle_menu_moveOptionCount) -/* 417C04 802A2E74 8C42D4A4 */ lw $v0, %lo(battle_menu_moveOptionCount)($v0) -/* 417C08 802A2E78 26100001 */ addiu $s0, $s0, 1 -/* 417C0C 802A2E7C 2442FFFF */ addiu $v0, $v0, -1 -/* 417C10 802A2E80 0202102A */ slt $v0, $s0, $v0 -/* 417C14 802A2E84 1440FFCF */ bnez $v0, .L802A2DC4 -/* 417C18 802A2E88 254A0004 */ addiu $t2, $t2, 4 -.L802A2E8C: -/* 417C1C 802A2E8C 3C02802B */ lui $v0, %hi(battle_menu_moveOptionCount) -/* 417C20 802A2E90 8C42D4A4 */ lw $v0, %lo(battle_menu_moveOptionCount)($v0) -/* 417C24 802A2E94 1840001C */ blez $v0, .L802A2F08 -/* 417C28 802A2E98 0000802D */ daddu $s0, $zero, $zero -/* 417C2C 802A2E9C 3C14802B */ lui $s4, %hi(battle_menu_moveOptionIconScripts) -/* 417C30 802A2EA0 2694D260 */ addiu $s4, $s4, %lo(battle_menu_moveOptionIconScripts) -/* 417C34 802A2EA4 3C13802B */ lui $s3, %hi(battle_menu_moveOptionIconIDs) -/* 417C38 802A2EA8 2673D128 */ addiu $s3, $s3, %lo(battle_menu_moveOptionIconIDs) -/* 417C3C 802A2EAC 3C11802B */ lui $s1, %hi(battle_menu_moveOptionIndexMap) -/* 417C40 802A2EB0 2631D1F8 */ addiu $s1, $s1, %lo(battle_menu_moveOptionIndexMap) -.L802A2EB4: -/* 417C44 802A2EB4 8E220000 */ lw $v0, ($s1) -/* 417C48 802A2EB8 26310004 */ addiu $s1, $s1, 4 -/* 417C4C 802A2EBC 00021080 */ sll $v0, $v0, 2 -/* 417C50 802A2EC0 00541021 */ addu $v0, $v0, $s4 -/* 417C54 802A2EC4 8C440000 */ lw $a0, ($v0) -/* 417C58 802A2EC8 0C050529 */ jal hud_element_create -/* 417C5C 802A2ECC 26100001 */ addiu $s0, $s0, 1 -/* 417C60 802A2ED0 0040902D */ daddu $s2, $v0, $zero -/* 417C64 802A2ED4 3C053EE6 */ lui $a1, 0x3ee6 -/* 417C68 802A2ED8 34A56666 */ ori $a1, $a1, 0x6666 -/* 417C6C 802A2EDC 0240202D */ daddu $a0, $s2, $zero -/* 417C70 802A2EE0 0C051308 */ jal hud_element_set_scale -/* 417C74 802A2EE4 AE720000 */ sw $s2, ($s3) -/* 417C78 802A2EE8 0240202D */ daddu $a0, $s2, $zero -/* 417C7C 802A2EEC 0C051280 */ jal hud_element_set_flags -/* 417C80 802A2EF0 34058080 */ ori $a1, $zero, 0x8080 -/* 417C84 802A2EF4 3C02802B */ lui $v0, %hi(battle_menu_moveOptionCount) -/* 417C88 802A2EF8 8C42D4A4 */ lw $v0, %lo(battle_menu_moveOptionCount)($v0) -/* 417C8C 802A2EFC 0202102A */ slt $v0, $s0, $v0 -/* 417C90 802A2F00 1440FFEC */ bnez $v0, .L802A2EB4 -/* 417C94 802A2F04 26730004 */ addiu $s3, $s3, 4 -.L802A2F08: -/* 417C98 802A2F08 3C048010 */ lui $a0, %hi(HES_AnimatedHandPointer) -/* 417C9C 802A2F0C 24844A28 */ addiu $a0, $a0, %lo(HES_AnimatedHandPointer) -/* 417CA0 802A2F10 0C050529 */ jal hud_element_create -/* 417CA4 802A2F14 00000000 */ nop -/* 417CA8 802A2F18 0040902D */ daddu $s2, $v0, $zero -/* 417CAC 802A2F1C 0240202D */ daddu $a0, $s2, $zero -/* 417CB0 802A2F20 3C052000 */ lui $a1, 0x2000 -/* 417CB4 802A2F24 3C01802B */ lui $at, %hi(battle_menu_moveCursorIcon) -/* 417CB8 802A2F28 AC32D118 */ sw $s2, %lo(battle_menu_moveCursorIcon)($at) -/* 417CBC 802A2F2C 0C051280 */ jal hud_element_set_flags -/* 417CC0 802A2F30 34A50080 */ ori $a1, $a1, 0x80 -/* 417CC4 802A2F34 3C11802B */ lui $s1, %hi(battle_menu_moveX) -/* 417CC8 802A2F38 2631D1F0 */ addiu $s1, $s1, %lo(battle_menu_moveX) -/* 417CCC 802A2F3C 3C10802B */ lui $s0, %hi(battle_menu_moveY) -/* 417CD0 802A2F40 2610D1F2 */ addiu $s0, $s0, %lo(battle_menu_moveY) -/* 417CD4 802A2F44 86250000 */ lh $a1, ($s1) -/* 417CD8 802A2F48 86060000 */ lh $a2, ($s0) -/* 417CDC 802A2F4C 0C051261 */ jal hud_element_set_render_pos -/* 417CE0 802A2F50 0240202D */ daddu $a0, $s2, $zero -/* 417CE4 802A2F54 3C048010 */ lui $a0, %hi(HES_GreenArrowUp) -/* 417CE8 802A2F58 248477E4 */ addiu $a0, $a0, %lo(HES_GreenArrowUp) -/* 417CEC 802A2F5C 0C050529 */ jal hud_element_create -/* 417CF0 802A2F60 00000000 */ nop -/* 417CF4 802A2F64 0040902D */ daddu $s2, $v0, $zero -/* 417CF8 802A2F68 0240202D */ daddu $a0, $s2, $zero -/* 417CFC 802A2F6C 3C052000 */ lui $a1, 0x2000 -/* 417D00 802A2F70 3C01802B */ lui $at, %hi(battle_menu_moveUpArrowIcon) -/* 417D04 802A2F74 AC32D11C */ sw $s2, %lo(battle_menu_moveUpArrowIcon)($at) -/* 417D08 802A2F78 0C051280 */ jal hud_element_set_flags -/* 417D0C 802A2F7C 34A50080 */ ori $a1, $a1, 0x80 -/* 417D10 802A2F80 0240202D */ daddu $a0, $s2, $zero -/* 417D14 802A2F84 86250000 */ lh $a1, ($s1) -/* 417D18 802A2F88 86060000 */ lh $a2, ($s0) -/* 417D1C 802A2F8C 24A50027 */ addiu $a1, $a1, 0x27 -/* 417D20 802A2F90 0C051261 */ jal hud_element_set_render_pos -/* 417D24 802A2F94 24C6FFF9 */ addiu $a2, $a2, -7 -/* 417D28 802A2F98 3C048010 */ lui $a0, %hi(HES_GreenArrowDown) -/* 417D2C 802A2F9C 24847798 */ addiu $a0, $a0, %lo(HES_GreenArrowDown) -/* 417D30 802A2FA0 0C050529 */ jal hud_element_create -/* 417D34 802A2FA4 00000000 */ nop -/* 417D38 802A2FA8 0040902D */ daddu $s2, $v0, $zero -/* 417D3C 802A2FAC 0240202D */ daddu $a0, $s2, $zero -/* 417D40 802A2FB0 3C052000 */ lui $a1, 0x2000 -/* 417D44 802A2FB4 3C01802B */ lui $at, %hi(battle_menu_moveDownArrowIcon) -/* 417D48 802A2FB8 AC32D120 */ sw $s2, %lo(battle_menu_moveDownArrowIcon)($at) -/* 417D4C 802A2FBC 0C051280 */ jal hud_element_set_flags -/* 417D50 802A2FC0 34A50080 */ ori $a1, $a1, 0x80 -/* 417D54 802A2FC4 0240202D */ daddu $a0, $s2, $zero -/* 417D58 802A2FC8 86250000 */ lh $a1, ($s1) -/* 417D5C 802A2FCC 86060000 */ lh $a2, ($s0) -/* 417D60 802A2FD0 24A50027 */ addiu $a1, $a1, 0x27 -/* 417D64 802A2FD4 0C051261 */ jal hud_element_set_render_pos -/* 417D68 802A2FD8 24C6004E */ addiu $a2, $a2, 0x4e -/* 417D6C 802A2FDC 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 417D70 802A2FE0 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 417D74 802A2FE4 1440000A */ bnez $v0, .L802A3010 -/* 417D78 802A2FE8 00000000 */ nop -/* 417D7C 802A2FEC 3C048011 */ lui $a0, %hi(HES_StatusFlower) -/* 417D80 802A2FF0 24848538 */ addiu $a0, $a0, %lo(HES_StatusFlower) -/* 417D84 802A2FF4 0C050529 */ jal hud_element_create -/* 417D88 802A2FF8 00000000 */ nop -/* 417D8C 802A2FFC 0040902D */ daddu $s2, $v0, $zero -/* 417D90 802A3000 3C01802B */ lui $at, %hi(battle_menu_moveTitleIcon) -/* 417D94 802A3004 AC22D188 */ sw $v0, %lo(battle_menu_moveTitleIcon)($at) -/* 417D98 802A3008 080A8C0F */ j .L802A303C -/* 417D9C 802A300C 0240202D */ daddu $a0, $s2, $zero -.L802A3010: -/* 417DA0 802A3010 3C048011 */ lui $a0, %hi(HES_MenuStarPower) -/* 417DA4 802A3014 24848974 */ addiu $a0, $a0, %lo(HES_MenuStarPower) -/* 417DA8 802A3018 0C050529 */ jal hud_element_create -/* 417DAC 802A301C 00000000 */ nop -/* 417DB0 802A3020 0040902D */ daddu $s2, $v0, $zero -/* 417DB4 802A3024 3C053F40 */ lui $a1, 0x3f40 -/* 417DB8 802A3028 3C01802B */ lui $at, %hi(battle_menu_moveTitleIcon) -/* 417DBC 802A302C AC32D188 */ sw $s2, %lo(battle_menu_moveTitleIcon)($at) -/* 417DC0 802A3030 0C051308 */ jal hud_element_set_scale -/* 417DC4 802A3034 0240202D */ daddu $a0, $s2, $zero -/* 417DC8 802A3038 0240202D */ daddu $a0, $s2, $zero -.L802A303C: -/* 417DCC 802A303C 0C051280 */ jal hud_element_set_flags -/* 417DD0 802A3040 24050080 */ addiu $a1, $zero, 0x80 -/* 417DD4 802A3044 0240202D */ daddu $a0, $s2, $zero -/* 417DD8 802A3048 3C05802B */ lui $a1, %hi(battle_menu_moveX) -/* 417DDC 802A304C 84A5D1F0 */ lh $a1, %lo(battle_menu_moveX)($a1) -/* 417DE0 802A3050 3C06802B */ lui $a2, %hi(battle_menu_moveY) -/* 417DE4 802A3054 84C6D1F2 */ lh $a2, %lo(battle_menu_moveY)($a2) -/* 417DE8 802A3058 0C051261 */ jal hud_element_set_render_pos -/* 417DEC 802A305C 24A50038 */ addiu $a1, $a1, 0x38 -/* 417DF0 802A3060 3C02802B */ lui $v0, %hi(battle_menu_moveOptionCount) -/* 417DF4 802A3064 8C42D4A4 */ lw $v0, %lo(battle_menu_moveOptionCount)($v0) -/* 417DF8 802A3068 1840004B */ blez $v0, .L802A3198 -/* 417DFC 802A306C 0000802D */ daddu $s0, $zero, $zero -/* 417E00 802A3070 24160001 */ addiu $s6, $zero, 1 -/* 417E04 802A3074 3C13802B */ lui $s3, %hi(battle_menu_moveOptionCostUnitIconIDs) -/* 417E08 802A3078 2673D190 */ addiu $s3, $s3, %lo(battle_menu_moveOptionCostUnitIconIDs) -/* 417E0C 802A307C 0260A82D */ daddu $s5, $s3, $zero -/* 417E10 802A3080 0200882D */ daddu $s1, $s0, $zero -/* 417E14 802A3084 3C14802B */ lui $s4, %hi(battle_menu_moveOptionDisplayCostReductionColors) -/* 417E18 802A3088 2694D3E0 */ addiu $s4, $s4, %lo(battle_menu_moveOptionDisplayCostReductionColors) -.L802A308C: -/* 417E1C 802A308C 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 417E20 802A3090 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 417E24 802A3094 14400014 */ bnez $v0, .L802A30E8 -/* 417E28 802A3098 00000000 */ nop -/* 417E2C 802A309C 8E820000 */ lw $v0, ($s4) -/* 417E30 802A30A0 10400005 */ beqz $v0, .L802A30B8 -/* 417E34 802A30A4 00000000 */ nop -/* 417E38 802A30A8 10560007 */ beq $v0, $s6, .L802A30C8 -/* 417E3C 802A30AC 00000000 */ nop -/* 417E40 802A30B0 080A8C36 */ j .L802A30D8 -/* 417E44 802A30B4 00000000 */ nop -.L802A30B8: -/* 417E48 802A30B8 3C048010 */ lui $a0, %hi(HES_FPCost) -/* 417E4C 802A30BC 24847638 */ addiu $a0, $a0, %lo(HES_FPCost) -/* 417E50 802A30C0 080A8C47 */ j .L802A311C -/* 417E54 802A30C4 00000000 */ nop -.L802A30C8: -/* 417E58 802A30C8 3C048010 */ lui $a0, %hi(HES_FPCostReduced) -/* 417E5C 802A30CC 24847664 */ addiu $a0, $a0, %lo(HES_FPCostReduced) -/* 417E60 802A30D0 080A8C47 */ j .L802A311C -/* 417E64 802A30D4 00000000 */ nop -.L802A30D8: -/* 417E68 802A30D8 3C048010 */ lui $a0, %hi(HES_FPCostReducedTwice) -/* 417E6C 802A30DC 24847690 */ addiu $a0, $a0, %lo(HES_FPCostReducedTwice) -/* 417E70 802A30E0 080A8C4F */ j .L802A313C -/* 417E74 802A30E4 00000000 */ nop -.L802A30E8: -/* 417E78 802A30E8 8E820000 */ lw $v0, ($s4) -/* 417E7C 802A30EC 10400005 */ beqz $v0, .L802A3104 -/* 417E80 802A30F0 00000000 */ nop -/* 417E84 802A30F4 10560007 */ beq $v0, $s6, .L802A3114 -/* 417E88 802A30F8 00000000 */ nop -/* 417E8C 802A30FC 080A8C4D */ j .L802A3134 -/* 417E90 802A3100 00000000 */ nop -.L802A3104: -/* 417E94 802A3104 3C048010 */ lui $a0, %hi(HES_POWCost) -/* 417E98 802A3108 248476E8 */ addiu $a0, $a0, %lo(HES_POWCost) -/* 417E9C 802A310C 080A8C47 */ j .L802A311C -/* 417EA0 802A3110 00000000 */ nop -.L802A3114: -/* 417EA4 802A3114 3C048010 */ lui $a0, %hi(HES_POWCostReduced) -/* 417EA8 802A3118 24847714 */ addiu $a0, $a0, %lo(HES_POWCostReduced) -.L802A311C: -/* 417EAC 802A311C 0C050529 */ jal hud_element_create -/* 417EB0 802A3120 00000000 */ nop -/* 417EB4 802A3124 0040902D */ daddu $s2, $v0, $zero -/* 417EB8 802A3128 02351021 */ addu $v0, $s1, $s5 -/* 417EBC 802A312C 080A8C53 */ j .L802A314C -/* 417EC0 802A3130 AC520000 */ sw $s2, ($v0) -.L802A3134: -/* 417EC4 802A3134 3C048010 */ lui $a0, %hi(HES_POWCostReducedTwice) -/* 417EC8 802A3138 24847740 */ addiu $a0, $a0, %lo(HES_POWCostReducedTwice) -.L802A313C: -/* 417ECC 802A313C 0C050529 */ jal hud_element_create -/* 417ED0 802A3140 00000000 */ nop -/* 417ED4 802A3144 0040902D */ daddu $s2, $v0, $zero -/* 417ED8 802A3148 AE720000 */ sw $s2, ($s3) -.L802A314C: -/* 417EDC 802A314C 0240202D */ daddu $a0, $s2, $zero -/* 417EE0 802A3150 0C051280 */ jal hud_element_set_flags -/* 417EE4 802A3154 24050080 */ addiu $a1, $zero, 0x80 -/* 417EE8 802A3158 0240202D */ daddu $a0, $s2, $zero -/* 417EEC 802A315C 26730004 */ addiu $s3, $s3, 4 -/* 417EF0 802A3160 26310004 */ addiu $s1, $s1, 4 -/* 417EF4 802A3164 26940004 */ addiu $s4, $s4, 4 -/* 417EF8 802A3168 3C05802B */ lui $a1, %hi(battle_menu_moveX) -/* 417EFC 802A316C 84A5D1F0 */ lh $a1, %lo(battle_menu_moveX)($a1) -/* 417F00 802A3170 3C06802B */ lui $a2, %hi(battle_menu_moveY) -/* 417F04 802A3174 84C6D1F2 */ lh $a2, %lo(battle_menu_moveY)($a2) -/* 417F08 802A3178 0C051261 */ jal hud_element_set_render_pos -/* 417F0C 802A317C 24A50038 */ addiu $a1, $a1, 0x38 -/* 417F10 802A3180 3C02802B */ lui $v0, %hi(battle_menu_moveOptionCount) -/* 417F14 802A3184 8C42D4A4 */ lw $v0, %lo(battle_menu_moveOptionCount)($v0) -/* 417F18 802A3188 26100001 */ addiu $s0, $s0, 1 -/* 417F1C 802A318C 0202102A */ slt $v0, $s0, $v0 -/* 417F20 802A3190 1440FFBE */ bnez $v0, .L802A308C -/* 417F24 802A3194 00000000 */ nop -.L802A3198: -/* 417F28 802A3198 3C13802B */ lui $s3, %hi(battle_menu_moveX) -/* 417F2C 802A319C 8673D1F0 */ lh $s3, %lo(battle_menu_moveX)($s3) -/* 417F30 802A31A0 2402000A */ addiu $v0, $zero, 0xa -/* 417F34 802A31A4 3C01802B */ lui $at, %hi(battle_menu_moveTextColor) -/* 417F38 802A31A8 A422D114 */ sh $v0, %lo(battle_menu_moveTextColor)($at) -/* 417F3C 802A31AC 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 417F40 802A31B0 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 417F44 802A31B4 3C12802B */ lui $s2, %hi(battle_menu_moveY) -/* 417F48 802A31B8 8652D1F2 */ lh $s2, %lo(battle_menu_moveY)($s2) -/* 417F4C 802A31BC 14400028 */ bnez $v0, .L802A3260 -/* 417F50 802A31C0 24040001 */ addiu $a0, $zero, 1 -/* 417F54 802A31C4 0260282D */ daddu $a1, $s3, $zero -/* 417F58 802A31C8 0240302D */ daddu $a2, $s2, $zero -/* 417F5C 802A31CC 24070096 */ addiu $a3, $zero, 0x96 -/* 417F60 802A31D0 3C02802A */ lui $v0, %hi(func_802A3C98) -/* 417F64 802A31D4 24423C98 */ addiu $v0, $v0, %lo(func_802A3C98) -/* 417F68 802A31D8 3C03802B */ lui $v1, %hi(D_802AD10E) -/* 417F6C 802A31DC 8063D10E */ lb $v1, %lo(D_802AD10E)($v1) -/* 417F70 802A31E0 2410FFFF */ addiu $s0, $zero, -1 -/* 417F74 802A31E4 AFA00014 */ sw $zero, 0x14($sp) -/* 417F78 802A31E8 AFA20018 */ sw $v0, 0x18($sp) -/* 417F7C 802A31EC AFA0001C */ sw $zero, 0x1c($sp) -/* 417F80 802A31F0 AFB00020 */ sw $s0, 0x20($sp) -/* 417F84 802A31F4 00831004 */ sllv $v0, $v1, $a0 -/* 417F88 802A31F8 00431021 */ addu $v0, $v0, $v1 -/* 417F8C 802A31FC 00021080 */ sll $v0, $v0, 2 -/* 417F90 802A3200 00431021 */ addu $v0, $v0, $v1 -/* 417F94 802A3204 2442001C */ addiu $v0, $v0, 0x1c -/* 417F98 802A3208 0C051F32 */ jal set_window_properties -/* 417F9C 802A320C AFA20010 */ sw $v0, 0x10($sp) -/* 417FA0 802A3210 24040002 */ addiu $a0, $zero, 2 -/* 417FA4 802A3214 26650010 */ addiu $a1, $s3, 0x10 -/* 417FA8 802A3218 2646FFFA */ addiu $a2, $s2, -6 -/* 417FAC 802A321C 2407005A */ addiu $a3, $zero, 0x5a -/* 417FB0 802A3220 24020010 */ addiu $v0, $zero, 0x10 -/* 417FB4 802A3224 24110001 */ addiu $s1, $zero, 1 -/* 417FB8 802A3228 AFA20010 */ sw $v0, 0x10($sp) -/* 417FBC 802A322C 3C02802A */ lui $v0, %hi(func_802A43DC) -/* 417FC0 802A3230 244243DC */ addiu $v0, $v0, %lo(func_802A43DC) -/* 417FC4 802A3234 AFB10014 */ sw $s1, 0x14($sp) -/* 417FC8 802A3238 AFA20018 */ sw $v0, 0x18($sp) -/* 417FCC 802A323C AFA0001C */ sw $zero, 0x1c($sp) -/* 417FD0 802A3240 0C051F32 */ jal set_window_properties -/* 417FD4 802A3244 AFB00020 */ sw $s0, 0x20($sp) -/* 417FD8 802A3248 24040003 */ addiu $a0, $zero, 3 -/* 417FDC 802A324C 26650072 */ addiu $a1, $s3, 0x72 -/* 417FE0 802A3250 2646FFF4 */ addiu $a2, $s2, -0xc -/* 417FE4 802A3254 24070020 */ addiu $a3, $zero, 0x20 -/* 417FE8 802A3258 080A8CBE */ j .L802A32F8 -/* 417FEC 802A325C 00E0102D */ daddu $v0, $a3, $zero -.L802A3260: -/* 417FF0 802A3260 0260282D */ daddu $a1, $s3, $zero -/* 417FF4 802A3264 0240302D */ daddu $a2, $s2, $zero -/* 417FF8 802A3268 24070090 */ addiu $a3, $zero, 0x90 -/* 417FFC 802A326C 3C02802A */ lui $v0, %hi(func_802A3C98) -/* 418000 802A3270 24423C98 */ addiu $v0, $v0, %lo(func_802A3C98) -/* 418004 802A3274 3C03802B */ lui $v1, %hi(D_802AD10E) -/* 418008 802A3278 8063D10E */ lb $v1, %lo(D_802AD10E)($v1) -/* 41800C 802A327C 2410FFFF */ addiu $s0, $zero, -1 -/* 418010 802A3280 AFA00014 */ sw $zero, 0x14($sp) -/* 418014 802A3284 AFA20018 */ sw $v0, 0x18($sp) -/* 418018 802A3288 AFA0001C */ sw $zero, 0x1c($sp) -/* 41801C 802A328C AFB00020 */ sw $s0, 0x20($sp) -/* 418020 802A3290 00831004 */ sllv $v0, $v1, $a0 -/* 418024 802A3294 00431021 */ addu $v0, $v0, $v1 -/* 418028 802A3298 00021080 */ sll $v0, $v0, 2 -/* 41802C 802A329C 00431021 */ addu $v0, $v0, $v1 -/* 418030 802A32A0 2442001C */ addiu $v0, $v0, 0x1c -/* 418034 802A32A4 0C051F32 */ jal set_window_properties -/* 418038 802A32A8 AFA20010 */ sw $v0, 0x10($sp) -/* 41803C 802A32AC 24040004 */ addiu $a0, $zero, 4 -/* 418040 802A32B0 2665000A */ addiu $a1, $s3, 0xa -/* 418044 802A32B4 2646FFFA */ addiu $a2, $s2, -6 -/* 418048 802A32B8 24070064 */ addiu $a3, $zero, 0x64 -/* 41804C 802A32BC 24020010 */ addiu $v0, $zero, 0x10 -/* 418050 802A32C0 24110001 */ addiu $s1, $zero, 1 -/* 418054 802A32C4 AFA20010 */ sw $v0, 0x10($sp) -/* 418058 802A32C8 3C02802A */ lui $v0, %hi(func_802A43DC) -/* 41805C 802A32CC 244243DC */ addiu $v0, $v0, %lo(func_802A43DC) -/* 418060 802A32D0 AFB10014 */ sw $s1, 0x14($sp) -/* 418064 802A32D4 AFA20018 */ sw $v0, 0x18($sp) -/* 418068 802A32D8 AFA0001C */ sw $zero, 0x1c($sp) -/* 41806C 802A32DC 0C051F32 */ jal set_window_properties -/* 418070 802A32E0 AFB00020 */ sw $s0, 0x20($sp) -/* 418074 802A32E4 24040005 */ addiu $a0, $zero, 5 -/* 418078 802A32E8 2665006E */ addiu $a1, $s3, 0x6e -/* 41807C 802A32EC 2646FFF4 */ addiu $a2, $s2, -0xc -/* 418080 802A32F0 24070020 */ addiu $a3, $zero, 0x20 -/* 418084 802A32F4 24020023 */ addiu $v0, $zero, 0x23 -.L802A32F8: -/* 418088 802A32F8 AFA20010 */ sw $v0, 0x10($sp) -/* 41808C 802A32FC 3C02802A */ lui $v0, %hi(func_802A4448) -/* 418090 802A3300 24424448 */ addiu $v0, $v0, %lo(func_802A4448) -/* 418094 802A3304 AFB10014 */ sw $s1, 0x14($sp) -/* 418098 802A3308 AFA20018 */ sw $v0, 0x18($sp) -/* 41809C 802A330C AFA0001C */ sw $zero, 0x1c($sp) -/* 4180A0 802A3310 0C051F32 */ jal set_window_properties -/* 4180A4 802A3314 AFB00020 */ sw $s0, 0x20($sp) -/* 4180A8 802A3318 24130014 */ addiu $s3, $zero, 0x14 -/* 4180AC 802A331C 24040008 */ addiu $a0, $zero, 8 -/* 4180B0 802A3320 0260282D */ daddu $a1, $s3, $zero -/* 4180B4 802A3324 240600BA */ addiu $a2, $zero, 0xba -/* 4180B8 802A3328 24070118 */ addiu $a3, $zero, 0x118 -/* 4180BC 802A332C 24020020 */ addiu $v0, $zero, 0x20 -/* 4180C0 802A3330 AFA20010 */ sw $v0, 0x10($sp) -/* 4180C4 802A3334 3C02802A */ lui $v0, %hi(func_802A4494) -/* 4180C8 802A3338 24424494 */ addiu $v0, $v0, %lo(func_802A4494) -/* 4180CC 802A333C AFA20018 */ sw $v0, 0x18($sp) -/* 4180D0 802A3340 2402FFFF */ addiu $v0, $zero, -1 -/* 4180D4 802A3344 AFB30014 */ sw $s3, 0x14($sp) -/* 4180D8 802A3348 AFA0001C */ sw $zero, 0x1c($sp) -/* 4180DC 802A334C 0C051F32 */ jal set_window_properties -/* 4180E0 802A3350 AFA20020 */ sw $v0, 0x20($sp) -/* 4180E4 802A3354 24040001 */ addiu $a0, $zero, 1 -/* 4180E8 802A3358 0C051F9F */ jal set_window_update -/* 4180EC 802A335C 0080282D */ daddu $a1, $a0, $zero -/* 4180F0 802A3360 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 4180F4 802A3364 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 4180F8 802A3368 54400006 */ bnel $v0, $zero, .L802A3384 -/* 4180FC 802A336C 24040004 */ addiu $a0, $zero, 4 -/* 418100 802A3370 24040002 */ addiu $a0, $zero, 2 -/* 418104 802A3374 0C051F9F */ jal set_window_update -/* 418108 802A3378 24050001 */ addiu $a1, $zero, 1 -/* 41810C 802A337C 080A8CE4 */ j .L802A3390 -/* 418110 802A3380 24040003 */ addiu $a0, $zero, 3 -.L802A3384: -/* 418114 802A3384 0C051F9F */ jal set_window_update -/* 418118 802A3388 24050001 */ addiu $a1, $zero, 1 -/* 41811C 802A338C 24040005 */ addiu $a0, $zero, 5 -.L802A3390: -/* 418120 802A3390 0C051F9F */ jal set_window_update -/* 418124 802A3394 24050001 */ addiu $a1, $zero, 1 -/* 418128 802A3398 24040008 */ addiu $a0, $zero, 8 -/* 41812C 802A339C 0C051F9F */ jal set_window_update -/* 418130 802A33A0 24050001 */ addiu $a1, $zero, 1 -/* 418134 802A33A4 3C05802B */ lui $a1, %hi(battle_menu_moveScrollLine) -/* 418138 802A33A8 24A5D10C */ addiu $a1, $a1, %lo(battle_menu_moveScrollLine) -/* 41813C 802A33AC 3C06802B */ lui $a2, %hi(battle_menu_moveOptionCount) -/* 418140 802A33B0 24C6D4A4 */ addiu $a2, $a2, %lo(battle_menu_moveOptionCount) -/* 418144 802A33B4 3C08802B */ lui $t0, %hi(battle_menu_moveCursorPos) -/* 418148 802A33B8 8108D109 */ lb $t0, %lo(battle_menu_moveCursorPos)($t0) -/* 41814C 802A33BC 3C07802B */ lui $a3, %hi(D_802AD10D) -/* 418150 802A33C0 80E7D10D */ lb $a3, %lo(D_802AD10D)($a3) -.L802A33C4: -/* 418154 802A33C4 80A20000 */ lb $v0, ($a1) -/* 418158 802A33C8 90A30000 */ lbu $v1, ($a1) -/* 41815C 802A33CC 00471021 */ addu $v0, $v0, $a3 -/* 418160 802A33D0 2442FFFF */ addiu $v0, $v0, -1 -/* 418164 802A33D4 0102102A */ slt $v0, $t0, $v0 -/* 418168 802A33D8 14400010 */ bnez $v0, .L802A341C -/* 41816C 802A33DC 0000202D */ daddu $a0, $zero, $zero -/* 418170 802A33E0 24630001 */ addiu $v1, $v1, 1 -/* 418174 802A33E4 A0A30000 */ sb $v1, ($a1) -/* 418178 802A33E8 00031E00 */ sll $v1, $v1, 0x18 -/* 41817C 802A33EC 8CC20000 */ lw $v0, ($a2) -/* 418180 802A33F0 00031E03 */ sra $v1, $v1, 0x18 -/* 418184 802A33F4 2442FFFA */ addiu $v0, $v0, -6 -/* 418188 802A33F8 0043102A */ slt $v0, $v0, $v1 -/* 41818C 802A33FC 50400007 */ beql $v0, $zero, .L802A341C -/* 418190 802A3400 24040001 */ addiu $a0, $zero, 1 -/* 418194 802A3404 90C20003 */ lbu $v0, 3($a2) -/* 418198 802A3408 2442FFFA */ addiu $v0, $v0, -6 -/* 41819C 802A340C A0A20000 */ sb $v0, ($a1) -/* 4181A0 802A3410 00021600 */ sll $v0, $v0, 0x18 -/* 4181A4 802A3414 04420001 */ bltzl $v0, .L802A341C -/* 4181A8 802A3418 A0A00000 */ sb $zero, ($a1) -.L802A341C: -/* 4181AC 802A341C 1480FFE9 */ bnez $a0, .L802A33C4 -/* 4181B0 802A3420 24020001 */ addiu $v0, $zero, 1 -/* 4181B4 802A3424 3C03802B */ lui $v1, %hi(battle_menu_moveScrollLine) -/* 4181B8 802A3428 9063D10C */ lbu $v1, %lo(battle_menu_moveScrollLine)($v1) -/* 4181BC 802A342C 3C04802B */ lui $a0, %hi(battle_menu_moveCursorPos) -/* 4181C0 802A3430 8084D109 */ lb $a0, %lo(battle_menu_moveCursorPos)($a0) -/* 4181C4 802A3434 3C01802B */ lui $at, %hi(battle_menu_moveState) -/* 4181C8 802A3438 A022D108 */ sb $v0, %lo(battle_menu_moveState)($at) -/* 4181CC 802A343C 24620006 */ addiu $v0, $v1, 6 -/* 4181D0 802A3440 00031E00 */ sll $v1, $v1, 0x18 -/* 4181D4 802A3444 00031E03 */ sra $v1, $v1, 0x18 -/* 4181D8 802A3448 00032823 */ negu $a1, $v1 -/* 4181DC 802A344C 3C01802B */ lui $at, %hi(D_802AD10D) -/* 4181E0 802A3450 A022D10D */ sb $v0, %lo(D_802AD10D)($at) -/* 4181E4 802A3454 00051040 */ sll $v0, $a1, 1 -/* 4181E8 802A3458 00451021 */ addu $v0, $v0, $a1 -/* 4181EC 802A345C 00021080 */ sll $v0, $v0, 2 -/* 4181F0 802A3460 00451021 */ addu $v0, $v0, $a1 -/* 4181F4 802A3464 00832023 */ subu $a0, $a0, $v1 -/* 4181F8 802A3468 3C01802B */ lui $at, %hi(battle_menu_moveScrollOffset) -/* 4181FC 802A346C A422D110 */ sh $v0, %lo(battle_menu_moveScrollOffset)($at) -/* 418200 802A3470 00041040 */ sll $v0, $a0, 1 -/* 418204 802A3474 00441021 */ addu $v0, $v0, $a0 -/* 418208 802A3478 00021080 */ sll $v0, $v0, 2 -/* 41820C 802A347C 00441021 */ addu $v0, $v0, $a0 -/* 418210 802A3480 3C01802B */ lui $at, %hi(D_802AD112) -/* 418214 802A3484 A422D112 */ sh $v0, %lo(D_802AD112)($at) -/* 418218 802A3488 080A8F1C */ j .L802A3C70 -/* 41821C 802A348C 0000102D */ daddu $v0, $zero, $zero -.L802A3490_418220: -/* 418220 802A3490 3C050001 */ lui $a1, 1 -/* 418224 802A3494 3C04802B */ lui $a0, %hi(battle_menu_moveCursorPos) -/* 418228 802A3498 2484D109 */ addiu $a0, $a0, %lo(battle_menu_moveCursorPos) -/* 41822C 802A349C 34A52000 */ ori $a1, $a1, 0x2000 -/* 418230 802A34A0 8E220218 */ lw $v0, 0x218($s1) -/* 418234 802A34A4 90830000 */ lbu $v1, ($a0) -/* 418238 802A34A8 00451024 */ and $v0, $v0, $a1 -/* 41823C 802A34AC 3C01802B */ lui $at, %hi(D_802AD10A) -/* 418240 802A34B0 A023D10A */ sb $v1, %lo(D_802AD10A)($at) -/* 418244 802A34B4 10400008 */ beqz $v0, .L802A34D8 -/* 418248 802A34B8 00031600 */ sll $v0, $v1, 0x18 -/* 41824C 802A34BC 1C400005 */ bgtz $v0, .L802A34D4 -/* 418250 802A34C0 2462FFFF */ addiu $v0, $v1, -1 -/* 418254 802A34C4 8E220214 */ lw $v0, 0x214($s1) -/* 418258 802A34C8 00451024 */ and $v0, $v0, $a1 -/* 41825C 802A34CC 10400002 */ beqz $v0, .L802A34D8 -/* 418260 802A34D0 2462FFFF */ addiu $v0, $v1, -1 -.L802A34D4: -/* 418264 802A34D4 A0820000 */ sb $v0, ($a0) -.L802A34D8: -/* 418268 802A34D8 3C060002 */ lui $a2, 2 -/* 41826C 802A34DC 8E220218 */ lw $v0, 0x218($s1) -/* 418270 802A34E0 34C60010 */ ori $a2, $a2, 0x10 -/* 418274 802A34E4 00461024 */ and $v0, $v0, $a2 -/* 418278 802A34E8 10400010 */ beqz $v0, .L802A352C -/* 41827C 802A34EC 00000000 */ nop -/* 418280 802A34F0 3C05802B */ lui $a1, %hi(battle_menu_moveCursorPos) -/* 418284 802A34F4 24A5D109 */ addiu $a1, $a1, %lo(battle_menu_moveCursorPos) -/* 418288 802A34F8 3C02802B */ lui $v0, %hi(battle_menu_moveOptionCount) -/* 41828C 802A34FC 8C42D4A4 */ lw $v0, %lo(battle_menu_moveOptionCount)($v0) -/* 418290 802A3500 80A30000 */ lb $v1, ($a1) -/* 418294 802A3504 90A40000 */ lbu $a0, ($a1) -/* 418298 802A3508 2442FFFF */ addiu $v0, $v0, -1 -/* 41829C 802A350C 0062182A */ slt $v1, $v1, $v0 -/* 4182A0 802A3510 14600005 */ bnez $v1, .L802A3528 -/* 4182A4 802A3514 24820001 */ addiu $v0, $a0, 1 -/* 4182A8 802A3518 8E220214 */ lw $v0, 0x214($s1) -/* 4182AC 802A351C 00461024 */ and $v0, $v0, $a2 -/* 4182B0 802A3520 10400002 */ beqz $v0, .L802A352C -/* 4182B4 802A3524 24820001 */ addiu $v0, $a0, 1 -.L802A3528: -/* 4182B8 802A3528 A0A20000 */ sb $v0, ($a1) -.L802A352C: -/* 4182BC 802A352C 3C10802B */ lui $s0, %hi(battle_menu_moveCursorPos) -/* 4182C0 802A3530 2610D109 */ addiu $s0, $s0, %lo(battle_menu_moveCursorPos) -/* 4182C4 802A3534 82020000 */ lb $v0, ($s0) -/* 4182C8 802A3538 04410005 */ bgez $v0, .L802A3550 -/* 4182CC 802A353C 00000000 */ nop -/* 4182D0 802A3540 3C02802B */ lui $v0, %hi(D_802AD4A7) -/* 4182D4 802A3544 9042D4A7 */ lbu $v0, %lo(D_802AD4A7)($v0) -/* 4182D8 802A3548 2442FFFF */ addiu $v0, $v0, -1 -/* 4182DC 802A354C A2020000 */ sb $v0, ($s0) -.L802A3550: -/* 4182E0 802A3550 3C02802B */ lui $v0, %hi(battle_menu_moveOptionCount) -/* 4182E4 802A3554 8C42D4A4 */ lw $v0, %lo(battle_menu_moveOptionCount)($v0) -/* 4182E8 802A3558 82030000 */ lb $v1, ($s0) -/* 4182EC 802A355C 2442FFFF */ addiu $v0, $v0, -1 -/* 4182F0 802A3560 0043102A */ slt $v0, $v0, $v1 -/* 4182F4 802A3564 54400001 */ bnel $v0, $zero, .L802A356C -/* 4182F8 802A3568 A2000000 */ sb $zero, ($s0) -.L802A356C: -/* 4182FC 802A356C 3C03802B */ lui $v1, %hi(D_802AD10A) -/* 418300 802A3570 8063D10A */ lb $v1, %lo(D_802AD10A)($v1) -/* 418304 802A3574 82020000 */ lb $v0, ($s0) -/* 418308 802A3578 10620009 */ beq $v1, $v0, .L802A35A0 -/* 41830C 802A357C 00031080 */ sll $v0, $v1, 2 -/* 418310 802A3580 3C04802B */ lui $a0, %hi(battle_menu_moveOptionIconIDs) -/* 418314 802A3584 00822021 */ addu $a0, $a0, $v0 -/* 418318 802A3588 8C84D128 */ lw $a0, %lo(battle_menu_moveOptionIconIDs)($a0) -/* 41831C 802A358C 3C053EE6 */ lui $a1, 0x3ee6 -/* 418320 802A3590 0C051308 */ jal hud_element_set_scale -/* 418324 802A3594 34A56666 */ ori $a1, $a1, 0x6666 -/* 418328 802A3598 0C05272D */ jal sfx_play_sound -/* 41832C 802A359C 240400C7 */ addiu $a0, $zero, 0xc7 -.L802A35A0: -/* 418330 802A35A0 3C04802B */ lui $a0, %hi(battle_menu_moveScrollLine) -/* 418334 802A35A4 2484D10C */ addiu $a0, $a0, %lo(battle_menu_moveScrollLine) -/* 418338 802A35A8 80820000 */ lb $v0, ($a0) -/* 41833C 802A35AC 82030000 */ lb $v1, ($s0) -/* 418340 802A35B0 24420001 */ addiu $v0, $v0, 1 -/* 418344 802A35B4 0062182A */ slt $v1, $v1, $v0 -/* 418348 802A35B8 90820000 */ lbu $v0, ($a0) -/* 41834C 802A35BC 10600005 */ beqz $v1, .L802A35D4 -/* 418350 802A35C0 2442FFFF */ addiu $v0, $v0, -1 -/* 418354 802A35C4 A0820000 */ sb $v0, ($a0) -/* 418358 802A35C8 00021600 */ sll $v0, $v0, 0x18 -/* 41835C 802A35CC 04420001 */ bltzl $v0, .L802A35D4 -/* 418360 802A35D0 A0800000 */ sb $zero, ($a0) -.L802A35D4: -/* 418364 802A35D4 3C02802B */ lui $v0, %hi(D_802AD10D) -/* 418368 802A35D8 8042D10D */ lb $v0, %lo(D_802AD10D)($v0) -/* 41836C 802A35DC 3C03802B */ lui $v1, %hi(battle_menu_moveCursorPos) -/* 418370 802A35E0 8063D109 */ lb $v1, %lo(battle_menu_moveCursorPos)($v1) -/* 418374 802A35E4 2442FFFF */ addiu $v0, $v0, -1 -/* 418378 802A35E8 0062182A */ slt $v1, $v1, $v0 -/* 41837C 802A35EC 14600015 */ bnez $v1, .L802A3644 -/* 418380 802A35F0 00000000 */ nop -/* 418384 802A35F4 3C04802B */ lui $a0, %hi(battle_menu_moveScrollLine) -/* 418388 802A35F8 2484D10C */ addiu $a0, $a0, %lo(battle_menu_moveScrollLine) -/* 41838C 802A35FC 90820000 */ lbu $v0, ($a0) -/* 418390 802A3600 3C05802B */ lui $a1, %hi(battle_menu_moveOptionCount) -/* 418394 802A3604 24A5D4A4 */ addiu $a1, $a1, %lo(battle_menu_moveOptionCount) -/* 418398 802A3608 24420001 */ addiu $v0, $v0, 1 -/* 41839C 802A360C A0820000 */ sb $v0, ($a0) -/* 4183A0 802A3610 00021600 */ sll $v0, $v0, 0x18 -/* 4183A4 802A3614 8CA30000 */ lw $v1, ($a1) -/* 4183A8 802A3618 00021603 */ sra $v0, $v0, 0x18 -/* 4183AC 802A361C 2463FFFA */ addiu $v1, $v1, -6 -/* 4183B0 802A3620 0062182A */ slt $v1, $v1, $v0 -/* 4183B4 802A3624 10600007 */ beqz $v1, .L802A3644 -/* 4183B8 802A3628 00000000 */ nop -/* 4183BC 802A362C 90A20003 */ lbu $v0, 3($a1) -/* 4183C0 802A3630 2442FFFA */ addiu $v0, $v0, -6 -/* 4183C4 802A3634 A0820000 */ sb $v0, ($a0) -/* 4183C8 802A3638 00021600 */ sll $v0, $v0, 0x18 -/* 4183CC 802A363C 04420001 */ bltzl $v0, .L802A3644 -/* 4183D0 802A3640 A0800000 */ sb $zero, ($a0) -.L802A3644: -/* 4183D4 802A3644 3C02802B */ lui $v0, %hi(battle_menu_moveScrollLine) -/* 4183D8 802A3648 9042D10C */ lbu $v0, %lo(battle_menu_moveScrollLine)($v0) -/* 4183DC 802A364C 8E230214 */ lw $v1, 0x214($s1) -/* 4183E0 802A3650 24420006 */ addiu $v0, $v0, 6 -/* 4183E4 802A3654 3C01802B */ lui $at, %hi(D_802AD10D) -/* 4183E8 802A3658 A022D10D */ sb $v0, %lo(D_802AD10D)($at) -/* 4183EC 802A365C 30628000 */ andi $v0, $v1, 0x8000 -/* 4183F0 802A3660 10400025 */ beqz $v0, .L802A36F8 -/* 4183F4 802A3664 30624000 */ andi $v0, $v1, 0x4000 -/* 4183F8 802A3668 3C11802B */ lui $s1, %hi(battle_menu_moveCursorPos) -/* 4183FC 802A366C 2631D109 */ addiu $s1, $s1, %lo(battle_menu_moveCursorPos) -/* 418400 802A3670 82220000 */ lb $v0, ($s1) -/* 418404 802A3674 00021080 */ sll $v0, $v0, 2 -/* 418408 802A3678 3C01802B */ lui $at, %hi(battle_menu_moveOptionIndexMap) -/* 41840C 802A367C 00220821 */ addu $at, $at, $v0 -/* 418410 802A3680 8C22D1F8 */ lw $v0, %lo(battle_menu_moveOptionIndexMap)($at) -/* 418414 802A3684 3C10802B */ lui $s0, %hi(battle_menu_moveOptionIndexMap) -/* 418418 802A3688 2610D1F8 */ addiu $s0, $s0, %lo(battle_menu_moveOptionIndexMap) -/* 41841C 802A368C 00021080 */ sll $v0, $v0, 2 -/* 418420 802A3690 3C03802B */ lui $v1, %hi(battle_menu_moveOptionsEnabled) -/* 418424 802A3694 00621821 */ addu $v1, $v1, $v0 -/* 418428 802A3698 8C63D510 */ lw $v1, %lo(battle_menu_moveOptionsEnabled)($v1) -/* 41842C 802A369C 24020001 */ addiu $v0, $zero, 1 -/* 418430 802A36A0 14620005 */ bne $v1, $v0, .L802A36B8 -/* 418434 802A36A4 00000000 */ nop -/* 418438 802A36A8 0C05272D */ jal sfx_play_sound -/* 41843C 802A36AC 240400C9 */ addiu $a0, $zero, 0xc9 -/* 418440 802A36B0 080A8F19 */ j .L802A3C64 -/* 418444 802A36B4 2402FFFF */ addiu $v0, $zero, -1 -.L802A36B8: -/* 418448 802A36B8 0C05272D */ jal sfx_play_sound -/* 41844C 802A36BC 2404021D */ addiu $a0, $zero, 0x21d -/* 418450 802A36C0 82220000 */ lb $v0, ($s1) -/* 418454 802A36C4 00021080 */ sll $v0, $v0, 2 -/* 418458 802A36C8 00501021 */ addu $v0, $v0, $s0 -/* 41845C 802A36CC 8C420000 */ lw $v0, ($v0) -/* 418460 802A36D0 3C03802B */ lui $v1, %hi(D_802AD258) -/* 418464 802A36D4 2463D258 */ addiu $v1, $v1, %lo(D_802AD258) -/* 418468 802A36D8 AC600000 */ sw $zero, ($v1) -/* 41846C 802A36DC 3C01802B */ lui $at, %hi(battle_menu_moveOptionCantUseTypes) -/* 418470 802A36E0 00220821 */ addu $at, $at, $v0 -/* 418474 802A36E4 8022D5E8 */ lb $v0, %lo(battle_menu_moveOptionCantUseTypes)($at) -/* 418478 802A36E8 54400001 */ bnel $v0, $zero, .L802A36F0 -/* 41847C 802A36EC AC620000 */ sw $v0, ($v1) -.L802A36F0: -/* 418480 802A36F0 080A8F19 */ j .L802A3C64 -/* 418484 802A36F4 24020028 */ addiu $v0, $zero, 0x28 -.L802A36F8: -/* 418488 802A36F8 1040015D */ beqz $v0, .L802A3C70 -/* 41848C 802A36FC 0000102D */ daddu $v0, $zero, $zero -/* 418490 802A3700 0C05272D */ jal sfx_play_sound -/* 418494 802A3704 240400CA */ addiu $a0, $zero, 0xca -/* 418498 802A3708 0C0A89F9 */ jal func_802A27E4 -/* 41849C 802A370C 00000000 */ nop -/* 4184A0 802A3710 080A8F19 */ j .L802A3C64 -/* 4184A4 802A3714 2402FFFE */ addiu $v0, $zero, -2 -.L802A3718_4184A8: -/* 4184A8 802A3718 3C02802B */ lui $v0, %hi(battle_menu_moveOptionCount) -/* 4184AC 802A371C 8C42D4A4 */ lw $v0, %lo(battle_menu_moveOptionCount)($v0) -/* 4184B0 802A3720 1840000F */ blez $v0, .L802A3760 -/* 4184B4 802A3724 0000802D */ daddu $s0, $zero, $zero -/* 4184B8 802A3728 3C11802B */ lui $s1, %hi(battle_menu_moveOptionIconIDs) -/* 4184BC 802A372C 2631D128 */ addiu $s1, $s1, %lo(battle_menu_moveOptionIconIDs) -/* 4184C0 802A3730 240500A0 */ addiu $a1, $zero, 0xa0 -.L802A3734: -/* 4184C4 802A3734 00A0302D */ daddu $a2, $a1, $zero -/* 4184C8 802A3738 00A0382D */ daddu $a3, $a1, $zero -/* 4184CC 802A373C 8E240000 */ lw $a0, ($s1) -/* 4184D0 802A3740 0C0513BF */ jal hud_element_set_tint -/* 4184D4 802A3744 26310004 */ addiu $s1, $s1, 4 -/* 4184D8 802A3748 3C02802B */ lui $v0, %hi(battle_menu_moveOptionCount) -/* 4184DC 802A374C 8C42D4A4 */ lw $v0, %lo(battle_menu_moveOptionCount)($v0) -/* 4184E0 802A3750 26100001 */ addiu $s0, $s0, 1 -/* 4184E4 802A3754 0202102A */ slt $v0, $s0, $v0 -/* 4184E8 802A3758 1440FFF6 */ bnez $v0, .L802A3734 -/* 4184EC 802A375C 240500A0 */ addiu $a1, $zero, 0xa0 -.L802A3760: -/* 4184F0 802A3760 240500A0 */ addiu $a1, $zero, 0xa0 -/* 4184F4 802A3764 00A0302D */ daddu $a2, $a1, $zero -/* 4184F8 802A3768 3C04802B */ lui $a0, %hi(battle_menu_moveCursorIcon) -/* 4184FC 802A376C 8C84D118 */ lw $a0, %lo(battle_menu_moveCursorIcon)($a0) -/* 418500 802A3770 0C0513BF */ jal hud_element_set_tint -/* 418504 802A3774 00A0382D */ daddu $a3, $a1, $zero -/* 418508 802A3778 240500A0 */ addiu $a1, $zero, 0xa0 -/* 41850C 802A377C 00A0302D */ daddu $a2, $a1, $zero -/* 418510 802A3780 3C04802B */ lui $a0, %hi(battle_menu_moveUpArrowIcon) -/* 418514 802A3784 8C84D11C */ lw $a0, %lo(battle_menu_moveUpArrowIcon)($a0) -/* 418518 802A3788 0C0513BF */ jal hud_element_set_tint -/* 41851C 802A378C 00A0382D */ daddu $a3, $a1, $zero -/* 418520 802A3790 240500A0 */ addiu $a1, $zero, 0xa0 -/* 418524 802A3794 00A0302D */ daddu $a2, $a1, $zero -/* 418528 802A3798 3C04802B */ lui $a0, %hi(battle_menu_moveDownArrowIcon) -/* 41852C 802A379C 8C84D120 */ lw $a0, %lo(battle_menu_moveDownArrowIcon)($a0) -/* 418530 802A37A0 0C0513BF */ jal hud_element_set_tint -/* 418534 802A37A4 00A0382D */ daddu $a3, $a1, $zero -/* 418538 802A37A8 240500A0 */ addiu $a1, $zero, 0xa0 -/* 41853C 802A37AC 00A0302D */ daddu $a2, $a1, $zero -/* 418540 802A37B0 3C04802B */ lui $a0, %hi(battle_menu_moveTitleIcon) -/* 418544 802A37B4 8C84D188 */ lw $a0, %lo(battle_menu_moveTitleIcon)($a0) -/* 418548 802A37B8 0C0513BF */ jal hud_element_set_tint -/* 41854C 802A37BC 00A0382D */ daddu $a3, $a1, $zero -/* 418550 802A37C0 3C02802B */ lui $v0, %hi(battle_menu_moveOptionCount) -/* 418554 802A37C4 8C42D4A4 */ lw $v0, %lo(battle_menu_moveOptionCount)($v0) -/* 418558 802A37C8 1840000F */ blez $v0, .L802A3808 -/* 41855C 802A37CC 0000802D */ daddu $s0, $zero, $zero -/* 418560 802A37D0 3C11802B */ lui $s1, %hi(battle_menu_moveOptionCostUnitIconIDs) -/* 418564 802A37D4 2631D190 */ addiu $s1, $s1, %lo(battle_menu_moveOptionCostUnitIconIDs) -/* 418568 802A37D8 240500A0 */ addiu $a1, $zero, 0xa0 -.L802A37DC: -/* 41856C 802A37DC 00A0302D */ daddu $a2, $a1, $zero -/* 418570 802A37E0 00A0382D */ daddu $a3, $a1, $zero -/* 418574 802A37E4 8E240000 */ lw $a0, ($s1) -/* 418578 802A37E8 0C0513BF */ jal hud_element_set_tint -/* 41857C 802A37EC 26310004 */ addiu $s1, $s1, 4 -/* 418580 802A37F0 3C02802B */ lui $v0, %hi(battle_menu_moveOptionCount) -/* 418584 802A37F4 8C42D4A4 */ lw $v0, %lo(battle_menu_moveOptionCount)($v0) -/* 418588 802A37F8 26100001 */ addiu $s0, $s0, 1 -/* 41858C 802A37FC 0202102A */ slt $v0, $s0, $v0 -/* 418590 802A3800 5440FFF6 */ bnel $v0, $zero, .L802A37DC -/* 418594 802A3804 240500A0 */ addiu $a1, $zero, 0xa0 -.L802A3808: -/* 418598 802A3808 3C04802B */ lui $a0, %hi(battle_menu_moveCursorIcon) -/* 41859C 802A380C 8C84D118 */ lw $a0, %lo(battle_menu_moveCursorIcon)($a0) -/* 4185A0 802A3810 3C058010 */ lui $a1, %hi(HES_HandPointer) -/* 4185A4 802A3814 24A54A00 */ addiu $a1, $a1, %lo(HES_HandPointer) -/* 4185A8 802A3818 0C0511FF */ jal hud_element_set_script -/* 4185AC 802A381C 00000000 */ nop -/* 4185B0 802A3820 24040001 */ addiu $a0, $zero, 1 -/* 4185B4 802A3824 2402000D */ addiu $v0, $zero, 0xd -/* 4185B8 802A3828 3C01802B */ lui $at, %hi(battle_menu_moveTextColor) -/* 4185BC 802A382C A422D114 */ sh $v0, %lo(battle_menu_moveTextColor)($at) -/* 4185C0 802A3830 0C051F9F */ jal set_window_update -/* 4185C4 802A3834 24050004 */ addiu $a1, $zero, 4 -/* 4185C8 802A3838 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 4185CC 802A383C 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 4185D0 802A3840 54400006 */ bnel $v0, $zero, .L802A385C -/* 4185D4 802A3844 24040004 */ addiu $a0, $zero, 4 -/* 4185D8 802A3848 24040002 */ addiu $a0, $zero, 2 -/* 4185DC 802A384C 0C051F9F */ jal set_window_update -/* 4185E0 802A3850 24050004 */ addiu $a1, $zero, 4 -/* 4185E4 802A3854 080A8E1A */ j .L802A3868 -/* 4185E8 802A3858 24040003 */ addiu $a0, $zero, 3 -.L802A385C: -/* 4185EC 802A385C 0C051F9F */ jal set_window_update -/* 4185F0 802A3860 0080282D */ daddu $a1, $a0, $zero -/* 4185F4 802A3864 24040005 */ addiu $a0, $zero, 5 -.L802A3868: -/* 4185F8 802A3868 0C051F9F */ jal set_window_update -/* 4185FC 802A386C 24050004 */ addiu $a1, $zero, 4 -/* 418600 802A3870 24040008 */ addiu $a0, $zero, 8 -/* 418604 802A3874 0C051F9F */ jal set_window_update -/* 418608 802A3878 24050002 */ addiu $a1, $zero, 2 -/* 41860C 802A387C 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 418610 802A3880 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 418614 802A3884 14400005 */ bnez $v0, .L802A389C -/* 418618 802A3888 00000000 */ nop -/* 41861C 802A388C 0C03A674 */ jal status_menu_stop_blinking_fp -/* 418620 802A3890 00000000 */ nop -/* 418624 802A3894 080A8E5D */ j .L802A3974_418704 -/* 418628 802A3898 00000000 */ nop -.L802A389C: -/* 41862C 802A389C 0C03A6A5 */ jal status_menu_stop_blinking_sp -/* 418630 802A38A0 00000000 */ nop -/* 418634 802A38A4 080A8E5D */ j .L802A3974_418704 -/* 418638 802A38A8 00000000 */ nop -.L802A38AC_41863C: -/* 41863C 802A38AC 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 418640 802A38B0 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 418644 802A38B4 14400005 */ bnez $v0, .L802A38CC -/* 418648 802A38B8 00000000 */ nop -/* 41864C 802A38BC 0C03A674 */ jal status_menu_stop_blinking_fp -/* 418650 802A38C0 00000000 */ nop -/* 418654 802A38C4 080A8F1C */ j .L802A3C70 -/* 418658 802A38C8 240200FF */ addiu $v0, $zero, 0xff -.L802A38CC: -/* 41865C 802A38CC 0C03A6A5 */ jal status_menu_stop_blinking_sp -/* 418660 802A38D0 00000000 */ nop -/* 418664 802A38D4 080A8F1C */ j .L802A3C70 -/* 418668 802A38D8 240200FF */ addiu $v0, $zero, 0xff -.L802A38DC_41866C: -/* 41866C 802A38DC 24040001 */ addiu $a0, $zero, 1 -/* 418670 802A38E0 0C051F9F */ jal set_window_update -/* 418674 802A38E4 24050002 */ addiu $a1, $zero, 2 -/* 418678 802A38E8 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 41867C 802A38EC 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 418680 802A38F0 54400006 */ bnel $v0, $zero, .L802A390C -/* 418684 802A38F4 24040004 */ addiu $a0, $zero, 4 -/* 418688 802A38F8 24040002 */ addiu $a0, $zero, 2 -/* 41868C 802A38FC 0C051F9F */ jal set_window_update -/* 418690 802A3900 0080282D */ daddu $a1, $a0, $zero -/* 418694 802A3904 080A8E46 */ j .L802A3918 -/* 418698 802A3908 24040003 */ addiu $a0, $zero, 3 -.L802A390C: -/* 41869C 802A390C 0C051F9F */ jal set_window_update -/* 4186A0 802A3910 24050002 */ addiu $a1, $zero, 2 -/* 4186A4 802A3914 24040005 */ addiu $a0, $zero, 5 -.L802A3918: -/* 4186A8 802A3918 0C051F9F */ jal set_window_update -/* 4186AC 802A391C 24050002 */ addiu $a1, $zero, 2 -/* 4186B0 802A3920 24040008 */ addiu $a0, $zero, 8 -/* 4186B4 802A3924 0C051F9F */ jal set_window_update -/* 4186B8 802A3928 24050002 */ addiu $a1, $zero, 2 -/* 4186BC 802A392C 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 4186C0 802A3930 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 4186C4 802A3934 14400005 */ bnez $v0, .L802A394C -/* 4186C8 802A3938 00000000 */ nop -/* 4186CC 802A393C 0C03A674 */ jal status_menu_stop_blinking_fp -/* 4186D0 802A3940 00000000 */ nop -/* 4186D4 802A3944 080A8E55 */ j .L802A3954 -/* 4186D8 802A3948 00000000 */ nop -.L802A394C: -/* 4186DC 802A394C 0C03A6A5 */ jal status_menu_stop_blinking_sp -/* 4186E0 802A3950 00000000 */ nop -.L802A3954: -/* 4186E4 802A3954 3C04802B */ lui $a0, %hi(battle_menu_moveCursorPos) -/* 4186E8 802A3958 8084D109 */ lb $a0, %lo(battle_menu_moveCursorPos)($a0) -/* 4186EC 802A395C 00041080 */ sll $v0, $a0, 2 -/* 4186F0 802A3960 3C01802B */ lui $at, %hi(battle_menu_moveOptionIndexMap) -/* 4186F4 802A3964 00220821 */ addu $at, $at, $v0 -/* 4186F8 802A3968 8C22D1F8 */ lw $v0, %lo(battle_menu_moveOptionIndexMap)($at) -/* 4186FC 802A396C 080A8E82 */ j .L802A3A08 -/* 418700 802A3970 2403000B */ addiu $v1, $zero, 0xb -.L802A3974_418704: -/* 418704 802A3974 3C03802B */ lui $v1, %hi(battle_menu_moveCursorPos) -/* 418708 802A3978 8063D109 */ lb $v1, %lo(battle_menu_moveCursorPos)($v1) -/* 41870C 802A397C 00031080 */ sll $v0, $v1, 2 -/* 418710 802A3980 3C01802B */ lui $at, %hi(battle_menu_moveOptionIndexMap) -/* 418714 802A3984 00220821 */ addu $at, $at, $v0 -/* 418718 802A3988 8C22D1F8 */ lw $v0, %lo(battle_menu_moveOptionIndexMap)($at) -/* 41871C 802A398C 3C01802B */ lui $at, %hi(battle_menu_moveOptionActive) -/* 418720 802A3990 AC23D600 */ sw $v1, %lo(battle_menu_moveOptionActive)($at) -/* 418724 802A3994 080A8F1C */ j .L802A3C70 -/* 418728 802A3998 24420001 */ addiu $v0, $v0, 1 -.L802A399C_41872C: -/* 41872C 802A399C 24040001 */ addiu $a0, $zero, 1 -/* 418730 802A39A0 0C051F9F */ jal set_window_update -/* 418734 802A39A4 0080282D */ daddu $a1, $a0, $zero -/* 418738 802A39A8 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 41873C 802A39AC 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 418740 802A39B0 54400006 */ bnel $v0, $zero, .L802A39CC -/* 418744 802A39B4 24040004 */ addiu $a0, $zero, 4 -/* 418748 802A39B8 24040002 */ addiu $a0, $zero, 2 -/* 41874C 802A39BC 0C051F9F */ jal set_window_update -/* 418750 802A39C0 24050001 */ addiu $a1, $zero, 1 -/* 418754 802A39C4 080A8E76 */ j .L802A39D8 -/* 418758 802A39C8 24040003 */ addiu $a0, $zero, 3 -.L802A39CC: -/* 41875C 802A39CC 0C051F9F */ jal set_window_update -/* 418760 802A39D0 24050001 */ addiu $a1, $zero, 1 -/* 418764 802A39D4 24040005 */ addiu $a0, $zero, 5 -.L802A39D8: -/* 418768 802A39D8 0C051F9F */ jal set_window_update -/* 41876C 802A39DC 24050001 */ addiu $a1, $zero, 1 -/* 418770 802A39E0 24040008 */ addiu $a0, $zero, 8 -/* 418774 802A39E4 0C051F9F */ jal set_window_update -/* 418778 802A39E8 24050001 */ addiu $a1, $zero, 1 -/* 41877C 802A39EC 3C04802B */ lui $a0, %hi(battle_menu_moveCursorPos) -/* 418780 802A39F0 8084D109 */ lb $a0, %lo(battle_menu_moveCursorPos)($a0) -/* 418784 802A39F4 00041080 */ sll $v0, $a0, 2 -/* 418788 802A39F8 3C01802B */ lui $at, %hi(battle_menu_moveOptionIndexMap) -/* 41878C 802A39FC 00220821 */ addu $at, $at, $v0 -/* 418790 802A3A00 8C22D1F8 */ lw $v0, %lo(battle_menu_moveOptionIndexMap)($at) -/* 418794 802A3A04 24030001 */ addiu $v1, $zero, 1 -.L802A3A08: -/* 418798 802A3A08 3C01802B */ lui $at, %hi(battle_menu_moveState) -/* 41879C 802A3A0C A023D108 */ sb $v1, %lo(battle_menu_moveState)($at) -/* 4187A0 802A3A10 3C01802B */ lui $at, %hi(battle_menu_moveOptionActive) -/* 4187A4 802A3A14 AC24D600 */ sw $a0, %lo(battle_menu_moveOptionActive)($at) -/* 4187A8 802A3A18 080A8F1C */ j .L802A3C70 -/* 4187AC 802A3A1C 24420001 */ addiu $v0, $v0, 1 -.L802A3A20_4187B0: -/* 4187B0 802A3A20 24040001 */ addiu $a0, $zero, 1 -/* 4187B4 802A3A24 0C051F9F */ jal set_window_update -/* 4187B8 802A3A28 24050009 */ addiu $a1, $zero, 9 -/* 4187BC 802A3A2C 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 4187C0 802A3A30 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 4187C4 802A3A34 54400006 */ bnel $v0, $zero, .L802A3A50 -/* 4187C8 802A3A38 24040004 */ addiu $a0, $zero, 4 -/* 4187CC 802A3A3C 24040002 */ addiu $a0, $zero, 2 -/* 4187D0 802A3A40 0C051F9F */ jal set_window_update -/* 4187D4 802A3A44 24050009 */ addiu $a1, $zero, 9 -/* 4187D8 802A3A48 080A8E97 */ j .L802A3A5C -/* 4187DC 802A3A4C 24040003 */ addiu $a0, $zero, 3 -.L802A3A50: -/* 4187E0 802A3A50 0C051F9F */ jal set_window_update -/* 4187E4 802A3A54 24050009 */ addiu $a1, $zero, 9 -/* 4187E8 802A3A58 24040005 */ addiu $a0, $zero, 5 -.L802A3A5C: -/* 4187EC 802A3A5C 0C051F9F */ jal set_window_update -/* 4187F0 802A3A60 24050009 */ addiu $a1, $zero, 9 -/* 4187F4 802A3A64 24040008 */ addiu $a0, $zero, 8 -/* 4187F8 802A3A68 0C051F9F */ jal set_window_update -/* 4187FC 802A3A6C 24050002 */ addiu $a1, $zero, 2 -/* 418800 802A3A70 080A8F19 */ j .L802A3C64 -/* 418804 802A3A74 2402FFFF */ addiu $v0, $zero, -1 -.L802A3A78_418808: -/* 418808 802A3A78 2402FFFF */ addiu $v0, $zero, -1 -/* 41880C 802A3A7C 0040182D */ daddu $v1, $v0, $zero -/* 418810 802A3A80 3C01802B */ lui $at, %hi(battle_menu_moveOptionActive) -/* 418814 802A3A84 AC23D600 */ sw $v1, %lo(battle_menu_moveOptionActive)($at) -/* 418818 802A3A88 24030029 */ addiu $v1, $zero, 0x29 -/* 41881C 802A3A8C 3C01802B */ lui $at, %hi(battle_menu_moveState) -/* 418820 802A3A90 A023D108 */ sb $v1, %lo(battle_menu_moveState)($at) -/* 418824 802A3A94 080A8F1C */ j .L802A3C70 -/* 418828 802A3A98 00000000 */ nop -.L802A3A9C_41882C: -/* 41882C 802A3A9C 24040001 */ addiu $a0, $zero, 1 -/* 418830 802A3AA0 0C051F9F */ jal set_window_update -/* 418834 802A3AA4 24050002 */ addiu $a1, $zero, 2 -/* 418838 802A3AA8 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 41883C 802A3AAC 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 418840 802A3AB0 54400006 */ bnel $v0, $zero, .L802A3ACC -/* 418844 802A3AB4 24040004 */ addiu $a0, $zero, 4 -/* 418848 802A3AB8 24040002 */ addiu $a0, $zero, 2 -/* 41884C 802A3ABC 0C051F9F */ jal set_window_update -/* 418850 802A3AC0 0080282D */ daddu $a1, $a0, $zero -/* 418854 802A3AC4 080A8EB6 */ j .L802A3AD8 -/* 418858 802A3AC8 24040003 */ addiu $a0, $zero, 3 -.L802A3ACC: -/* 41885C 802A3ACC 0C051F9F */ jal set_window_update -/* 418860 802A3AD0 24050002 */ addiu $a1, $zero, 2 -/* 418864 802A3AD4 24040005 */ addiu $a0, $zero, 5 -.L802A3AD8: -/* 418868 802A3AD8 0C051F9F */ jal set_window_update -/* 41886C 802A3ADC 24050002 */ addiu $a1, $zero, 2 -/* 418870 802A3AE0 24040008 */ addiu $a0, $zero, 8 -/* 418874 802A3AE4 0C051F9F */ jal set_window_update -/* 418878 802A3AE8 24050002 */ addiu $a1, $zero, 2 -/* 41887C 802A3AEC 3C11001D */ lui $s1, 0x1d -/* 418880 802A3AF0 3C02802B */ lui $v0, %hi(D_802AD258) -/* 418884 802A3AF4 8C42D258 */ lw $v0, %lo(D_802AD258)($v0) -/* 418888 802A3AF8 14400008 */ bnez $v0, .L802A3B1C -/* 41888C 802A3AFC 363100C3 */ ori $s1, $s1, 0xc3 -/* 418890 802A3B00 3C11001D */ lui $s1, 0x1d -/* 418894 802A3B04 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 418898 802A3B08 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 41889C 802A3B0C 14400003 */ bnez $v0, .L802A3B1C -/* 4188A0 802A3B10 363100A0 */ ori $s1, $s1, 0xa0 -/* 4188A4 802A3B14 3C11001D */ lui $s1, 0x1d -/* 4188A8 802A3B18 3631009F */ ori $s1, $s1, 0x9f -.L802A3B1C: -/* 4188AC 802A3B1C 0220202D */ daddu $a0, $s1, $zero -/* 4188B0 802A3B20 0C04991D */ jal get_msg_width -/* 4188B4 802A3B24 0000282D */ daddu $a1, $zero, $zero -/* 4188B8 802A3B28 24500017 */ addiu $s0, $v0, 0x17 -/* 4188BC 802A3B2C 001017C2 */ srl $v0, $s0, 0x1f -/* 4188C0 802A3B30 02021021 */ addu $v0, $s0, $v0 -/* 4188C4 802A3B34 00021043 */ sra $v0, $v0, 1 -/* 4188C8 802A3B38 240300A0 */ addiu $v1, $zero, 0xa0 -/* 4188CC 802A3B3C 00629823 */ subu $s3, $v1, $v0 -/* 4188D0 802A3B40 0C04992C */ jal get_msg_lines -/* 4188D4 802A3B44 0220202D */ daddu $a0, $s1, $zero -/* 4188D8 802A3B48 24040009 */ addiu $a0, $zero, 9 -/* 4188DC 802A3B4C 0260282D */ daddu $a1, $s3, $zero -/* 4188E0 802A3B50 24060050 */ addiu $a2, $zero, 0x50 -/* 4188E4 802A3B54 0200382D */ daddu $a3, $s0, $zero -/* 4188E8 802A3B58 2442FFFF */ addiu $v0, $v0, -1 -/* 4188EC 802A3B5C 00021040 */ sll $v0, $v0, 1 -/* 4188F0 802A3B60 3C03802B */ lui $v1, %hi(D_802AB340) -/* 4188F4 802A3B64 00621821 */ addu $v1, $v1, $v0 -/* 4188F8 802A3B68 8463B340 */ lh $v1, %lo(D_802AB340)($v1) -/* 4188FC 802A3B6C 24020014 */ addiu $v0, $zero, 0x14 -/* 418900 802A3B70 AFA20014 */ sw $v0, 0x14($sp) -/* 418904 802A3B74 3C02802A */ lui $v0, %hi(func_802A4534) -/* 418908 802A3B78 24424534 */ addiu $v0, $v0, %lo(func_802A4534) -/* 41890C 802A3B7C AFA20018 */ sw $v0, 0x18($sp) -/* 418910 802A3B80 2402FFFF */ addiu $v0, $zero, -1 -/* 418914 802A3B84 AFA0001C */ sw $zero, 0x1c($sp) -/* 418918 802A3B88 AFA20020 */ sw $v0, 0x20($sp) -/* 41891C 802A3B8C 0C051F32 */ jal set_window_properties -/* 418920 802A3B90 AFA30010 */ sw $v1, 0x10($sp) -/* 418924 802A3B94 24040009 */ addiu $a0, $zero, 9 -/* 418928 802A3B98 0C051F9F */ jal set_window_update -/* 41892C 802A3B9C 24050001 */ addiu $a1, $zero, 1 -/* 418930 802A3BA0 2403003C */ addiu $v1, $zero, 0x3c -/* 418934 802A3BA4 3C01802B */ lui $at, %hi(D_802AD10B) -/* 418938 802A3BA8 A023D10B */ sb $v1, %lo(D_802AD10B)($at) -/* 41893C 802A3BAC 2403002A */ addiu $v1, $zero, 0x2a -/* 418940 802A3BB0 3C01802B */ lui $at, %hi(battle_menu_moveState) -/* 418944 802A3BB4 A023D108 */ sb $v1, %lo(battle_menu_moveState)($at) -/* 418948 802A3BB8 080A8F1C */ j .L802A3C70 -/* 41894C 802A3BBC 2402FFFF */ addiu $v0, $zero, -1 -.L802A3BC0_418950: -/* 418950 802A3BC0 3C028007 */ lui $v0, %hi(gGameStatusPtr) -/* 418954 802A3BC4 8C42419C */ lw $v0, %lo(gGameStatusPtr)($v0) -/* 418958 802A3BC8 8C420010 */ lw $v0, 0x10($v0) -/* 41895C 802A3BCC 3042C000 */ andi $v0, $v0, 0xc000 -/* 418960 802A3BD0 10400003 */ beqz $v0, .L802A3BE0 -/* 418964 802A3BD4 00000000 */ nop -/* 418968 802A3BD8 3C01802B */ lui $at, %hi(D_802AD10B) -/* 41896C 802A3BDC A020D10B */ sb $zero, %lo(D_802AD10B)($at) -.L802A3BE0: -/* 418970 802A3BE0 3C04802B */ lui $a0, %hi(D_802AD10B) -/* 418974 802A3BE4 2484D10B */ addiu $a0, $a0, %lo(D_802AD10B) -/* 418978 802A3BE8 80820000 */ lb $v0, ($a0) -/* 41897C 802A3BEC 90830000 */ lbu $v1, ($a0) -/* 418980 802A3BF0 10400004 */ beqz $v0, .L802A3C04 -/* 418984 802A3BF4 2462FFFF */ addiu $v0, $v1, -1 -/* 418988 802A3BF8 A0820000 */ sb $v0, ($a0) -/* 41898C 802A3BFC 080A8F1C */ j .L802A3C70 -/* 418990 802A3C00 2402FFFF */ addiu $v0, $zero, -1 -.L802A3C04: -/* 418994 802A3C04 24040009 */ addiu $a0, $zero, 9 -/* 418998 802A3C08 0C051F9F */ jal set_window_update -/* 41899C 802A3C0C 24050002 */ addiu $a1, $zero, 2 -/* 4189A0 802A3C10 24040001 */ addiu $a0, $zero, 1 -/* 4189A4 802A3C14 0C051F9F */ jal set_window_update -/* 4189A8 802A3C18 0080282D */ daddu $a1, $a0, $zero -/* 4189AC 802A3C1C 3C02802B */ lui $v0, %hi(battle_menu_hasSpiritsMenu) -/* 4189B0 802A3C20 8C42D4A0 */ lw $v0, %lo(battle_menu_hasSpiritsMenu)($v0) -/* 4189B4 802A3C24 54400006 */ bnel $v0, $zero, .L802A3C40 -/* 4189B8 802A3C28 24040004 */ addiu $a0, $zero, 4 -/* 4189BC 802A3C2C 24040002 */ addiu $a0, $zero, 2 -/* 4189C0 802A3C30 0C051F9F */ jal set_window_update -/* 4189C4 802A3C34 24050001 */ addiu $a1, $zero, 1 -/* 4189C8 802A3C38 080A8F13 */ j .L802A3C4C -/* 4189CC 802A3C3C 24040003 */ addiu $a0, $zero, 3 -.L802A3C40: -/* 4189D0 802A3C40 0C051F9F */ jal set_window_update -/* 4189D4 802A3C44 24050001 */ addiu $a1, $zero, 1 -/* 4189D8 802A3C48 24040005 */ addiu $a0, $zero, 5 -.L802A3C4C: -/* 4189DC 802A3C4C 0C051F9F */ jal set_window_update -/* 4189E0 802A3C50 24050001 */ addiu $a1, $zero, 1 -/* 4189E4 802A3C54 24040008 */ addiu $a0, $zero, 8 -/* 4189E8 802A3C58 0C051F9F */ jal set_window_update -/* 4189EC 802A3C5C 24050001 */ addiu $a1, $zero, 1 -/* 4189F0 802A3C60 24020001 */ addiu $v0, $zero, 1 -.L802A3C64: -/* 4189F4 802A3C64 3C01802B */ lui $at, %hi(battle_menu_moveState) -/* 4189F8 802A3C68 A022D108 */ sb $v0, %lo(battle_menu_moveState)($at) -.L802A3C6C_4189FC: -/* 4189FC 802A3C6C 0000102D */ daddu $v0, $zero, $zero -.L802A3C70: -/* 418A00 802A3C70 8FBF0044 */ lw $ra, 0x44($sp) -/* 418A04 802A3C74 8FB60040 */ lw $s6, 0x40($sp) -/* 418A08 802A3C78 8FB5003C */ lw $s5, 0x3c($sp) -/* 418A0C 802A3C7C 8FB40038 */ lw $s4, 0x38($sp) -/* 418A10 802A3C80 8FB30034 */ lw $s3, 0x34($sp) -/* 418A14 802A3C84 8FB20030 */ lw $s2, 0x30($sp) -/* 418A18 802A3C88 8FB1002C */ lw $s1, 0x2c($sp) -/* 418A1C 802A3C8C 8FB00028 */ lw $s0, 0x28($sp) -/* 418A20 802A3C90 03E00008 */ jr $ra -/* 418A24 802A3C94 27BD0048 */ addiu $sp, $sp, 0x48 diff --git a/ver/us/asm/nonmatchings/7B440/reset_player_status.s b/ver/us/asm/nonmatchings/7B440/reset_player_status.s deleted file mode 100644 index e194fa6e4f..0000000000 --- a/ver/us/asm/nonmatchings/7B440/reset_player_status.s +++ /dev/null @@ -1,169 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel reset_player_status -/* 7B50C 800E205C 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* 7B510 800E2060 2402FFFF */ addiu $v0, $zero, -1 -/* 7B514 800E2064 3C058011 */ lui $a1, %hi(D_8010C92C) -/* 7B518 800E2068 24A5C92C */ addiu $a1, $a1, %lo(D_8010C92C) -/* 7B51C 800E206C AFB00010 */ sw $s0, 0x10($sp) -/* 7B520 800E2070 3C108011 */ lui $s0, %hi(gPlayerStatus) -/* 7B524 800E2074 2610EFC8 */ addiu $s0, $s0, %lo(gPlayerStatus) -/* 7B528 800E2078 3C018011 */ lui $at, %hi(D_8010C96C) -/* 7B52C 800E207C AC22C96C */ sw $v0, %lo(D_8010C96C)($at) -/* 7B530 800E2080 24020001 */ addiu $v0, $zero, 1 -/* 7B534 800E2084 AFBF0014 */ sw $ra, 0x14($sp) -/* 7B538 800E2088 3C018011 */ lui $at, %hi(TweesterTouchingPartner) -/* 7B53C 800E208C AC20C954 */ sw $zero, %lo(TweesterTouchingPartner)($at) -/* 7B540 800E2090 3C018011 */ lui $at, %hi(D_8010C920) -/* 7B544 800E2094 AC20C920 */ sw $zero, %lo(D_8010C920)($at) -/* 7B548 800E2098 3C018011 */ lui $at, %hi(D_8010C940) -/* 7B54C 800E209C AC20C940 */ sw $zero, %lo(D_8010C940)($at) -/* 7B550 800E20A0 3C018011 */ lui $at, %hi(D_8010C958) -/* 7B554 800E20A4 AC20C958 */ sw $zero, %lo(D_8010C958)($at) -/* 7B558 800E20A8 ACA00000 */ sw $zero, ($a1) -/* 7B55C 800E20AC 3C018011 */ lui $at, %hi(D_8010C95C) -/* 7B560 800E20B0 AC20C95C */ sw $zero, %lo(D_8010C95C)($at) -/* 7B564 800E20B4 3C018011 */ lui $at, %hi(D_8010C980) -/* 7B568 800E20B8 AC20C980 */ sw $zero, %lo(D_8010C980)($at) -/* 7B56C 800E20BC 3C01800F */ lui $at, %hi(D_800F7B40) -/* 7B570 800E20C0 AC207B40 */ sw $zero, %lo(D_800F7B40)($at) -/* 7B574 800E20C4 3C01800F */ lui $at, %hi(D_800F7B44) -/* 7B578 800E20C8 AC207B44 */ sw $zero, %lo(D_800F7B44)($at) -/* 7B57C 800E20CC 3C018011 */ lui $at, %hi(D_8010C938) -/* 7B580 800E20D0 AC20C938 */ sw $zero, %lo(D_8010C938)($at) -/* 7B584 800E20D4 3C018011 */ lui $at, %hi(D_8010C990) -/* 7B588 800E20D8 AC20C990 */ sw $zero, %lo(D_8010C990)($at) -/* 7B58C 800E20DC A202000D */ sb $v0, 0xd($s0) -/* 7B590 800E20E0 2402000D */ addiu $v0, $zero, 0xd -/* 7B594 800E20E4 3C048007 */ lui $a0, %hi(gGameStatusPtr) -/* 7B598 800E20E8 2484419C */ addiu $a0, $a0, %lo(gGameStatusPtr) -/* 7B59C 800E20EC A20200BE */ sb $v0, 0xbe($s0) -/* 7B5A0 800E20F0 8C830000 */ lw $v1, ($a0) -/* 7B5A4 800E20F4 240200FF */ addiu $v0, $zero, 0xff -/* 7B5A8 800E20F8 A202000E */ sb $v0, 0xe($s0) -/* 7B5AC 800E20FC A202000F */ sb $v0, 0xf($s0) -/* 7B5B0 800E2100 9062007E */ lbu $v0, 0x7e($v1) -/* 7B5B4 800E2104 304200F7 */ andi $v0, $v0, 0xf7 -/* 7B5B8 800E2108 A062007E */ sb $v0, 0x7e($v1) -/* 7B5BC 800E210C 8C830000 */ lw $v1, ($a0) -/* 7B5C0 800E2110 9062007E */ lbu $v0, 0x7e($v1) -/* 7B5C4 800E2114 304200EF */ andi $v0, $v0, 0xef -/* 7B5C8 800E2118 A062007E */ sb $v0, 0x7e($v1) -/* 7B5CC 800E211C 8C840000 */ lw $a0, ($a0) -/* 7B5D0 800E2120 9082007E */ lbu $v0, 0x7e($a0) -/* 7B5D4 800E2124 3C013F80 */ lui $at, 0x3f80 -/* 7B5D8 800E2128 44811000 */ mtc1 $at, $f2 -/* 7B5DC 800E212C 30420001 */ andi $v0, $v0, 1 -/* 7B5E0 800E2130 1040000F */ beqz $v0, .L800E2170 -/* 7B5E4 800E2134 24020037 */ addiu $v0, $zero, 0x37 -/* 7B5E8 800E2138 A60200B0 */ sh $v0, 0xb0($s0) -/* 7B5EC 800E213C 8E020004 */ lw $v0, 4($s0) -/* 7B5F0 800E2140 24030026 */ addiu $v1, $zero, 0x26 -/* 7B5F4 800E2144 A60300B2 */ sh $v1, 0xb2($s0) -/* 7B5F8 800E2148 34421000 */ ori $v0, $v0, 0x1000 -/* 7B5FC 800E214C AE020004 */ sw $v0, 4($s0) -/* 7B600 800E2150 9082007E */ lbu $v0, 0x7e($a0) -/* 7B604 800E2154 30420002 */ andi $v0, $v0, 2 -/* 7B608 800E2158 1040000A */ beqz $v0, .L800E2184 -/* 7B60C 800E215C 24020002 */ addiu $v0, $zero, 2 -/* 7B610 800E2160 ACA20000 */ sw $v0, ($a1) -/* 7B614 800E2164 9082007F */ lbu $v0, 0x7f($a0) -/* 7B618 800E2168 08038861 */ j .L800E2184 -/* 7B61C 800E216C A202000C */ sb $v0, 0xc($s0) -.L800E2170: -/* 7B620 800E2170 24020025 */ addiu $v0, $zero, 0x25 -/* 7B624 800E2174 A60200B0 */ sh $v0, 0xb0($s0) -/* 7B628 800E2178 2402001A */ addiu $v0, $zero, 0x1a -/* 7B62C 800E217C A60200B2 */ sh $v0, 0xb2($s0) -/* 7B630 800E2180 A0800080 */ sb $zero, 0x80($a0) -.L800E2184: -/* 7B634 800E2184 3C02800F */ lui $v0, %hi(DefaultMoveSpeeds) -/* 7B638 800E2188 24427B70 */ addiu $v0, $v0, %lo(DefaultMoveSpeeds) -/* 7B63C 800E218C C4400000 */ lwc1 $f0, ($v0) -/* 7B640 800E2190 46020002 */ mul.s $f0, $f0, $f2 -/* 7B644 800E2194 00000000 */ nop -/* 7B648 800E2198 24420004 */ addiu $v0, $v0, 4 -/* 7B64C 800E219C E6000058 */ swc1 $f0, 0x58($s0) -/* 7B650 800E21A0 C4400000 */ lwc1 $f0, ($v0) -/* 7B654 800E21A4 46020002 */ mul.s $f0, $f0, $f2 -/* 7B658 800E21A8 00000000 */ nop -/* 7B65C 800E21AC E600005C */ swc1 $f0, 0x5c($s0) -/* 7B660 800E21B0 C4400004 */ lwc1 $f0, 4($v0) -/* 7B664 800E21B4 46020002 */ mul.s $f0, $f0, $f2 -/* 7B668 800E21B8 00000000 */ nop -/* 7B66C 800E21BC 0000202D */ daddu $a0, $zero, $zero -/* 7B670 800E21C0 0C039769 */ jal set_action_state -/* 7B674 800E21C4 E600006C */ swc1 $f0, 0x6c($s0) -/* 7B678 800E21C8 3C068007 */ lui $a2, %hi(gGameStatusPtr) -/* 7B67C 800E21CC 8CC6419C */ lw $a2, %lo(gGameStatusPtr)($a2) -/* 7B680 800E21D0 AE000054 */ sw $zero, 0x54($s0) -/* 7B684 800E21D4 AE000080 */ sw $zero, 0x80($s0) -/* 7B688 800E21D8 AE000064 */ sw $zero, 0x64($s0) -/* 7B68C 800E21DC AE000088 */ sw $zero, 0x88($s0) -/* 7B690 800E21E0 AE0000B8 */ sw $zero, 0xb8($s0) -/* 7B694 800E21E4 A60000C0 */ sh $zero, 0xc0($s0) -/* 7B698 800E21E8 AE000028 */ sw $zero, 0x28($s0) -/* 7B69C 800E21EC AE00002C */ sw $zero, 0x2c($s0) -/* 7B6A0 800E21F0 AE000030 */ sw $zero, 0x30($s0) -/* 7B6A4 800E21F4 AE000084 */ sw $zero, 0x84($s0) -/* 7B6A8 800E21F8 AE000090 */ sw $zero, 0x90($s0) -/* 7B6AC 800E21FC AE000094 */ sw $zero, 0x94($s0) -/* 7B6B0 800E2200 AE000098 */ sw $zero, 0x98($s0) -/* 7B6B4 800E2204 AE00009C */ sw $zero, 0x9c($s0) -/* 7B6B8 800E2208 84C30086 */ lh $v1, 0x86($a2) -/* 7B6BC 800E220C 84C2008C */ lh $v0, 0x8c($a2) -/* 7B6C0 800E2210 00031900 */ sll $v1, $v1, 4 -/* 7B6C4 800E2214 3C018009 */ lui $at, %hi(gAreas+0x4) -/* 7B6C8 800E2218 00230821 */ addu $at, $at, $v1 -/* 7B6CC 800E221C 8C2334F4 */ lw $v1, %lo(gAreas+0x4)($at) -/* 7B6D0 800E2220 00021140 */ sll $v0, $v0, 5 -/* 7B6D4 800E2224 00431021 */ addu $v0, $v0, $v1 -/* 7B6D8 800E2228 8C440004 */ lw $a0, 4($v0) -/* 7B6DC 800E222C 8C850014 */ lw $a1, 0x14($a0) -/* 7B6E0 800E2230 10A0001B */ beqz $a1, .L800E22A0 -/* 7B6E4 800E2234 00000000 */ nop -/* 7B6E8 800E2238 84C3008E */ lh $v1, 0x8e($a2) -/* 7B6EC 800E223C 8C820018 */ lw $v0, 0x18($a0) -/* 7B6F0 800E2240 0062102A */ slt $v0, $v1, $v0 -/* 7B6F4 800E2244 10400016 */ beqz $v0, .L800E22A0 -/* 7B6F8 800E2248 00031100 */ sll $v0, $v1, 4 -/* 7B6FC 800E224C 00451021 */ addu $v0, $v0, $a1 -/* 7B700 800E2250 C4400000 */ lwc1 $f0, ($v0) -/* 7B704 800E2254 E6000028 */ swc1 $f0, 0x28($s0) -/* 7B708 800E2258 84C2008E */ lh $v0, 0x8e($a2) -/* 7B70C 800E225C 8C830014 */ lw $v1, 0x14($a0) -/* 7B710 800E2260 00021100 */ sll $v0, $v0, 4 -/* 7B714 800E2264 00431021 */ addu $v0, $v0, $v1 -/* 7B718 800E2268 C4400004 */ lwc1 $f0, 4($v0) -/* 7B71C 800E226C E600002C */ swc1 $f0, 0x2c($s0) -/* 7B720 800E2270 84C2008E */ lh $v0, 0x8e($a2) -/* 7B724 800E2274 8C830014 */ lw $v1, 0x14($a0) -/* 7B728 800E2278 00021100 */ sll $v0, $v0, 4 -/* 7B72C 800E227C 00431021 */ addu $v0, $v0, $v1 -/* 7B730 800E2280 C4400008 */ lwc1 $f0, 8($v0) -/* 7B734 800E2284 E6000030 */ swc1 $f0, 0x30($s0) -/* 7B738 800E2288 84C2008E */ lh $v0, 0x8e($a2) -/* 7B73C 800E228C 8C830014 */ lw $v1, 0x14($a0) -/* 7B740 800E2290 00021100 */ sll $v0, $v0, 4 -/* 7B744 800E2294 00431021 */ addu $v0, $v0, $v1 -/* 7B748 800E2298 C440000C */ lwc1 $f0, 0xc($v0) -/* 7B74C 800E229C E6000084 */ swc1 $f0, 0x84($s0) -.L800E22A0: -/* 7B750 800E22A0 C6000028 */ lwc1 $f0, 0x28($s0) -/* 7B754 800E22A4 C602002C */ lwc1 $f2, 0x2c($s0) -/* 7B758 800E22A8 C6040030 */ lwc1 $f4, 0x30($s0) -/* 7B75C 800E22AC 3C02800B */ lui $v0, %hi(gCameras) -/* 7B760 800E22B0 24421D80 */ addiu $v0, $v0, %lo(gCameras) -/* 7B764 800E22B4 E4400060 */ swc1 $f0, 0x60($v0) -/* 7B768 800E22B8 E4420064 */ swc1 $f2, 0x64($v0) -/* 7B76C 800E22BC 0C039668 */ jal phys_reset_spin_history -/* 7B770 800E22C0 E4440068 */ swc1 $f4, 0x68($v0) -/* 7B774 800E22C4 3C048011 */ lui $a0, %hi(gPlayerSpinState) -/* 7B778 800E22C8 2484F250 */ addiu $a0, $a0, %lo(gPlayerSpinState) -/* 7B77C 800E22CC 0C00A580 */ jal mem_clear -/* 7B780 800E22D0 24050034 */ addiu $a1, $zero, 0x34 -/* 7B784 800E22D4 8FBF0014 */ lw $ra, 0x14($sp) -/* 7B788 800E22D8 8FB00010 */ lw $s0, 0x10($sp) -/* 7B78C 800E22DC 03E00008 */ jr $ra -/* 7B790 800E22E0 27BD0018 */ addiu $sp, $sp, 0x18 diff --git a/ver/us/asm/nonmatchings/80850_len_3060/is_ability_active.s b/ver/us/asm/nonmatchings/80850_len_3060/is_ability_active.s index 892c4ea0e9..221d54ccb2 100644 --- a/ver/us/asm/nonmatchings/80850_len_3060/is_ability_active.s +++ b/ver/us/asm/nonmatchings/80850_len_3060/is_ability_active.s @@ -48,25 +48,25 @@ glabel is_ability_active /* 83280 800E9DD0 906378FA */ lbu $v1, %lo(gItemTable+0x1A)($v1) .L800E9DD4: /* 83284 800E9DD4 2D220038 */ sltiu $v0, $t1, 0x38 -/* 83288 800E9DD8 504000A9 */ beql $v0, $zero, L800EA080 +/* 83288 800E9DD8 504000A9 */ beql $v0, $zero, .L800EA080 /* 8328C 800E9DDC 24E70001 */ addiu $a3, $a3, 1 /* 83290 800E9DE0 8D420000 */ lw $v0, ($t2) /* 83294 800E9DE4 00400008 */ jr $v0 /* 83298 800E9DE8 00000000 */ nop .L800E9DEC: -/* 8329C 800E9DEC 0803A81D */ j L800EA074 +/* 8329C 800E9DEC 0803A81D */ j .L800EA074 /* 832A0 800E9DF0 2402004C */ addiu $v0, $zero, 0x4c .L800E9DF4: -/* 832A4 800E9DF4 0803A81D */ j L800EA074 +/* 832A4 800E9DF4 0803A81D */ j .L800EA074 /* 832A8 800E9DF8 24020040 */ addiu $v0, $zero, 0x40 .L800E9DFC: -/* 832AC 800E9DFC 0803A81D */ j L800EA074 +/* 832AC 800E9DFC 0803A81D */ j .L800EA074 /* 832B0 800E9E00 2402004D */ addiu $v0, $zero, 0x4d .L800E9E04: -/* 832B4 800E9E04 0803A81D */ j L800EA074 +/* 832B4 800E9E04 0803A81D */ j .L800EA074 /* 832B8 800E9E08 24020052 */ addiu $v0, $zero, 0x52 .L800E9E0C: -/* 832BC 800E9E0C 0803A81D */ j L800EA074 +/* 832BC 800E9E0C 0803A81D */ j .L800EA074 /* 832C0 800E9E10 24020035 */ addiu $v0, $zero, 0x35 .L800E9E14: /* 832C4 800E9E14 24020053 */ addiu $v0, $zero, 0x53 @@ -74,33 +74,33 @@ glabel is_ability_active /* 832CC 800E9E1C 24A50001 */ addiu $a1, $a1, 1 .L800E9E20: /* 832D0 800E9E20 8102000A */ lb $v0, 0xa($t0) -/* 832D4 800E9E24 50400096 */ beql $v0, $zero, L800EA080 +/* 832D4 800E9E24 50400096 */ beql $v0, $zero, .L800EA080 /* 832D8 800E9E28 24E70001 */ addiu $a3, $a3, 1 /* 832DC 800E9E2C 0803A81F */ j .L800EA07C /* 832E0 800E9E30 24A50001 */ addiu $a1, $a1, 1 .L800E9E34: -/* 832E4 800E9E34 0803A81D */ j L800EA074 +/* 832E4 800E9E34 0803A81D */ j .L800EA074 /* 832E8 800E9E38 24020041 */ addiu $v0, $zero, 0x41 .L800E9E3C: -/* 832EC 800E9E3C 0803A81D */ j L800EA074 +/* 832EC 800E9E3C 0803A81D */ j .L800EA074 /* 832F0 800E9E40 24020042 */ addiu $v0, $zero, 0x42 .L800E9E44: -/* 832F4 800E9E44 0803A81D */ j L800EA074 +/* 832F4 800E9E44 0803A81D */ j .L800EA074 /* 832F8 800E9E48 2402005A */ addiu $v0, $zero, 0x5a .L800E9E4C: -/* 832FC 800E9E4C 0803A81D */ j L800EA074 +/* 832FC 800E9E4C 0803A81D */ j .L800EA074 /* 83300 800E9E50 2402003C */ addiu $v0, $zero, 0x3c .L800E9E54: -/* 83304 800E9E54 0803A81D */ j L800EA074 +/* 83304 800E9E54 0803A81D */ j .L800EA074 /* 83308 800E9E58 2402004E */ addiu $v0, $zero, 0x4e .L800E9E5C: -/* 8330C 800E9E5C 0803A81D */ j L800EA074 +/* 8330C 800E9E5C 0803A81D */ j .L800EA074 /* 83310 800E9E60 2402005B */ addiu $v0, $zero, 0x5b .L800E9E64: -/* 83314 800E9E64 0803A81D */ j L800EA074 +/* 83314 800E9E64 0803A81D */ j .L800EA074 /* 83318 800E9E68 2402003D */ addiu $v0, $zero, 0x3d .L800E9E6C: -/* 8331C 800E9E6C 0803A81D */ j L800EA074 +/* 8331C 800E9E6C 0803A81D */ j .L800EA074 /* 83320 800E9E70 24020043 */ addiu $v0, $zero, 0x43 .L800E9E74: /* 83324 800E9E74 24020054 */ addiu $v0, $zero, 0x54 @@ -149,7 +149,7 @@ glabel is_ability_active /* 833C0 800E9F10 2405FFFF */ addiu $a1, $zero, -1 /* 833C4 800E9F14 24020059 */ addiu $v0, $zero, 0x59 .L800E9F18: -/* 833C8 800E9F18 54620059 */ bnel $v1, $v0, L800EA080 +/* 833C8 800E9F18 54620059 */ bnel $v1, $v0, .L800EA080 /* 833CC 800E9F1C 24E70001 */ addiu $a3, $a3, 1 /* 833D0 800E9F20 24020006 */ addiu $v0, $zero, 6 /* 833D4 800E9F24 ACC20000 */ sw $v0, ($a2) @@ -158,130 +158,130 @@ glabel is_ability_active /* 833E0 800E9F30 0803A81F */ j .L800EA07C /* 833E4 800E9F34 2405FFFF */ addiu $a1, $zero, -1 .L800E9F38: -/* 833E8 800E9F38 0803A81D */ j L800EA074 +/* 833E8 800E9F38 0803A81D */ j .L800EA074 /* 833EC 800E9F3C 2402005C */ addiu $v0, $zero, 0x5c .L800E9F40: -/* 833F0 800E9F40 0803A81D */ j L800EA074 +/* 833F0 800E9F40 0803A81D */ j .L800EA074 /* 833F4 800E9F44 2402005D */ addiu $v0, $zero, 0x5d .L800E9F48: -/* 833F8 800E9F48 0803A81D */ j L800EA074 +/* 833F8 800E9F48 0803A81D */ j .L800EA074 /* 833FC 800E9F4C 2402005E */ addiu $v0, $zero, 0x5e .L800E9F50: -/* 83400 800E9F50 0803A81D */ j L800EA074 +/* 83400 800E9F50 0803A81D */ j .L800EA074 /* 83404 800E9F54 24020044 */ addiu $v0, $zero, 0x44 .L800E9F58: -/* 83408 800E9F58 0803A81D */ j L800EA074 +/* 83408 800E9F58 0803A81D */ j .L800EA074 /* 8340C 800E9F5C 2402005F */ addiu $v0, $zero, 0x5f .L800E9F60: -/* 83410 800E9F60 0803A81D */ j L800EA074 +/* 83410 800E9F60 0803A81D */ j .L800EA074 /* 83414 800E9F64 24020060 */ addiu $v0, $zero, 0x60 .L800E9F68: -/* 83418 800E9F68 0803A81D */ j L800EA074 +/* 83418 800E9F68 0803A81D */ j .L800EA074 /* 8341C 800E9F6C 2402004F */ addiu $v0, $zero, 0x4f .L800E9F70: -/* 83420 800E9F70 0803A81D */ j L800EA074 +/* 83420 800E9F70 0803A81D */ j .L800EA074 /* 83424 800E9F74 24020061 */ addiu $v0, $zero, 0x61 .L800E9F78: -/* 83428 800E9F78 0803A81D */ j L800EA074 +/* 83428 800E9F78 0803A81D */ j .L800EA074 /* 8342C 800E9F7C 24020062 */ addiu $v0, $zero, 0x62 .L800E9F80: -/* 83430 800E9F80 0803A81D */ j L800EA074 +/* 83430 800E9F80 0803A81D */ j .L800EA074 /* 83434 800E9F84 24020063 */ addiu $v0, $zero, 0x63 .L800E9F88: -/* 83438 800E9F88 0803A81D */ j L800EA074 +/* 83438 800E9F88 0803A81D */ j .L800EA074 /* 8343C 800E9F8C 24020045 */ addiu $v0, $zero, 0x45 .L800E9F90: -/* 83440 800E9F90 0803A81D */ j L800EA074 +/* 83440 800E9F90 0803A81D */ j .L800EA074 /* 83444 800E9F94 2402003B */ addiu $v0, $zero, 0x3b .L800E9F98: -/* 83448 800E9F98 0803A81D */ j L800EA074 +/* 83448 800E9F98 0803A81D */ j .L800EA074 /* 8344C 800E9F9C 2402006E */ addiu $v0, $zero, 0x6e .L800E9FA0: -/* 83450 800E9FA0 0803A81D */ j L800EA074 +/* 83450 800E9FA0 0803A81D */ j .L800EA074 /* 83454 800E9FA4 24020064 */ addiu $v0, $zero, 0x64 .L800E9FA8: -/* 83458 800E9FA8 0803A81D */ j L800EA074 +/* 83458 800E9FA8 0803A81D */ j .L800EA074 /* 8345C 800E9FAC 24020065 */ addiu $v0, $zero, 0x65 .L800E9FB0: -/* 83460 800E9FB0 0803A81D */ j L800EA074 +/* 83460 800E9FB0 0803A81D */ j .L800EA074 /* 83464 800E9FB4 24020046 */ addiu $v0, $zero, 0x46 .L800E9FB8: -/* 83468 800E9FB8 0803A81D */ j L800EA074 +/* 83468 800E9FB8 0803A81D */ j .L800EA074 /* 8346C 800E9FBC 24020047 */ addiu $v0, $zero, 0x47 .L800E9FC0: -/* 83470 800E9FC0 0803A81D */ j L800EA074 +/* 83470 800E9FC0 0803A81D */ j .L800EA074 /* 83474 800E9FC4 2402003E */ addiu $v0, $zero, 0x3e .L800E9FC8: -/* 83478 800E9FC8 0803A81D */ j L800EA074 +/* 83478 800E9FC8 0803A81D */ j .L800EA074 /* 8347C 800E9FCC 24020048 */ addiu $v0, $zero, 0x48 .L800E9FD0: -/* 83480 800E9FD0 0803A81D */ j L800EA074 +/* 83480 800E9FD0 0803A81D */ j .L800EA074 /* 83484 800E9FD4 24020066 */ addiu $v0, $zero, 0x66 .L800E9FD8: -/* 83488 800E9FD8 0803A81D */ j L800EA074 +/* 83488 800E9FD8 0803A81D */ j .L800EA074 /* 8348C 800E9FDC 24020049 */ addiu $v0, $zero, 0x49 .L800E9FE0: -/* 83490 800E9FE0 0803A81D */ j L800EA074 +/* 83490 800E9FE0 0803A81D */ j .L800EA074 /* 83494 800E9FE4 24020067 */ addiu $v0, $zero, 0x67 .L800E9FE8: -/* 83498 800E9FE8 0803A81D */ j L800EA074 +/* 83498 800E9FE8 0803A81D */ j .L800EA074 /* 8349C 800E9FEC 2402006D */ addiu $v0, $zero, 0x6d .L800E9FF0: -/* 834A0 800E9FF0 0803A81D */ j L800EA074 +/* 834A0 800E9FF0 0803A81D */ j .L800EA074 /* 834A4 800E9FF4 2402006A */ addiu $v0, $zero, 0x6a .L800E9FF8: -/* 834A8 800E9FF8 0803A81D */ j L800EA074 +/* 834A8 800E9FF8 0803A81D */ j .L800EA074 /* 834AC 800E9FFC 2402006C */ addiu $v0, $zero, 0x6c .L800EA000: -/* 834B0 800EA000 0803A81D */ j L800EA074 +/* 834B0 800EA000 0803A81D */ j .L800EA074 /* 834B4 800EA004 24020050 */ addiu $v0, $zero, 0x50 .L800EA008: -/* 834B8 800EA008 0803A81D */ j L800EA074 +/* 834B8 800EA008 0803A81D */ j .L800EA074 /* 834BC 800EA00C 24020038 */ addiu $v0, $zero, 0x38 .L800EA010: -/* 834C0 800EA010 0803A81D */ j L800EA074 +/* 834C0 800EA010 0803A81D */ j .L800EA074 /* 834C4 800EA014 24020068 */ addiu $v0, $zero, 0x68 .L800EA018: -/* 834C8 800EA018 0803A81D */ j L800EA074 +/* 834C8 800EA018 0803A81D */ j .L800EA074 /* 834CC 800EA01C 24020069 */ addiu $v0, $zero, 0x69 .L800EA020: -/* 834D0 800EA020 0803A81D */ j L800EA074 +/* 834D0 800EA020 0803A81D */ j .L800EA074 /* 834D4 800EA024 2402006B */ addiu $v0, $zero, 0x6b .L800EA028: -/* 834D8 800EA028 0803A81D */ j L800EA074 +/* 834D8 800EA028 0803A81D */ j .L800EA074 /* 834DC 800EA02C 2402006F */ addiu $v0, $zero, 0x6f .L800EA030: -/* 834E0 800EA030 0803A81D */ j L800EA074 +/* 834E0 800EA030 0803A81D */ j .L800EA074 /* 834E4 800EA034 24020070 */ addiu $v0, $zero, 0x70 .L800EA038: -/* 834E8 800EA038 0803A81D */ j L800EA074 +/* 834E8 800EA038 0803A81D */ j .L800EA074 /* 834EC 800EA03C 24020071 */ addiu $v0, $zero, 0x71 .L800EA040: -/* 834F0 800EA040 0803A81D */ j L800EA074 +/* 834F0 800EA040 0803A81D */ j .L800EA074 /* 834F4 800EA044 24020072 */ addiu $v0, $zero, 0x72 .L800EA048: -/* 834F8 800EA048 0803A81D */ j L800EA074 +/* 834F8 800EA048 0803A81D */ j .L800EA074 /* 834FC 800EA04C 24020073 */ addiu $v0, $zero, 0x73 .L800EA050: -/* 83500 800EA050 0803A81D */ j L800EA074 +/* 83500 800EA050 0803A81D */ j .L800EA074 /* 83504 800EA054 24020033 */ addiu $v0, $zero, 0x33 .L800EA058: -/* 83508 800EA058 0803A81D */ j L800EA074 +/* 83508 800EA058 0803A81D */ j .L800EA074 /* 8350C 800EA05C 24020074 */ addiu $v0, $zero, 0x74 .L800EA060: -/* 83510 800EA060 0803A81D */ j L800EA074 +/* 83510 800EA060 0803A81D */ j .L800EA074 /* 83514 800EA064 24020075 */ addiu $v0, $zero, 0x75 .L800EA068: -/* 83518 800EA068 0803A81D */ j L800EA074 +/* 83518 800EA068 0803A81D */ j .L800EA074 /* 8351C 800EA06C 24020076 */ addiu $v0, $zero, 0x76 .L800EA070: /* 83520 800EA070 2402004A */ addiu $v0, $zero, 0x4a -dlabel L800EA074 +.L800EA074: /* 83524 800EA074 50620001 */ beql $v1, $v0, .L800EA07C /* 83528 800EA078 24A50001 */ addiu $a1, $a1, 1 .L800EA07C: /* 8352C 800EA07C 24E70001 */ addiu $a3, $a3, 1 -dlabel L800EA080 +.L800EA080: /* 83530 800EA080 28E20040 */ slti $v0, $a3, 0x40 /* 83534 800EA084 1440FF4C */ bnez $v0, .L800E9DB8 /* 83538 800EA088 00071040 */ sll $v0, $a3, 1 diff --git a/ver/us/asm/nonmatchings/C50A0/appendGfx_item_entity.s b/ver/us/asm/nonmatchings/C50A0/appendGfx_item_entity.s deleted file mode 100644 index 6a5e96ab01..0000000000 --- a/ver/us/asm/nonmatchings/C50A0/appendGfx_item_entity.s +++ /dev/null @@ -1,719 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel appendGfx_item_entity -/* C88A4 801321A4 27BDFEB8 */ addiu $sp, $sp, -0x148 -/* C88A8 801321A8 AFB3012C */ sw $s3, 0x12c($sp) -/* C88AC 801321AC 0080982D */ daddu $s3, $a0, $zero -/* C88B0 801321B0 AFB40130 */ sw $s4, 0x130($sp) -/* C88B4 801321B4 AFBF013C */ sw $ra, 0x13c($sp) -/* C88B8 801321B8 AFB60138 */ sw $s6, 0x138($sp) -/* C88BC 801321BC AFB50134 */ sw $s5, 0x134($sp) -/* C88C0 801321C0 AFB20128 */ sw $s2, 0x128($sp) -/* C88C4 801321C4 AFB10124 */ sw $s1, 0x124($sp) -/* C88C8 801321C8 AFB00120 */ sw $s0, 0x120($sp) -/* C88CC 801321CC F7B40140 */ sdc1 $f20, 0x140($sp) -/* C88D0 801321D0 8E640000 */ lw $a0, ($s3) -/* C88D4 801321D4 3C020808 */ lui $v0, 0x808 -/* C88D8 801321D8 00821024 */ and $v0, $a0, $v0 -/* C88DC 801321DC 10400025 */ beqz $v0, .L80132274 -/* C88E0 801321E0 241400FF */ addiu $s4, $zero, 0xff -/* C88E4 801321E4 3C020008 */ lui $v0, 8 -/* C88E8 801321E8 00821024 */ and $v0, $a0, $v0 -/* C88EC 801321EC 1040000C */ beqz $v0, .L80132220 -/* C88F0 801321F0 3C038080 */ lui $v1, 0x8080 -/* C88F4 801321F4 9262002F */ lbu $v0, 0x2f($s3) -/* C88F8 801321F8 00540018 */ mult $v0, $s4 -/* C88FC 801321FC 00001012 */ mflo $v0 -/* C8900 80132200 34638081 */ ori $v1, $v1, 0x8081 -/* C8904 80132204 00000000 */ nop -/* C8908 80132208 00430018 */ mult $v0, $v1 -/* C890C 8013220C 00001810 */ mfhi $v1 -/* C8910 80132210 00621821 */ addu $v1, $v1, $v0 -/* C8914 80132214 000319C3 */ sra $v1, $v1, 7 -/* C8918 80132218 000217C3 */ sra $v0, $v0, 0x1f -/* C891C 8013221C 0062A023 */ subu $s4, $v1, $v0 -.L80132220: -/* C8920 80132220 3C020800 */ lui $v0, 0x800 -/* C8924 80132224 00821024 */ and $v0, $a0, $v0 -/* C8928 80132228 10400012 */ beqz $v0, .L80132274 -/* C892C 8013222C 27A40118 */ addiu $a0, $sp, 0x118 -/* C8930 80132230 27A50119 */ addiu $a1, $sp, 0x119 -/* C8934 80132234 27A6011A */ addiu $a2, $sp, 0x11a -/* C8938 80132238 0C046FA0 */ jal get_background_color_blend -/* C893C 8013223C 27A7011B */ addiu $a3, $sp, 0x11b -/* C8940 80132240 93A3011B */ lbu $v1, 0x11b($sp) -/* C8944 80132244 240200FF */ addiu $v0, $zero, 0xff -/* C8948 80132248 00431023 */ subu $v0, $v0, $v1 -/* C894C 8013224C 02820018 */ mult $s4, $v0 -/* C8950 80132250 00001012 */ mflo $v0 -/* C8954 80132254 3C038080 */ lui $v1, 0x8080 -/* C8958 80132258 34638081 */ ori $v1, $v1, 0x8081 -/* C895C 8013225C 00430018 */ mult $v0, $v1 -/* C8960 80132260 00001810 */ mfhi $v1 -/* C8964 80132264 00621821 */ addu $v1, $v1, $v0 -/* C8968 80132268 000319C3 */ sra $v1, $v1, 7 -/* C896C 8013226C 000217C3 */ sra $v0, $v0, 0x1f -/* C8970 80132270 0062A023 */ subu $s4, $v1, $v0 -.L80132274: -/* C8974 80132274 8E620000 */ lw $v0, ($s3) -/* C8978 80132278 3C030004 */ lui $v1, 4 -/* C897C 8013227C 00431024 */ and $v0, $v0, $v1 -/* C8980 80132280 14400002 */ bnez $v0, .L8013228C -/* C8984 80132284 2410FFFD */ addiu $s0, $zero, -3 -/* C8988 80132288 2410FFFE */ addiu $s0, $zero, -2 -.L8013228C: -/* C898C 8013228C 86630018 */ lh $v1, 0x18($s3) -/* C8990 80132290 24020157 */ addiu $v0, $zero, 0x157 -/* C8994 80132294 10620005 */ beq $v1, $v0, .L801322AC -/* C8998 80132298 24020159 */ addiu $v0, $zero, 0x159 -/* C899C 8013229C 10620003 */ beq $v1, $v0, .L801322AC -/* C89A0 801322A0 24020156 */ addiu $v0, $zero, 0x156 -/* C89A4 801322A4 14620005 */ bne $v1, $v0, .L801322BC -/* C89A8 801322A8 00000000 */ nop -.L801322AC: -/* C89AC 801322AC 3C013F80 */ lui $at, 0x3f80 -/* C89B0 801322B0 44810000 */ mtc1 $at, $f0 -/* C89B4 801322B4 00000000 */ nop -/* C89B8 801322B8 E6600030 */ swc1 $f0, 0x30($s3) -.L801322BC: -/* C89BC 801322BC 3C03800A */ lui $v1, %hi(gCurrentCamID) -/* C89C0 801322C0 8463A634 */ lh $v1, %lo(gCurrentCamID)($v1) -/* C89C4 801322C4 3C014334 */ lui $at, 0x4334 -/* C89C8 801322C8 44816000 */ mtc1 $at, $f12 -/* C89CC 801322CC 00031080 */ sll $v0, $v1, 2 -/* C89D0 801322D0 00431021 */ addu $v0, $v0, $v1 -/* C89D4 801322D4 00021080 */ sll $v0, $v0, 2 -/* C89D8 801322D8 00431023 */ subu $v0, $v0, $v1 -/* C89DC 801322DC 000218C0 */ sll $v1, $v0, 3 -/* C89E0 801322E0 00431021 */ addu $v0, $v0, $v1 -/* C89E4 801322E4 000210C0 */ sll $v0, $v0, 3 -/* C89E8 801322E8 3C01800B */ lui $at, %hi(gCameras+0x6C) -/* C89EC 801322EC 00220821 */ addu $at, $at, $v0 -/* C89F0 801322F0 C4201DEC */ lwc1 $f0, %lo(gCameras+0x6C)($at) -/* C89F4 801322F4 0C00A6C9 */ jal clamp_angle -/* C89F8 801322F8 46006301 */ sub.s $f12, $f12, $f0 -/* C89FC 801322FC 27B20058 */ addiu $s2, $sp, 0x58 -/* C8A00 80132300 0240202D */ daddu $a0, $s2, $zero -/* C8A04 80132304 C664000C */ lwc1 $f4, 0xc($s3) -/* C8A08 80132308 44901000 */ mtc1 $s0, $f2 -/* C8A0C 8013230C 00000000 */ nop -/* C8A10 80132310 468010A0 */ cvt.s.w $f2, $f2 -/* C8A14 80132314 46022100 */ add.s $f4, $f4, $f2 -/* C8A18 80132318 8E650008 */ lw $a1, 8($s3) -/* C8A1C 8013231C 8E670010 */ lw $a3, 0x10($s3) -/* C8A20 80132320 44062000 */ mfc1 $a2, $f4 -/* C8A24 80132324 0C019E40 */ jal guTranslateF -/* C8A28 80132328 46000506 */ mov.s $f20, $f0 -/* C8A2C 8013232C 27B10098 */ addiu $s1, $sp, 0x98 -/* C8A30 80132330 4405A000 */ mfc1 $a1, $f20 -/* C8A34 80132334 44800000 */ mtc1 $zero, $f0 -/* C8A38 80132338 3C073F80 */ lui $a3, 0x3f80 -/* C8A3C 8013233C 44060000 */ mfc1 $a2, $f0 -/* C8A40 80132340 0220202D */ daddu $a0, $s1, $zero -/* C8A44 80132344 0C019EC8 */ jal guRotateF -/* C8A48 80132348 AFA60010 */ sw $a2, 0x10($sp) -/* C8A4C 8013234C 8E620000 */ lw $v0, ($s3) -/* C8A50 80132350 30424000 */ andi $v0, $v0, 0x4000 -/* C8A54 80132354 1040000A */ beqz $v0, .L80132380 -/* C8A58 80132358 27B000D8 */ addiu $s0, $sp, 0xd8 -/* C8A5C 8013235C 8E650030 */ lw $a1, 0x30($s3) -/* C8A60 80132360 0200202D */ daddu $a0, $s0, $zero -/* C8A64 80132364 00A0302D */ daddu $a2, $a1, $zero -/* C8A68 80132368 0C019DF0 */ jal guScaleF -/* C8A6C 8013236C 00A0382D */ daddu $a3, $a1, $zero -/* C8A70 80132370 0220202D */ daddu $a0, $s1, $zero -/* C8A74 80132374 0200282D */ daddu $a1, $s0, $zero -/* C8A78 80132378 0C019D80 */ jal guMtxCatF -/* C8A7C 8013237C 0220302D */ daddu $a2, $s1, $zero -.L80132380: -/* C8A80 80132380 0220202D */ daddu $a0, $s1, $zero -/* C8A84 80132384 0240282D */ daddu $a1, $s2, $zero -/* C8A88 80132388 0C019D80 */ jal guMtxCatF -/* C8A8C 8013238C 0240302D */ daddu $a2, $s2, $zero -/* C8A90 80132390 0240202D */ daddu $a0, $s2, $zero -/* C8A94 80132394 0C019D40 */ jal guMtxF2L -/* C8A98 80132398 27A50018 */ addiu $a1, $sp, 0x18 -/* C8A9C 8013239C 3C020001 */ lui $v0, 1 -/* C8AA0 801323A0 34421630 */ ori $v0, $v0, 0x1630 -/* C8AA4 801323A4 27A70018 */ addiu $a3, $sp, 0x18 -/* C8AA8 801323A8 0240282D */ daddu $a1, $s2, $zero -/* C8AAC 801323AC 3C038007 */ lui $v1, %hi(gMatrixListPos) -/* C8AB0 801323B0 946341F0 */ lhu $v1, %lo(gMatrixListPos)($v1) -/* C8AB4 801323B4 3C04800A */ lui $a0, %hi(gDisplayContext) -/* C8AB8 801323B8 8C84A674 */ lw $a0, %lo(gDisplayContext)($a0) -/* C8ABC 801323BC 00031980 */ sll $v1, $v1, 6 -/* C8AC0 801323C0 00832021 */ addu $a0, $a0, $v1 -/* C8AC4 801323C4 00822021 */ addu $a0, $a0, $v0 -.L801323C8: -/* C8AC8 801323C8 8CF50000 */ lw $s5, ($a3) -/* C8ACC 801323CC 8CF60004 */ lw $s6, 4($a3) -/* C8AD0 801323D0 8CF80008 */ lw $t8, 8($a3) -/* C8AD4 801323D4 8CF9000C */ lw $t9, 0xc($a3) -/* C8AD8 801323D8 AC950000 */ sw $s5, ($a0) -/* C8ADC 801323DC AC960004 */ sw $s6, 4($a0) -/* C8AE0 801323E0 AC980008 */ sw $t8, 8($a0) -/* C8AE4 801323E4 AC99000C */ sw $t9, 0xc($a0) -/* C8AE8 801323E8 24E70010 */ addiu $a3, $a3, 0x10 -/* C8AEC 801323EC 14E5FFF6 */ bne $a3, $a1, .L801323C8 -/* C8AF0 801323F0 24840010 */ addiu $a0, $a0, 0x10 -/* C8AF4 801323F4 3C02DA38 */ lui $v0, 0xda38 -/* C8AF8 801323F8 34420002 */ ori $v0, $v0, 2 -/* C8AFC 801323FC 3C050001 */ lui $a1, 1 -/* C8B00 80132400 3C09800A */ lui $t1, %hi(gMasterGfxPos) -/* C8B04 80132404 2529A66C */ addiu $t1, $t1, %lo(gMasterGfxPos) -/* C8B08 80132408 34A51630 */ ori $a1, $a1, 0x1630 -/* C8B0C 8013240C 3C078007 */ lui $a3, %hi(gMatrixListPos) -/* C8B10 80132410 24E741F0 */ addiu $a3, $a3, %lo(gMatrixListPos) -/* C8B14 80132414 8D280000 */ lw $t0, ($t1) -/* C8B18 80132418 94E40000 */ lhu $a0, ($a3) -/* C8B1C 8013241C 0100302D */ daddu $a2, $t0, $zero -/* C8B20 80132420 25080008 */ addiu $t0, $t0, 8 -/* C8B24 80132424 3083FFFF */ andi $v1, $a0, 0xffff -/* C8B28 80132428 00031980 */ sll $v1, $v1, 6 -/* C8B2C 8013242C 00651821 */ addu $v1, $v1, $a1 -/* C8B30 80132430 AD280000 */ sw $t0, ($t1) -/* C8B34 80132434 ACC20000 */ sw $v0, ($a2) -/* C8B38 80132438 3C02800A */ lui $v0, %hi(gDisplayContext) -/* C8B3C 8013243C 8C42A674 */ lw $v0, %lo(gDisplayContext)($v0) -/* C8B40 80132440 3C058015 */ lui $a1, %hi(D_80151328) -/* C8B44 80132444 8CA51328 */ lw $a1, %lo(D_80151328)($a1) -/* C8B48 80132448 00431021 */ addu $v0, $v0, $v1 -/* C8B4C 8013244C ACC20004 */ sw $v0, 4($a2) -/* C8B50 80132450 94A20000 */ lhu $v0, ($a1) -/* C8B54 80132454 24840001 */ addiu $a0, $a0, 1 -/* C8B58 80132458 10400009 */ beqz $v0, .L80132480 -/* C8B5C 8013245C A4E40000 */ sh $a0, ($a3) -/* C8B60 80132460 25020008 */ addiu $v0, $t0, 8 -/* C8B64 80132464 AD220000 */ sw $v0, ($t1) -/* C8B68 80132468 3C02DE00 */ lui $v0, 0xde00 -/* C8B6C 8013246C AD020000 */ sw $v0, ($t0) -/* C8B70 80132470 3C028015 */ lui $v0, %hi(D_8014BBD8) -/* C8B74 80132474 2442BBD8 */ addiu $v0, $v0, %lo(D_8014BBD8) -/* C8B78 80132478 0804C927 */ j .L8013249C -/* C8B7C 8013247C AD020004 */ sw $v0, 4($t0) -.L80132480: -/* C8B80 80132480 25020008 */ addiu $v0, $t0, 8 -/* C8B84 80132484 AD220000 */ sw $v0, ($t1) -/* C8B88 80132488 3C02DE00 */ lui $v0, 0xde00 -/* C8B8C 8013248C AD020000 */ sw $v0, ($t0) -/* C8B90 80132490 3C028015 */ lui $v0, %hi(D_8014B870) -/* C8B94 80132494 2442B870 */ addiu $v0, $v0, %lo(D_8014B870) -/* C8B98 80132498 AD020004 */ sw $v0, 4($t0) -.L8013249C: -/* C8B9C 8013249C 3C03D9FD */ lui $v1, 0xd9fd -/* C8BA0 801324A0 3C08800A */ lui $t0, %hi(gMasterGfxPos) -/* C8BA4 801324A4 2508A66C */ addiu $t0, $t0, %lo(gMasterGfxPos) -/* C8BA8 801324A8 8D070000 */ lw $a3, ($t0) -/* C8BAC 801324AC 3463F9FF */ ori $v1, $v1, 0xf9ff -/* C8BB0 801324B0 00E0102D */ daddu $v0, $a3, $zero -/* C8BB4 801324B4 24E70008 */ addiu $a3, $a3, 8 -/* C8BB8 801324B8 AD070000 */ sw $a3, ($t0) -/* C8BBC 801324BC AC430000 */ sw $v1, ($v0) -/* C8BC0 801324C0 AC400004 */ sw $zero, 4($v0) -/* C8BC4 801324C4 24E20008 */ addiu $v0, $a3, 8 -/* C8BC8 801324C8 AD020000 */ sw $v0, ($t0) -/* C8BCC 801324CC 3C02DE00 */ lui $v0, 0xde00 -/* C8BD0 801324D0 ACE20000 */ sw $v0, ($a3) -/* C8BD4 801324D4 3C028015 */ lui $v0, %hi(D_8014C620) -/* C8BD8 801324D8 2442C620 */ addiu $v0, $v0, %lo(D_8014C620) -/* C8BDC 801324DC ACE20004 */ sw $v0, 4($a3) -/* C8BE0 801324E0 8E620000 */ lw $v0, ($s3) -/* C8BE4 801324E4 3C030808 */ lui $v1, 0x808 -/* C8BE8 801324E8 00431024 */ and $v0, $v0, $v1 -/* C8BEC 801324EC 10400025 */ beqz $v0, .L80132584 -/* C8BF0 801324F0 00000000 */ nop -/* C8BF4 801324F4 3C028015 */ lui $v0, %hi(D_80151328) -/* C8BF8 801324F8 8C421328 */ lw $v0, %lo(D_80151328)($v0) -/* C8BFC 801324FC 94420000 */ lhu $v0, ($v0) -/* C8C00 80132500 10400009 */ beqz $v0, .L80132528 -/* C8C04 80132504 3C04E200 */ lui $a0, 0xe200 -/* C8C08 80132508 3484001C */ ori $a0, $a0, 0x1c -/* C8C0C 8013250C 3C030C18 */ lui $v1, 0xc18 -/* C8C10 80132510 34634348 */ ori $v1, $v1, 0x4348 -/* C8C14 80132514 24E20010 */ addiu $v0, $a3, 0x10 -/* C8C18 80132518 AD020000 */ sw $v0, ($t0) -/* C8C1C 8013251C ACE40008 */ sw $a0, 8($a3) -/* C8C20 80132520 0804C961 */ j .L80132584 -/* C8C24 80132524 ACE3000C */ sw $v1, 0xc($a3) -.L80132528: -/* C8C28 80132528 3C05E200 */ lui $a1, 0xe200 -/* C8C2C 8013252C 34A5001C */ ori $a1, $a1, 0x1c -/* C8C30 80132530 3C030050 */ lui $v1, 0x50 -/* C8C34 80132534 34634348 */ ori $v1, $v1, 0x4348 -/* C8C38 80132538 3C06FC30 */ lui $a2, 0xfc30 -/* C8C3C 8013253C 34C6B261 */ ori $a2, $a2, 0xb261 -/* C8C40 80132540 3C04FF2F */ lui $a0, 0xff2f -/* C8C44 80132544 3484FFFF */ ori $a0, $a0, 0xffff -/* C8C48 80132548 24E20010 */ addiu $v0, $a3, 0x10 -/* C8C4C 8013254C AD020000 */ sw $v0, ($t0) -/* C8C50 80132550 24E20018 */ addiu $v0, $a3, 0x18 -/* C8C54 80132554 ACE50008 */ sw $a1, 8($a3) -/* C8C58 80132558 ACE3000C */ sw $v1, 0xc($a3) -/* C8C5C 8013255C AD020000 */ sw $v0, ($t0) -/* C8C60 80132560 24E20020 */ addiu $v0, $a3, 0x20 -/* C8C64 80132564 ACE60010 */ sw $a2, 0x10($a3) -/* C8C68 80132568 ACE40014 */ sw $a0, 0x14($a3) -/* C8C6C 8013256C AD020000 */ sw $v0, ($t0) -/* C8C70 80132570 3C02FA00 */ lui $v0, 0xfa00 -/* C8C74 80132574 ACE20018 */ sw $v0, 0x18($a3) -/* C8C78 80132578 2402FF00 */ addiu $v0, $zero, -0x100 -/* C8C7C 8013257C 02821025 */ or $v0, $s4, $v0 -/* C8C80 80132580 ACE2001C */ sw $v0, 0x1c($a3) -.L80132584: -/* C8C84 80132584 8E620000 */ lw $v0, ($s3) -/* C8C88 80132588 3C030004 */ lui $v1, 4 -/* C8C8C 8013258C 00431024 */ and $v0, $v0, $v1 -/* C8C90 80132590 144000CE */ bnez $v0, .L801328CC -/* C8C94 80132594 3C05F500 */ lui $a1, 0xf500 -/* C8C98 80132598 34A50100 */ ori $a1, $a1, 0x100 -/* C8C9C 8013259C 3C060703 */ lui $a2, 0x703 -/* C8CA0 801325A0 3C0F800A */ lui $t7, %hi(gMasterGfxPos) -/* C8CA4 801325A4 25EFA66C */ addiu $t7, $t7, %lo(gMasterGfxPos) -/* C8CA8 801325A8 34C6C000 */ ori $a2, $a2, 0xc000 -/* C8CAC 801325AC 3C02FD10 */ lui $v0, 0xfd10 -/* C8CB0 801325B0 8DEE0000 */ lw $t6, ($t7) -/* C8CB4 801325B4 3C10E600 */ lui $s0, 0xe600 -/* C8CB8 801325B8 01C0202D */ daddu $a0, $t6, $zero -/* C8CBC 801325BC 25CE0008 */ addiu $t6, $t6, 8 -/* C8CC0 801325C0 ADEE0000 */ sw $t6, ($t7) -/* C8CC4 801325C4 AC820000 */ sw $v0, ($a0) -/* C8CC8 801325C8 9263002D */ lbu $v1, 0x2d($s3) -/* C8CCC 801325CC 25C20008 */ addiu $v0, $t6, 8 -/* C8CD0 801325D0 ADE20000 */ sw $v0, ($t7) -/* C8CD4 801325D4 25C20010 */ addiu $v0, $t6, 0x10 -/* C8CD8 801325D8 ADE20000 */ sw $v0, ($t7) -/* C8CDC 801325DC 25C20018 */ addiu $v0, $t6, 0x18 -/* C8CE0 801325E0 ADE20000 */ sw $v0, ($t7) -/* C8CE4 801325E4 3C028015 */ lui $v0, %hi(gHudElementCacheTablePalette) -/* C8CE8 801325E8 8C4212D0 */ lw $v0, %lo(gHudElementCacheTablePalette)($v0) -/* C8CEC 801325EC 000318C0 */ sll $v1, $v1, 3 -/* C8CF0 801325F0 00621821 */ addu $v1, $v1, $v0 -/* C8CF4 801325F4 8C630004 */ lw $v1, 4($v1) -/* C8CF8 801325F8 25C20020 */ addiu $v0, $t6, 0x20 -/* C8CFC 801325FC ADE20000 */ sw $v0, ($t7) -/* C8D00 80132600 3C02E800 */ lui $v0, 0xe800 -/* C8D04 80132604 AC830004 */ sw $v1, 4($a0) -/* C8D08 80132608 ADC20000 */ sw $v0, ($t6) -/* C8D0C 8013260C 3C020700 */ lui $v0, 0x700 -/* C8D10 80132610 ADC2000C */ sw $v0, 0xc($t6) -/* C8D14 80132614 3C02F000 */ lui $v0, 0xf000 -/* C8D18 80132618 ADC20018 */ sw $v0, 0x18($t6) -/* C8D1C 8013261C 3C028015 */ lui $v0, %hi(D_80151328) -/* C8D20 80132620 8C421328 */ lw $v0, %lo(D_80151328)($v0) -/* C8D24 80132624 3C11E700 */ lui $s1, 0xe700 -/* C8D28 80132628 ADC00004 */ sw $zero, 4($t6) -/* C8D2C 8013262C ADC50008 */ sw $a1, 8($t6) -/* C8D30 80132630 ADD00010 */ sw $s0, 0x10($t6) -/* C8D34 80132634 ADC00014 */ sw $zero, 0x14($t6) -/* C8D38 80132638 ADC6001C */ sw $a2, 0x1c($t6) -/* C8D3C 8013263C ADD10020 */ sw $s1, 0x20($t6) -/* C8D40 80132640 ADC00024 */ sw $zero, 0x24($t6) -/* C8D44 80132644 94430000 */ lhu $v1, ($v0) -/* C8D48 80132648 25C20028 */ addiu $v0, $t6, 0x28 -/* C8D4C 8013264C 10600060 */ beqz $v1, .L801327D0 -/* C8D50 80132650 ADE20000 */ sw $v0, ($t7) -/* C8D54 80132654 3C03FD48 */ lui $v1, 0xfd48 -/* C8D58 80132658 3463000B */ ori $v1, $v1, 0xb -/* C8D5C 8013265C 3C07F548 */ lui $a3, 0xf548 -/* C8D60 80132660 34E70400 */ ori $a3, $a3, 0x400 -/* C8D64 80132664 3C05070A */ lui $a1, 0x70a -/* C8D68 80132668 34A50280 */ ori $a1, $a1, 0x280 -/* C8D6C 8013266C 3C0B0702 */ lui $t3, 0x702 -/* C8D70 80132670 356BE05C */ ori $t3, $t3, 0xe05c -/* C8D74 80132674 3C04F540 */ lui $a0, 0xf540 -/* C8D78 80132678 34840400 */ ori $a0, $a0, 0x400 -/* C8D7C 8013267C 3C0C010A */ lui $t4, 0x10a -/* C8D80 80132680 358C0280 */ ori $t4, $t4, 0x280 -/* C8D84 80132684 3C0AF240 */ lui $t2, 0xf240 -/* C8D88 80132688 354A0400 */ ori $t2, $t2, 0x400 -/* C8D8C 8013268C 3C080145 */ lui $t0, 0x145 -/* C8D90 80132690 3508C45C */ ori $t0, $t0, 0xc45c -/* C8D94 80132694 3C09001A */ lui $t1, 0x1a -/* C8D98 80132698 35290280 */ ori $t1, $t1, 0x280 -/* C8D9C 8013269C 3C06F510 */ lui $a2, 0xf510 -/* C8DA0 801326A0 34C60900 */ ori $a2, $a2, 0x900 -/* C8DA4 801326A4 3C0D020F */ lui $t5, 0x20f -/* C8DA8 801326A8 35ADC000 */ ori $t5, $t5, 0xc000 -/* C8DAC 801326AC 25C20030 */ addiu $v0, $t6, 0x30 -/* C8DB0 801326B0 ADE20000 */ sw $v0, ($t7) -/* C8DB4 801326B4 ADC30028 */ sw $v1, 0x28($t6) -/* C8DB8 801326B8 9263002C */ lbu $v1, 0x2c($s3) -/* C8DBC 801326BC 25C20038 */ addiu $v0, $t6, 0x38 -/* C8DC0 801326C0 ADE20000 */ sw $v0, ($t7) -/* C8DC4 801326C4 25C20040 */ addiu $v0, $t6, 0x40 -/* C8DC8 801326C8 ADE20000 */ sw $v0, ($t7) -/* C8DCC 801326CC 25C20048 */ addiu $v0, $t6, 0x48 -/* C8DD0 801326D0 ADE20000 */ sw $v0, ($t7) -/* C8DD4 801326D4 25C20050 */ addiu $v0, $t6, 0x50 -/* C8DD8 801326D8 ADE20000 */ sw $v0, ($t7) -/* C8DDC 801326DC 25C20058 */ addiu $v0, $t6, 0x58 -/* C8DE0 801326E0 ADE20000 */ sw $v0, ($t7) -/* C8DE4 801326E4 25C20060 */ addiu $v0, $t6, 0x60 -/* C8DE8 801326E8 ADE20000 */ sw $v0, ($t7) -/* C8DEC 801326EC 25C20068 */ addiu $v0, $t6, 0x68 -/* C8DF0 801326F0 ADE20000 */ sw $v0, ($t7) -/* C8DF4 801326F4 25C20070 */ addiu $v0, $t6, 0x70 -/* C8DF8 801326F8 ADE20000 */ sw $v0, ($t7) -/* C8DFC 801326FC 3C028015 */ lui $v0, %hi(gHudElementCacheTableRaster) -/* C8E00 80132700 8C4212C8 */ lw $v0, %lo(gHudElementCacheTableRaster)($v0) -/* C8E04 80132704 000318C0 */ sll $v1, $v1, 3 -/* C8E08 80132708 00621821 */ addu $v1, $v1, $v0 -/* C8E0C 8013270C 8C630004 */ lw $v1, 4($v1) -/* C8E10 80132710 25C20078 */ addiu $v0, $t6, 0x78 -/* C8E14 80132714 ADE20000 */ sw $v0, ($t7) -/* C8E18 80132718 3C02F400 */ lui $v0, 0xf400 -/* C8E1C 8013271C ADC20040 */ sw $v0, 0x40($t6) -/* C8E20 80132720 3C020200 */ lui $v0, 0x200 -/* C8E24 80132724 ADC2006C */ sw $v0, 0x6c($t6) -/* C8E28 80132728 3C02F200 */ lui $v0, 0xf200 -/* C8E2C 8013272C ADC70030 */ sw $a3, 0x30($t6) -/* C8E30 80132730 ADC50034 */ sw $a1, 0x34($t6) -/* C8E34 80132734 ADD00038 */ sw $s0, 0x38($t6) -/* C8E38 80132738 ADC0003C */ sw $zero, 0x3c($t6) -/* C8E3C 8013273C ADCB0044 */ sw $t3, 0x44($t6) -/* C8E40 80132740 ADD10048 */ sw $s1, 0x48($t6) -/* C8E44 80132744 ADC0004C */ sw $zero, 0x4c($t6) -/* C8E48 80132748 ADC40050 */ sw $a0, 0x50($t6) -/* C8E4C 8013274C ADCC0054 */ sw $t4, 0x54($t6) -/* C8E50 80132750 ADCA0058 */ sw $t2, 0x58($t6) -/* C8E54 80132754 ADC8005C */ sw $t0, 0x5c($t6) -/* C8E58 80132758 ADC40060 */ sw $a0, 0x60($t6) -/* C8E5C 8013275C ADC90064 */ sw $t1, 0x64($t6) -/* C8E60 80132760 ADC60068 */ sw $a2, 0x68($t6) -/* C8E64 80132764 ADC20070 */ sw $v0, 0x70($t6) -/* C8E68 80132768 ADCD0074 */ sw $t5, 0x74($t6) -/* C8E6C 8013276C ADC3002C */ sw $v1, 0x2c($t6) -/* C8E70 80132770 8E620000 */ lw $v0, ($s3) -/* C8E74 80132774 3C030808 */ lui $v1, 0x808 -/* C8E78 80132778 00431024 */ and $v0, $v0, $v1 -/* C8E7C 8013277C 1040000A */ beqz $v0, .L801327A8 -/* C8E80 80132780 27A40058 */ addiu $a0, $sp, 0x58 -/* C8E84 80132784 0000282D */ daddu $a1, $zero, $zero -/* C8E88 80132788 00A0302D */ daddu $a2, $a1, $zero -/* C8E8C 8013278C 24070018 */ addiu $a3, $zero, 0x18 -/* C8E90 80132790 00E0102D */ daddu $v0, $a3, $zero -/* C8E94 80132794 AFA20010 */ sw $v0, 0x10($sp) -/* C8E98 80132798 0C052479 */ jal func_801491E4 -/* C8E9C 8013279C AFB40014 */ sw $s4, 0x14($sp) -/* C8EA0 801327A0 0804CA27 */ j .L8013289C -/* C8EA4 801327A4 00000000 */ nop -.L801327A8: -/* C8EA8 801327A8 0000282D */ daddu $a1, $zero, $zero -/* C8EAC 801327AC 00A0302D */ daddu $a2, $a1, $zero -/* C8EB0 801327B0 24070018 */ addiu $a3, $zero, 0x18 -/* C8EB4 801327B4 00E0102D */ daddu $v0, $a3, $zero -/* C8EB8 801327B8 AFA20010 */ sw $v0, 0x10($sp) -/* C8EBC 801327BC 240200FF */ addiu $v0, $zero, 0xff -/* C8EC0 801327C0 0C052479 */ jal func_801491E4 -/* C8EC4 801327C4 AFA20014 */ sw $v0, 0x14($sp) -/* C8EC8 801327C8 0804CA27 */ j .L8013289C -/* C8ECC 801327CC 00000000 */ nop -.L801327D0: -/* C8ED0 801327D0 3C03FD48 */ lui $v1, 0xfd48 -/* C8ED4 801327D4 3463000B */ ori $v1, $v1, 0xb -/* C8ED8 801327D8 3C05F548 */ lui $a1, 0xf548 -/* C8EDC 801327DC 34A50400 */ ori $a1, $a1, 0x400 -/* C8EE0 801327E0 3C04070A */ lui $a0, 0x70a -/* C8EE4 801327E4 34840280 */ ori $a0, $a0, 0x280 -/* C8EE8 801327E8 3C080702 */ lui $t0, 0x702 -/* C8EEC 801327EC 3508E05C */ ori $t0, $t0, 0xe05c -/* C8EF0 801327F0 3C0AF540 */ lui $t2, 0xf540 -/* C8EF4 801327F4 354A0400 */ ori $t2, $t2, 0x400 -/* C8EF8 801327F8 3C09000A */ lui $t1, 0xa -/* C8EFC 801327FC 35290280 */ ori $t1, $t1, 0x280 -/* C8F00 80132800 3C07F240 */ lui $a3, 0xf240 -/* C8F04 80132804 34E70400 */ ori $a3, $a3, 0x400 -/* C8F08 80132808 3C060045 */ lui $a2, 0x45 -/* C8F0C 8013280C 34C6C45C */ ori $a2, $a2, 0xc45c -/* C8F10 80132810 25C20030 */ addiu $v0, $t6, 0x30 -/* C8F14 80132814 ADE20000 */ sw $v0, ($t7) -/* C8F18 80132818 ADC30028 */ sw $v1, 0x28($t6) -/* C8F1C 8013281C 9263002C */ lbu $v1, 0x2c($s3) -/* C8F20 80132820 25C20038 */ addiu $v0, $t6, 0x38 -/* C8F24 80132824 ADE20000 */ sw $v0, ($t7) -/* C8F28 80132828 25C20040 */ addiu $v0, $t6, 0x40 -/* C8F2C 8013282C ADE20000 */ sw $v0, ($t7) -/* C8F30 80132830 25C20048 */ addiu $v0, $t6, 0x48 -/* C8F34 80132834 ADE20000 */ sw $v0, ($t7) -/* C8F38 80132838 25C20050 */ addiu $v0, $t6, 0x50 -/* C8F3C 8013283C ADE20000 */ sw $v0, ($t7) -/* C8F40 80132840 25C20058 */ addiu $v0, $t6, 0x58 -/* C8F44 80132844 ADE20000 */ sw $v0, ($t7) -/* C8F48 80132848 3C028015 */ lui $v0, %hi(gHudElementCacheTableRaster) -/* C8F4C 8013284C 8C4212C8 */ lw $v0, %lo(gHudElementCacheTableRaster)($v0) -/* C8F50 80132850 000318C0 */ sll $v1, $v1, 3 -/* C8F54 80132854 00621821 */ addu $v1, $v1, $v0 -/* C8F58 80132858 8C630004 */ lw $v1, 4($v1) -/* C8F5C 8013285C 25C20060 */ addiu $v0, $t6, 0x60 -/* C8F60 80132860 ADE20000 */ sw $v0, ($t7) -/* C8F64 80132864 3C02F400 */ lui $v0, 0xf400 -/* C8F68 80132868 ADC50030 */ sw $a1, 0x30($t6) -/* C8F6C 8013286C ADC40034 */ sw $a0, 0x34($t6) -/* C8F70 80132870 ADD00038 */ sw $s0, 0x38($t6) -/* C8F74 80132874 ADC0003C */ sw $zero, 0x3c($t6) -/* C8F78 80132878 ADC20040 */ sw $v0, 0x40($t6) -/* C8F7C 8013287C ADC80044 */ sw $t0, 0x44($t6) -/* C8F80 80132880 ADD10048 */ sw $s1, 0x48($t6) -/* C8F84 80132884 ADC0004C */ sw $zero, 0x4c($t6) -/* C8F88 80132888 ADCA0050 */ sw $t2, 0x50($t6) -/* C8F8C 8013288C ADC90054 */ sw $t1, 0x54($t6) -/* C8F90 80132890 ADC70058 */ sw $a3, 0x58($t6) -/* C8F94 80132894 ADC6005C */ sw $a2, 0x5c($t6) -/* C8F98 80132898 ADC3002C */ sw $v1, 0x2c($t6) -.L8013289C: -/* C8F9C 8013289C 3C03800A */ lui $v1, %hi(gMasterGfxPos) -/* C8FA0 801328A0 2463A66C */ addiu $v1, $v1, %lo(gMasterGfxPos) -/* C8FA4 801328A4 8C620000 */ lw $v0, ($v1) -/* C8FA8 801328A8 0040202D */ daddu $a0, $v0, $zero -/* C8FAC 801328AC 24420008 */ addiu $v0, $v0, 8 -/* C8FB0 801328B0 AC620000 */ sw $v0, ($v1) -/* C8FB4 801328B4 3C02DE00 */ lui $v0, 0xde00 -/* C8FB8 801328B8 AC820000 */ sw $v0, ($a0) -/* C8FBC 801328BC 3C028015 */ lui $v0, %hi(D_8014C678) -/* C8FC0 801328C0 2442C678 */ addiu $v0, $v0, %lo(D_8014C678) -/* C8FC4 801328C4 0804CAFF */ j .L80132BFC -/* C8FC8 801328C8 AC820004 */ sw $v0, 4($a0) -.L801328CC: -/* C8FCC 801328CC 34A50100 */ ori $a1, $a1, 0x100 -/* C8FD0 801328D0 3C060703 */ lui $a2, 0x703 -/* C8FD4 801328D4 3C0F800A */ lui $t7, %hi(gMasterGfxPos) -/* C8FD8 801328D8 25EFA66C */ addiu $t7, $t7, %lo(gMasterGfxPos) -/* C8FDC 801328DC 34C6C000 */ ori $a2, $a2, 0xc000 -/* C8FE0 801328E0 3C02FD10 */ lui $v0, 0xfd10 -/* C8FE4 801328E4 8DEE0000 */ lw $t6, ($t7) -/* C8FE8 801328E8 3C10E600 */ lui $s0, 0xe600 -/* C8FEC 801328EC 01C0202D */ daddu $a0, $t6, $zero -/* C8FF0 801328F0 25CE0008 */ addiu $t6, $t6, 8 -/* C8FF4 801328F4 ADEE0000 */ sw $t6, ($t7) -/* C8FF8 801328F8 AC820000 */ sw $v0, ($a0) -/* C8FFC 801328FC 9263002D */ lbu $v1, 0x2d($s3) -/* C9000 80132900 25C20008 */ addiu $v0, $t6, 8 -/* C9004 80132904 ADE20000 */ sw $v0, ($t7) -/* C9008 80132908 25C20010 */ addiu $v0, $t6, 0x10 -/* C900C 8013290C ADE20000 */ sw $v0, ($t7) -/* C9010 80132910 25C20018 */ addiu $v0, $t6, 0x18 -/* C9014 80132914 ADE20000 */ sw $v0, ($t7) -/* C9018 80132918 3C028015 */ lui $v0, %hi(gHudElementCacheTablePalette) -/* C901C 8013291C 8C4212D0 */ lw $v0, %lo(gHudElementCacheTablePalette)($v0) -/* C9020 80132920 000318C0 */ sll $v1, $v1, 3 -/* C9024 80132924 00621821 */ addu $v1, $v1, $v0 -/* C9028 80132928 8C630004 */ lw $v1, 4($v1) -/* C902C 8013292C 25C20020 */ addiu $v0, $t6, 0x20 -/* C9030 80132930 ADE20000 */ sw $v0, ($t7) -/* C9034 80132934 3C02E800 */ lui $v0, 0xe800 -/* C9038 80132938 AC830004 */ sw $v1, 4($a0) -/* C903C 8013293C ADC20000 */ sw $v0, ($t6) -/* C9040 80132940 3C020700 */ lui $v0, 0x700 -/* C9044 80132944 ADC2000C */ sw $v0, 0xc($t6) -/* C9048 80132948 3C02F000 */ lui $v0, 0xf000 -/* C904C 8013294C ADC20018 */ sw $v0, 0x18($t6) -/* C9050 80132950 3C028015 */ lui $v0, %hi(D_80151328) -/* C9054 80132954 8C421328 */ lw $v0, %lo(D_80151328)($v0) -/* C9058 80132958 3C11E700 */ lui $s1, 0xe700 -/* C905C 8013295C ADC00004 */ sw $zero, 4($t6) -/* C9060 80132960 ADC50008 */ sw $a1, 8($t6) -/* C9064 80132964 ADD00010 */ sw $s0, 0x10($t6) -/* C9068 80132968 ADC00014 */ sw $zero, 0x14($t6) -/* C906C 8013296C ADC6001C */ sw $a2, 0x1c($t6) -/* C9070 80132970 ADD10020 */ sw $s1, 0x20($t6) -/* C9074 80132974 ADC00024 */ sw $zero, 0x24($t6) -/* C9078 80132978 94430000 */ lhu $v1, ($v0) -/* C907C 8013297C 25C20028 */ addiu $v0, $t6, 0x28 -/* C9080 80132980 10600060 */ beqz $v1, .L80132B04 -/* C9084 80132984 ADE20000 */ sw $v0, ($t7) -/* C9088 80132988 3C03FD48 */ lui $v1, 0xfd48 -/* C908C 8013298C 3463000F */ ori $v1, $v1, 0xf -/* C9090 80132990 3C07F548 */ lui $a3, 0xf548 -/* C9094 80132994 34E70400 */ ori $a3, $a3, 0x400 -/* C9098 80132998 3C05070A */ lui $a1, 0x70a -/* C909C 8013299C 34A50280 */ ori $a1, $a1, 0x280 -/* C90A0 801329A0 3C0B0703 */ lui $t3, 0x703 -/* C90A4 801329A4 356BE07C */ ori $t3, $t3, 0xe07c -/* C90A8 801329A8 3C04F540 */ lui $a0, 0xf540 -/* C90AC 801329AC 34840400 */ ori $a0, $a0, 0x400 -/* C90B0 801329B0 3C0C010A */ lui $t4, 0x10a -/* C90B4 801329B4 358C0280 */ ori $t4, $t4, 0x280 -/* C90B8 801329B8 3C0AF240 */ lui $t2, 0xf240 -/* C90BC 801329BC 354A0400 */ ori $t2, $t2, 0x400 -/* C90C0 801329C0 3C080147 */ lui $t0, 0x147 -/* C90C4 801329C4 3508C47C */ ori $t0, $t0, 0xc47c -/* C90C8 801329C8 3C09001A */ lui $t1, 0x1a -/* C90CC 801329CC 35290280 */ ori $t1, $t1, 0x280 -/* C90D0 801329D0 3C06F510 */ lui $a2, 0xf510 -/* C90D4 801329D4 34C60900 */ ori $a2, $a2, 0x900 -/* C90D8 801329D8 3C0D020F */ lui $t5, 0x20f -/* C90DC 801329DC 35ADC000 */ ori $t5, $t5, 0xc000 -/* C90E0 801329E0 25C20030 */ addiu $v0, $t6, 0x30 -/* C90E4 801329E4 ADE20000 */ sw $v0, ($t7) -/* C90E8 801329E8 ADC30028 */ sw $v1, 0x28($t6) -/* C90EC 801329EC 9263002C */ lbu $v1, 0x2c($s3) -/* C90F0 801329F0 25C20038 */ addiu $v0, $t6, 0x38 -/* C90F4 801329F4 ADE20000 */ sw $v0, ($t7) -/* C90F8 801329F8 25C20040 */ addiu $v0, $t6, 0x40 -/* C90FC 801329FC ADE20000 */ sw $v0, ($t7) -/* C9100 80132A00 25C20048 */ addiu $v0, $t6, 0x48 -/* C9104 80132A04 ADE20000 */ sw $v0, ($t7) -/* C9108 80132A08 25C20050 */ addiu $v0, $t6, 0x50 -/* C910C 80132A0C ADE20000 */ sw $v0, ($t7) -/* C9110 80132A10 25C20058 */ addiu $v0, $t6, 0x58 -/* C9114 80132A14 ADE20000 */ sw $v0, ($t7) -/* C9118 80132A18 25C20060 */ addiu $v0, $t6, 0x60 -/* C911C 80132A1C ADE20000 */ sw $v0, ($t7) -/* C9120 80132A20 25C20068 */ addiu $v0, $t6, 0x68 -/* C9124 80132A24 ADE20000 */ sw $v0, ($t7) -/* C9128 80132A28 25C20070 */ addiu $v0, $t6, 0x70 -/* C912C 80132A2C ADE20000 */ sw $v0, ($t7) -/* C9130 80132A30 3C028015 */ lui $v0, %hi(gHudElementCacheTableRaster) -/* C9134 80132A34 8C4212C8 */ lw $v0, %lo(gHudElementCacheTableRaster)($v0) -/* C9138 80132A38 000318C0 */ sll $v1, $v1, 3 -/* C913C 80132A3C 00621821 */ addu $v1, $v1, $v0 -/* C9140 80132A40 8C630004 */ lw $v1, 4($v1) -/* C9144 80132A44 25C20078 */ addiu $v0, $t6, 0x78 -/* C9148 80132A48 ADE20000 */ sw $v0, ($t7) -/* C914C 80132A4C 3C02F400 */ lui $v0, 0xf400 -/* C9150 80132A50 ADC20040 */ sw $v0, 0x40($t6) -/* C9154 80132A54 3C020200 */ lui $v0, 0x200 -/* C9158 80132A58 ADC2006C */ sw $v0, 0x6c($t6) -/* C915C 80132A5C 3C02F200 */ lui $v0, 0xf200 -/* C9160 80132A60 ADC70030 */ sw $a3, 0x30($t6) -/* C9164 80132A64 ADC50034 */ sw $a1, 0x34($t6) -/* C9168 80132A68 ADD00038 */ sw $s0, 0x38($t6) -/* C916C 80132A6C ADC0003C */ sw $zero, 0x3c($t6) -/* C9170 80132A70 ADCB0044 */ sw $t3, 0x44($t6) -/* C9174 80132A74 ADD10048 */ sw $s1, 0x48($t6) -/* C9178 80132A78 ADC0004C */ sw $zero, 0x4c($t6) -/* C917C 80132A7C ADC40050 */ sw $a0, 0x50($t6) -/* C9180 80132A80 ADCC0054 */ sw $t4, 0x54($t6) -/* C9184 80132A84 ADCA0058 */ sw $t2, 0x58($t6) -/* C9188 80132A88 ADC8005C */ sw $t0, 0x5c($t6) -/* C918C 80132A8C ADC40060 */ sw $a0, 0x60($t6) -/* C9190 80132A90 ADC90064 */ sw $t1, 0x64($t6) -/* C9194 80132A94 ADC60068 */ sw $a2, 0x68($t6) -/* C9198 80132A98 ADC20070 */ sw $v0, 0x70($t6) -/* C919C 80132A9C ADCD0074 */ sw $t5, 0x74($t6) -/* C91A0 80132AA0 ADC3002C */ sw $v1, 0x2c($t6) -/* C91A4 80132AA4 8E620000 */ lw $v0, ($s3) -/* C91A8 80132AA8 3C030808 */ lui $v1, 0x808 -/* C91AC 80132AAC 00431024 */ and $v0, $v0, $v1 -/* C91B0 80132AB0 1040000A */ beqz $v0, .L80132ADC -/* C91B4 80132AB4 27A40058 */ addiu $a0, $sp, 0x58 -/* C91B8 80132AB8 0000282D */ daddu $a1, $zero, $zero -/* C91BC 80132ABC 00A0302D */ daddu $a2, $a1, $zero -/* C91C0 80132AC0 24070020 */ addiu $a3, $zero, 0x20 -/* C91C4 80132AC4 00E0102D */ daddu $v0, $a3, $zero -/* C91C8 80132AC8 AFA20010 */ sw $v0, 0x10($sp) -/* C91CC 80132ACC 0C052479 */ jal func_801491E4 -/* C91D0 80132AD0 AFB40014 */ sw $s4, 0x14($sp) -/* C91D4 80132AD4 0804CAF4 */ j .L80132BD0 -/* C91D8 80132AD8 00000000 */ nop -.L80132ADC: -/* C91DC 80132ADC 0000282D */ daddu $a1, $zero, $zero -/* C91E0 80132AE0 00A0302D */ daddu $a2, $a1, $zero -/* C91E4 80132AE4 24070020 */ addiu $a3, $zero, 0x20 -/* C91E8 80132AE8 00E0102D */ daddu $v0, $a3, $zero -/* C91EC 80132AEC AFA20010 */ sw $v0, 0x10($sp) -/* C91F0 80132AF0 240200FF */ addiu $v0, $zero, 0xff -/* C91F4 80132AF4 0C052479 */ jal func_801491E4 -/* C91F8 80132AF8 AFA20014 */ sw $v0, 0x14($sp) -/* C91FC 80132AFC 0804CAF4 */ j .L80132BD0 -/* C9200 80132B00 00000000 */ nop -.L80132B04: -/* C9204 80132B04 3C03FD48 */ lui $v1, 0xfd48 -/* C9208 80132B08 3463000F */ ori $v1, $v1, 0xf -/* C920C 80132B0C 3C05F548 */ lui $a1, 0xf548 -/* C9210 80132B10 34A50400 */ ori $a1, $a1, 0x400 -/* C9214 80132B14 3C04070A */ lui $a0, 0x70a -/* C9218 80132B18 34840280 */ ori $a0, $a0, 0x280 -/* C921C 80132B1C 3C080703 */ lui $t0, 0x703 -/* C9220 80132B20 3508E07C */ ori $t0, $t0, 0xe07c -/* C9224 80132B24 3C0AF540 */ lui $t2, 0xf540 -/* C9228 80132B28 354A0400 */ ori $t2, $t2, 0x400 -/* C922C 80132B2C 3C09000A */ lui $t1, 0xa -/* C9230 80132B30 35290280 */ ori $t1, $t1, 0x280 -/* C9234 80132B34 3C07F240 */ lui $a3, 0xf240 -/* C9238 80132B38 34E70400 */ ori $a3, $a3, 0x400 -/* C923C 80132B3C 3C060047 */ lui $a2, 0x47 -/* C9240 80132B40 34C6C47C */ ori $a2, $a2, 0xc47c -/* C9244 80132B44 25C20030 */ addiu $v0, $t6, 0x30 -/* C9248 80132B48 ADE20000 */ sw $v0, ($t7) -/* C924C 80132B4C ADC30028 */ sw $v1, 0x28($t6) -/* C9250 80132B50 9263002C */ lbu $v1, 0x2c($s3) -/* C9254 80132B54 25C20038 */ addiu $v0, $t6, 0x38 -/* C9258 80132B58 ADE20000 */ sw $v0, ($t7) -/* C925C 80132B5C 25C20040 */ addiu $v0, $t6, 0x40 -/* C9260 80132B60 ADE20000 */ sw $v0, ($t7) -/* C9264 80132B64 25C20048 */ addiu $v0, $t6, 0x48 -/* C9268 80132B68 ADE20000 */ sw $v0, ($t7) -/* C926C 80132B6C 25C20050 */ addiu $v0, $t6, 0x50 -/* C9270 80132B70 ADE20000 */ sw $v0, ($t7) -/* C9274 80132B74 25C20058 */ addiu $v0, $t6, 0x58 -/* C9278 80132B78 ADE20000 */ sw $v0, ($t7) -/* C927C 80132B7C 3C028015 */ lui $v0, %hi(gHudElementCacheTableRaster) -/* C9280 80132B80 8C4212C8 */ lw $v0, %lo(gHudElementCacheTableRaster)($v0) -/* C9284 80132B84 000318C0 */ sll $v1, $v1, 3 -/* C9288 80132B88 00621821 */ addu $v1, $v1, $v0 -/* C928C 80132B8C 8C630004 */ lw $v1, 4($v1) -/* C9290 80132B90 25C20060 */ addiu $v0, $t6, 0x60 -/* C9294 80132B94 ADE20000 */ sw $v0, ($t7) -/* C9298 80132B98 3C02F400 */ lui $v0, 0xf400 -/* C929C 80132B9C ADC50030 */ sw $a1, 0x30($t6) -/* C92A0 80132BA0 ADC40034 */ sw $a0, 0x34($t6) -/* C92A4 80132BA4 ADD00038 */ sw $s0, 0x38($t6) -/* C92A8 80132BA8 ADC0003C */ sw $zero, 0x3c($t6) -/* C92AC 80132BAC ADC20040 */ sw $v0, 0x40($t6) -/* C92B0 80132BB0 ADC80044 */ sw $t0, 0x44($t6) -/* C92B4 80132BB4 ADD10048 */ sw $s1, 0x48($t6) -/* C92B8 80132BB8 ADC0004C */ sw $zero, 0x4c($t6) -/* C92BC 80132BBC ADCA0050 */ sw $t2, 0x50($t6) -/* C92C0 80132BC0 ADC90054 */ sw $t1, 0x54($t6) -/* C92C4 80132BC4 ADC70058 */ sw $a3, 0x58($t6) -/* C92C8 80132BC8 ADC6005C */ sw $a2, 0x5c($t6) -/* C92CC 80132BCC ADC3002C */ sw $v1, 0x2c($t6) -.L80132BD0: -/* C92D0 80132BD0 3C03800A */ lui $v1, %hi(gMasterGfxPos) -/* C92D4 80132BD4 2463A66C */ addiu $v1, $v1, %lo(gMasterGfxPos) -/* C92D8 80132BD8 8C620000 */ lw $v0, ($v1) -/* C92DC 80132BDC 0040202D */ daddu $a0, $v0, $zero -/* C92E0 80132BE0 24420008 */ addiu $v0, $v0, 8 -/* C92E4 80132BE4 AC620000 */ sw $v0, ($v1) -/* C92E8 80132BE8 3C02DE00 */ lui $v0, 0xde00 -/* C92EC 80132BEC AC820000 */ sw $v0, ($a0) -/* C92F0 80132BF0 3C028015 */ lui $v0, %hi(D_8014C6A0) -/* C92F4 80132BF4 2442C6A0 */ addiu $v0, $v0, %lo(D_8014C6A0) -/* C92F8 80132BF8 AC820004 */ sw $v0, 4($a0) -.L80132BFC: -/* C92FC 80132BFC 3C03D838 */ lui $v1, 0xd838 -/* C9300 80132C00 3C04800A */ lui $a0, %hi(gMasterGfxPos) -/* C9304 80132C04 2484A66C */ addiu $a0, $a0, %lo(gMasterGfxPos) -/* C9308 80132C08 8C820000 */ lw $v0, ($a0) -/* C930C 80132C0C 34630002 */ ori $v1, $v1, 2 -/* C9310 80132C10 0040282D */ daddu $a1, $v0, $zero -/* C9314 80132C14 24420008 */ addiu $v0, $v0, 8 -/* C9318 80132C18 AC820000 */ sw $v0, ($a0) -/* C931C 80132C1C ACA30000 */ sw $v1, ($a1) -/* C9320 80132C20 24030040 */ addiu $v1, $zero, 0x40 -/* C9324 80132C24 ACA30004 */ sw $v1, 4($a1) -/* C9328 80132C28 24430008 */ addiu $v1, $v0, 8 -/* C932C 80132C2C AC830000 */ sw $v1, ($a0) -/* C9330 80132C30 3C03E700 */ lui $v1, 0xe700 -/* C9334 80132C34 AC430000 */ sw $v1, ($v0) -/* C9338 80132C38 AC400004 */ sw $zero, 4($v0) -/* C933C 80132C3C 86630018 */ lh $v1, 0x18($s3) -/* C9340 80132C40 24020157 */ addiu $v0, $zero, 0x157 -/* C9344 80132C44 14620003 */ bne $v1, $v0, .L80132C54 -/* C9348 80132C48 00000000 */ nop -/* C934C 80132C4C 0C04C2C3 */ jal draw_coin_sparkles -/* C9350 80132C50 0260202D */ daddu $a0, $s3, $zero -.L80132C54: -/* C9354 80132C54 8FBF013C */ lw $ra, 0x13c($sp) -/* C9358 80132C58 8FB60138 */ lw $s6, 0x138($sp) -/* C935C 80132C5C 8FB50134 */ lw $s5, 0x134($sp) -/* C9360 80132C60 8FB40130 */ lw $s4, 0x130($sp) -/* C9364 80132C64 8FB3012C */ lw $s3, 0x12c($sp) -/* C9368 80132C68 8FB20128 */ lw $s2, 0x128($sp) -/* C936C 80132C6C 8FB10124 */ lw $s1, 0x124($sp) -/* C9370 80132C70 8FB00120 */ lw $s0, 0x120($sp) -/* C9374 80132C74 D7B40140 */ ldc1 $f20, 0x140($sp) -/* C9378 80132C78 03E00008 */ jr $ra -/* C937C 80132C7C 27BD0148 */ addiu $sp, $sp, 0x148 diff --git a/ver/us/asm/nonmatchings/C50A0/item_entity_update.s b/ver/us/asm/nonmatchings/C50A0/item_entity_update.s deleted file mode 100644 index 5ae94eb87d..0000000000 --- a/ver/us/asm/nonmatchings/C50A0/item_entity_update.s +++ /dev/null @@ -1,90 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel jtbl_80150BC0 -.word .L80131E38, .L80131E44, .L80131EC4, .L80131E98, .L80131EA4, 0 - -.section .text - -glabel item_entity_update -/* C84D4 80131DD4 27BDFFD8 */ addiu $sp, $sp, -0x28 -/* C84D8 80131DD8 AFB20018 */ sw $s2, 0x18($sp) -/* C84DC 80131DDC 0080902D */ daddu $s2, $a0, $zero -/* C84E0 80131DE0 AFBF0020 */ sw $ra, 0x20($sp) -/* C84E4 80131DE4 AFB3001C */ sw $s3, 0x1c($sp) -/* C84E8 80131DE8 AFB10014 */ sw $s1, 0x14($sp) -/* C84EC 80131DEC AFB00010 */ sw $s0, 0x10($sp) -/* C84F0 80131DF0 9242002E */ lbu $v0, 0x2e($s2) -/* C84F4 80131DF4 2442FFFF */ addiu $v0, $v0, -1 -/* C84F8 80131DF8 A242002E */ sb $v0, 0x2e($s2) -/* C84FC 80131DFC 304200FF */ andi $v0, $v0, 0xff -/* C8500 80131E00 14400033 */ bnez $v0, .L80131ED0 -/* C8504 80131E04 00000000 */ nop -/* C8508 80131E08 3C138015 */ lui $s3, %hi(jtbl_80150BC0) -/* C850C 80131E0C 26730BC0 */ addiu $s3, $s3, %lo(jtbl_80150BC0) -.L80131E10: -/* C8510 80131E10 8E510024 */ lw $s1, 0x24($s2) -/* C8514 80131E14 8E230000 */ lw $v1, ($s1) -/* C8518 80131E18 2C620005 */ sltiu $v0, $v1, 5 -/* C851C 80131E1C 1040FFFC */ beqz $v0, .L80131E10 -/* C8520 80131E20 26310004 */ addiu $s1, $s1, 4 -/* C8524 80131E24 00031080 */ sll $v0, $v1, 2 -/* C8528 80131E28 00531021 */ addu $v0, $v0, $s3 -/* C852C 80131E2C 8C420000 */ lw $v0, ($v0) -/* C8530 80131E30 00400008 */ jr $v0 -/* C8534 80131E34 00000000 */ nop -.L80131E38: -/* C8538 80131E38 2402003C */ addiu $v0, $zero, 0x3c -/* C853C 80131E3C 0804C7B4 */ j .L80131ED0 -/* C8540 80131E40 A242002E */ sb $v0, 0x2e($s2) -.L80131E44: -/* C8544 80131E44 92220003 */ lbu $v0, 3($s1) -/* C8548 80131E48 A242002E */ sb $v0, 0x2e($s2) -/* C854C 80131E4C 3C028007 */ lui $v0, %hi(gGameStatusPtr) -/* C8550 80131E50 8C42419C */ lw $v0, %lo(gGameStatusPtr)($v0) -/* C8554 80131E54 80420070 */ lb $v0, 0x70($v0) -/* C8558 80131E58 14400007 */ bnez $v0, .L80131E78 -/* C855C 80131E5C 2631000C */ addiu $s1, $s1, 0xc -/* C8560 80131E60 92220003 */ lbu $v0, 3($s1) -/* C8564 80131E64 26310004 */ addiu $s1, $s1, 4 -/* C8568 80131E68 A242002C */ sb $v0, 0x2c($s2) -/* C856C 80131E6C 92220003 */ lbu $v0, 3($s1) -/* C8570 80131E70 0804C7A3 */ j .L80131E8C -/* C8574 80131E74 26310004 */ addiu $s1, $s1, 4 -.L80131E78: -/* C8578 80131E78 86220000 */ lh $v0, ($s1) -/* C857C 80131E7C 26310004 */ addiu $s1, $s1, 4 -/* C8580 80131E80 A242002C */ sb $v0, 0x2c($s2) -/* C8584 80131E84 86220000 */ lh $v0, ($s1) -/* C8588 80131E88 26310004 */ addiu $s1, $s1, 4 -.L80131E8C: -/* C858C 80131E8C A242002D */ sb $v0, 0x2d($s2) -/* C8590 80131E90 0804C7B4 */ j .L80131ED0 -/* C8594 80131E94 AE510024 */ sw $s1, 0x24($s2) -.L80131E98: -/* C8598 80131E98 AE510028 */ sw $s1, 0x28($s2) -/* C859C 80131E9C 0804C784 */ j .L80131E10 -/* C85A0 80131EA0 AE510024 */ sw $s1, 0x24($s2) -.L80131EA4: -/* C85A4 80131EA4 8E240000 */ lw $a0, ($s1) -/* C85A8 80131EA8 26310004 */ addiu $s1, $s1, 4 -/* C85AC 80131EAC 8E300000 */ lw $s0, ($s1) -/* C85B0 80131EB0 0C00A67F */ jal rand_int -/* C85B4 80131EB4 26310004 */ addiu $s1, $s1, 4 -/* C85B8 80131EB8 0050102A */ slt $v0, $v0, $s0 -/* C85BC 80131EBC 5040FFD4 */ beql $v0, $zero, .L80131E10 -/* C85C0 80131EC0 AE510024 */ sw $s1, 0x24($s2) -.L80131EC4: -/* C85C4 80131EC4 8E420028 */ lw $v0, 0x28($s2) -/* C85C8 80131EC8 0804C784 */ j .L80131E10 -/* C85CC 80131ECC AE420024 */ sw $v0, 0x24($s2) -.L80131ED0: -/* C85D0 80131ED0 8FBF0020 */ lw $ra, 0x20($sp) -/* C85D4 80131ED4 8FB3001C */ lw $s3, 0x1c($sp) -/* C85D8 80131ED8 8FB20018 */ lw $s2, 0x18($sp) -/* C85DC 80131EDC 8FB10014 */ lw $s1, 0x14($sp) -/* C85E0 80131EE0 8FB00010 */ lw $s0, 0x10($sp) -/* C85E4 80131EE4 03E00008 */ jr $ra -/* C85E8 80131EE8 27BD0028 */ addiu $sp, $sp, 0x28 diff --git a/ver/us/asm/nonmatchings/C50A0/update_item_entity_temp.s b/ver/us/asm/nonmatchings/C50A0/update_item_entity_temp.s deleted file mode 100644 index 5e97fe89db..0000000000 --- a/ver/us/asm/nonmatchings/C50A0/update_item_entity_temp.s +++ /dev/null @@ -1,894 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel jtbl_80150E20 -.word .L801357A8_CBEA8, .L80135B24_CC224, .L80135E48_CC548, .L80135E78_CC578, .L80135F08_CC608, .L80135F78_CC678, .L8013637C_CCA7C, .L8013637C_CCA7C, .L80135F94_CC694, .L80135FE8_CC6E8, .L8013610C_CC80C, .L8013614C_CC84C, .L8013629C_CC99C, .L801362D0_CC9D0, .L80136310_CCA10, 0 - -.section .text - -glabel update_item_entity_temp -/* CBDDC 801356DC 27BDFFC0 */ addiu $sp, $sp, -0x40 -/* CBDE0 801356E0 AFB10024 */ sw $s1, 0x24($sp) -/* CBDE4 801356E4 0080882D */ daddu $s1, $a0, $zero -/* CBDE8 801356E8 AFB40030 */ sw $s4, 0x30($sp) -/* CBDEC 801356EC 3C148011 */ lui $s4, %hi(gPlayerData) -/* CBDF0 801356F0 2694F290 */ addiu $s4, $s4, %lo(gPlayerData) -/* CBDF4 801356F4 AFB3002C */ sw $s3, 0x2c($sp) -/* CBDF8 801356F8 3C138011 */ lui $s3, %hi(gPlayerStatus) -/* CBDFC 801356FC 2673EFC8 */ addiu $s3, $s3, %lo(gPlayerStatus) -/* CBE00 80135700 AFBF0038 */ sw $ra, 0x38($sp) -/* CBE04 80135704 AFB50034 */ sw $s5, 0x34($sp) -/* CBE08 80135708 AFB20028 */ sw $s2, 0x28($sp) -/* CBE0C 8013570C AFB00020 */ sw $s0, 0x20($sp) -/* CBE10 80135710 8222001A */ lb $v0, 0x1a($s1) -/* CBE14 80135714 3C108015 */ lui $s0, %hi(D_801565B0) -/* CBE18 80135718 261065B0 */ addiu $s0, $s0, %lo(D_801565B0) -/* CBE1C 8013571C 14400016 */ bnez $v0, .L80135778 -/* CBE20 80135720 24120001 */ addiu $s2, $zero, 1 -/* CBE24 80135724 8E220000 */ lw $v0, ($s1) -/* CBE28 80135728 3C030200 */ lui $v1, 0x200 -/* CBE2C 8013572C 3C018015 */ lui $at, %hi(isPickingUpItem) -/* CBE30 80135730 A43265A4 */ sh $s2, %lo(isPickingUpItem)($at) -/* CBE34 80135734 00431024 */ and $v0, $v0, $v1 -/* CBE38 80135738 1440000C */ bnez $v0, .L8013576C -/* CBE3C 8013573C 00000000 */ nop -/* CBE40 80135740 0C03805E */ jal disable_player_input -/* CBE44 80135744 00000000 */ nop -/* CBE48 80135748 0C03BD8A */ jal partner_disable_input -/* CBE4C 8013574C 00000000 */ nop -/* CBE50 80135750 3C03800A */ lui $v1, %hi(gOverrideFlags) -/* CBE54 80135754 2463A650 */ addiu $v1, $v1, %lo(gOverrideFlags) -/* CBE58 80135758 8C620000 */ lw $v0, ($v1) -/* CBE5C 8013575C 24040002 */ addiu $a0, $zero, 2 -/* CBE60 80135760 34420040 */ ori $v0, $v0, 0x40 -/* CBE64 80135764 0C009C22 */ jal set_time_freeze_mode -/* CBE68 80135768 AC620000 */ sw $v0, ($v1) -.L8013576C: -/* CBE6C 8013576C 0C04C3DC */ jal item_entity_disable_shadow -/* CBE70 80135770 0220202D */ daddu $a0, $s1, $zero -/* CBE74 80135774 A232001A */ sb $s2, 0x1a($s1) -.L80135778: -/* CBE78 80135778 9222001A */ lbu $v0, 0x1a($s1) -/* CBE7C 8013577C 2442FFFF */ addiu $v0, $v0, -1 -/* CBE80 80135780 00021600 */ sll $v0, $v0, 0x18 -/* CBE84 80135784 00021E03 */ sra $v1, $v0, 0x18 -/* CBE88 80135788 2C62000F */ sltiu $v0, $v1, 0xf -/* CBE8C 8013578C 104002FB */ beqz $v0, .L8013637C_CCA7C -/* CBE90 80135790 00031080 */ sll $v0, $v1, 2 -/* CBE94 80135794 3C018015 */ lui $at, %hi(jtbl_80150E20) -/* CBE98 80135798 00220821 */ addu $at, $at, $v0 -/* CBE9C 8013579C 8C220E20 */ lw $v0, %lo(jtbl_80150E20)($at) -/* CBEA0 801357A0 00400008 */ jr $v0 -/* CBEA4 801357A4 00000000 */ nop -.L801357A8_CBEA8: -/* CBEA8 801357A8 8E220000 */ lw $v0, ($s1) -/* CBEAC 801357AC 3C030200 */ lui $v1, 0x200 -/* CBEB0 801357B0 00431024 */ and $v0, $v0, $v1 -/* CBEB4 801357B4 1440001D */ bnez $v0, .L8013582C -/* CBEB8 801357B8 3C031000 */ lui $v1, 0x1000 -/* CBEBC 801357BC 8E620004 */ lw $v0, 4($s3) -/* CBEC0 801357C0 00431024 */ and $v0, $v0, $v1 -/* CBEC4 801357C4 14400019 */ bnez $v0, .L8013582C -/* CBEC8 801357C8 826300B4 */ lb $v1, 0xb4($s3) -/* CBECC 801357CC 866200C0 */ lh $v0, 0xc0($s3) -/* CBED0 801357D0 14400005 */ bnez $v0, .L801357E8 -/* CBED4 801357D4 24020003 */ addiu $v0, $zero, 3 -/* CBED8 801357D8 10620003 */ beq $v1, $v0, .L801357E8 -/* CBEDC 801357DC 24020008 */ addiu $v0, $zero, 8 -/* CBEE0 801357E0 14620007 */ bne $v1, $v0, .L80135800 -/* CBEE4 801357E4 24020006 */ addiu $v0, $zero, 6 -.L801357E8: -/* CBEE8 801357E8 82620014 */ lb $v0, 0x14($s3) -/* CBEEC 801357EC 10400004 */ beqz $v0, .L80135800 -/* CBEF0 801357F0 24020006 */ addiu $v0, $zero, 6 -/* CBEF4 801357F4 82620015 */ lb $v0, 0x15($s3) -/* CBEF8 801357F8 1440000C */ bnez $v0, .L8013582C -/* CBEFC 801357FC 24020006 */ addiu $v0, $zero, 6 -.L80135800: -/* CBF00 80135800 1062000A */ beq $v1, $v0, .L8013582C -/* CBF04 80135804 24020021 */ addiu $v0, $zero, 0x21 -/* CBF08 80135808 10620008 */ beq $v1, $v0, .L8013582C -/* CBF0C 8013580C 00000000 */ nop -/* CBF10 80135810 10600006 */ beqz $v1, .L8013582C -/* CBF14 80135814 2402001D */ addiu $v0, $zero, 0x1d -/* CBF18 80135818 146202D8 */ bne $v1, $v0, .L8013637C_CCA7C -/* CBF1C 8013581C 24020001 */ addiu $v0, $zero, 1 -/* CBF20 80135820 826300B6 */ lb $v1, 0xb6($s3) -/* CBF24 80135824 146202D5 */ bne $v1, $v0, .L8013637C_CCA7C -/* CBF28 80135828 00000000 */ nop -.L8013582C: -/* CBF2C 8013582C 96220006 */ lhu $v0, 6($s1) -/* CBF30 80135830 30420001 */ andi $v0, $v0, 1 -/* CBF34 80135834 1440001C */ bnez $v0, .L801358A8 -/* CBF38 80135838 00000000 */ nop -/* CBF3C 8013583C 86240018 */ lh $a0, 0x18($s1) -/* CBF40 80135840 00041140 */ sll $v0, $a0, 5 -/* CBF44 80135844 3C038008 */ lui $v1, %hi(gItemTable+0x18) -/* CBF48 80135848 00621821 */ addu $v1, $v1, $v0 -/* CBF4C 8013584C 946378F8 */ lhu $v1, %lo(gItemTable+0x18)($v1) -/* CBF50 80135850 30620040 */ andi $v0, $v1, 0x40 -/* CBF54 80135854 10400003 */ beqz $v0, .L80135864 -/* CBF58 80135858 30620008 */ andi $v0, $v1, 8 -/* CBF5C 8013585C 0804D628 */ j .L801358A0 -/* CBF60 80135860 240400D3 */ addiu $a0, $zero, 0xd3 -.L80135864: -/* CBF64 80135864 10400003 */ beqz $v0, .L80135874 -/* CBF68 80135868 24020157 */ addiu $v0, $zero, 0x157 -/* CBF6C 8013586C 0804D628 */ j .L801358A0 -/* CBF70 80135870 240400D2 */ addiu $a0, $zero, 0xd2 -.L80135874: -/* CBF74 80135874 1482000A */ bne $a0, $v0, .L801358A0 -/* CBF78 80135878 240400D1 */ addiu $a0, $zero, 0xd1 -/* CBF7C 8013587C C6200010 */ lwc1 $f0, 0x10($s1) -/* CBF80 80135880 24040211 */ addiu $a0, $zero, 0x211 -/* CBF84 80135884 E7A00010 */ swc1 $f0, 0x10($sp) -/* CBF88 80135888 8E260008 */ lw $a2, 8($s1) -/* CBF8C 8013588C 8E27000C */ lw $a3, 0xc($s1) -/* CBF90 80135890 0C052757 */ jal sfx_play_sound_at_position -/* CBF94 80135894 0000282D */ daddu $a1, $zero, $zero -/* CBF98 80135898 0804D62A */ j .L801358A8 -/* CBF9C 8013589C 00000000 */ nop -.L801358A0: -/* CBFA0 801358A0 0C05272D */ jal sfx_play_sound -/* CBFA4 801358A4 00000000 */ nop -.L801358A8: -/* CBFA8 801358A8 86220018 */ lh $v0, 0x18($s1) -/* CBFAC 801358AC 00021140 */ sll $v0, $v0, 5 -/* CBFB0 801358B0 3C018008 */ lui $at, %hi(gItemTable+0x4) -/* CBFB4 801358B4 00220821 */ addu $at, $at, $v0 -/* CBFB8 801358B8 842278E4 */ lh $v0, %lo(gItemTable+0x4)($at) -/* CBFBC 801358BC 000210C0 */ sll $v0, $v0, 3 -/* CBFC0 801358C0 3C048009 */ lui $a0, %hi(gItemHudScripts) -/* CBFC4 801358C4 00822021 */ addu $a0, $a0, $v0 -/* CBFC8 801358C8 8C84A680 */ lw $a0, %lo(gItemHudScripts)($a0) -/* CBFCC 801358CC 0C050529 */ jal hud_element_create -/* CBFD0 801358D0 00000000 */ nop -/* CBFD4 801358D4 0040202D */ daddu $a0, $v0, $zero -/* CBFD8 801358D8 24050080 */ addiu $a1, $zero, 0x80 -/* CBFDC 801358DC 3C108015 */ lui $s0, %hi(D_801568E0) -/* CBFE0 801358E0 261068E0 */ addiu $s0, $s0, %lo(D_801568E0) -/* CBFE4 801358E4 0C051280 */ jal hud_element_set_flags -/* CBFE8 801358E8 AE040000 */ sw $a0, ($s0) -/* CBFEC 801358EC 2405FF9C */ addiu $a1, $zero, -0x64 -/* CBFF0 801358F0 8E040000 */ lw $a0, ($s0) -/* CBFF4 801358F4 0C051261 */ jal hud_element_set_render_pos -/* CBFF8 801358F8 00A0302D */ daddu $a2, $a1, $zero -/* CBFFC 801358FC 24020002 */ addiu $v0, $zero, 2 -/* CC000 80135900 3C108008 */ lui $s0, %hi(gItemTable) -/* CC004 80135904 261078E0 */ addiu $s0, $s0, %lo(gItemTable) -/* CC008 80135908 A222001A */ sb $v0, 0x1a($s1) -/* CC00C 8013590C 8E220000 */ lw $v0, ($s1) -/* CC010 80135910 3C030200 */ lui $v1, 0x200 -/* CC014 80135914 00431024 */ and $v0, $v0, $v1 -/* CC018 80135918 14400066 */ bnez $v0, .L80135AB4 -/* CC01C 8013591C 00000000 */ nop -/* CC020 80135920 86220018 */ lh $v0, 0x18($s1) -/* CC024 80135924 00021140 */ sll $v0, $v0, 5 -/* CC028 80135928 00501021 */ addu $v0, $v0, $s0 -/* CC02C 8013592C 94420018 */ lhu $v0, 0x18($v0) -/* CC030 80135930 30420004 */ andi $v0, $v0, 4 -/* CC034 80135934 1040000F */ beqz $v0, .L80135974 -/* CC038 80135938 0000202D */ daddu $a0, $zero, $zero -/* CC03C 8013593C 0280182D */ daddu $v1, $s4, $zero -.L80135940: -/* CC040 80135940 846201B4 */ lh $v0, 0x1b4($v1) -/* CC044 80135944 10400006 */ beqz $v0, .L80135960 -/* CC048 80135948 2882000A */ slti $v0, $a0, 0xa -/* CC04C 8013594C 24840001 */ addiu $a0, $a0, 1 -/* CC050 80135950 2882000A */ slti $v0, $a0, 0xa -/* CC054 80135954 1440FFFA */ bnez $v0, .L80135940 -/* CC058 80135958 24630002 */ addiu $v1, $v1, 2 -/* CC05C 8013595C 2882000A */ slti $v0, $a0, 0xa -.L80135960: -/* CC060 80135960 1040002D */ beqz $v0, .L80135A18 -/* CC064 80135964 00041040 */ sll $v0, $a0, 1 -/* CC068 80135968 96230018 */ lhu $v1, 0x18($s1) -/* CC06C 8013596C 02821021 */ addu $v0, $s4, $v0 -/* CC070 80135970 A44301B4 */ sh $v1, 0x1b4($v0) -.L80135974: -/* CC074 80135974 86220018 */ lh $v0, 0x18($s1) -/* CC078 80135978 00021140 */ sll $v0, $v0, 5 -/* CC07C 8013597C 3C018008 */ lui $at, %hi(gItemTable+0x18) -/* CC080 80135980 00220821 */ addu $at, $at, $v0 -/* CC084 80135984 942278F8 */ lhu $v0, %lo(gItemTable+0x18)($at) -/* CC088 80135988 30420008 */ andi $v0, $v0, 8 -/* CC08C 8013598C 1040000F */ beqz $v0, .L801359CC -/* CC090 80135990 0000202D */ daddu $a0, $zero, $zero -/* CC094 80135994 0280182D */ daddu $v1, $s4, $zero -.L80135998: -/* CC098 80135998 84620074 */ lh $v0, 0x74($v1) -/* CC09C 8013599C 10400006 */ beqz $v0, .L801359B8 -/* CC0A0 801359A0 28820020 */ slti $v0, $a0, 0x20 -/* CC0A4 801359A4 24840001 */ addiu $a0, $a0, 1 -/* CC0A8 801359A8 28820020 */ slti $v0, $a0, 0x20 -/* CC0AC 801359AC 1440FFFA */ bnez $v0, .L80135998 -/* CC0B0 801359B0 24630002 */ addiu $v1, $v1, 2 -/* CC0B4 801359B4 28820020 */ slti $v0, $a0, 0x20 -.L801359B8: -/* CC0B8 801359B8 10400017 */ beqz $v0, .L80135A18 -/* CC0BC 801359BC 00041040 */ sll $v0, $a0, 1 -/* CC0C0 801359C0 96230018 */ lhu $v1, 0x18($s1) -/* CC0C4 801359C4 02821021 */ addu $v0, $s4, $v0 -/* CC0C8 801359C8 A4430074 */ sh $v1, 0x74($v0) -.L801359CC: -/* CC0CC 801359CC 86220018 */ lh $v0, 0x18($s1) -/* CC0D0 801359D0 00021140 */ sll $v0, $v0, 5 -/* CC0D4 801359D4 3C018008 */ lui $at, %hi(gItemTable+0x18) -/* CC0D8 801359D8 00220821 */ addu $at, $at, $v0 -/* CC0DC 801359DC 942278F8 */ lhu $v0, %lo(gItemTable+0x18)($at) -/* CC0E0 801359E0 30420040 */ andi $v0, $v0, 0x40 -/* CC0E4 801359E4 10400012 */ beqz $v0, .L80135A30 -/* CC0E8 801359E8 0000202D */ daddu $a0, $zero, $zero -/* CC0EC 801359EC 0280182D */ daddu $v1, $s4, $zero -.L801359F0: -/* CC0F0 801359F0 846200B4 */ lh $v0, 0xb4($v1) -/* CC0F4 801359F4 10400006 */ beqz $v0, .L80135A10 -/* CC0F8 801359F8 28820080 */ slti $v0, $a0, 0x80 -/* CC0FC 801359FC 24840001 */ addiu $a0, $a0, 1 -/* CC100 80135A00 28820080 */ slti $v0, $a0, 0x80 -/* CC104 80135A04 1440FFFA */ bnez $v0, .L801359F0 -/* CC108 80135A08 24630002 */ addiu $v1, $v1, 2 -/* CC10C 80135A0C 28820080 */ slti $v0, $a0, 0x80 -.L80135A10: -/* CC110 80135A10 14400004 */ bnez $v0, .L80135A24 -/* CC114 80135A14 00041040 */ sll $v0, $a0, 1 -.L80135A18: -/* CC118 80135A18 2402000A */ addiu $v0, $zero, 0xa -/* CC11C 80135A1C 0804D6AD */ j .L80135AB4 -/* CC120 80135A20 A222001A */ sb $v0, 0x1a($s1) -.L80135A24: -/* CC124 80135A24 96230018 */ lhu $v1, 0x18($s1) -/* CC128 80135A28 02821021 */ addu $v0, $s4, $v0 -/* CC12C 80135A2C A44300B4 */ sh $v1, 0xb4($v0) -.L80135A30: -/* CC130 80135A30 86230018 */ lh $v1, 0x18($s1) -/* CC134 80135A34 2402015C */ addiu $v0, $zero, 0x15c -/* CC138 80135A38 1462000B */ bne $v1, $v0, .L80135A68 -/* CC13C 80135A3C 24020007 */ addiu $v0, $zero, 7 -/* CC140 80135A40 9282000F */ lbu $v0, 0xf($s4) -/* CC144 80135A44 24420001 */ addiu $v0, $v0, 1 -/* CC148 80135A48 A282000F */ sb $v0, 0xf($s4) -/* CC14C 80135A4C 304200FF */ andi $v0, $v0, 0xff -/* CC150 80135A50 2C4200DF */ sltiu $v0, $v0, 0xdf -/* CC154 80135A54 14400002 */ bnez $v0, .L80135A60 -/* CC158 80135A58 240200DE */ addiu $v0, $zero, 0xde -/* CC15C 80135A5C A282000F */ sb $v0, 0xf($s4) -.L80135A60: -/* CC160 80135A60 86230018 */ lh $v1, 0x18($s1) -/* CC164 80135A64 24020007 */ addiu $v0, $zero, 7 -.L80135A68: -/* CC168 80135A68 14620002 */ bne $v1, $v0, .L80135A74 -/* CC16C 80135A6C 24020001 */ addiu $v0, $zero, 1 -/* CC170 80135A70 A282000A */ sb $v0, 0xa($s4) -.L80135A74: -/* CC174 80135A74 96220018 */ lhu $v0, 0x18($s1) -/* CC178 80135A78 2442FFFC */ addiu $v0, $v0, -4 -/* CC17C 80135A7C 2C420003 */ sltiu $v0, $v0, 3 -/* CC180 80135A80 10400004 */ beqz $v0, .L80135A94 -/* CC184 80135A84 00000000 */ nop -/* CC188 80135A88 92220019 */ lbu $v0, 0x19($s1) -/* CC18C 80135A8C 2442FFFC */ addiu $v0, $v0, -4 -/* CC190 80135A90 A2820001 */ sb $v0, 1($s4) -.L80135A94: -/* CC194 80135A94 96220018 */ lhu $v0, 0x18($s1) -/* CC198 80135A98 2442FFFF */ addiu $v0, $v0, -1 -/* CC19C 80135A9C 2C420003 */ sltiu $v0, $v0, 3 -/* CC1A0 80135AA0 10400004 */ beqz $v0, .L80135AB4 -/* CC1A4 80135AA4 00000000 */ nop -/* CC1A8 80135AA8 92220019 */ lbu $v0, 0x19($s1) -/* CC1AC 80135AAC 2442FFFF */ addiu $v0, $v0, -1 -/* CC1B0 80135AB0 A2820000 */ sb $v0, ($s4) -.L80135AB4: -/* CC1B4 80135AB4 8E220000 */ lw $v0, ($s1) -/* CC1B8 80135AB8 04410003 */ bgez $v0, .L80135AC8 -/* CC1BC 80135ABC 00000000 */ nop -/* CC1C0 80135AC0 0C051514 */ jal set_global_flag -/* CC1C4 80135AC4 86240004 */ lh $a0, 4($s1) -.L80135AC8: -/* CC1C8 80135AC8 8222001A */ lb $v0, 0x1a($s1) -/* CC1CC 80135ACC 2412000A */ addiu $s2, $zero, 0xa -/* CC1D0 80135AD0 1452000E */ bne $v0, $s2, .L80135B0C -/* CC1D4 80135AD4 00000000 */ nop -/* CC1D8 80135AD8 0C04D8E8 */ jal func_801363A0 -/* CC1DC 80135ADC 0220202D */ daddu $a0, $s1, $zero -/* CC1E0 80135AE0 2404000C */ addiu $a0, $zero, 0xc -/* CC1E4 80135AE4 3C108014 */ lui $s0, %hi(basic_window_update) -/* CC1E8 80135AE8 26107474 */ addiu $s0, $s0, %lo(basic_window_update) -/* CC1EC 80135AEC 0C051F9F */ jal set_window_update -/* CC1F0 80135AF0 0200282D */ daddu $a1, $s0, $zero -/* CC1F4 80135AF4 24040011 */ addiu $a0, $zero, 0x11 -/* CC1F8 80135AF8 0C051F9F */ jal set_window_update -/* CC1FC 80135AFC 0200282D */ daddu $a1, $s0, $zero -/* CC200 80135B00 24040013 */ addiu $a0, $zero, 0x13 -/* CC204 80135B04 0C051F9F */ jal set_window_update -/* CC208 80135B08 0200282D */ daddu $a1, $s0, $zero -.L80135B0C: -/* CC20C 80135B0C 0C03A6D5 */ jal increment_status_menu_disabled -/* CC210 80135B10 00000000 */ nop -/* CC214 80135B14 3C018015 */ lui $at, %hi(D_801568E4) -/* CC218 80135B18 AC3268E4 */ sw $s2, %lo(D_801568E4)($at) -/* CC21C 80135B1C 0804D8DF */ j .L8013637C_CCA7C -/* CC220 80135B20 00000000 */ nop -.L80135B24_CC224: -/* CC224 80135B24 3C038015 */ lui $v1, %hi(D_801568E4) -/* CC228 80135B28 8C6368E4 */ lw $v1, %lo(D_801568E4)($v1) -/* CC22C 80135B2C 24020009 */ addiu $v0, $zero, 9 -/* CC230 80135B30 1462003C */ bne $v1, $v0, .L80135C24 -/* CC234 80135B34 00000000 */ nop -/* CC238 80135B38 86240018 */ lh $a0, 0x18($s1) -/* CC23C 80135B3C 00041140 */ sll $v0, $a0, 5 -/* CC240 80135B40 3C038008 */ lui $v1, %hi(gItemTable+0x18) -/* CC244 80135B44 00621821 */ addu $v1, $v1, $v0 -/* CC248 80135B48 946378F8 */ lhu $v1, %lo(gItemTable+0x18)($v1) -/* CC24C 80135B4C 30620040 */ andi $v0, $v1, 0x40 -/* CC250 80135B50 1440000F */ bnez $v0, .L80135B90 -/* CC254 80135B54 30620008 */ andi $v0, $v1, 8 -/* CC258 80135B58 1440000D */ bnez $v0, .L80135B90 -/* CC25C 80135B5C 2402015C */ addiu $v0, $zero, 0x15c -/* CC260 80135B60 1082000B */ beq $a0, $v0, .L80135B90 -/* CC264 80135B64 30620020 */ andi $v0, $v1, 0x20 -/* CC268 80135B68 14400009 */ bnez $v0, .L80135B90 -/* CC26C 80135B6C 3C030400 */ lui $v1, 0x400 -/* CC270 80135B70 8E220000 */ lw $v0, ($s1) -/* CC274 80135B74 00431024 */ and $v0, $v0, $v1 -/* CC278 80135B78 14400005 */ bnez $v0, .L80135B90 -/* CC27C 80135B7C 00000000 */ nop -/* CC280 80135B80 96220006 */ lhu $v0, 6($s1) -/* CC284 80135B84 30420002 */ andi $v0, $v0, 2 -/* CC288 80135B88 1040000F */ beqz $v0, .L80135BC8 -/* CC28C 80135B8C 00000000 */ nop -.L80135B90: -/* CC290 80135B90 C6600028 */ lwc1 $f0, 0x28($s3) -/* CC294 80135B94 E6200008 */ swc1 $f0, 8($s1) -/* CC298 80135B98 866200B0 */ lh $v0, 0xb0($s3) -/* CC29C 80135B9C C660002C */ lwc1 $f0, 0x2c($s3) -/* CC2A0 80135BA0 44821000 */ mtc1 $v0, $f2 -/* CC2A4 80135BA4 00000000 */ nop -/* CC2A8 80135BA8 468010A0 */ cvt.s.w $f2, $f2 -/* CC2AC 80135BAC 46020000 */ add.s $f0, $f0, $f2 -/* CC2B0 80135BB0 3C040006 */ lui $a0, 6 -/* CC2B4 80135BB4 E620000C */ swc1 $f0, 0xc($s1) -/* CC2B8 80135BB8 C6600030 */ lwc1 $f0, 0x30($s3) -/* CC2BC 80135BBC 3484000C */ ori $a0, $a0, 0xc -/* CC2C0 80135BC0 0C037FDE */ jal suggest_player_anim_setUnkFlag -/* CC2C4 80135BC4 E6200010 */ swc1 $f0, 0x10($s1) -.L80135BC8: -/* CC2C8 80135BC8 86220018 */ lh $v0, 0x18($s1) -/* CC2CC 80135BCC 00021140 */ sll $v0, $v0, 5 -/* CC2D0 80135BD0 3C018008 */ lui $at, %hi(gItemTable+0x18) -/* CC2D4 80135BD4 00220821 */ addu $at, $at, $v0 -/* CC2D8 80135BD8 942278F8 */ lhu $v0, %lo(gItemTable+0x18)($at) -/* CC2DC 80135BDC 30420020 */ andi $v0, $v0, 0x20 -/* CC2E0 80135BE0 10400010 */ beqz $v0, .L80135C24 -/* CC2E4 80135BE4 00000000 */ nop -/* CC2E8 80135BE8 C624000C */ lwc1 $f4, 0xc($s1) -/* CC2EC 80135BEC 3C014100 */ lui $at, 0x4100 -/* CC2F0 80135BF0 44810000 */ mtc1 $at, $f0 -/* CC2F4 80135BF4 3C013F80 */ lui $at, 0x3f80 -/* CC2F8 80135BF8 44811000 */ mtc1 $at, $f2 -/* CC2FC 80135BFC 3C028015 */ lui $v0, %hi(D_801568F0) -/* CC300 80135C00 244268F0 */ addiu $v0, $v0, %lo(D_801568F0) -/* CC304 80135C04 AFA20014 */ sw $v0, 0x14($sp) -/* CC308 80135C08 46002100 */ add.s $f4, $f4, $f0 -/* CC30C 80135C0C E7A20010 */ swc1 $f2, 0x10($sp) -/* CC310 80135C10 8E250008 */ lw $a1, 8($s1) -/* CC314 80135C14 8E270010 */ lw $a3, 0x10($s1) -/* CC318 80135C18 44062000 */ mfc1 $a2, $f4 -/* CC31C 80135C1C 0C01C0AC */ jal fx_got_item_outline -/* CC320 80135C20 24040001 */ addiu $a0, $zero, 1 -.L80135C24: -/* CC324 80135C24 3C028015 */ lui $v0, %hi(D_801568E4) -/* CC328 80135C28 8C4268E4 */ lw $v0, %lo(D_801568E4)($v0) -/* CC32C 80135C2C 28420009 */ slti $v0, $v0, 9 -/* CC330 80135C30 1040001D */ beqz $v0, .L80135CA8 -/* CC334 80135C34 00000000 */ nop -/* CC338 80135C38 86240018 */ lh $a0, 0x18($s1) -/* CC33C 80135C3C 00041140 */ sll $v0, $a0, 5 -/* CC340 80135C40 3C038008 */ lui $v1, %hi(gItemTable+0x18) -/* CC344 80135C44 00621821 */ addu $v1, $v1, $v0 -/* CC348 80135C48 946378F8 */ lhu $v1, %lo(gItemTable+0x18)($v1) -/* CC34C 80135C4C 30620040 */ andi $v0, $v1, 0x40 -/* CC350 80135C50 54400013 */ bnel $v0, $zero, .L80135CA0 -/* CC354 80135C54 3C040006 */ lui $a0, 6 -/* CC358 80135C58 30620008 */ andi $v0, $v1, 8 -/* CC35C 80135C5C 54400010 */ bnel $v0, $zero, .L80135CA0 -/* CC360 80135C60 3C040006 */ lui $a0, 6 -/* CC364 80135C64 2402015C */ addiu $v0, $zero, 0x15c -/* CC368 80135C68 1082000C */ beq $a0, $v0, .L80135C9C -/* CC36C 80135C6C 30620020 */ andi $v0, $v1, 0x20 -/* CC370 80135C70 5440000B */ bnel $v0, $zero, .L80135CA0 -/* CC374 80135C74 3C040006 */ lui $a0, 6 -/* CC378 80135C78 8E220000 */ lw $v0, ($s1) -/* CC37C 80135C7C 3C030400 */ lui $v1, 0x400 -/* CC380 80135C80 00431024 */ and $v0, $v0, $v1 -/* CC384 80135C84 54400006 */ bnel $v0, $zero, .L80135CA0 -/* CC388 80135C88 3C040006 */ lui $a0, 6 -/* CC38C 80135C8C 96220006 */ lhu $v0, 6($s1) -/* CC390 80135C90 30420002 */ andi $v0, $v0, 2 -/* CC394 80135C94 10400004 */ beqz $v0, .L80135CA8 -/* CC398 80135C98 00000000 */ nop -.L80135C9C: -/* CC39C 80135C9C 3C040006 */ lui $a0, 6 -.L80135CA0: -/* CC3A0 80135CA0 0C037FDE */ jal suggest_player_anim_setUnkFlag -/* CC3A4 80135CA4 3484000C */ ori $a0, $a0, 0xc -.L80135CA8: -/* CC3A8 80135CA8 3C038015 */ lui $v1, %hi(D_801568E4) -/* CC3AC 80135CAC 8C6368E4 */ lw $v1, %lo(D_801568E4)($v1) -/* CC3B0 80135CB0 24020007 */ addiu $v0, $zero, 7 -/* CC3B4 80135CB4 1462001E */ bne $v1, $v0, .L80135D30 -/* CC3B8 80135CB8 24020006 */ addiu $v0, $zero, 6 -/* CC3BC 80135CBC 86240018 */ lh $a0, 0x18($s1) -/* CC3C0 80135CC0 00041140 */ sll $v0, $a0, 5 -/* CC3C4 80135CC4 3C038008 */ lui $v1, %hi(gItemTable+0x18) -/* CC3C8 80135CC8 00621821 */ addu $v1, $v1, $v0 -/* CC3CC 80135CCC 946378F8 */ lhu $v1, %lo(gItemTable+0x18)($v1) -/* CC3D0 80135CD0 30620040 */ andi $v0, $v1, 0x40 -/* CC3D4 80135CD4 1440000F */ bnez $v0, .L80135D14 -/* CC3D8 80135CD8 30620008 */ andi $v0, $v1, 8 -/* CC3DC 80135CDC 1440000D */ bnez $v0, .L80135D14 -/* CC3E0 80135CE0 2402015C */ addiu $v0, $zero, 0x15c -/* CC3E4 80135CE4 1082000B */ beq $a0, $v0, .L80135D14 -/* CC3E8 80135CE8 30620020 */ andi $v0, $v1, 0x20 -/* CC3EC 80135CEC 14400009 */ bnez $v0, .L80135D14 -/* CC3F0 80135CF0 3C030400 */ lui $v1, 0x400 -/* CC3F4 80135CF4 8E220000 */ lw $v0, ($s1) -/* CC3F8 80135CF8 00431024 */ and $v0, $v0, $v1 -/* CC3FC 80135CFC 14400005 */ bnez $v0, .L80135D14 -/* CC400 80135D00 00000000 */ nop -/* CC404 80135D04 96220006 */ lhu $v0, 6($s1) -/* CC408 80135D08 30420002 */ andi $v0, $v0, 2 -/* CC40C 80135D0C 10400005 */ beqz $v0, .L80135D24 -/* CC410 80135D10 00000000 */ nop -.L80135D14: -/* CC414 80135D14 8E220000 */ lw $v0, ($s1) -/* CC418 80135D18 2403FFBF */ addiu $v1, $zero, -0x41 -/* CC41C 80135D1C 00431024 */ and $v0, $v0, $v1 -/* CC420 80135D20 AE220000 */ sw $v0, ($s1) -.L80135D24: -/* CC424 80135D24 3C038015 */ lui $v1, %hi(D_801568E4) -/* CC428 80135D28 8C6368E4 */ lw $v1, %lo(D_801568E4)($v1) -/* CC42C 80135D2C 24020006 */ addiu $v0, $zero, 6 -.L80135D30: -/* CC430 80135D30 14620010 */ bne $v1, $v0, .L80135D74 -/* CC434 80135D34 00000000 */ nop -/* CC438 80135D38 0C04D8E8 */ jal func_801363A0 -/* CC43C 80135D3C 0220202D */ daddu $a0, $s1, $zero -/* CC440 80135D40 2404000C */ addiu $a0, $zero, 0xc -/* CC444 80135D44 3C108014 */ lui $s0, %hi(basic_window_update) -/* CC448 80135D48 26107474 */ addiu $s0, $s0, %lo(basic_window_update) -/* CC44C 80135D4C 0C051F9F */ jal set_window_update -/* CC450 80135D50 0200282D */ daddu $a1, $s0, $zero -/* CC454 80135D54 86230018 */ lh $v1, 0x18($s1) -/* CC458 80135D58 2402015C */ addiu $v0, $zero, 0x15c -/* CC45C 80135D5C 10620005 */ beq $v1, $v0, .L80135D74 -/* CC460 80135D60 24020157 */ addiu $v0, $zero, 0x157 -/* CC464 80135D64 10620003 */ beq $v1, $v0, .L80135D74 -/* CC468 80135D68 24040013 */ addiu $a0, $zero, 0x13 -/* CC46C 80135D6C 0C051F9F */ jal set_window_update -/* CC470 80135D70 0200282D */ daddu $a1, $s0, $zero -.L80135D74: -/* CC474 80135D74 3C038015 */ lui $v1, %hi(D_801568E4) -/* CC478 80135D78 246368E4 */ addiu $v1, $v1, %lo(D_801568E4) -/* CC47C 80135D7C 8C620000 */ lw $v0, ($v1) -/* CC480 80135D80 10400003 */ beqz $v0, .L80135D90 -/* CC484 80135D84 2442FFFF */ addiu $v0, $v0, -1 -/* CC488 80135D88 0804D8DF */ j .L8013637C_CCA7C -/* CC48C 80135D8C AC620000 */ sw $v0, ($v1) -.L80135D90: -/* CC490 80135D90 3C028007 */ lui $v0, %hi(gGameStatusPtr) -/* CC494 80135D94 8C42419C */ lw $v0, %lo(gGameStatusPtr)($v0) -/* CC498 80135D98 3C03000F */ lui $v1, 0xf -/* CC49C 80135D9C 8C420010 */ lw $v0, 0x10($v0) -/* CC4A0 80135DA0 3463C000 */ ori $v1, $v1, 0xc000 -/* CC4A4 80135DA4 00431024 */ and $v0, $v0, $v1 -/* CC4A8 80135DA8 10400174 */ beqz $v0, .L8013637C_CCA7C -/* CC4AC 80135DAC 00000000 */ nop -/* CC4B0 80135DB0 0C04C3DC */ jal item_entity_disable_shadow -/* CC4B4 80135DB4 0220202D */ daddu $a0, $s1, $zero -/* CC4B8 80135DB8 0C037F3D */ jal func_800DFCF4 -/* CC4BC 80135DBC 00000000 */ nop -/* CC4C0 80135DC0 1040000A */ beqz $v0, .L80135DEC -/* CC4C4 80135DC4 2402001D */ addiu $v0, $zero, 0x1d -/* CC4C8 80135DC8 826300B4 */ lb $v1, 0xb4($s3) -/* CC4CC 80135DCC 10620007 */ beq $v1, $v0, .L80135DEC -/* CC4D0 80135DD0 3C031000 */ lui $v1, 0x1000 -/* CC4D4 80135DD4 8E620004 */ lw $v0, 4($s3) -/* CC4D8 80135DD8 00431024 */ and $v0, $v0, $v1 -/* CC4DC 80135DDC 14400003 */ bnez $v0, .L80135DEC -/* CC4E0 80135DE0 00000000 */ nop -/* CC4E4 80135DE4 0C039769 */ jal set_action_state -/* CC4E8 80135DE8 0000202D */ daddu $a0, $zero, $zero -.L80135DEC: -/* CC4EC 80135DEC 86220018 */ lh $v0, 0x18($s1) -/* CC4F0 80135DF0 00021140 */ sll $v0, $v0, 5 -/* CC4F4 80135DF4 3C018008 */ lui $at, %hi(gItemTable+0x18) -/* CC4F8 80135DF8 00220821 */ addu $at, $at, $v0 -/* CC4FC 80135DFC 942278F8 */ lhu $v0, %lo(gItemTable+0x18)($at) -/* CC500 80135E00 30420020 */ andi $v0, $v0, 0x20 -/* CC504 80135E04 10400006 */ beqz $v0, .L80135E20 -/* CC508 80135E08 2404000C */ addiu $a0, $zero, 0xc -/* CC50C 80135E0C 3C028015 */ lui $v0, %hi(D_801568F0) -/* CC510 80135E10 8C4268F0 */ lw $v0, %lo(D_801568F0)($v0) -/* CC514 80135E14 8C43000C */ lw $v1, 0xc($v0) -/* CC518 80135E18 2402000A */ addiu $v0, $zero, 0xa -/* CC51C 80135E1C AC620014 */ sw $v0, 0x14($v1) -.L80135E20: -/* CC520 80135E20 3C108014 */ lui $s0, %hi(basic_hidden_window_update) -/* CC524 80135E24 26107574 */ addiu $s0, $s0, %lo(basic_hidden_window_update) -/* CC528 80135E28 0C051F9F */ jal set_window_update -/* CC52C 80135E2C 0200282D */ daddu $a1, $s0, $zero -/* CC530 80135E30 24040013 */ addiu $a0, $zero, 0x13 -/* CC534 80135E34 0C051F9F */ jal set_window_update -/* CC538 80135E38 0200282D */ daddu $a1, $s0, $zero -/* CC53C 80135E3C 24020003 */ addiu $v0, $zero, 3 -/* CC540 80135E40 0804D8DF */ j .L8013637C_CCA7C -/* CC544 80135E44 A222001A */ sb $v0, 0x1a($s1) -.L80135E48_CC548: -/* CC548 80135E48 3C038016 */ lui $v1, %hi(gWindows) -/* CC54C 80135E4C 24639D50 */ addiu $v1, $v1, %lo(gWindows) -/* CC550 80135E50 90620180 */ lbu $v0, 0x180($v1) -/* CC554 80135E54 30420008 */ andi $v0, $v0, 8 -/* CC558 80135E58 14400148 */ bnez $v0, .L8013637C_CCA7C -/* CC55C 80135E5C 00000000 */ nop -/* CC560 80135E60 90620260 */ lbu $v0, 0x260($v1) -/* CC564 80135E64 30420008 */ andi $v0, $v0, 8 -/* CC568 80135E68 14400144 */ bnez $v0, .L8013637C_CCA7C -/* CC56C 80135E6C 24020004 */ addiu $v0, $zero, 4 -/* CC570 80135E70 0804D8DF */ j .L8013637C_CCA7C -/* CC574 80135E74 A222001A */ sb $v0, 0x1a($s1) -.L80135E78_CC578: -/* CC578 80135E78 86220018 */ lh $v0, 0x18($s1) -/* CC57C 80135E7C 00021140 */ sll $v0, $v0, 5 -/* CC580 80135E80 3C018008 */ lui $at, %hi(gItemTable+0x18) -/* CC584 80135E84 00220821 */ addu $at, $at, $v0 -/* CC588 80135E88 942278F8 */ lhu $v0, %lo(gItemTable+0x18)($at) -/* CC58C 80135E8C 30420004 */ andi $v0, $v0, 4 -/* CC590 80135E90 10400009 */ beqz $v0, .L80135EB8 -/* CC594 80135E94 0000202D */ daddu $a0, $zero, $zero -/* CC598 80135E98 3C05F840 */ lui $a1, 0xf840 -/* CC59C 80135E9C 0C0B1EAF */ jal evt_get_variable -/* CC5A0 80135EA0 34A55BE1 */ ori $a1, $a1, 0x5be1 -/* CC5A4 80135EA4 14400004 */ bnez $v0, .L80135EB8 -/* CC5A8 80135EA8 0000202D */ daddu $a0, $zero, $zero -/* CC5AC 80135EAC 3C05F840 */ lui $a1, 0xf840 -/* CC5B0 80135EB0 0804D7BB */ j .L80135EEC -/* CC5B4 80135EB4 34A55BE1 */ ori $a1, $a1, 0x5be1 -.L80135EB8: -/* CC5B8 80135EB8 86230018 */ lh $v1, 0x18($s1) -/* CC5BC 80135EBC 2402015C */ addiu $v0, $zero, 0x15c -/* CC5C0 80135EC0 1462000F */ bne $v1, $v0, .L80135F00 -/* CC5C4 80135EC4 24020009 */ addiu $v0, $zero, 9 -/* CC5C8 80135EC8 0000202D */ daddu $a0, $zero, $zero -/* CC5CC 80135ECC 3C05F840 */ lui $a1, 0xf840 -/* CC5D0 80135ED0 0C0B1EAF */ jal evt_get_variable -/* CC5D4 80135ED4 34A55BE5 */ ori $a1, $a1, 0x5be5 -/* CC5D8 80135ED8 14400009 */ bnez $v0, .L80135F00 -/* CC5DC 80135EDC 24020009 */ addiu $v0, $zero, 9 -/* CC5E0 80135EE0 0000202D */ daddu $a0, $zero, $zero -/* CC5E4 80135EE4 3C05F840 */ lui $a1, 0xf840 -/* CC5E8 80135EE8 34A55BE5 */ ori $a1, $a1, 0x5be5 -.L80135EEC: -/* CC5EC 80135EEC 0C0B2026 */ jal evt_set_variable -/* CC5F0 80135EF0 24060001 */ addiu $a2, $zero, 1 -/* CC5F4 80135EF4 24020005 */ addiu $v0, $zero, 5 -/* CC5F8 80135EF8 0804D8DF */ j .L8013637C_CCA7C -/* CC5FC 80135EFC A222001A */ sb $v0, 0x1a($s1) -.L80135F00: -/* CC600 80135F00 0804D8DF */ j .L8013637C_CCA7C -/* CC604 80135F04 A222001A */ sb $v0, 0x1a($s1) -.L80135F08_CC608: -/* CC608 80135F08 86230018 */ lh $v1, 0x18($s1) -/* CC60C 80135F0C 00031140 */ sll $v0, $v1, 5 -/* CC610 80135F10 3C018008 */ lui $at, %hi(gItemTable+0x18) -/* CC614 80135F14 00220821 */ addu $at, $at, $v0 -/* CC618 80135F18 942278F8 */ lhu $v0, %lo(gItemTable+0x18)($at) -/* CC61C 80135F1C 30420004 */ andi $v0, $v0, 4 -/* CC620 80135F20 10400003 */ beqz $v0, .L80135F30 -/* CC624 80135F24 0000202D */ daddu $a0, $zero, $zero -/* CC628 80135F28 3C04001D */ lui $a0, 0x1d -/* CC62C 80135F2C 34840002 */ ori $a0, $a0, 2 -.L80135F30: -/* CC630 80135F30 2402015C */ addiu $v0, $zero, 0x15c -/* CC634 80135F34 14620003 */ bne $v1, $v0, .L80135F44 -/* CC638 80135F38 00000000 */ nop -/* CC63C 80135F3C 3C04001D */ lui $a0, 0x1d -/* CC640 80135F40 34840003 */ ori $a0, $a0, 3 -.L80135F44: -/* CC644 80135F44 3C058015 */ lui $a1, %hi(D_801568F8) -/* CC648 80135F48 24A568F8 */ addiu $a1, $a1, %lo(D_801568F8) -/* CC64C 80135F4C 0C049640 */ jal msg_get_printer_for_msg -/* CC650 80135F50 00000000 */ nop -/* CC654 80135F54 0040202D */ daddu $a0, $v0, $zero -/* CC658 80135F58 0000282D */ daddu $a1, $zero, $zero -/* CC65C 80135F5C 3C018015 */ lui $at, %hi(D_801568F4) -/* CC660 80135F60 AC2468F4 */ sw $a0, %lo(D_801568F4)($at) -/* CC664 80135F64 0C0496AE */ jal msg_printer_set_origin_pos -/* CC668 80135F68 00A0302D */ daddu $a2, $a1, $zero -/* CC66C 80135F6C 24020006 */ addiu $v0, $zero, 6 -/* CC670 80135F70 0804D8DF */ j .L8013637C_CCA7C -/* CC674 80135F74 A222001A */ sb $v0, 0x1a($s1) -.L80135F78_CC678: -/* CC678 80135F78 3C038015 */ lui $v1, %hi(D_801568F8) -/* CC67C 80135F7C 8C6368F8 */ lw $v1, %lo(D_801568F8)($v1) -/* CC680 80135F80 24020001 */ addiu $v0, $zero, 1 -/* CC684 80135F84 146200FD */ bne $v1, $v0, .L8013637C_CCA7C -/* CC688 80135F88 00000000 */ nop -/* CC68C 80135F8C 3C018015 */ lui $at, %hi(isPickingUpItem) -/* CC690 80135F90 A42065A4 */ sh $zero, %lo(isPickingUpItem)($at) -.L80135F94_CC694: -/* CC694 80135F94 8E220000 */ lw $v0, ($s1) -/* CC698 80135F98 3C030200 */ lui $v1, 0x200 -/* CC69C 80135F9C 00431024 */ and $v0, $v0, $v1 -/* CC6A0 80135FA0 1440000D */ bnez $v0, .L80135FD8 -/* CC6A4 80135FA4 00000000 */ nop -/* CC6A8 80135FA8 0C009C22 */ jal set_time_freeze_mode -/* CC6AC 80135FAC 0000202D */ daddu $a0, $zero, $zero -/* CC6B0 80135FB0 0C038069 */ jal enable_player_input -/* CC6B4 80135FB4 00000000 */ nop -/* CC6B8 80135FB8 0C03BD80 */ jal partner_enable_input -/* CC6BC 80135FBC 00000000 */ nop -/* CC6C0 80135FC0 3C02800A */ lui $v0, %hi(gOverrideFlags) -/* CC6C4 80135FC4 2442A650 */ addiu $v0, $v0, %lo(gOverrideFlags) -/* CC6C8 80135FC8 8C430000 */ lw $v1, ($v0) -/* CC6CC 80135FCC 2404FFBF */ addiu $a0, $zero, -0x41 -/* CC6D0 80135FD0 00641824 */ and $v1, $v1, $a0 -/* CC6D4 80135FD4 AC430000 */ sw $v1, ($v0) -.L80135FD8: -/* CC6D8 80135FD8 3C048015 */ lui $a0, %hi(D_801568E0) -/* CC6DC 80135FDC 8C8468E0 */ lw $a0, %lo(D_801568E0)($a0) -/* CC6E0 80135FE0 0804D8D5 */ j .L80136354 -/* CC6E4 80135FE4 00000000 */ nop -.L80135FE8_CC6E8: -/* CC6E8 80135FE8 3C028007 */ lui $v0, %hi(gGameStatusPtr) -/* CC6EC 80135FEC 8C42419C */ lw $v0, %lo(gGameStatusPtr)($v0) -/* CC6F0 80135FF0 8C420010 */ lw $v0, 0x10($v0) -/* CC6F4 80135FF4 30428000 */ andi $v0, $v0, 0x8000 -/* CC6F8 80135FF8 104000E0 */ beqz $v0, .L8013637C_CCA7C -/* CC6FC 80135FFC 24070001 */ addiu $a3, $zero, 1 -/* CC700 80136000 0000202D */ daddu $a0, $zero, $zero -/* CC704 80136004 3C038008 */ lui $v1, %hi(gItemTable) -/* CC708 80136008 246378E0 */ addiu $v1, $v1, %lo(gItemTable) -/* CC70C 8013600C 86220018 */ lh $v0, 0x18($s1) -/* CC710 80136010 0060402D */ daddu $t0, $v1, $zero -/* CC714 80136014 00021140 */ sll $v0, $v0, 5 -/* CC718 80136018 00482821 */ addu $a1, $v0, $t0 -/* CC71C 8013601C 84A20004 */ lh $v0, 4($a1) -/* CC720 80136020 3C0A8009 */ lui $t2, %hi(gItemHudScripts) -/* CC724 80136024 254AA680 */ addiu $t2, $t2, %lo(gItemHudScripts) -/* CC728 80136028 000210C0 */ sll $v0, $v0, 3 -/* CC72C 8013602C 3C018009 */ lui $at, %hi(gItemHudScripts) -/* CC730 80136030 00220821 */ addu $at, $at, $v0 -/* CC734 80136034 8C22A680 */ lw $v0, %lo(gItemHudScripts)($at) -/* CC738 80136038 00E0482D */ daddu $t1, $a3, $zero -/* CC73C 8013603C AE020000 */ sw $v0, ($s0) -/* CC740 80136040 86230018 */ lh $v1, 0x18($s1) -/* CC744 80136044 00E0102D */ daddu $v0, $a3, $zero -/* CC748 80136048 AE02018C */ sw $v0, 0x18c($s0) -/* CC74C 8013604C AE030108 */ sw $v1, 0x108($s0) -/* CC750 80136050 8CA20000 */ lw $v0, ($a1) -/* CC754 80136054 0280302D */ daddu $a2, $s4, $zero -/* CC758 80136058 AE020084 */ sw $v0, 0x84($s0) -/* CC75C 8013605C 8CA20014 */ lw $v0, 0x14($a1) -/* CC760 80136060 26030004 */ addiu $v1, $s0, 4 -/* CC764 80136064 AE020294 */ sw $v0, 0x294($s0) -.L80136068: -/* CC768 80136068 84C201B4 */ lh $v0, 0x1b4($a2) -/* CC76C 8013606C 10400011 */ beqz $v0, .L801360B4 -/* CC770 80136070 24840001 */ addiu $a0, $a0, 1 -/* CC774 80136074 00021140 */ sll $v0, $v0, 5 -/* CC778 80136078 00482821 */ addu $a1, $v0, $t0 -/* CC77C 8013607C 84A20004 */ lh $v0, 4($a1) -/* CC780 80136080 000210C0 */ sll $v0, $v0, 3 -/* CC784 80136084 004A1021 */ addu $v0, $v0, $t2 -/* CC788 80136088 8C420000 */ lw $v0, ($v0) -/* CC78C 8013608C AC620000 */ sw $v0, ($v1) -/* CC790 80136090 84C201B4 */ lh $v0, 0x1b4($a2) -/* CC794 80136094 AC69018C */ sw $t1, 0x18c($v1) -/* CC798 80136098 AC620108 */ sw $v0, 0x108($v1) -/* CC79C 8013609C 8CA20000 */ lw $v0, ($a1) -/* CC7A0 801360A0 AC620084 */ sw $v0, 0x84($v1) -/* CC7A4 801360A4 8CA20014 */ lw $v0, 0x14($a1) -/* CC7A8 801360A8 24E70001 */ addiu $a3, $a3, 1 -/* CC7AC 801360AC AC620294 */ sw $v0, 0x294($v1) -/* CC7B0 801360B0 24630004 */ addiu $v1, $v1, 4 -.L801360B4: -/* CC7B4 801360B4 2882000A */ slti $v0, $a0, 0xa -/* CC7B8 801360B8 1440FFEB */ bnez $v0, .L80136068 -/* CC7BC 801360BC 24C60002 */ addiu $a2, $a2, 2 -/* CC7C0 801360C0 0200202D */ daddu $a0, $s0, $zero -/* CC7C4 801360C4 24020002 */ addiu $v0, $zero, 2 -/* CC7C8 801360C8 AC820318 */ sw $v0, 0x318($a0) -/* CC7CC 801360CC AC870324 */ sw $a3, 0x324($a0) -/* CC7D0 801360D0 0C03D390 */ jal create_popup_menu -/* CC7D4 801360D4 AC800328 */ sw $zero, 0x328($a0) -/* CC7D8 801360D8 2404000C */ addiu $a0, $zero, 0xc -/* CC7DC 801360DC 3C108014 */ lui $s0, %hi(basic_hidden_window_update) -/* CC7E0 801360E0 26107574 */ addiu $s0, $s0, %lo(basic_hidden_window_update) -/* CC7E4 801360E4 0C051F9F */ jal set_window_update -/* CC7E8 801360E8 0200282D */ daddu $a1, $s0, $zero -/* CC7EC 801360EC 24040011 */ addiu $a0, $zero, 0x11 -/* CC7F0 801360F0 0C051F9F */ jal set_window_update -/* CC7F4 801360F4 0200282D */ daddu $a1, $s0, $zero -/* CC7F8 801360F8 2402000B */ addiu $v0, $zero, 0xb -/* CC7FC 801360FC 3C018015 */ lui $at, %hi(D_801568E4) -/* CC800 80136100 AC2068E4 */ sw $zero, %lo(D_801568E4)($at) -/* CC804 80136104 0804D8DF */ j .L8013637C_CCA7C -/* CC808 80136108 A222001A */ sb $v0, 0x1a($s1) -.L8013610C_CC80C: -/* CC80C 8013610C 3C038016 */ lui $v1, %hi(gWindows) -/* CC810 80136110 24639D50 */ addiu $v1, $v1, %lo(gWindows) -/* CC814 80136114 90620180 */ lbu $v0, 0x180($v1) -/* CC818 80136118 30420008 */ andi $v0, $v0, 8 -/* CC81C 8013611C 14400097 */ bnez $v0, .L8013637C_CCA7C -/* CC820 80136120 00000000 */ nop -/* CC824 80136124 90620220 */ lbu $v0, 0x220($v1) -/* CC828 80136128 30420008 */ andi $v0, $v0, 8 -/* CC82C 8013612C 14400093 */ bnez $v0, .L8013637C_CCA7C -/* CC830 80136130 00000000 */ nop -/* CC834 80136134 90620260 */ lbu $v0, 0x260($v1) -/* CC838 80136138 30420008 */ andi $v0, $v0, 8 -/* CC83C 8013613C 1440008F */ bnez $v0, .L8013637C_CCA7C -/* CC840 80136140 2402000C */ addiu $v0, $zero, 0xc -/* CC844 80136144 0804D8DF */ j .L8013637C_CCA7C -/* CC848 80136148 A222001A */ sb $v0, 0x1a($s1) -.L8013614C_CC84C: -/* CC84C 8013614C 3C158015 */ lui $s5, %hi(D_801568E4) -/* CC850 80136150 26B568E4 */ addiu $s5, $s5, %lo(D_801568E4) -/* CC854 80136154 8EA20000 */ lw $v0, ($s5) -/* CC858 80136158 1440000A */ bnez $v0, .L80136184 -/* CC85C 8013615C 24420001 */ addiu $v0, $v0, 1 -/* CC860 80136160 8602032C */ lh $v0, 0x32c($s0) -/* CC864 80136164 3C018015 */ lui $at, %hi(D_801568E8) -/* CC868 80136168 AC2268E8 */ sw $v0, %lo(D_801568E8)($at) -/* CC86C 8013616C 10400083 */ beqz $v0, .L8013637C_CCA7C -/* CC870 80136170 00000000 */ nop -/* CC874 80136174 0C03C4EC */ jal hide_popup_menu -/* CC878 80136178 00000000 */ nop -/* CC87C 8013617C 8EA20000 */ lw $v0, ($s5) -/* CC880 80136180 24420001 */ addiu $v0, $v0, 1 -.L80136184: -/* CC884 80136184 AEA20000 */ sw $v0, ($s5) -/* CC888 80136188 2842000F */ slti $v0, $v0, 0xf -/* CC88C 8013618C 1440007B */ bnez $v0, .L8013637C_CCA7C -/* CC890 80136190 00000000 */ nop -/* CC894 80136194 0C03C54E */ jal destroy_popup_menu -/* CC898 80136198 00000000 */ nop -/* CC89C 8013619C 3C128015 */ lui $s2, %hi(D_801568E8) -/* CC8A0 801361A0 265268E8 */ addiu $s2, $s2, %lo(D_801568E8) -/* CC8A4 801361A4 8E430000 */ lw $v1, ($s2) -/* CC8A8 801361A8 240200FF */ addiu $v0, $zero, 0xff -/* CC8AC 801361AC 14620002 */ bne $v1, $v0, .L801361B8 -/* CC8B0 801361B0 24020001 */ addiu $v0, $zero, 1 -/* CC8B4 801361B4 AE420000 */ sw $v0, ($s2) -.L801361B8: -/* CC8B8 801361B8 8E420000 */ lw $v0, ($s2) -/* CC8BC 801361BC 3C048015 */ lui $a0, %hi(D_801568E0) -/* CC8C0 801361C0 8C8468E0 */ lw $a0, %lo(D_801568E0)($a0) -/* CC8C4 801361C4 2442FFFF */ addiu $v0, $v0, -1 -/* CC8C8 801361C8 00021080 */ sll $v0, $v0, 2 -/* CC8CC 801361CC 02021021 */ addu $v0, $s0, $v0 -/* CC8D0 801361D0 8C450000 */ lw $a1, ($v0) -/* CC8D4 801361D4 8C420108 */ lw $v0, 0x108($v0) -/* CC8D8 801361D8 3C108015 */ lui $s0, %hi(D_801568EC) -/* CC8DC 801361DC 261068EC */ addiu $s0, $s0, %lo(D_801568EC) -/* CC8E0 801361E0 0C0511FF */ jal hud_element_set_script -/* CC8E4 801361E4 AE020000 */ sw $v0, ($s0) -/* CC8E8 801361E8 8E040000 */ lw $a0, ($s0) -/* CC8EC 801361EC 8E650028 */ lw $a1, 0x28($s3) -/* CC8F0 801361F0 8E670030 */ lw $a3, 0x30($s3) -/* CC8F4 801361F4 24020003 */ addiu $v0, $zero, 3 -/* CC8F8 801361F8 AFA20010 */ sw $v0, 0x10($sp) -/* CC8FC 801361FC 866200B0 */ lh $v0, 0xb0($s3) -/* CC900 80136200 C662002C */ lwc1 $f2, 0x2c($s3) -/* CC904 80136204 44820000 */ mtc1 $v0, $f0 -/* CC908 80136208 00000000 */ nop -/* CC90C 8013620C 46800020 */ cvt.s.w $f0, $f0 -/* CC910 80136210 46001080 */ add.s $f2, $f2, $f0 -/* CC914 80136214 44061000 */ mfc1 $a2, $f2 -/* CC918 80136218 AFA00014 */ sw $zero, 0x14($sp) -/* CC91C 8013621C 0C04C6B2 */ jal make_item_entity_delayed -/* CC920 80136220 AFA00018 */ sw $zero, 0x18($sp) -/* CC924 80136224 0C04C3D6 */ jal get_item_entity -/* CC928 80136228 0040202D */ daddu $a0, $v0, $zero -/* CC92C 8013622C 2403FFFF */ addiu $v1, $zero, -1 -/* CC930 80136230 A043001D */ sb $v1, 0x1d($v0) -/* CC934 80136234 8E430000 */ lw $v1, ($s2) -/* CC938 80136238 28620002 */ slti $v0, $v1, 2 -/* CC93C 8013623C 1440000A */ bnez $v0, .L80136268 -/* CC940 80136240 3C040006 */ lui $a0, 6 -/* CC944 80136244 2462FFFE */ addiu $v0, $v1, -2 -/* CC948 80136248 00021040 */ sll $v0, $v0, 1 -/* CC94C 8013624C 02821021 */ addu $v0, $s4, $v0 -/* CC950 80136250 0C039DB3 */ jal sort_items -/* CC954 80136254 A44001B4 */ sh $zero, 0x1b4($v0) -/* CC958 80136258 86240018 */ lh $a0, 0x18($s1) -/* CC95C 8013625C 0C039D5D */ jal add_item -/* CC960 80136260 00000000 */ nop -/* CC964 80136264 3C040006 */ lui $a0, 6 -.L80136268: -/* CC968 80136268 0C037FDE */ jal suggest_player_anim_setUnkFlag -/* CC96C 8013626C 3484000C */ ori $a0, $a0, 0xc -/* CC970 80136270 0C04D8E8 */ jal func_801363A0 -/* CC974 80136274 0220202D */ daddu $a0, $s1, $zero -/* CC978 80136278 3C058014 */ lui $a1, %hi(basic_window_update) -/* CC97C 8013627C 24A57474 */ addiu $a1, $a1, %lo(basic_window_update) -/* CC980 80136280 0C051F9F */ jal set_window_update -/* CC984 80136284 2404000C */ addiu $a0, $zero, 0xc -/* CC988 80136288 24020032 */ addiu $v0, $zero, 0x32 -/* CC98C 8013628C AEA20000 */ sw $v0, ($s5) -/* CC990 80136290 2402000D */ addiu $v0, $zero, 0xd -/* CC994 80136294 0804D8DF */ j .L8013637C_CCA7C -/* CC998 80136298 A222001A */ sb $v0, 0x1a($s1) -.L8013629C_CC99C: -/* CC99C 8013629C 3C028007 */ lui $v0, %hi(gGameStatusPtr) -/* CC9A0 801362A0 8C42419C */ lw $v0, %lo(gGameStatusPtr)($v0) -/* CC9A4 801362A4 8C420010 */ lw $v0, 0x10($v0) -/* CC9A8 801362A8 30428000 */ andi $v0, $v0, 0x8000 -/* CC9AC 801362AC 10400033 */ beqz $v0, .L8013637C_CCA7C -/* CC9B0 801362B0 00000000 */ nop -/* CC9B4 801362B4 3C058014 */ lui $a1, %hi(basic_hidden_window_update) -/* CC9B8 801362B8 24A57574 */ addiu $a1, $a1, %lo(basic_hidden_window_update) -/* CC9BC 801362BC 0C051F9F */ jal set_window_update -/* CC9C0 801362C0 2404000C */ addiu $a0, $zero, 0xc -/* CC9C4 801362C4 2402000E */ addiu $v0, $zero, 0xe -/* CC9C8 801362C8 0804D8DF */ j .L8013637C_CCA7C -/* CC9CC 801362CC A222001A */ sb $v0, 0x1a($s1) -.L801362D0_CC9D0: -/* CC9D0 801362D0 3C038016 */ lui $v1, %hi(gWindows) -/* CC9D4 801362D4 24639D50 */ addiu $v1, $v1, %lo(gWindows) -/* CC9D8 801362D8 90620180 */ lbu $v0, 0x180($v1) -/* CC9DC 801362DC 30420008 */ andi $v0, $v0, 8 -/* CC9E0 801362E0 14400026 */ bnez $v0, .L8013637C_CCA7C -/* CC9E4 801362E4 00000000 */ nop -/* CC9E8 801362E8 90620220 */ lbu $v0, 0x220($v1) -/* CC9EC 801362EC 30420008 */ andi $v0, $v0, 8 -/* CC9F0 801362F0 14400022 */ bnez $v0, .L8013637C_CCA7C -/* CC9F4 801362F4 00000000 */ nop -/* CC9F8 801362F8 90620260 */ lbu $v0, 0x260($v1) -/* CC9FC 801362FC 30420008 */ andi $v0, $v0, 8 -/* CCA00 80136300 1440001E */ bnez $v0, .L8013637C_CCA7C -/* CCA04 80136304 2402000F */ addiu $v0, $zero, 0xf -/* CCA08 80136308 0804D8DF */ j .L8013637C_CCA7C -/* CCA0C 8013630C A222001A */ sb $v0, 0x1a($s1) -.L80136310_CCA10: -/* CCA10 80136310 3C040001 */ lui $a0, 1 -/* CCA14 80136314 0C037FDE */ jal suggest_player_anim_setUnkFlag -/* CCA18 80136318 34840002 */ ori $a0, $a0, 2 -/* CCA1C 8013631C 0C009C22 */ jal set_time_freeze_mode -/* CCA20 80136320 0000202D */ daddu $a0, $zero, $zero -/* CCA24 80136324 0C038069 */ jal enable_player_input -/* CCA28 80136328 00000000 */ nop -/* CCA2C 8013632C 0C03BD80 */ jal partner_enable_input -/* CCA30 80136330 00000000 */ nop -/* CCA34 80136334 3C02800A */ lui $v0, %hi(gOverrideFlags) -/* CCA38 80136338 2442A650 */ addiu $v0, $v0, %lo(gOverrideFlags) -/* CCA3C 8013633C 2405FFBF */ addiu $a1, $zero, -0x41 -/* CCA40 80136340 8C430000 */ lw $v1, ($v0) -/* CCA44 80136344 3C048015 */ lui $a0, %hi(D_801568E0) -/* CCA48 80136348 8C8468E0 */ lw $a0, %lo(D_801568E0)($a0) -/* CCA4C 8013634C 00651824 */ and $v1, $v1, $a1 -/* CCA50 80136350 AC430000 */ sw $v1, ($v0) -.L80136354: -/* CCA54 80136354 0C05123D */ jal hud_element_free -/* CCA58 80136358 00000000 */ nop -/* CCA5C 8013635C 0C04CE4C */ jal remove_item_entity_by_reference -/* CCA60 80136360 0220202D */ daddu $a0, $s1, $zero -/* CCA64 80136364 0C039DB3 */ jal sort_items -/* CCA68 80136368 00000000 */ nop -/* CCA6C 8013636C 0C03A6CC */ jal decrement_status_menu_disabled -/* CCA70 80136370 00000000 */ nop -/* CCA74 80136374 3C018015 */ lui $at, %hi(isPickingUpItem) -/* CCA78 80136378 A42065A4 */ sh $zero, %lo(isPickingUpItem)($at) -.L8013637C_CCA7C: -/* CCA7C 8013637C 8FBF0038 */ lw $ra, 0x38($sp) -/* CCA80 80136380 8FB50034 */ lw $s5, 0x34($sp) -/* CCA84 80136384 8FB40030 */ lw $s4, 0x30($sp) -/* CCA88 80136388 8FB3002C */ lw $s3, 0x2c($sp) -/* CCA8C 8013638C 8FB20028 */ lw $s2, 0x28($sp) -/* CCA90 80136390 8FB10024 */ lw $s1, 0x24($sp) -/* CCA94 80136394 8FB00020 */ lw $s0, 0x20($sp) -/* CCA98 80136398 03E00008 */ jr $ra -/* CCA9C 8013639C 27BD0040 */ addiu $sp, $sp, 0x40 diff --git a/ver/us/asm/nonmatchings/E21870/func_802B704C.s b/ver/us/asm/nonmatchings/E21870/func_802B704C.s deleted file mode 100644 index 7a86558efa..0000000000 --- a/ver/us/asm/nonmatchings/E21870/func_802B704C.s +++ /dev/null @@ -1,67 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_802B704C -/* E218BC 802B704C 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* E218C0 802B7050 AFB00010 */ sw $s0, 0x10($sp) -/* E218C4 802B7054 3C108011 */ lui $s0, %hi(gPlayerStatus) -/* E218C8 802B7058 2610EFC8 */ addiu $s0, $s0, %lo(gPlayerStatus) -/* E218CC 802B705C AFBF0014 */ sw $ra, 0x14($sp) -/* E218D0 802B7060 0C011052 */ jal is_starting_conversation -/* E218D4 802B7064 00000000 */ nop -/* E218D8 802B7068 14400031 */ bnez $v0, .L802B7130 -/* E218DC 802B706C 0000102D */ daddu $v0, $zero, $zero -/* E218E0 802B7070 8E020000 */ lw $v0, ($s0) -/* E218E4 802B7074 30420020 */ andi $v0, $v0, 0x20 -/* E218E8 802B7078 1440002D */ bnez $v0, .L802B7130 -/* E218EC 802B707C 0000102D */ daddu $v0, $zero, $zero -/* E218F0 802B7080 8E020004 */ lw $v0, 4($s0) -/* E218F4 802B7084 30420080 */ andi $v0, $v0, 0x80 -/* E218F8 802B7088 10400029 */ beqz $v0, .L802B7130 -/* E218FC 802B708C 0000102D */ daddu $v0, $zero, $zero -/* E21900 802B7090 0C03814E */ jal has_valid_conversation_npc -/* E21904 802B7094 00000000 */ nop -/* E21908 802B7098 14400025 */ bnez $v0, .L802B7130 -/* E2190C 802B709C 0000102D */ daddu $v0, $zero, $zero -/* E21910 802B70A0 0C0381B6 */ jal func_800E06D8 -/* E21914 802B70A4 00000000 */ nop -/* E21918 802B70A8 14400021 */ bnez $v0, .L802B7130 -/* E2191C 802B70AC 0000102D */ daddu $v0, $zero, $zero -/* E21920 802B70B0 3C028007 */ lui $v0, %hi(gGameStatusPtr) -/* E21924 802B70B4 8C42419C */ lw $v0, %lo(gGameStatusPtr)($v0) -/* E21928 802B70B8 3C049249 */ lui $a0, 0x9249 -/* E2192C 802B70BC 9443008C */ lhu $v1, 0x8c($v0) -/* E21930 802B70C0 34842493 */ ori $a0, $a0, 0x2493 -/* E21934 802B70C4 00031C00 */ sll $v1, $v1, 0x10 -/* E21938 802B70C8 00031403 */ sra $v0, $v1, 0x10 -/* E2193C 802B70CC 00440018 */ mult $v0, $a0 -/* E21940 802B70D0 00031FC3 */ sra $v1, $v1, 0x1f -/* E21944 802B70D4 00002810 */ mfhi $a1 -/* E21948 802B70D8 00A22021 */ addu $a0, $a1, $v0 -/* E2194C 802B70DC 00042083 */ sra $a0, $a0, 2 -/* E21950 802B70E0 00832023 */ subu $a0, $a0, $v1 -/* E21954 802B70E4 000418C0 */ sll $v1, $a0, 3 -/* E21958 802B70E8 00641823 */ subu $v1, $v1, $a0 -/* E2195C 802B70EC 00431023 */ subu $v0, $v0, $v1 -/* E21960 802B70F0 00021400 */ sll $v0, $v0, 0x10 -/* E21964 802B70F4 00021403 */ sra $v0, $v0, 0x10 -/* E21968 802B70F8 2442FFFE */ addiu $v0, $v0, -2 -/* E2196C 802B70FC 04420001 */ bltzl $v0, .L802B7104 -/* E21970 802B7100 00021023 */ negu $v0, $v0 -.L802B7104: -/* E21974 802B7104 00042400 */ sll $a0, $a0, 0x10 -/* E21978 802B7108 00042403 */ sra $a0, $a0, 0x10 -/* E2197C 802B710C 00441021 */ addu $v0, $v0, $a0 -/* E21980 802B7110 28420006 */ slti $v0, $v0, 6 -/* E21984 802B7114 10400006 */ beqz $v0, .L802B7130 -/* E21988 802B7118 0000102D */ daddu $v0, $zero, $zero -/* E2198C 802B711C 0C0ADC00 */ jal func_802B7000_2 -/* E21990 802B7120 00000000 */ nop -/* E21994 802B7124 14400002 */ bnez $v0, .L802B7130 -/* E21998 802B7128 0000102D */ daddu $v0, $zero, $zero -/* E2199C 802B712C 24020001 */ addiu $v0, $zero, 1 -.L802B7130: -/* E219A0 802B7130 8FBF0014 */ lw $ra, 0x14($sp) -/* E219A4 802B7134 8FB00010 */ lw $s0, 0x10($sp) -/* E219A8 802B7138 03E00008 */ jr $ra -/* E219AC 802B713C 27BD0018 */ addiu $sp, $sp, 0x18 diff --git a/ver/us/asm/nonmatchings/E21870/func_802B7140.s b/ver/us/asm/nonmatchings/E21870/func_802B7140.s deleted file mode 100644 index 8d56b49d63..0000000000 --- a/ver/us/asm/nonmatchings/E21870/func_802B7140.s +++ /dev/null @@ -1,41 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_802B7140 -/* E219B0 802B7140 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* E219B4 802B7144 AFB00010 */ sw $s0, 0x10($sp) -/* E219B8 802B7148 3C10802B */ lui $s0, %hi(D_802B7D18_E22588) -/* E219BC 802B714C 26107D18 */ addiu $s0, $s0, %lo(D_802B7D18_E22588) -/* E219C0 802B7150 AFBF0014 */ sw $ra, 0x14($sp) -/* E219C4 802B7154 8E040000 */ lw $a0, ($s0) -/* E219C8 802B7158 0C00A580 */ jal mem_clear -/* E219CC 802B715C 24050028 */ addiu $a1, $zero, 0x28 -/* E219D0 802B7160 3C048011 */ lui $a0, %hi(gPlayerStatus) -/* E219D4 802B7164 2484EFC8 */ addiu $a0, $a0, %lo(gPlayerStatus) -/* E219D8 802B7168 8E030000 */ lw $v1, ($s0) -/* E219DC 802B716C C4800028 */ lwc1 $f0, 0x28($a0) -/* E219E0 802B7170 E4600000 */ swc1 $f0, ($v1) -/* E219E4 802B7174 848200B0 */ lh $v0, 0xb0($a0) -/* E219E8 802B7178 C480002C */ lwc1 $f0, 0x2c($a0) -/* E219EC 802B717C 44821000 */ mtc1 $v0, $f2 -/* E219F0 802B7180 00000000 */ nop -/* E219F4 802B7184 468010A0 */ cvt.s.w $f2, $f2 -/* E219F8 802B7188 46020000 */ add.s $f0, $f0, $f2 -/* E219FC 802B718C 3C014100 */ lui $at, 0x4100 -/* E21A00 802B7190 44811000 */ mtc1 $at, $f2 -/* E21A04 802B7194 00000000 */ nop -/* E21A08 802B7198 46020000 */ add.s $f0, $f0, $f2 -/* E21A0C 802B719C E4600004 */ swc1 $f0, 4($v1) -/* E21A10 802B71A0 C4800030 */ lwc1 $f0, 0x30($a0) -/* E21A14 802B71A4 E4600008 */ swc1 $f0, 8($v1) -/* E21A18 802B71A8 8C820004 */ lw $v0, 4($a0) -/* E21A1C 802B71AC 34420040 */ ori $v0, $v0, 0x40 -/* E21A20 802B71B0 AC820004 */ sw $v0, 4($a0) -/* E21A24 802B71B4 8FBF0014 */ lw $ra, 0x14($sp) -/* E21A28 802B71B8 8FB00010 */ lw $s0, 0x10($sp) -/* E21A2C 802B71BC 3C03802B */ lui $v1, %hi(func_802B74F0) -/* E21A30 802B71C0 246374F0 */ addiu $v1, $v1, %lo(func_802B74F0) -/* E21A34 802B71C4 3C018011 */ lui $at, %hi(D_8010C920) -/* E21A38 802B71C8 AC23C920 */ sw $v1, %lo(D_8010C920)($at) -/* E21A3C 802B71CC 03E00008 */ jr $ra -/* E21A40 802B71D0 27BD0018 */ addiu $sp, $sp, 0x18 diff --git a/ver/us/asm/nonmatchings/E21870/func_802B71D4.s b/ver/us/asm/nonmatchings/E21870/func_802B71D4.s deleted file mode 100644 index f3788edf58..0000000000 --- a/ver/us/asm/nonmatchings/E21870/func_802B71D4.s +++ /dev/null @@ -1,222 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel jtbl_802B7D20_E22590 -.word .L802B73C0_E21C30, .L802B73C8_E21C38, .L802B73D0_E21C40, .L802B73D8_E21C48, .L802B73E0_E21C50, .L802B73E8_E21C58, 0, 0 - -.section .text - -glabel func_802B71D4 -/* E21A44 802B71D4 3C028011 */ lui $v0, %hi(gPlayerStatus+0x4) -/* E21A48 802B71D8 8C42EFCC */ lw $v0, %lo(gPlayerStatus+0x4)($v0) -/* E21A4C 802B71DC 27BDFF38 */ addiu $sp, $sp, -0xc8 -/* E21A50 802B71E0 AFBF00C0 */ sw $ra, 0xc0($sp) -/* E21A54 802B71E4 AFB300BC */ sw $s3, 0xbc($sp) -/* E21A58 802B71E8 AFB200B8 */ sw $s2, 0xb8($sp) -/* E21A5C 802B71EC AFB100B4 */ sw $s1, 0xb4($sp) -/* E21A60 802B71F0 30420040 */ andi $v0, $v0, 0x40 -/* E21A64 802B71F4 104000B7 */ beqz $v0, .L802B74D4 -/* E21A68 802B71F8 AFB000B0 */ sw $s0, 0xb0($sp) -/* E21A6C 802B71FC 3C13802B */ lui $s3, %hi(D_802B7D18_E22588) -/* E21A70 802B7200 26737D18 */ addiu $s3, $s3, %lo(D_802B7D18_E22588) -/* E21A74 802B7204 8E620000 */ lw $v0, ($s3) -/* E21A78 802B7208 27A40018 */ addiu $a0, $sp, 0x18 -/* E21A7C 802B720C 8C45000C */ lw $a1, 0xc($v0) -/* E21A80 802B7210 3C120001 */ lui $s2, 1 -/* E21A84 802B7214 00A0302D */ daddu $a2, $a1, $zero -/* E21A88 802B7218 0C019DF0 */ jal guScaleF -/* E21A8C 802B721C 00A0382D */ daddu $a3, $a1, $zero -/* E21A90 802B7220 27B00058 */ addiu $s0, $sp, 0x58 -/* E21A94 802B7224 3C038007 */ lui $v1, %hi(gCurrentCameraID) -/* E21A98 802B7228 8C637410 */ lw $v1, %lo(gCurrentCameraID)($v1) -/* E21A9C 802B722C 44800000 */ mtc1 $zero, $f0 -/* E21AA0 802B7230 00031080 */ sll $v0, $v1, 2 -/* E21AA4 802B7234 00431021 */ addu $v0, $v0, $v1 -/* E21AA8 802B7238 00021080 */ sll $v0, $v0, 2 -/* E21AAC 802B723C 00431023 */ subu $v0, $v0, $v1 -/* E21AB0 802B7240 000218C0 */ sll $v1, $v0, 3 -/* E21AB4 802B7244 00431021 */ addu $v0, $v0, $v1 -/* E21AB8 802B7248 000210C0 */ sll $v0, $v0, 3 -/* E21ABC 802B724C 44060000 */ mfc1 $a2, $f0 -/* E21AC0 802B7250 3C01800B */ lui $at, %hi(gCameras+0x6C) -/* E21AC4 802B7254 00220821 */ addu $at, $at, $v0 -/* E21AC8 802B7258 C4201DEC */ lwc1 $f0, %lo(gCameras+0x6C)($at) -/* E21ACC 802B725C 3C073F80 */ lui $a3, 0x3f80 -/* E21AD0 802B7260 46000007 */ neg.s $f0, $f0 -/* E21AD4 802B7264 44050000 */ mfc1 $a1, $f0 -/* E21AD8 802B7268 0200202D */ daddu $a0, $s0, $zero -/* E21ADC 802B726C 0C019EC8 */ jal guRotateF -/* E21AE0 802B7270 AFA60010 */ sw $a2, 0x10($sp) -/* E21AE4 802B7274 27A40018 */ addiu $a0, $sp, 0x18 -/* E21AE8 802B7278 0200282D */ daddu $a1, $s0, $zero -/* E21AEC 802B727C 0C019D80 */ jal guMtxCatF -/* E21AF0 802B7280 0080302D */ daddu $a2, $a0, $zero -/* E21AF4 802B7284 8E620000 */ lw $v0, ($s3) -/* E21AF8 802B7288 36521630 */ ori $s2, $s2, 0x1630 -/* E21AFC 802B728C 8C450000 */ lw $a1, ($v0) -/* E21B00 802B7290 8C460004 */ lw $a2, 4($v0) -/* E21B04 802B7294 8C470008 */ lw $a3, 8($v0) -/* E21B08 802B7298 0C019E40 */ jal guTranslateF -/* E21B0C 802B729C 0200202D */ daddu $a0, $s0, $zero -/* E21B10 802B72A0 27A40018 */ addiu $a0, $sp, 0x18 -/* E21B14 802B72A4 0200282D */ daddu $a1, $s0, $zero -/* E21B18 802B72A8 0C019D80 */ jal guMtxCatF -/* E21B1C 802B72AC 0200302D */ daddu $a2, $s0, $zero -/* E21B20 802B72B0 0200202D */ daddu $a0, $s0, $zero -/* E21B24 802B72B4 3C108007 */ lui $s0, %hi(gMatrixListPos) -/* E21B28 802B72B8 261041F0 */ addiu $s0, $s0, %lo(gMatrixListPos) -/* E21B2C 802B72BC 3C11800A */ lui $s1, %hi(gDisplayContext) -/* E21B30 802B72C0 2631A674 */ addiu $s1, $s1, %lo(gDisplayContext) -/* E21B34 802B72C4 96050000 */ lhu $a1, ($s0) -/* E21B38 802B72C8 8E220000 */ lw $v0, ($s1) -/* E21B3C 802B72CC 00052980 */ sll $a1, $a1, 6 -/* E21B40 802B72D0 00B22821 */ addu $a1, $a1, $s2 -/* E21B44 802B72D4 0C019D40 */ jal guMtxF2L -/* E21B48 802B72D8 00452821 */ addu $a1, $v0, $a1 -/* E21B4C 802B72DC 3C02DA38 */ lui $v0, 0xda38 -/* E21B50 802B72E0 34420002 */ ori $v0, $v0, 2 -/* E21B54 802B72E4 3C07800A */ lui $a3, %hi(gMasterGfxPos) -/* E21B58 802B72E8 24E7A66C */ addiu $a3, $a3, %lo(gMasterGfxPos) -/* E21B5C 802B72EC 3C089249 */ lui $t0, 0x9249 -/* E21B60 802B72F0 35082493 */ ori $t0, $t0, 0x2493 -/* E21B64 802B72F4 8CE50000 */ lw $a1, ($a3) -/* E21B68 802B72F8 96060000 */ lhu $a2, ($s0) -/* E21B6C 802B72FC 00A0202D */ daddu $a0, $a1, $zero -/* E21B70 802B7300 24A50008 */ addiu $a1, $a1, 8 -/* E21B74 802B7304 AC820000 */ sw $v0, ($a0) -/* E21B78 802B7308 30C2FFFF */ andi $v0, $a2, 0xffff -/* E21B7C 802B730C 00021180 */ sll $v0, $v0, 6 -/* E21B80 802B7310 8E230000 */ lw $v1, ($s1) -/* E21B84 802B7314 00521021 */ addu $v0, $v0, $s2 -/* E21B88 802B7318 00621821 */ addu $v1, $v1, $v0 -/* E21B8C 802B731C AC830004 */ sw $v1, 4($a0) -/* E21B90 802B7320 3C038007 */ lui $v1, %hi(gGameStatusPtr) -/* E21B94 802B7324 8C63419C */ lw $v1, %lo(gGameStatusPtr)($v1) -/* E21B98 802B7328 3C02DE00 */ lui $v0, 0xde00 -/* E21B9C 802B732C ACA20000 */ sw $v0, ($a1) -/* E21BA0 802B7330 3C02802B */ lui $v0, %hi(D_802B7CA0_E22510) -/* E21BA4 802B7334 24427CA0 */ addiu $v0, $v0, %lo(D_802B7CA0_E22510) -/* E21BA8 802B7338 ACA20004 */ sw $v0, 4($a1) -/* E21BAC 802B733C 9462008C */ lhu $v0, 0x8c($v1) -/* E21BB0 802B7340 24C60001 */ addiu $a2, $a2, 1 -/* E21BB4 802B7344 ACE50000 */ sw $a1, ($a3) -/* E21BB8 802B7348 00021400 */ sll $v0, $v0, 0x10 -/* E21BBC 802B734C 00022403 */ sra $a0, $v0, 0x10 -/* E21BC0 802B7350 00880018 */ mult $a0, $t0 -/* E21BC4 802B7354 24A50008 */ addiu $a1, $a1, 8 -/* E21BC8 802B7358 A6060000 */ sh $a2, ($s0) -/* E21BCC 802B735C 000217C3 */ sra $v0, $v0, 0x1f -/* E21BD0 802B7360 00004810 */ mfhi $t1 -/* E21BD4 802B7364 01241821 */ addu $v1, $t1, $a0 -/* E21BD8 802B7368 00031883 */ sra $v1, $v1, 2 -/* E21BDC 802B736C 00621823 */ subu $v1, $v1, $v0 -/* E21BE0 802B7370 000310C0 */ sll $v0, $v1, 3 -/* E21BE4 802B7374 00431023 */ subu $v0, $v0, $v1 -/* E21BE8 802B7378 00822023 */ subu $a0, $a0, $v0 -/* E21BEC 802B737C 00042400 */ sll $a0, $a0, 0x10 -/* E21BF0 802B7380 00042403 */ sra $a0, $a0, 0x10 -/* E21BF4 802B7384 2484FFFE */ addiu $a0, $a0, -2 -/* E21BF8 802B7388 04820001 */ bltzl $a0, .L802B7390 -/* E21BFC 802B738C 00042023 */ negu $a0, $a0 -.L802B7390: -/* E21C00 802B7390 00031C00 */ sll $v1, $v1, 0x10 -/* E21C04 802B7394 00031C03 */ sra $v1, $v1, 0x10 -/* E21C08 802B7398 00832021 */ addu $a0, $a0, $v1 -/* E21C0C 802B739C 2C820006 */ sltiu $v0, $a0, 6 -/* E21C10 802B73A0 10400013 */ beqz $v0, .L802B73F0 -/* E21C14 802B73A4 ACE50000 */ sw $a1, ($a3) -/* E21C18 802B73A8 00041080 */ sll $v0, $a0, 2 -/* E21C1C 802B73AC 3C01802B */ lui $at, %hi(jtbl_802B7D20_E22590) -/* E21C20 802B73B0 00220821 */ addu $at, $at, $v0 -/* E21C24 802B73B4 8C227D20 */ lw $v0, %lo(jtbl_802B7D20_E22590)($at) -/* E21C28 802B73B8 00400008 */ jr $v0 -/* E21C2C 802B73BC 00000000 */ nop -.L802B73C0_E21C30: -/* E21C30 802B73C0 080ADCFF */ j .L802B73FC -/* E21C34 802B73C4 24030004 */ addiu $v1, $zero, 4 -.L802B73C8_E21C38: -/* E21C38 802B73C8 080ADCFF */ j .L802B73FC -/* E21C3C 802B73CC 24030008 */ addiu $v1, $zero, 8 -.L802B73D0_E21C40: -/* E21C40 802B73D0 080ADCFF */ j .L802B73FC -/* E21C44 802B73D4 24030010 */ addiu $v1, $zero, 0x10 -.L802B73D8_E21C48: -/* E21C48 802B73D8 080ADCFF */ j .L802B73FC -/* E21C4C 802B73DC 24030020 */ addiu $v1, $zero, 0x20 -.L802B73E0_E21C50: -/* E21C50 802B73E0 080ADCFF */ j .L802B73FC -/* E21C54 802B73E4 24030040 */ addiu $v1, $zero, 0x40 -.L802B73E8_E21C58: -/* E21C58 802B73E8 080ADCFF */ j .L802B73FC -/* E21C5C 802B73EC 24030080 */ addiu $v1, $zero, 0x80 -.L802B73F0: -/* E21C60 802B73F0 8E620000 */ lw $v0, ($s3) -/* E21C64 802B73F4 2403FFFF */ addiu $v1, $zero, -1 -/* E21C68 802B73F8 AC400020 */ sw $zero, 0x20($v0) -.L802B73FC: -/* E21C6C 802B73FC 3C11802B */ lui $s1, %hi(D_802B7C60_E224D0) -/* E21C70 802B7400 26317C60 */ addiu $s1, $s1, %lo(D_802B7C60_E224D0) -/* E21C74 802B7404 04600017 */ bltz $v1, .L802B7464 -/* E21C78 802B7408 AFB1009C */ sw $s1, 0x9c($sp) -/* E21C7C 802B740C 3C10802B */ lui $s0, %hi(D_802B7D18_E22588) -/* E21C80 802B7410 26107D18 */ addiu $s0, $s0, %lo(D_802B7D18_E22588) -/* E21C84 802B7414 8E040000 */ lw $a0, ($s0) -/* E21C88 802B7418 8C820020 */ lw $v0, 0x20($a0) -/* E21C8C 802B741C 24630002 */ addiu $v1, $v1, 2 -/* E21C90 802B7420 24420001 */ addiu $v0, $v0, 1 -/* E21C94 802B7424 AC820020 */ sw $v0, 0x20($a0) -/* E21C98 802B7428 0043102A */ slt $v0, $v0, $v1 -/* E21C9C 802B742C 14400005 */ bnez $v0, .L802B7444 -/* E21CA0 802B7430 00000000 */ nop -/* E21CA4 802B7434 AC800020 */ sw $zero, 0x20($a0) -/* E21CA8 802B7438 2404007D */ addiu $a0, $zero, 0x7d -/* E21CAC 802B743C 0C052736 */ jal sfx_play_sound_at_player -/* E21CB0 802B7440 0000282D */ daddu $a1, $zero, $zero -.L802B7444: -/* E21CB4 802B7444 8E020000 */ lw $v0, ($s0) -/* E21CB8 802B7448 8C420020 */ lw $v0, 0x20($v0) -/* E21CBC 802B744C 28420002 */ slti $v0, $v0, 2 -/* E21CC0 802B7450 50400004 */ beql $v0, $zero, .L802B7464 -/* E21CC4 802B7454 AFB1009C */ sw $s1, 0x9c($sp) -/* E21CC8 802B7458 3C02802B */ lui $v0, %hi(D_802B7C80_E224F0) -/* E21CCC 802B745C 24427C80 */ addiu $v0, $v0, %lo(D_802B7C80_E224F0) -/* E21CD0 802B7460 AFA2009C */ sw $v0, 0x9c($sp) -.L802B7464: -/* E21CD4 802B7464 0000202D */ daddu $a0, $zero, $zero -/* E21CD8 802B7468 27A50098 */ addiu $a1, $sp, 0x98 -/* E21CDC 802B746C 0080302D */ daddu $a2, $a0, $zero -/* E21CE0 802B7470 27A70058 */ addiu $a3, $sp, 0x58 -/* E21CE4 802B7474 3C02802B */ lui $v0, %hi(D_802B7640_E21EB0) -/* E21CE8 802B7478 24427640 */ addiu $v0, $v0, %lo(D_802B7640_E21EB0) -/* E21CEC 802B747C AFA20098 */ sw $v0, 0x98($sp) -/* E21CF0 802B7480 24020038 */ addiu $v0, $zero, 0x38 -/* E21CF4 802B7484 A7A200A0 */ sh $v0, 0xa0($sp) -/* E21CF8 802B7488 A7A200A2 */ sh $v0, 0xa2($sp) -/* E21CFC 802B748C 2402FFE4 */ addiu $v0, $zero, -0x1c -/* E21D00 802B7490 A7A200A4 */ sh $v0, 0xa4($sp) -/* E21D04 802B7494 2402002E */ addiu $v0, $zero, 0x2e -/* E21D08 802B7498 A7A200A6 */ sh $v0, 0xa6($sp) -/* E21D0C 802B749C 240200FF */ addiu $v0, $zero, 0xff -/* E21D10 802B74A0 0C04EBDC */ jal fold_appendGfx_component -/* E21D14 802B74A4 A3A200A8 */ sb $v0, 0xa8($sp) -/* E21D18 802B74A8 3C05D838 */ lui $a1, 0xd838 -/* E21D1C 802B74AC 3C03800A */ lui $v1, %hi(gMasterGfxPos) -/* E21D20 802B74B0 2463A66C */ addiu $v1, $v1, %lo(gMasterGfxPos) -/* E21D24 802B74B4 8C620000 */ lw $v0, ($v1) -/* E21D28 802B74B8 34A50002 */ ori $a1, $a1, 2 -/* E21D2C 802B74BC 0040202D */ daddu $a0, $v0, $zero -/* E21D30 802B74C0 24420008 */ addiu $v0, $v0, 8 -/* E21D34 802B74C4 AC620000 */ sw $v0, ($v1) -/* E21D38 802B74C8 24020040 */ addiu $v0, $zero, 0x40 -/* E21D3C 802B74CC AC850000 */ sw $a1, ($a0) -/* E21D40 802B74D0 AC820004 */ sw $v0, 4($a0) -.L802B74D4: -/* E21D44 802B74D4 8FBF00C0 */ lw $ra, 0xc0($sp) -/* E21D48 802B74D8 8FB300BC */ lw $s3, 0xbc($sp) -/* E21D4C 802B74DC 8FB200B8 */ lw $s2, 0xb8($sp) -/* E21D50 802B74E0 8FB100B4 */ lw $s1, 0xb4($sp) -/* E21D54 802B74E4 8FB000B0 */ lw $s0, 0xb0($sp) -/* E21D58 802B74E8 03E00008 */ jr $ra -/* E21D5C 802B74EC 27BD00C8 */ addiu $sp, $sp, 0xc8 diff --git a/ver/us/asm/nonmatchings/E21870/func_802B74F0.s b/ver/us/asm/nonmatchings/E21870/func_802B74F0.s deleted file mode 100644 index 81b960fb1e..0000000000 --- a/ver/us/asm/nonmatchings/E21870/func_802B74F0.s +++ /dev/null @@ -1,95 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_802B74F0 -/* E21D60 802B74F0 27BDFFE0 */ addiu $sp, $sp, -0x20 -/* E21D64 802B74F4 AFB00010 */ sw $s0, 0x10($sp) -/* E21D68 802B74F8 3C108011 */ lui $s0, %hi(gPlayerStatus) -/* E21D6C 802B74FC 2610EFC8 */ addiu $s0, $s0, %lo(gPlayerStatus) -/* E21D70 802B7500 AFB10014 */ sw $s1, 0x14($sp) -/* E21D74 802B7504 3C11802B */ lui $s1, %hi(D_802B7D18_E22588) -/* E21D78 802B7508 26317D18 */ addiu $s1, $s1, %lo(D_802B7D18_E22588) -/* E21D7C 802B750C AFBF0018 */ sw $ra, 0x18($sp) -/* E21D80 802B7510 860200B0 */ lh $v0, 0xb0($s0) -/* E21D84 802B7514 C600002C */ lwc1 $f0, 0x2c($s0) -/* E21D88 802B7518 44821000 */ mtc1 $v0, $f2 -/* E21D8C 802B751C 00000000 */ nop -/* E21D90 802B7520 468010A0 */ cvt.s.w $f2, $f2 -/* E21D94 802B7524 46020000 */ add.s $f0, $f0, $f2 -/* E21D98 802B7528 3C014120 */ lui $at, 0x4120 -/* E21D9C 802B752C 44811000 */ mtc1 $at, $f2 -/* E21DA0 802B7530 8E220000 */ lw $v0, ($s1) -/* E21DA4 802B7534 46020000 */ add.s $f0, $f0, $f2 -/* E21DA8 802B7538 C4420004 */ lwc1 $f2, 4($v0) -/* E21DAC 802B753C 46020001 */ sub.s $f0, $f0, $f2 -/* E21DB0 802B7540 3C013FC0 */ lui $at, 0x3fc0 -/* E21DB4 802B7544 44812000 */ mtc1 $at, $f4 -/* E21DB8 802B7548 00000000 */ nop -/* E21DBC 802B754C 46040003 */ div.s $f0, $f0, $f4 -/* E21DC0 802B7550 46001080 */ add.s $f2, $f2, $f0 -/* E21DC4 802B7554 E4420004 */ swc1 $f2, 4($v0) -/* E21DC8 802B7558 C6000028 */ lwc1 $f0, 0x28($s0) -/* E21DCC 802B755C E4400000 */ swc1 $f0, ($v0) -/* E21DD0 802B7560 C6000030 */ lwc1 $f0, 0x30($s0) -/* E21DD4 802B7564 0C0ADC13 */ jal func_802B704C -/* E21DD8 802B7568 E4400008 */ swc1 $f0, 8($v0) -/* E21DDC 802B756C 14400008 */ bnez $v0, .L802B7590 -/* E21DE0 802B7570 24020001 */ addiu $v0, $zero, 1 -/* E21DE4 802B7574 8E020004 */ lw $v0, 4($s0) -/* E21DE8 802B7578 2403FFBF */ addiu $v1, $zero, -0x41 -/* E21DEC 802B757C 3C018011 */ lui $at, %hi(D_8010C920) -/* E21DF0 802B7580 AC20C920 */ sw $zero, %lo(D_8010C920)($at) -/* E21DF4 802B7584 00431024 */ and $v0, $v0, $v1 -/* E21DF8 802B7588 080ADD8B */ j .L802B762C -/* E21DFC 802B758C AE020004 */ sw $v0, 4($s0) -.L802B7590: -/* E21E00 802B7590 8E240000 */ lw $a0, ($s1) -/* E21E04 802B7594 8C830024 */ lw $v1, 0x24($a0) -/* E21E08 802B7598 10620017 */ beq $v1, $v0, .L802B75F8 -/* E21E0C 802B759C 28620002 */ slti $v0, $v1, 2 -/* E21E10 802B75A0 50400005 */ beql $v0, $zero, .L802B75B8 -/* E21E14 802B75A4 24020002 */ addiu $v0, $zero, 2 -/* E21E18 802B75A8 10600007 */ beqz $v1, .L802B75C8 -/* E21E1C 802B75AC 00000000 */ nop -/* E21E20 802B75B0 080ADD8B */ j .L802B762C -/* E21E24 802B75B4 00000000 */ nop -.L802B75B8: -/* E21E28 802B75B8 10620015 */ beq $v1, $v0, .L802B7610 -/* E21E2C 802B75BC 00000000 */ nop -/* E21E30 802B75C0 080ADD8B */ j .L802B762C -/* E21E34 802B75C4 00000000 */ nop -.L802B75C8: -/* E21E38 802B75C8 8C820018 */ lw $v0, 0x18($a0) -/* E21E3C 802B75CC 0040182D */ daddu $v1, $v0, $zero -/* E21E40 802B75D0 24420001 */ addiu $v0, $v0, 1 -/* E21E44 802B75D4 28630006 */ slti $v1, $v1, 6 -/* E21E48 802B75D8 14600014 */ bnez $v1, .L802B762C -/* E21E4C 802B75DC AC820018 */ sw $v0, 0x18($a0) -/* E21E50 802B75E0 8C820024 */ lw $v0, 0x24($a0) -/* E21E54 802B75E4 3C013EB8 */ lui $at, 0x3eb8 -/* E21E58 802B75E8 342151EC */ ori $at, $at, 0x51ec -/* E21E5C 802B75EC 44810000 */ mtc1 $at, $f0 -/* E21E60 802B75F0 080ADD89 */ j .L802B7624 -/* E21E64 802B75F4 24420001 */ addiu $v0, $v0, 1 -.L802B75F8: -/* E21E68 802B75F8 8C820024 */ lw $v0, 0x24($a0) -/* E21E6C 802B75FC 3C013F11 */ lui $at, 0x3f11 -/* E21E70 802B7600 3421EB85 */ ori $at, $at, 0xeb85 -/* E21E74 802B7604 44810000 */ mtc1 $at, $f0 -/* E21E78 802B7608 080ADD89 */ j .L802B7624 -/* E21E7C 802B760C 24420001 */ addiu $v0, $v0, 1 -.L802B7610: -/* E21E80 802B7610 8C820024 */ lw $v0, 0x24($a0) -/* E21E84 802B7614 3C013F07 */ lui $at, 0x3f07 -/* E21E88 802B7618 3421AE14 */ ori $at, $at, 0xae14 -/* E21E8C 802B761C 44810000 */ mtc1 $at, $f0 -/* E21E90 802B7620 24420001 */ addiu $v0, $v0, 1 -.L802B7624: -/* E21E94 802B7624 E480000C */ swc1 $f0, 0xc($a0) -/* E21E98 802B7628 AC820024 */ sw $v0, 0x24($a0) -.L802B762C: -/* E21E9C 802B762C 8FBF0018 */ lw $ra, 0x18($sp) -/* E21EA0 802B7630 8FB10014 */ lw $s1, 0x14($sp) -/* E21EA4 802B7634 8FB00010 */ lw $s0, 0x10($sp) -/* E21EA8 802B7638 03E00008 */ jr $ra -/* E21EAC 802B763C 27BD0020 */ addiu $sp, $sp, 0x20 diff --git a/ver/us/asm/nonmatchings/a5dd0_len_114e0/mdl_create_model.s b/ver/us/asm/nonmatchings/a5dd0_len_114e0/mdl_create_model.s deleted file mode 100644 index 005b5bd368..0000000000 --- a/ver/us/asm/nonmatchings/a5dd0_len_114e0/mdl_create_model.s +++ /dev/null @@ -1,305 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel mdl_create_model -/* AC90C 8011620C 27BDFFB8 */ addiu $sp, $sp, -0x48 -/* AC910 80116210 AFB40040 */ sw $s4, 0x40($sp) -/* AC914 80116214 0080A02D */ daddu $s4, $a0, $zero -/* AC918 80116218 AFBF0044 */ sw $ra, 0x44($sp) -/* AC91C 8011621C AFB3003C */ sw $s3, 0x3c($sp) -/* AC920 80116220 AFB20038 */ sw $s2, 0x38($sp) -/* AC924 80116224 AFB10034 */ sw $s1, 0x34($sp) -/* AC928 80116228 AFB00030 */ sw $s0, 0x30($sp) -/* AC92C 8011622C 8E920004 */ lw $s2, 4($s4) -/* AC930 80116230 2405005F */ addiu $a1, $zero, 0x5f -/* AC934 80116234 0C0456C3 */ jal get_model_property -/* AC938 80116238 0240202D */ daddu $a0, $s2, $zero -/* AC93C 8011623C 0040802D */ daddu $s0, $v0, $zero -/* AC940 80116240 12000023 */ beqz $s0, .L801162D0 -/* AC944 80116244 0000982D */ daddu $s3, $zero, $zero -/* AC948 80116248 9202000B */ lbu $v0, 0xb($s0) -/* AC94C 8011624C 00028902 */ srl $s1, $v0, 4 -/* AC950 80116250 1220001F */ beqz $s1, .L801162D0 -/* AC954 80116254 0240202D */ daddu $a0, $s2, $zero -/* AC958 80116258 0C0456C3 */ jal get_model_property -/* AC95C 8011625C 24050061 */ addiu $a1, $zero, 0x61 -/* AC960 80116260 0040802D */ daddu $s0, $v0, $zero -/* AC964 80116264 12000019 */ beqz $s0, .L801162CC -/* AC968 80116268 27A20020 */ addiu $v0, $sp, 0x20 -/* AC96C 8011626C C6000008 */ lwc1 $f0, 8($s0) -/* AC970 80116270 C602002C */ lwc1 $f2, 0x2c($s0) -/* AC974 80116274 46020000 */ add.s $f0, $f0, $f2 -/* AC978 80116278 3C013F00 */ lui $at, 0x3f00 -/* AC97C 8011627C 44812000 */ mtc1 $at, $f4 -/* AC980 80116280 00000000 */ nop -/* AC984 80116284 46040002 */ mul.s $f0, $f0, $f4 -/* AC988 80116288 00000000 */ nop -/* AC98C 8011628C C6020044 */ lwc1 $f2, 0x44($s0) -/* AC990 80116290 44050000 */ mfc1 $a1, $f0 -/* AC994 80116294 C6000020 */ lwc1 $f0, 0x20($s0) -/* AC998 80116298 46020000 */ add.s $f0, $f0, $f2 -/* AC99C 8011629C 46040002 */ mul.s $f0, $f0, $f4 -/* AC9A0 801162A0 00000000 */ nop -/* AC9A4 801162A4 44070000 */ mfc1 $a3, $f0 -/* AC9A8 801162A8 3C013F80 */ lui $at, 0x3f80 -/* AC9AC 801162AC 44810000 */ mtc1 $at, $f0 -/* AC9B0 801162B0 AFA20014 */ sw $v0, 0x14($sp) -/* AC9B4 801162B4 E7A00010 */ swc1 $f0, 0x10($sp) -/* AC9B8 801162B8 8E060014 */ lw $a2, 0x14($s0) -/* AC9BC 801162BC 0C01C124 */ jal fx_flame -/* AC9C0 801162C0 2624FFFF */ addiu $a0, $s1, -1 -/* AC9C4 801162C4 08045995 */ j .L80116654 -/* AC9C8 801162C8 00000000 */ nop -.L801162CC: -/* AC9CC 801162CC 0000982D */ daddu $s3, $zero, $zero -.L801162D0: -/* AC9D0 801162D0 3C108015 */ lui $s0, %hi(gCurrentModels) -/* AC9D4 801162D4 261012CC */ addiu $s0, $s0, %lo(gCurrentModels) -/* AC9D8 801162D8 8E030000 */ lw $v1, ($s0) -.L801162DC: -/* AC9DC 801162DC 8C620000 */ lw $v0, ($v1) -/* AC9E0 801162E0 10400005 */ beqz $v0, .L801162F8 -/* AC9E4 801162E4 00000000 */ nop -/* AC9E8 801162E8 26730001 */ addiu $s3, $s3, 1 -/* AC9EC 801162EC 2A620100 */ slti $v0, $s3, 0x100 -/* AC9F0 801162F0 1440FFFA */ bnez $v0, .L801162DC -/* AC9F4 801162F4 24630004 */ addiu $v1, $v1, 4 -.L801162F8: -/* AC9F8 801162F8 0C00AB39 */ jal heap_malloc -/* AC9FC 801162FC 240400B0 */ addiu $a0, $zero, 0xb0 -/* ACA00 80116300 00131880 */ sll $v1, $s3, 2 -/* ACA04 80116304 8E040000 */ lw $a0, ($s0) -/* ACA08 80116308 0040882D */ daddu $s1, $v0, $zero -/* ACA0C 8011630C 00641821 */ addu $v1, $v1, $a0 -/* ACA10 80116310 AC710000 */ sw $s1, ($v1) -/* ACA14 80116314 96820000 */ lhu $v0, ($s4) -/* ACA18 80116318 3C038015 */ lui $v1, %hi(D_80153226) -/* ACA1C 8011631C 94633226 */ lhu $v1, %lo(D_80153226)($v1) -/* ACA20 80116320 34420001 */ ori $v0, $v0, 1 -/* ACA24 80116324 A6230002 */ sh $v1, 2($s1) -/* ACA28 80116328 A6220000 */ sh $v0, ($s1) -/* ACA2C 8011632C 8E820004 */ lw $v0, 4($s4) -/* ACA30 80116330 2405005F */ addiu $a1, $zero, 0x5f -/* ACA34 80116334 AE220008 */ sw $v0, 8($s1) -/* ACA38 80116338 0040902D */ daddu $s2, $v0, $zero -/* ACA3C 8011633C 8E820008 */ lw $v0, 8($s4) -/* ACA40 80116340 0240202D */ daddu $a0, $s2, $zero -/* ACA44 80116344 A22000A7 */ sb $zero, 0xa7($s1) -/* ACA48 80116348 0C0456C3 */ jal get_model_property -/* ACA4C 8011634C AE22000C */ sw $v0, 0xc($s1) -/* ACA50 80116350 0040802D */ daddu $s0, $v0, $zero -/* ACA54 80116354 52000004 */ beql $s0, $zero, .L80116368 -/* ACA58 80116358 A22000A4 */ sb $zero, 0xa4($s1) -/* ACA5C 8011635C 9202000B */ lbu $v0, 0xb($s0) -/* ACA60 80116360 3042000F */ andi $v0, $v0, 0xf -/* ACA64 80116364 A22200A4 */ sb $v0, 0xa4($s1) -.L80116368: -/* ACA68 80116368 A22000A5 */ sb $zero, 0xa5($s1) -/* ACA6C 8011636C 8E430000 */ lw $v1, ($s2) -/* ACA70 80116370 24020005 */ addiu $v0, $zero, 5 -/* ACA74 80116374 10620005 */ beq $v1, $v0, .L8011638C -/* ACA78 80116378 0240202D */ daddu $a0, $s2, $zero -/* ACA7C 8011637C 0C0456C3 */ jal get_model_property -/* ACA80 80116380 2405005C */ addiu $a1, $zero, 0x5c -/* ACA84 80116384 080458E8 */ j .L801163A0 -/* ACA88 80116388 0040802D */ daddu $s0, $v0, $zero -.L8011638C: -/* ACA8C 8011638C 0C0456C3 */ jal get_model_property -/* ACA90 80116390 24050060 */ addiu $a1, $zero, 0x60 -/* ACA94 80116394 0040802D */ daddu $s0, $v0, $zero -/* ACA98 80116398 12000006 */ beqz $s0, .L801163B4 -/* ACA9C 8011639C 2610000C */ addiu $s0, $s0, 0xc -.L801163A0: -/* ACAA0 801163A0 12000005 */ beqz $s0, .L801163B8 -/* ACAA4 801163A4 24020001 */ addiu $v0, $zero, 1 -/* ACAA8 801163A8 9202000B */ lbu $v0, 0xb($s0) -/* ACAAC 801163AC 080458EF */ j .L801163BC -/* ACAB0 801163B0 A22200A6 */ sb $v0, 0xa6($s1) -.L801163B4: -/* ACAB4 801163B4 24020001 */ addiu $v0, $zero, 1 -.L801163B8: -/* ACAB8 801163B8 A22200A6 */ sb $v0, 0xa6($s1) -.L801163BC: -/* ACABC 801163BC 3C028015 */ lui $v0, %hi(mdl_treeIterPos) -/* ACAC0 801163C0 8C423224 */ lw $v0, %lo(mdl_treeIterPos)($v0) -/* ACAC4 801163C4 3C03800A */ lui $v1, %hi(mdl_currentModelTreeNodeInfo) -/* ACAC8 801163C8 8C63A5F4 */ lw $v1, %lo(mdl_currentModelTreeNodeInfo)($v1) -/* ACACC 801163CC 00021080 */ sll $v0, $v0, 2 -/* ACAD0 801163D0 00431021 */ addu $v0, $v0, $v1 -/* ACAD4 801163D4 90420002 */ lbu $v0, 2($v0) -/* ACAD8 801163D8 A22000A9 */ sb $zero, 0xa9($s1) -/* ACADC 801163DC A22200A8 */ sb $v0, 0xa8($s1) -/* ACAE0 801163E0 0C046F85 */ jal is_identity_fixed_mtx -/* ACAE4 801163E4 8E84000C */ lw $a0, 0xc($s4) -/* ACAE8 801163E8 14400021 */ bnez $v0, .L80116470 -/* ACAEC 801163EC 26240018 */ addiu $a0, $s1, 0x18 -/* ACAF0 801163F0 0C00AB39 */ jal heap_malloc -/* ACAF4 801163F4 24040040 */ addiu $a0, $zero, 0x40 -/* ACAF8 801163F8 AE220004 */ sw $v0, 4($s1) -/* ACAFC 801163FC 8E84000C */ lw $a0, 0xc($s4) -/* ACB00 80116400 24830040 */ addiu $v1, $a0, 0x40 -.L80116404: -/* ACB04 80116404 8C880000 */ lw $t0, ($a0) -/* ACB08 80116408 8C890004 */ lw $t1, 4($a0) -/* ACB0C 8011640C 8C8A0008 */ lw $t2, 8($a0) -/* ACB10 80116410 8C8B000C */ lw $t3, 0xc($a0) -/* ACB14 80116414 AC480000 */ sw $t0, ($v0) -/* ACB18 80116418 AC490004 */ sw $t1, 4($v0) -/* ACB1C 8011641C AC4A0008 */ sw $t2, 8($v0) -/* ACB20 80116420 AC4B000C */ sw $t3, 0xc($v0) -/* ACB24 80116424 24840010 */ addiu $a0, $a0, 0x10 -/* ACB28 80116428 1483FFF6 */ bne $a0, $v1, .L80116404 -/* ACB2C 8011642C 24420010 */ addiu $v0, $v0, 0x10 -/* ACB30 80116430 8E220004 */ lw $v0, 4($s1) -/* ACB34 80116434 26230018 */ addiu $v1, $s1, 0x18 -/* ACB38 80116438 24440040 */ addiu $a0, $v0, 0x40 -.L8011643C: -/* ACB3C 8011643C 8C480000 */ lw $t0, ($v0) -/* ACB40 80116440 8C490004 */ lw $t1, 4($v0) -/* ACB44 80116444 8C4A0008 */ lw $t2, 8($v0) -/* ACB48 80116448 8C4B000C */ lw $t3, 0xc($v0) -/* ACB4C 8011644C AC680000 */ sw $t0, ($v1) -/* ACB50 80116450 AC690004 */ sw $t1, 4($v1) -/* ACB54 80116454 AC6A0008 */ sw $t2, 8($v1) -/* ACB58 80116458 AC6B000C */ sw $t3, 0xc($v1) -/* ACB5C 8011645C 24420010 */ addiu $v0, $v0, 0x10 -/* ACB60 80116460 1444FFF6 */ bne $v0, $a0, .L8011643C -/* ACB64 80116464 24630010 */ addiu $v1, $v1, 0x10 -/* ACB68 80116468 08045921 */ j .L80116484 -/* ACB6C 8011646C 00000000 */ nop -.L80116470: -/* ACB70 80116470 0C019D10 */ jal guMtxIdent -/* ACB74 80116474 AE200004 */ sw $zero, 4($s1) -/* ACB78 80116478 96220000 */ lhu $v0, ($s1) -/* ACB7C 8011647C 34422000 */ ori $v0, $v0, 0x2000 -/* ACB80 80116480 A6220000 */ sh $v0, ($s1) -.L80116484: -/* ACB84 80116484 0C019D28 */ jal guMtxIdentF -/* ACB88 80116488 26240058 */ addiu $a0, $s1, 0x58 -/* ACB8C 8011648C AE200010 */ sw $zero, 0x10($s1) -/* ACB90 80116490 0240202D */ daddu $a0, $s2, $zero -/* ACB94 80116494 0C0456C3 */ jal get_model_property -/* ACB98 80116498 24050061 */ addiu $a1, $zero, 0x61 -/* ACB9C 8011649C 0040802D */ daddu $s0, $v0, $zero -/* ACBA0 801164A0 12000017 */ beqz $s0, .L80116500 -/* ACBA4 801164A4 00000000 */ nop -/* ACBA8 801164A8 C6060008 */ lwc1 $f6, 8($s0) -/* ACBAC 801164AC C600002C */ lwc1 $f0, 0x2c($s0) -/* ACBB0 801164B0 46003180 */ add.s $f6, $f6, $f0 -/* ACBB4 801164B4 3C013F00 */ lui $at, 0x3f00 -/* ACBB8 801164B8 44814000 */ mtc1 $at, $f8 -/* ACBBC 801164BC 00000000 */ nop -/* ACBC0 801164C0 46083182 */ mul.s $f6, $f6, $f8 -/* ACBC4 801164C4 00000000 */ nop -/* ACBC8 801164C8 C6040014 */ lwc1 $f4, 0x14($s0) -/* ACBCC 801164CC C6000038 */ lwc1 $f0, 0x38($s0) -/* ACBD0 801164D0 46002100 */ add.s $f4, $f4, $f0 -/* ACBD4 801164D4 46082102 */ mul.s $f4, $f4, $f8 -/* ACBD8 801164D8 00000000 */ nop -/* ACBDC 801164DC C6020044 */ lwc1 $f2, 0x44($s0) -/* ACBE0 801164E0 C6000020 */ lwc1 $f0, 0x20($s0) -/* ACBE4 801164E4 46020000 */ add.s $f0, $f0, $f2 -/* ACBE8 801164E8 46080002 */ mul.s $f0, $f0, $f8 -/* ACBEC 801164EC 00000000 */ nop -/* ACBF0 801164F0 E7A60024 */ swc1 $f6, 0x24($sp) -/* ACBF4 801164F4 E7A40028 */ swc1 $f4, 0x28($sp) -/* ACBF8 801164F8 08045945 */ j .L80116514 -/* ACBFC 801164FC E7A0002C */ swc1 $f0, 0x2c($sp) -.L80116500: -/* ACC00 80116500 44800000 */ mtc1 $zero, $f0 -/* ACC04 80116504 00000000 */ nop -/* ACC08 80116508 E7A0002C */ swc1 $f0, 0x2c($sp) -/* ACC0C 8011650C E7A00028 */ swc1 $f0, 0x28($sp) -/* ACC10 80116510 E7A00024 */ swc1 $f0, 0x24($sp) -.L80116514: -/* ACC14 80116514 8E220004 */ lw $v0, 4($s1) -/* ACC18 80116518 1040000F */ beqz $v0, .L80116558 -/* ACC1C 8011651C 27A20024 */ addiu $v0, $sp, 0x24 -/* ACC20 80116520 C7A00024 */ lwc1 $f0, 0x24($sp) -/* ACC24 80116524 C7A20028 */ lwc1 $f2, 0x28($sp) -/* ACC28 80116528 C7A4002C */ lwc1 $f4, 0x2c($sp) -/* ACC2C 8011652C AFA20010 */ sw $v0, 0x10($sp) -/* ACC30 80116530 27A20028 */ addiu $v0, $sp, 0x28 -/* ACC34 80116534 AFA20014 */ sw $v0, 0x14($sp) -/* ACC38 80116538 27A2002C */ addiu $v0, $sp, 0x2c -/* ACC3C 8011653C AFA20018 */ sw $v0, 0x18($sp) -/* ACC40 80116540 8E240004 */ lw $a0, 4($s1) -/* ACC44 80116544 44050000 */ mfc1 $a1, $f0 -/* ACC48 80116548 44061000 */ mfc1 $a2, $f2 -/* ACC4C 8011654C 44072000 */ mfc1 $a3, $f4 -/* ACC50 80116550 0C019E78 */ jal guMtxXFML -/* ACC54 80116554 00000000 */ nop -.L80116558: -/* ACC58 80116558 C7A00024 */ lwc1 $f0, 0x24($sp) -/* ACC5C 8011655C C7A20028 */ lwc1 $f2, 0x28($sp) -/* ACC60 80116560 C7A4002C */ lwc1 $f4, 0x2c($sp) -/* ACC64 80116564 E6200098 */ swc1 $f0, 0x98($s1) -/* ACC68 80116568 E622009C */ swc1 $f2, 0x9c($s1) -/* ACC6C 8011656C E62400A0 */ swc1 $f4, 0xa0($s1) -/* ACC70 80116570 C602002C */ lwc1 $f2, 0x2c($s0) -/* ACC74 80116574 C6000008 */ lwc1 $f0, 8($s0) -/* ACC78 80116578 46001301 */ sub.s $f12, $f2, $f0 -/* ACC7C 8011657C 3C013FE0 */ lui $at, 0x3fe0 -/* ACC80 80116580 44812800 */ mtc1 $at, $f5 -/* ACC84 80116584 44802000 */ mtc1 $zero, $f4 -/* ACC88 80116588 460061A1 */ cvt.d.s $f6, $f12 -/* ACC8C 8011658C 46243182 */ mul.d $f6, $f6, $f4 -/* ACC90 80116590 00000000 */ nop -/* ACC94 80116594 C6020038 */ lwc1 $f2, 0x38($s0) -/* ACC98 80116598 C6000014 */ lwc1 $f0, 0x14($s0) -/* ACC9C 8011659C 46001281 */ sub.s $f10, $f2, $f0 -/* ACCA0 801165A0 460050A1 */ cvt.d.s $f2, $f10 -/* ACCA4 801165A4 46241082 */ mul.d $f2, $f2, $f4 -/* ACCA8 801165A8 00000000 */ nop -/* ACCAC 801165AC C6080044 */ lwc1 $f8, 0x44($s0) -/* ACCB0 801165B0 C6000020 */ lwc1 $f0, 0x20($s0) -/* ACCB4 801165B4 46004201 */ sub.s $f8, $f8, $f0 -/* ACCB8 801165B8 46004021 */ cvt.d.s $f0, $f8 -/* ACCBC 801165BC 46240002 */ mul.d $f0, $f0, $f4 -/* ACCC0 801165C0 00000000 */ nop -/* ACCC4 801165C4 4620338D */ trunc.w.d $f14, $f6 -/* ACCC8 801165C8 E60E0004 */ swc1 $f14, 4($s0) -/* ACCCC 801165CC 4620138D */ trunc.w.d $f14, $f2 -/* ACCD0 801165D0 E60E0010 */ swc1 $f14, 0x10($s0) -/* ACCD4 801165D4 4620038D */ trunc.w.d $f14, $f0 -/* ACCD8 801165D8 E60E001C */ swc1 $f14, 0x1c($s0) -/* ACCDC 801165DC 8E220004 */ lw $v0, 4($s1) -/* ACCE0 801165E0 E7AC0024 */ swc1 $f12, 0x24($sp) -/* ACCE4 801165E4 E7AA0028 */ swc1 $f10, 0x28($sp) -/* ACCE8 801165E8 14400013 */ bnez $v0, .L80116638 -/* ACCEC 801165EC E7A8002C */ swc1 $f8, 0x2c($sp) -/* ACCF0 801165F0 3C0142C8 */ lui $at, 0x42c8 -/* ACCF4 801165F4 44810000 */ mtc1 $at, $f0 -/* ACCF8 801165F8 00000000 */ nop -/* ACCFC 801165FC 4600603C */ c.lt.s $f12, $f0 -/* ACD00 80116600 00000000 */ nop -/* ACD04 80116604 4500000C */ bc1f .L80116638 -/* ACD08 80116608 00000000 */ nop -/* ACD0C 8011660C 4600503C */ c.lt.s $f10, $f0 -/* ACD10 80116610 00000000 */ nop -/* ACD14 80116614 45000008 */ bc1f .L80116638 -/* ACD18 80116618 00000000 */ nop -/* ACD1C 8011661C 4600403C */ c.lt.s $f8, $f0 -/* ACD20 80116620 00000000 */ nop -/* ACD24 80116624 45000004 */ bc1f .L80116638 -/* ACD28 80116628 00000000 */ nop -/* ACD2C 8011662C 96220000 */ lhu $v0, ($s1) -/* ACD30 80116630 34420200 */ ori $v0, $v0, 0x200 -/* ACD34 80116634 A6220000 */ sh $v0, ($s1) -.L80116638: -/* ACD38 80116638 3C028015 */ lui $v0, %hi(mdl_treeIterPos) -/* ACD3C 8011663C 8C423224 */ lw $v0, %lo(mdl_treeIterPos)($v0) -/* ACD40 80116640 3C03800A */ lui $v1, %hi(mdl_currentModelTreeNodeInfo) -/* ACD44 80116644 8C63A5F4 */ lw $v1, %lo(mdl_currentModelTreeNodeInfo)($v1) -/* ACD48 80116648 00021080 */ sll $v0, $v0, 2 -/* ACD4C 8011664C 00431021 */ addu $v0, $v0, $v1 -/* ACD50 80116650 A0530000 */ sb $s3, ($v0) -.L80116654: -/* ACD54 80116654 8FBF0044 */ lw $ra, 0x44($sp) -/* ACD58 80116658 8FB40040 */ lw $s4, 0x40($sp) -/* ACD5C 8011665C 8FB3003C */ lw $s3, 0x3c($sp) -/* ACD60 80116660 8FB20038 */ lw $s2, 0x38($sp) -/* ACD64 80116664 8FB10034 */ lw $s1, 0x34($sp) -/* ACD68 80116668 8FB00030 */ lw $s0, 0x30($sp) -/* ACD6C 8011666C 03E00008 */ jr $ra -/* ACD70 80116670 27BD0048 */ addiu $sp, $sp, 0x48 diff --git a/ver/us/asm/nonmatchings/audio/28910_len_5090/func_8004E0F4.s b/ver/us/asm/nonmatchings/audio/28910_len_5090/func_8004E0F4.s deleted file mode 100644 index 73f36c5598..0000000000 --- a/ver/us/asm/nonmatchings/audio/28910_len_5090/func_8004E0F4.s +++ /dev/null @@ -1,32 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_8004E0F4 -/* 294F4 8004E0F4 27BDFFE0 */ addiu $sp, $sp, -0x20 -/* 294F8 8004E0F8 AFB10014 */ sw $s1, 0x14($sp) -/* 294FC 8004E0FC 0080882D */ daddu $s1, $a0, $zero -/* 29500 8004E100 AFBF0018 */ sw $ra, 0x18($sp) -/* 29504 8004E104 AFB00010 */ sw $s0, 0x10($sp) -/* 29508 8004E108 8E240000 */ lw $a0, ($s1) -/* 2950C 8004E10C 1080000B */ beqz $a0, .L8004E13C -/* 29510 8004E110 0000802D */ daddu $s0, $zero, $zero -/* 29514 8004E114 0C0135E5 */ jal au_bgm_get_player_with_song_name -/* 29518 8004E118 00000000 */ nop -/* 2951C 8004E11C 50400008 */ beql $v0, $zero, .L8004E140 -/* 29520 8004E120 24100002 */ addiu $s0, $zero, 2 -/* 29524 8004E124 8E250004 */ lw $a1, 4($s1) -/* 29528 8004E128 8E26000C */ lw $a2, 0xc($s1) -/* 2952C 8004E12C 0C014EC1 */ jal func_80053B04 -/* 29530 8004E130 2444002C */ addiu $a0, $v0, 0x2c -/* 29534 8004E134 08013851 */ j .L8004E144 -/* 29538 8004E138 0200102D */ daddu $v0, $s0, $zero -.L8004E13C: -/* 2953C 8004E13C 24100003 */ addiu $s0, $zero, 3 -.L8004E140: -/* 29540 8004E140 0200102D */ daddu $v0, $s0, $zero -.L8004E144: -/* 29544 8004E144 8FBF0018 */ lw $ra, 0x18($sp) -/* 29548 8004E148 8FB10014 */ lw $s1, 0x14($sp) -/* 2954C 8004E14C 8FB00010 */ lw $s0, 0x10($sp) -/* 29550 8004E150 03E00008 */ jr $ra -/* 29554 8004E154 27BD0020 */ addiu $sp, $sp, 0x20 diff --git a/ver/us/asm/nonmatchings/battle/action_cmd/power_shock/func_802A9310_42D220.s b/ver/us/asm/nonmatchings/battle/action_cmd/power_shock/func_802A9310_42D220.s deleted file mode 100644 index 5488d2f720..0000000000 --- a/ver/us/asm/nonmatchings/battle/action_cmd/power_shock/func_802A9310_42D220.s +++ /dev/null @@ -1,412 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel jtbl_802A9AC0_42D9D0 -.word .L802A9358_42D268, .L802A93D8_42D2E8, .L802A9838_42D748, .L802A9838_42D748, .L802A9838_42D748, .L802A9838_42D748, .L802A9838_42D748, .L802A9838_42D748, .L802A9838_42D748, .L802A9838_42D748, .L802A949C_42D3AC, .L802A950C_42D41C, .L802A97F4_42D704, 0, 0, 0 - -.section .text - -glabel func_802A9310_42D220 -/* 42D220 802A9310 27BDFFE0 */ addiu $sp, $sp, -0x20 -/* 42D224 802A9314 AFB10014 */ sw $s1, 0x14($sp) -/* 42D228 802A9318 3C11802A */ lui $s1, %hi(gActionCommandStatus) -/* 42D22C 802A931C 2631FBE0 */ addiu $s1, $s1, %lo(gActionCommandStatus) -/* 42D230 802A9320 AFBF001C */ sw $ra, 0x1c($sp) -/* 42D234 802A9324 AFB20018 */ sw $s2, 0x18($sp) -/* 42D238 802A9328 AFB00010 */ sw $s0, 0x10($sp) -/* 42D23C 802A932C 8623004C */ lh $v1, 0x4c($s1) -/* 42D240 802A9330 3C12800E */ lui $s2, %hi(gBattleStatus) -/* 42D244 802A9334 2652C070 */ addiu $s2, $s2, %lo(gBattleStatus) -/* 42D248 802A9338 2C62000D */ sltiu $v0, $v1, 0xd -/* 42D24C 802A933C 1040013F */ beqz $v0, .L802A983C -/* 42D250 802A9340 00031080 */ sll $v0, $v1, 2 -/* 42D254 802A9344 3C01802B */ lui $at, %hi(jtbl_802A9AC0_42D9D0) -/* 42D258 802A9348 00220821 */ addu $at, $at, $v0 -/* 42D25C 802A934C 8C229AC0 */ lw $v0, %lo(jtbl_802A9AC0_42D9D0)($at) -/* 42D260 802A9350 00400008 */ jr $v0 -/* 42D264 802A9354 00000000 */ nop -.L802A9358_42D268: -/* 42D268 802A9358 0C093EB1 */ jal btl_set_popup_duration -/* 42D26C 802A935C 24040063 */ addiu $a0, $zero, 0x63 -/* 42D270 802A9360 82220061 */ lb $v0, 0x61($s1) -/* 42D274 802A9364 8E300004 */ lw $s0, 4($s1) -/* 42D278 802A9368 10400004 */ beqz $v0, .L802A937C -/* 42D27C 802A936C 0200202D */ daddu $a0, $s0, $zero -/* 42D280 802A9370 0C05128B */ jal hud_element_clear_flags -/* 42D284 802A9374 24050002 */ addiu $a1, $zero, 2 -/* 42D288 802A9378 0200202D */ daddu $a0, $s0, $zero -.L802A937C: -/* 42D28C 802A937C 0C0513AC */ jal hud_element_set_alpha -/* 42D290 802A9380 240500FF */ addiu $a1, $zero, 0xff -/* 42D294 802A9384 8E300008 */ lw $s0, 8($s1) -/* 42D298 802A9388 240500FF */ addiu $a1, $zero, 0xff -/* 42D29C 802A938C 0C0513AC */ jal hud_element_set_alpha -/* 42D2A0 802A9390 0200202D */ daddu $a0, $s0, $zero -/* 42D2A4 802A9394 82220061 */ lb $v0, 0x61($s1) -/* 42D2A8 802A9398 10400003 */ beqz $v0, .L802A93A8 -/* 42D2AC 802A939C 0200202D */ daddu $a0, $s0, $zero -/* 42D2B0 802A93A0 0C05128B */ jal hud_element_clear_flags -/* 42D2B4 802A93A4 24050002 */ addiu $a1, $zero, 2 -.L802A93A8: -/* 42D2B8 802A93A8 8E300014 */ lw $s0, 0x14($s1) -/* 42D2BC 802A93AC 240500FF */ addiu $a1, $zero, 0xff -/* 42D2C0 802A93B0 0C0513AC */ jal hud_element_set_alpha -/* 42D2C4 802A93B4 0200202D */ daddu $a0, $s0, $zero -/* 42D2C8 802A93B8 82220061 */ lb $v0, 0x61($s1) -/* 42D2CC 802A93BC 10400003 */ beqz $v0, .L802A93CC -/* 42D2D0 802A93C0 0200202D */ daddu $a0, $s0, $zero -/* 42D2D4 802A93C4 0C05128B */ jal hud_element_clear_flags -/* 42D2D8 802A93C8 24050002 */ addiu $a1, $zero, 2 -.L802A93CC: -/* 42D2DC 802A93CC 24020001 */ addiu $v0, $zero, 1 -/* 42D2E0 802A93D0 080AA60E */ j .L802A9838_42D748 -/* 42D2E4 802A93D4 A622004C */ sh $v0, 0x4c($s1) -.L802A93D8_42D2E8: -/* 42D2E8 802A93D8 0C093EB1 */ jal btl_set_popup_duration -/* 42D2EC 802A93DC 24040063 */ addiu $a0, $zero, 0x63 -/* 42D2F0 802A93E0 8622006C */ lh $v0, 0x6c($s1) -/* 42D2F4 802A93E4 9623006C */ lhu $v1, 0x6c($s1) -/* 42D2F8 802A93E8 10400003 */ beqz $v0, .L802A93F8 -/* 42D2FC 802A93EC 2462FFFF */ addiu $v0, $v1, -1 -/* 42D300 802A93F0 080AA60E */ j .L802A9838_42D748 -/* 42D304 802A93F4 A622006C */ sh $v0, 0x6c($s1) -.L802A93F8: -/* 42D308 802A93F8 96220056 */ lhu $v0, 0x56($s1) -/* 42D30C 802A93FC 24420014 */ addiu $v0, $v0, 0x14 -/* 42D310 802A9400 A6220056 */ sh $v0, 0x56($s1) -/* 42D314 802A9404 00021400 */ sll $v0, $v0, 0x10 -/* 42D318 802A9408 00021403 */ sra $v0, $v0, 0x10 -/* 42D31C 802A940C 28420033 */ slti $v0, $v0, 0x33 -/* 42D320 802A9410 14400002 */ bnez $v0, .L802A941C -/* 42D324 802A9414 24020032 */ addiu $v0, $zero, 0x32 -/* 42D328 802A9418 A6220056 */ sh $v0, 0x56($s1) -.L802A941C: -/* 42D32C 802A941C 8E240004 */ lw $a0, 4($s1) -/* 42D330 802A9420 86250056 */ lh $a1, 0x56($s1) -/* 42D334 802A9424 0C051261 */ jal hud_element_set_render_pos -/* 42D338 802A9428 86260058 */ lh $a2, 0x58($s1) -/* 42D33C 802A942C 8E240008 */ lw $a0, 8($s1) -/* 42D340 802A9430 86260058 */ lh $a2, 0x58($s1) -/* 42D344 802A9434 86250056 */ lh $a1, 0x56($s1) -/* 42D348 802A9438 0C051261 */ jal hud_element_set_render_pos -/* 42D34C 802A943C 24C6001C */ addiu $a2, $a2, 0x1c -/* 42D350 802A9440 3C0451EB */ lui $a0, 0x51eb -/* 42D354 802A9444 3484851F */ ori $a0, $a0, 0x851f -/* 42D358 802A9448 24020064 */ addiu $v0, $zero, 0x64 -/* 42D35C 802A944C 86230046 */ lh $v1, 0x46($s1) -/* 42D360 802A9450 86260058 */ lh $a2, 0x58($s1) -/* 42D364 802A9454 00432823 */ subu $a1, $v0, $v1 -/* 42D368 802A9458 00051100 */ sll $v0, $a1, 4 -/* 42D36C 802A945C 00451023 */ subu $v0, $v0, $a1 -/* 42D370 802A9460 00021080 */ sll $v0, $v0, 2 -/* 42D374 802A9464 00440018 */ mult $v0, $a0 -/* 42D378 802A9468 24C60011 */ addiu $a2, $a2, 0x11 -/* 42D37C 802A946C 000217C3 */ sra $v0, $v0, 0x1f -/* 42D380 802A9470 2405001D */ addiu $a1, $zero, 0x1d -/* 42D384 802A9474 8E240014 */ lw $a0, 0x14($s1) -/* 42D388 802A9478 00004810 */ mfhi $t1 -/* 42D38C 802A947C 00091943 */ sra $v1, $t1, 5 -/* 42D390 802A9480 00621823 */ subu $v1, $v1, $v0 -/* 42D394 802A9484 86220056 */ lh $v0, 0x56($s1) -/* 42D398 802A9488 00A32823 */ subu $a1, $a1, $v1 -/* 42D39C 802A948C 0C051261 */ jal hud_element_set_render_pos -/* 42D3A0 802A9490 00452823 */ subu $a1, $v0, $a1 -/* 42D3A4 802A9494 080AA60E */ j .L802A9838_42D748 -/* 42D3A8 802A9498 00000000 */ nop -.L802A949C_42D3AC: -/* 42D3AC 802A949C 0C093EB1 */ jal btl_set_popup_duration -/* 42D3B0 802A94A0 24040063 */ addiu $a0, $zero, 0x63 -/* 42D3B4 802A94A4 8622004E */ lh $v0, 0x4e($s1) -/* 42D3B8 802A94A8 9623004E */ lhu $v1, 0x4e($s1) -/* 42D3BC 802A94AC 10400003 */ beqz $v0, .L802A94BC -/* 42D3C0 802A94B0 2462FFFF */ addiu $v0, $v1, -1 -/* 42D3C4 802A94B4 080AA60E */ j .L802A9838_42D748 -/* 42D3C8 802A94B8 A622004E */ sh $v0, 0x4e($s1) -.L802A94BC: -/* 42D3CC 802A94BC 8E240004 */ lw $a0, 4($s1) -/* 42D3D0 802A94C0 3C058011 */ lui $a1, %hi(HES_MashAButton) -/* 42D3D4 802A94C4 24A58B80 */ addiu $a1, $a1, %lo(HES_MashAButton) -/* 42D3D8 802A94C8 0C0511FF */ jal hud_element_set_script -/* 42D3DC 802A94CC 00000000 */ nop -/* 42D3E0 802A94D0 3C048000 */ lui $a0, 0x8000 -/* 42D3E4 802A94D4 34840041 */ ori $a0, $a0, 0x41 -/* 42D3E8 802A94D8 0000282D */ daddu $a1, $zero, $zero -/* 42D3EC 802A94DC 00A0302D */ daddu $a2, $a1, $zero -/* 42D3F0 802A94E0 00A0382D */ daddu $a3, $a1, $zero -/* 42D3F4 802A94E4 96220052 */ lhu $v0, 0x52($s1) -/* 42D3F8 802A94E8 24030001 */ addiu $v1, $zero, 1 -/* 42D3FC 802A94EC A6200044 */ sh $zero, 0x44($s1) -/* 42D400 802A94F0 A220005C */ sb $zero, 0x5c($s1) -/* 42D404 802A94F4 3C01802B */ lui $at, %hi(D_802A9B00) -/* 42D408 802A94F8 AC239B00 */ sw $v1, %lo(D_802A9B00)($at) -/* 42D40C 802A94FC 0C0526AE */ jal sfx_play_sound_with_params -/* 42D410 802A9500 A6220054 */ sh $v0, 0x54($s1) -/* 42D414 802A9504 2402000B */ addiu $v0, $zero, 0xb -/* 42D418 802A9508 A622004C */ sh $v0, 0x4c($s1) -.L802A950C_42D41C: -/* 42D41C 802A950C 0C093EB1 */ jal btl_set_popup_duration -/* 42D420 802A9510 24040063 */ addiu $a0, $zero, 0x63 -/* 42D424 802A9514 86220068 */ lh $v0, 0x68($s1) -/* 42D428 802A9518 14400027 */ bnez $v0, .L802A95B8 -/* 42D42C 802A951C 00000000 */ nop -/* 42D430 802A9520 86220064 */ lh $v0, 0x64($s1) -/* 42D434 802A9524 1040001E */ beqz $v0, .L802A95A0 -/* 42D438 802A9528 00000000 */ nop -/* 42D43C 802A952C 82220080 */ lb $v0, 0x80($s1) -/* 42D440 802A9530 00021040 */ sll $v0, $v0, 1 -/* 42D444 802A9534 02221021 */ addu $v0, $s1, $v0 -/* 42D448 802A9538 84430074 */ lh $v1, 0x74($v0) -/* 42D44C 802A953C 86220044 */ lh $v0, 0x44($s1) -/* 42D450 802A9540 14600002 */ bnez $v1, .L802A954C -/* 42D454 802A9544 0043001A */ div $zero, $v0, $v1 -/* 42D458 802A9548 0007000D */ break 7 -.L802A954C: -/* 42D45C 802A954C 2401FFFF */ addiu $at, $zero, -1 -/* 42D460 802A9550 14610004 */ bne $v1, $at, .L802A9564 -/* 42D464 802A9554 3C018000 */ lui $at, 0x8000 -/* 42D468 802A9558 14410002 */ bne $v0, $at, .L802A9564 -/* 42D46C 802A955C 00000000 */ nop -/* 42D470 802A9560 0006000D */ break 6 -.L802A9564: -/* 42D474 802A9564 00001012 */ mflo $v0 -/* 42D478 802A9568 3C036666 */ lui $v1, 0x6666 -/* 42D47C 802A956C 34636667 */ ori $v1, $v1, 0x6667 -/* 42D480 802A9570 00430018 */ mult $v0, $v1 -/* 42D484 802A9574 000217C3 */ sra $v0, $v0, 0x1f -/* 42D488 802A9578 00001810 */ mfhi $v1 -/* 42D48C 802A957C 000318C3 */ sra $v1, $v1, 3 -/* 42D490 802A9580 00621823 */ subu $v1, $v1, $v0 -/* 42D494 802A9584 00031880 */ sll $v1, $v1, 2 -/* 42D498 802A9588 96220044 */ lhu $v0, 0x44($s1) -/* 42D49C 802A958C 3C01802B */ lui $at, %hi(D_802A9AA0_42D9B0 + 0x2) -/* 42D4A0 802A9590 00230821 */ addu $at, $at, $v1 -/* 42D4A4 802A9594 94239AA2 */ lhu $v1, %lo(D_802A9AA0_42D9B0 + 0x2)($at) -/* 42D4A8 802A9598 080AA56A */ j .L802A95A8 -/* 42D4AC 802A959C 00431023 */ subu $v0, $v0, $v1 -.L802A95A0: -/* 42D4B0 802A95A0 96220044 */ lhu $v0, 0x44($s1) -/* 42D4B4 802A95A4 2442FFF6 */ addiu $v0, $v0, -0xa -.L802A95A8: -/* 42D4B8 802A95A8 A6220044 */ sh $v0, 0x44($s1) -/* 42D4BC 802A95AC 00021400 */ sll $v0, $v0, 0x10 -/* 42D4C0 802A95B0 04420001 */ bltzl $v0, .L802A95B8 -/* 42D4C4 802A95B4 A6200044 */ sh $zero, 0x44($s1) -.L802A95B8: -/* 42D4C8 802A95B8 8E420214 */ lw $v0, 0x214($s2) -/* 42D4CC 802A95BC 30428000 */ andi $v0, $v0, 0x8000 -/* 42D4D0 802A95C0 1040002B */ beqz $v0, .L802A9670 -/* 42D4D4 802A95C4 00000000 */ nop -/* 42D4D8 802A95C8 86250064 */ lh $a1, 0x64($s1) -/* 42D4DC 802A95CC 10A0001F */ beqz $a1, .L802A964C -/* 42D4E0 802A95D0 3C0451EB */ lui $a0, 0x51eb -/* 42D4E4 802A95D4 86220050 */ lh $v0, 0x50($s1) -/* 42D4E8 802A95D8 8E430434 */ lw $v1, 0x434($s2) -/* 42D4EC 802A95DC 00021080 */ sll $v0, $v0, 2 -/* 42D4F0 802A95E0 00431021 */ addu $v0, $v0, $v1 -/* 42D4F4 802A95E4 8C430000 */ lw $v1, ($v0) -/* 42D4F8 802A95E8 3484851F */ ori $a0, $a0, 0x851f -/* 42D4FC 802A95EC 00031040 */ sll $v0, $v1, 1 -/* 42D500 802A95F0 00431021 */ addu $v0, $v0, $v1 -/* 42D504 802A95F4 000210C0 */ sll $v0, $v0, 3 -/* 42D508 802A95F8 00431021 */ addu $v0, $v0, $v1 -/* 42D50C 802A95FC 00021900 */ sll $v1, $v0, 4 -/* 42D510 802A9600 00431021 */ addu $v0, $v0, $v1 -/* 42D514 802A9604 00021040 */ sll $v0, $v0, 1 -/* 42D518 802A9608 00440018 */ mult $v0, $a0 -/* 42D51C 802A960C 000217C3 */ sra $v0, $v0, 0x1f -/* 42D520 802A9610 00001810 */ mfhi $v1 -/* 42D524 802A9614 00031943 */ sra $v1, $v1, 5 -/* 42D528 802A9618 00621823 */ subu $v1, $v1, $v0 -/* 42D52C 802A961C 00650018 */ mult $v1, $a1 -/* 42D530 802A9620 00001812 */ mflo $v1 -/* 42D534 802A9624 00000000 */ nop -/* 42D538 802A9628 00000000 */ nop -/* 42D53C 802A962C 00640018 */ mult $v1, $a0 -/* 42D540 802A9630 00031FC3 */ sra $v1, $v1, 0x1f -/* 42D544 802A9634 00001010 */ mfhi $v0 -/* 42D548 802A9638 00022143 */ sra $a0, $v0, 5 -/* 42D54C 802A963C 96220044 */ lhu $v0, 0x44($s1) -/* 42D550 802A9640 00832823 */ subu $a1, $a0, $v1 -/* 42D554 802A9644 080AA59B */ j .L802A966C -/* 42D558 802A9648 00451021 */ addu $v0, $v0, $a1 -.L802A964C: -/* 42D55C 802A964C 96220044 */ lhu $v0, 0x44($s1) -/* 42D560 802A9650 24420064 */ addiu $v0, $v0, 0x64 -/* 42D564 802A9654 A6220044 */ sh $v0, 0x44($s1) -/* 42D568 802A9658 00021400 */ sll $v0, $v0, 0x10 -/* 42D56C 802A965C 00021403 */ sra $v0, $v0, 0x10 -/* 42D570 802A9660 284201F4 */ slti $v0, $v0, 0x1f4 -/* 42D574 802A9664 14400002 */ bnez $v0, .L802A9670 -/* 42D578 802A9668 240201F4 */ addiu $v0, $zero, 0x1f4 -.L802A966C: -/* 42D57C 802A966C A6220044 */ sh $v0, 0x44($s1) -.L802A9670: -/* 42D580 802A9670 86220044 */ lh $v0, 0x44($s1) -/* 42D584 802A9674 28422711 */ slti $v0, $v0, 0x2711 -/* 42D588 802A9678 14400010 */ bnez $v0, .L802A96BC -/* 42D58C 802A967C 3C1051EB */ lui $s0, 0x51eb -/* 42D590 802A9680 8E300010 */ lw $s0, 0x10($s1) -/* 42D594 802A9684 86250056 */ lh $a1, 0x56($s1) -/* 42D598 802A9688 86260058 */ lh $a2, 0x58($s1) -/* 42D59C 802A968C 24022710 */ addiu $v0, $zero, 0x2710 -/* 42D5A0 802A9690 A6220044 */ sh $v0, 0x44($s1) -/* 42D5A4 802A9694 24020001 */ addiu $v0, $zero, 1 -/* 42D5A8 802A9698 A6220068 */ sh $v0, 0x68($s1) -/* 42D5AC 802A969C 0200202D */ daddu $a0, $s0, $zero -/* 42D5B0 802A96A0 24A50032 */ addiu $a1, $a1, 0x32 -/* 42D5B4 802A96A4 0C051261 */ jal hud_element_set_render_pos -/* 42D5B8 802A96A8 24C6001C */ addiu $a2, $a2, 0x1c -/* 42D5BC 802A96AC 0200202D */ daddu $a0, $s0, $zero -/* 42D5C0 802A96B0 0C05128B */ jal hud_element_clear_flags -/* 42D5C4 802A96B4 24050002 */ addiu $a1, $zero, 2 -/* 42D5C8 802A96B8 3C1051EB */ lui $s0, 0x51eb -.L802A96BC: -/* 42D5CC 802A96BC 3610851F */ ori $s0, $s0, 0x851f -/* 42D5D0 802A96C0 96230044 */ lhu $v1, 0x44($s1) -/* 42D5D4 802A96C4 3C048000 */ lui $a0, 0x8000 -/* 42D5D8 802A96C8 00031C00 */ sll $v1, $v1, 0x10 -/* 42D5DC 802A96CC 00031403 */ sra $v0, $v1, 0x10 -/* 42D5E0 802A96D0 00500018 */ mult $v0, $s0 -/* 42D5E4 802A96D4 34840041 */ ori $a0, $a0, 0x41 -/* 42D5E8 802A96D8 0000282D */ daddu $a1, $zero, $zero -/* 42D5EC 802A96DC 00A0302D */ daddu $a2, $a1, $zero -/* 42D5F0 802A96E0 00031FC3 */ sra $v1, $v1, 0x1f -/* 42D5F4 802A96E4 00004810 */ mfhi $t1 -/* 42D5F8 802A96E8 00094143 */ sra $t0, $t1, 5 -/* 42D5FC 802A96EC 01034023 */ subu $t0, $t0, $v1 -/* 42D600 802A96F0 00081600 */ sll $v0, $t0, 0x18 -/* 42D604 802A96F4 00021603 */ sra $v0, $v0, 0x18 -/* 42D608 802A96F8 00023840 */ sll $a3, $v0, 1 -/* 42D60C 802A96FC 00E23821 */ addu $a3, $a3, $v0 -/* 42D610 802A9700 00073880 */ sll $a3, $a3, 2 -/* 42D614 802A9704 0C0526F9 */ jal sfx_adjust_env_sound_params -/* 42D618 802A9708 A2480084 */ sb $t0, 0x84($s2) -/* 42D61C 802A970C 86220054 */ lh $v0, 0x54($s1) -/* 42D620 802A9710 96230054 */ lhu $v1, 0x54($s1) -/* 42D624 802A9714 14400044 */ bnez $v0, .L802A9828 -/* 42D628 802A9718 2462FFFF */ addiu $v0, $v1, -1 -/* 42D62C 802A971C 86220064 */ lh $v0, 0x64($s1) -/* 42D630 802A9720 86250044 */ lh $a1, 0x44($s1) -/* 42D634 802A9724 50400001 */ beql $v0, $zero, .L802A972C -/* 42D638 802A9728 0000282D */ daddu $a1, $zero, $zero -.L802A972C: -/* 42D63C 802A972C 00B00018 */ mult $a1, $s0 -/* 42D640 802A9730 000517C3 */ sra $v0, $a1, 0x1f -/* 42D644 802A9734 00004810 */ mfhi $t1 -/* 42D648 802A9738 00091943 */ sra $v1, $t1, 5 -/* 42D64C 802A973C 00621023 */ subu $v0, $v1, $v0 -/* 42D650 802A9740 14A00004 */ bnez $a1, .L802A9754 -/* 42D654 802A9744 A2420084 */ sb $v0, 0x84($s2) -/* 42D658 802A9748 2402FFFF */ addiu $v0, $zero, -1 -/* 42D65C 802A974C 080AA5DD */ j .L802A9774 -/* 42D660 802A9750 A2420081 */ sb $v0, 0x81($s2) -.L802A9754: -/* 42D664 802A9754 00021600 */ sll $v0, $v0, 0x18 -/* 42D668 802A9758 86230046 */ lh $v1, 0x46($s1) -/* 42D66C 802A975C 00021603 */ sra $v0, $v0, 0x18 -/* 42D670 802A9760 0043102A */ slt $v0, $v0, $v1 -/* 42D674 802A9764 54400003 */ bnel $v0, $zero, .L802A9774 -/* 42D678 802A9768 A2400081 */ sb $zero, 0x81($s2) -/* 42D67C 802A976C 24020001 */ addiu $v0, $zero, 1 -/* 42D680 802A9770 A2420081 */ sb $v0, 0x81($s2) -.L802A9774: -/* 42D684 802A9774 82220080 */ lb $v0, 0x80($s1) -/* 42D688 802A9778 2442FFFF */ addiu $v0, $v0, -1 -/* 42D68C 802A977C 00021040 */ sll $v0, $v0, 1 -/* 42D690 802A9780 02221021 */ addu $v0, $s1, $v0 -/* 42D694 802A9784 94420074 */ lhu $v0, 0x74($v0) -/* 42D698 802A9788 00021400 */ sll $v0, $v0, 0x10 -/* 42D69C 802A978C 00021C03 */ sra $v1, $v0, 0x10 -/* 42D6A0 802A9790 000217C2 */ srl $v0, $v0, 0x1f -/* 42D6A4 802A9794 00621021 */ addu $v0, $v1, $v0 -/* 42D6A8 802A9798 82430084 */ lb $v1, 0x84($s2) -/* 42D6AC 802A979C 00021043 */ sra $v0, $v0, 1 -/* 42D6B0 802A97A0 0043102A */ slt $v0, $v0, $v1 -/* 42D6B4 802A97A4 14400002 */ bnez $v0, .L802A97B0 -/* 42D6B8 802A97A8 24020001 */ addiu $v0, $zero, 1 -/* 42D6BC 802A97AC 2402FFFC */ addiu $v0, $zero, -4 -.L802A97B0: -/* 42D6C0 802A97B0 A2420086 */ sb $v0, 0x86($s2) -/* 42D6C4 802A97B4 82430081 */ lb $v1, 0x81($s2) -/* 42D6C8 802A97B8 24020001 */ addiu $v0, $zero, 1 -/* 42D6CC 802A97BC 14620004 */ bne $v1, $v0, .L802A97D0 -/* 42D6D0 802A97C0 3C048000 */ lui $a0, 0x8000 -/* 42D6D4 802A97C4 0C09A458 */ jal func_80269160 -/* 42D6D8 802A97C8 00000000 */ nop -/* 42D6DC 802A97CC 3C048000 */ lui $a0, 0x8000 -.L802A97D0: -/* 42D6E0 802A97D0 0C05271B */ jal sfx_stop_sound -/* 42D6E4 802A97D4 34840041 */ ori $a0, $a0, 0x41 -/* 42D6E8 802A97D8 0C093EB1 */ jal btl_set_popup_duration -/* 42D6EC 802A97DC 0000202D */ daddu $a0, $zero, $zero -/* 42D6F0 802A97E0 24020005 */ addiu $v0, $zero, 5 -/* 42D6F4 802A97E4 A6220054 */ sh $v0, 0x54($s1) -/* 42D6F8 802A97E8 2402000C */ addiu $v0, $zero, 0xc -/* 42D6FC 802A97EC 080AA60E */ j .L802A9838_42D748 -/* 42D700 802A97F0 A622004C */ sh $v0, 0x4c($s1) -.L802A97F4_42D704: -/* 42D704 802A97F4 86220064 */ lh $v0, 0x64($s1) -/* 42D708 802A97F8 14400007 */ bnez $v0, .L802A9818 -/* 42D70C 802A97FC 00000000 */ nop -/* 42D710 802A9800 96220044 */ lhu $v0, 0x44($s1) -/* 42D714 802A9804 2442FF9C */ addiu $v0, $v0, -0x64 -/* 42D718 802A9808 A6220044 */ sh $v0, 0x44($s1) -/* 42D71C 802A980C 00021400 */ sll $v0, $v0, 0x10 -/* 42D720 802A9810 04420001 */ bltzl $v0, .L802A9818 -/* 42D724 802A9814 A6200044 */ sh $zero, 0x44($s1) -.L802A9818: -/* 42D728 802A9818 86220054 */ lh $v0, 0x54($s1) -/* 42D72C 802A981C 96230054 */ lhu $v1, 0x54($s1) -/* 42D730 802A9820 10400003 */ beqz $v0, .L802A9830 -/* 42D734 802A9824 2462FFFF */ addiu $v0, $v1, -1 -.L802A9828: -/* 42D738 802A9828 080AA60E */ j .L802A9838_42D748 -/* 42D73C 802A982C A6220054 */ sh $v0, 0x54($s1) -.L802A9830: -/* 42D740 802A9830 0C09A327 */ jal func_80268C9C -/* 42D744 802A9834 00000000 */ nop -.L802A9838_42D748: -/* 42D748 802A9838 8623004C */ lh $v1, 0x4c($s1) -.L802A983C: -/* 42D74C 802A983C 24040001 */ addiu $a0, $zero, 1 -/* 42D750 802A9840 10640007 */ beq $v1, $a0, .L802A9860 -/* 42D754 802A9844 00000000 */ nop -/* 42D758 802A9848 1860001B */ blez $v1, .L802A98B8 -/* 42D75C 802A984C 2862000C */ slti $v0, $v1, 0xc -/* 42D760 802A9850 10400019 */ beqz $v0, .L802A98B8 -/* 42D764 802A9854 2862000A */ slti $v0, $v1, 0xa -/* 42D768 802A9858 14400017 */ bnez $v0, .L802A98B8 -/* 42D76C 802A985C 00000000 */ nop -.L802A9860: -/* 42D770 802A9860 86220066 */ lh $v0, 0x66($s1) -/* 42D774 802A9864 1440000C */ bnez $v0, .L802A9898 -/* 42D778 802A9868 00000000 */ nop -/* 42D77C 802A986C 96220046 */ lhu $v0, 0x46($s1) -/* 42D780 802A9870 24420007 */ addiu $v0, $v0, 7 -/* 42D784 802A9874 A6220046 */ sh $v0, 0x46($s1) -/* 42D788 802A9878 00021400 */ sll $v0, $v0, 0x10 -/* 42D78C 802A987C 00021403 */ sra $v0, $v0, 0x10 -/* 42D790 802A9880 28420064 */ slti $v0, $v0, 0x64 -/* 42D794 802A9884 1440000C */ bnez $v0, .L802A98B8 -/* 42D798 802A9888 24020064 */ addiu $v0, $zero, 0x64 -/* 42D79C 802A988C A6220046 */ sh $v0, 0x46($s1) -/* 42D7A0 802A9890 080AA62E */ j .L802A98B8 -/* 42D7A4 802A9894 A6240066 */ sh $a0, 0x66($s1) -.L802A9898: -/* 42D7A8 802A9898 96220046 */ lhu $v0, 0x46($s1) -/* 42D7AC 802A989C 2442FFF9 */ addiu $v0, $v0, -7 -/* 42D7B0 802A98A0 A6220046 */ sh $v0, 0x46($s1) -/* 42D7B4 802A98A4 00021400 */ sll $v0, $v0, 0x10 -/* 42D7B8 802A98A8 1C400003 */ bgtz $v0, .L802A98B8 -/* 42D7BC 802A98AC 00000000 */ nop -/* 42D7C0 802A98B0 A6200046 */ sh $zero, 0x46($s1) -/* 42D7C4 802A98B4 A6200066 */ sh $zero, 0x66($s1) -.L802A98B8: -/* 42D7C8 802A98B8 8FBF001C */ lw $ra, 0x1c($sp) -/* 42D7CC 802A98BC 8FB20018 */ lw $s2, 0x18($sp) -/* 42D7D0 802A98C0 8FB10014 */ lw $s1, 0x14($sp) -/* 42D7D4 802A98C4 8FB00010 */ lw $s0, 0x10($sp) -/* 42D7D8 802A98C8 03E00008 */ jr $ra -/* 42D7DC 802A98CC 27BD0020 */ addiu $sp, $sp, 0x20 diff --git a/ver/us/asm/nonmatchings/battle/area_flo2/5CE690/func_80218440_5CEAD0.s b/ver/us/asm/nonmatchings/battle/area_flo2/5CE690/func_80218440_5CEAD0.s deleted file mode 100644 index d7b5cfee37..0000000000 --- a/ver/us/asm/nonmatchings/battle/area_flo2/5CE690/func_80218440_5CEAD0.s +++ /dev/null @@ -1,117 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_80218440_5CEAD0 -/* 5CEAD0 80218440 27BDFFB8 */ addiu $sp, $sp, -0x48 -/* 5CEAD4 80218444 AFB1003C */ sw $s1, 0x3c($sp) -/* 5CEAD8 80218448 0080882D */ daddu $s1, $a0, $zero -/* 5CEADC 8021844C AFBF0040 */ sw $ra, 0x40($sp) -/* 5CEAE0 80218450 AFB00038 */ sw $s0, 0x38($sp) -/* 5CEAE4 80218454 8E30000C */ lw $s0, 0xc($s1) -/* 5CEAE8 80218458 8E050000 */ lw $a1, ($s0) -/* 5CEAEC 8021845C 0C0B1EAF */ jal evt_get_variable -/* 5CEAF0 80218460 26100004 */ addiu $s0, $s0, 4 -/* 5CEAF4 80218464 0040282D */ daddu $a1, $v0, $zero -/* 5CEAF8 80218468 30A20002 */ andi $v0, $a1, 2 -/* 5CEAFC 8021846C 14400004 */ bnez $v0, .L80218480 -/* 5CEB00 80218470 0000202D */ daddu $a0, $zero, $zero -/* 5CEB04 80218474 24020002 */ addiu $v0, $zero, 2 -/* 5CEB08 80218478 AFA20010 */ sw $v0, 0x10($sp) -/* 5CEB0C 8021847C 24040001 */ addiu $a0, $zero, 1 -.L80218480: -/* 5CEB10 80218480 30A20008 */ andi $v0, $a1, 8 -/* 5CEB14 80218484 14400007 */ bnez $v0, .L802184A4 -/* 5CEB18 80218488 30A20020 */ andi $v0, $a1, 0x20 -/* 5CEB1C 8021848C 00041080 */ sll $v0, $a0, 2 -/* 5CEB20 80218490 03A21821 */ addu $v1, $sp, $v0 -/* 5CEB24 80218494 24020008 */ addiu $v0, $zero, 8 -/* 5CEB28 80218498 AC620010 */ sw $v0, 0x10($v1) -/* 5CEB2C 8021849C 24840001 */ addiu $a0, $a0, 1 -/* 5CEB30 802184A0 30A20020 */ andi $v0, $a1, 0x20 -.L802184A4: -/* 5CEB34 802184A4 14400007 */ bnez $v0, .L802184C4 -/* 5CEB38 802184A8 30A20080 */ andi $v0, $a1, 0x80 -/* 5CEB3C 802184AC 00041080 */ sll $v0, $a0, 2 -/* 5CEB40 802184B0 03A21821 */ addu $v1, $sp, $v0 -/* 5CEB44 802184B4 24020020 */ addiu $v0, $zero, 0x20 -/* 5CEB48 802184B8 AC620010 */ sw $v0, 0x10($v1) -/* 5CEB4C 802184BC 24840001 */ addiu $a0, $a0, 1 -/* 5CEB50 802184C0 30A20080 */ andi $v0, $a1, 0x80 -.L802184C4: -/* 5CEB54 802184C4 14400007 */ bnez $v0, .L802184E4 -/* 5CEB58 802184C8 30A20200 */ andi $v0, $a1, 0x200 -/* 5CEB5C 802184CC 00041080 */ sll $v0, $a0, 2 -/* 5CEB60 802184D0 03A21821 */ addu $v1, $sp, $v0 -/* 5CEB64 802184D4 24020080 */ addiu $v0, $zero, 0x80 -/* 5CEB68 802184D8 AC620010 */ sw $v0, 0x10($v1) -/* 5CEB6C 802184DC 24840001 */ addiu $a0, $a0, 1 -/* 5CEB70 802184E0 30A20200 */ andi $v0, $a1, 0x200 -.L802184E4: -/* 5CEB74 802184E4 14400007 */ bnez $v0, .L80218504 -/* 5CEB78 802184E8 30A20001 */ andi $v0, $a1, 1 -/* 5CEB7C 802184EC 00041080 */ sll $v0, $a0, 2 -/* 5CEB80 802184F0 03A21821 */ addu $v1, $sp, $v0 -/* 5CEB84 802184F4 24020200 */ addiu $v0, $zero, 0x200 -/* 5CEB88 802184F8 AC620010 */ sw $v0, 0x10($v1) -/* 5CEB8C 802184FC 24840001 */ addiu $a0, $a0, 1 -/* 5CEB90 80218500 30A20001 */ andi $v0, $a1, 1 -.L80218504: -/* 5CEB94 80218504 14400007 */ bnez $v0, .L80218524 -/* 5CEB98 80218508 30A20004 */ andi $v0, $a1, 4 -/* 5CEB9C 8021850C 00041080 */ sll $v0, $a0, 2 -/* 5CEBA0 80218510 03A21821 */ addu $v1, $sp, $v0 -/* 5CEBA4 80218514 24020001 */ addiu $v0, $zero, 1 -/* 5CEBA8 80218518 AC620010 */ sw $v0, 0x10($v1) -/* 5CEBAC 8021851C 00822021 */ addu $a0, $a0, $v0 -/* 5CEBB0 80218520 30A20004 */ andi $v0, $a1, 4 -.L80218524: -/* 5CEBB4 80218524 14400007 */ bnez $v0, .L80218544 -/* 5CEBB8 80218528 30A20010 */ andi $v0, $a1, 0x10 -/* 5CEBBC 8021852C 00041080 */ sll $v0, $a0, 2 -/* 5CEBC0 80218530 03A21821 */ addu $v1, $sp, $v0 -/* 5CEBC4 80218534 24020004 */ addiu $v0, $zero, 4 -/* 5CEBC8 80218538 AC620010 */ sw $v0, 0x10($v1) -/* 5CEBCC 8021853C 24840001 */ addiu $a0, $a0, 1 -/* 5CEBD0 80218540 30A20010 */ andi $v0, $a1, 0x10 -.L80218544: -/* 5CEBD4 80218544 14400005 */ bnez $v0, .L8021855C -/* 5CEBD8 80218548 00041080 */ sll $v0, $a0, 2 -/* 5CEBDC 8021854C 03A21821 */ addu $v1, $sp, $v0 -/* 5CEBE0 80218550 24020010 */ addiu $v0, $zero, 0x10 -/* 5CEBE4 80218554 AC620010 */ sw $v0, 0x10($v1) -/* 5CEBE8 80218558 24840001 */ addiu $a0, $a0, 1 -.L8021855C: -/* 5CEBEC 8021855C 1480000F */ bnez $a0, .L8021859C -/* 5CEBF0 80218560 30A20100 */ andi $v0, $a1, 0x100 -/* 5CEBF4 80218564 14400005 */ bnez $v0, .L8021857C -/* 5CEBF8 80218568 30A20040 */ andi $v0, $a1, 0x40 -/* 5CEBFC 8021856C 24020100 */ addiu $v0, $zero, 0x100 -/* 5CEC00 80218570 AFA20010 */ sw $v0, 0x10($sp) -/* 5CEC04 80218574 24040001 */ addiu $a0, $zero, 1 -/* 5CEC08 80218578 30A20040 */ andi $v0, $a1, 0x40 -.L8021857C: -/* 5CEC0C 8021857C 14400005 */ bnez $v0, .L80218594 -/* 5CEC10 80218580 00041080 */ sll $v0, $a0, 2 -/* 5CEC14 80218584 03A21821 */ addu $v1, $sp, $v0 -/* 5CEC18 80218588 24020040 */ addiu $v0, $zero, 0x40 -/* 5CEC1C 8021858C AC620010 */ sw $v0, 0x10($v1) -/* 5CEC20 80218590 24840001 */ addiu $a0, $a0, 1 -.L80218594: -/* 5CEC24 80218594 10800006 */ beqz $a0, .L802185B0 -/* 5CEC28 80218598 2406FFFF */ addiu $a2, $zero, -1 -.L8021859C: -/* 5CEC2C 8021859C 0C00A67F */ jal rand_int -/* 5CEC30 802185A0 2484FFFF */ addiu $a0, $a0, -1 -/* 5CEC34 802185A4 00021080 */ sll $v0, $v0, 2 -/* 5CEC38 802185A8 03A21021 */ addu $v0, $sp, $v0 -/* 5CEC3C 802185AC 8C460010 */ lw $a2, 0x10($v0) -.L802185B0: -/* 5CEC40 802185B0 8E050000 */ lw $a1, ($s0) -/* 5CEC44 802185B4 0C0B2026 */ jal evt_set_variable -/* 5CEC48 802185B8 0220202D */ daddu $a0, $s1, $zero -/* 5CEC4C 802185BC 8FBF0040 */ lw $ra, 0x40($sp) -/* 5CEC50 802185C0 8FB1003C */ lw $s1, 0x3c($sp) -/* 5CEC54 802185C4 8FB00038 */ lw $s0, 0x38($sp) -/* 5CEC58 802185C8 24020002 */ addiu $v0, $zero, 2 -/* 5CEC5C 802185CC 03E00008 */ jr $ra -/* 5CEC60 802185D0 27BD0048 */ addiu $sp, $sp, 0x48 diff --git a/ver/us/asm/nonmatchings/battle/area_isk_part_1/4E29B0/b_area_isk_part_1_ChompChainUpdate.s b/ver/us/asm/nonmatchings/battle/area_isk_part_1/4E29B0/b_area_isk_part_1_ChompChainUpdate.s deleted file mode 100644 index 9c012d66cc..0000000000 --- a/ver/us/asm/nonmatchings/battle/area_isk_part_1/4E29B0/b_area_isk_part_1_ChompChainUpdate.s +++ /dev/null @@ -1,280 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel D_80224920_4EF060 -.double 0.2, 0.0 - -.section .text - -glabel b_area_isk_part_1_ChompChainUpdate -/* 4E2C0C 802184CC 27BDFF98 */ addiu $sp, $sp, -0x68 -/* 4E2C10 802184D0 AFBF0038 */ sw $ra, 0x38($sp) -/* 4E2C14 802184D4 AFB50034 */ sw $s5, 0x34($sp) -/* 4E2C18 802184D8 AFB40030 */ sw $s4, 0x30($sp) -/* 4E2C1C 802184DC AFB3002C */ sw $s3, 0x2c($sp) -/* 4E2C20 802184E0 AFB20028 */ sw $s2, 0x28($sp) -/* 4E2C24 802184E4 AFB10024 */ sw $s1, 0x24($sp) -/* 4E2C28 802184E8 AFB00020 */ sw $s0, 0x20($sp) -/* 4E2C2C 802184EC F7BC0060 */ sdc1 $f28, 0x60($sp) -/* 4E2C30 802184F0 F7BA0058 */ sdc1 $f26, 0x58($sp) -/* 4E2C34 802184F4 F7B80050 */ sdc1 $f24, 0x50($sp) -/* 4E2C38 802184F8 F7B60048 */ sdc1 $f22, 0x48($sp) -/* 4E2C3C 802184FC F7B40040 */ sdc1 $f20, 0x40($sp) -/* 4E2C40 80218500 0C09A75B */ jal get_actor -/* 4E2C44 80218504 8C840148 */ lw $a0, 0x148($a0) -/* 4E2C48 80218508 0040882D */ daddu $s1, $v0, $zero -/* 4E2C4C 8021850C 16200003 */ bnez $s1, .L8021851C -/* 4E2C50 80218510 2402000A */ addiu $v0, $zero, 0xa -/* 4E2C54 80218514 0808621E */ j .L80218878 -/* 4E2C58 80218518 0000102D */ daddu $v0, $zero, $zero -.L8021851C: -/* 4E2C5C 8021851C 82230210 */ lb $v1, 0x210($s1) -/* 4E2C60 80218520 8E320078 */ lw $s2, 0x78($s1) -/* 4E2C64 80218524 1462000D */ bne $v1, $v0, .L8021855C -/* 4E2C68 80218528 24150003 */ addiu $s5, $zero, 3 -/* 4E2C6C 8021852C C6220144 */ lwc1 $f2, 0x144($s1) -/* 4E2C70 80218530 3C014018 */ lui $at, 0x4018 -/* 4E2C74 80218534 44810800 */ mtc1 $at, $f1 -/* 4E2C78 80218538 44800000 */ mtc1 $zero, $f0 -/* 4E2C7C 8021853C 460010A1 */ cvt.d.s $f2, $f2 -/* 4E2C80 80218540 46201080 */ add.d $f2, $f2, $f0 -/* 4E2C84 80218544 C6200148 */ lwc1 $f0, 0x148($s1) -/* 4E2C88 80218548 3C014004 */ lui $at, 0x4004 -/* 4E2C8C 8021854C 44812800 */ mtc1 $at, $f5 -/* 4E2C90 80218550 44802000 */ mtc1 $zero, $f4 -/* 4E2C94 80218554 08086162 */ j .L80218588 -/* 4E2C98 80218558 46000021 */ cvt.d.s $f0, $f0 -.L8021855C: -/* 4E2C9C 8021855C C6220144 */ lwc1 $f2, 0x144($s1) -/* 4E2CA0 80218560 3C014028 */ lui $at, 0x4028 -/* 4E2CA4 80218564 44810800 */ mtc1 $at, $f1 -/* 4E2CA8 80218568 44800000 */ mtc1 $zero, $f0 -/* 4E2CAC 8021856C 460010A1 */ cvt.d.s $f2, $f2 -/* 4E2CB0 80218570 46201080 */ add.d $f2, $f2, $f0 -/* 4E2CB4 80218574 C6200148 */ lwc1 $f0, 0x148($s1) -/* 4E2CB8 80218578 3C014014 */ lui $at, 0x4014 -/* 4E2CBC 8021857C 44812800 */ mtc1 $at, $f5 -/* 4E2CC0 80218580 44802000 */ mtc1 $zero, $f4 -/* 4E2CC4 80218584 46000021 */ cvt.d.s $f0, $f0 -.L80218588: -/* 4E2CC8 80218588 46240000 */ add.d $f0, $f0, $f4 -/* 4E2CCC 8021858C 46201520 */ cvt.s.d $f20, $f2 -/* 4E2CD0 80218590 462005A0 */ cvt.s.d $f22, $f0 -/* 4E2CD4 80218594 0000982D */ daddu $s3, $zero, $zero -/* 4E2CD8 80218598 2414000A */ addiu $s4, $zero, 0xa -/* 4E2CDC 8021859C 26500004 */ addiu $s0, $s2, 4 -/* 4E2CE0 802185A0 3C014060 */ lui $at, 0x4060 -/* 4E2CE4 802185A4 4481E000 */ mtc1 $at, $f28 -/* 4E2CE8 802185A8 3C0140E0 */ lui $at, 0x40e0 -/* 4E2CEC 802185AC 4481D000 */ mtc1 $at, $f26 -/* 4E2CF0 802185B0 3C013F80 */ lui $at, 0x3f80 -/* 4E2CF4 802185B4 4481C000 */ mtc1 $at, $f24 -.L802185B8: -/* 4E2CF8 802185B8 82220210 */ lb $v0, 0x210($s1) -/* 4E2CFC 802185BC 54540005 */ bnel $v0, $s4, .L802185D4 -/* 4E2D00 802185C0 E61A0020 */ swc1 $f26, 0x20($s0) -/* 4E2D04 802185C4 E61C0020 */ swc1 $f28, 0x20($s0) -/* 4E2D08 802185C8 E61C0028 */ swc1 $f28, 0x28($s0) -/* 4E2D0C 802185CC 08086177 */ j .L802185DC -/* 4E2D10 802185D0 E61C0024 */ swc1 $f28, 0x24($s0) -.L802185D4: -/* 4E2D14 802185D4 E61A0028 */ swc1 $f26, 0x28($s0) -/* 4E2D18 802185D8 E61A0024 */ swc1 $f26, 0x24($s0) -.L802185DC: -/* 4E2D1C 802185DC C6020014 */ lwc1 $f2, 0x14($s0) -/* 4E2D20 802185E0 C6000010 */ lwc1 $f0, 0x10($s0) -/* 4E2D24 802185E4 46001081 */ sub.s $f2, $f2, $f0 -/* 4E2D28 802185E8 46000007 */ neg.s $f0, $f0 -/* 4E2D2C 802185EC 46000000 */ add.s $f0, $f0, $f0 -/* 4E2D30 802185F0 4600103C */ c.lt.s $f2, $f0 -/* 4E2D34 802185F4 00000000 */ nop -/* 4E2D38 802185F8 4500000D */ bc1f .L80218630 -/* 4E2D3C 802185FC E6020014 */ swc1 $f2, 0x14($s0) -/* 4E2D40 80218600 E6000014 */ swc1 $f0, 0x14($s0) -/* 4E2D44 80218604 8E2200A8 */ lw $v0, 0xa8($s1) -/* 4E2D48 80218608 10400009 */ beqz $v0, .L80218630 -/* 4E2D4C 8021860C 00000000 */ nop -/* 4E2D50 80218610 16600007 */ bnez $s3, .L80218630 -/* 4E2D54 80218614 24042063 */ addiu $a0, $zero, 0x2063 -/* 4E2D58 80218618 C620014C */ lwc1 $f0, 0x14c($s1) -/* 4E2D5C 8021861C E7A00010 */ swc1 $f0, 0x10($sp) -/* 4E2D60 80218620 8E260144 */ lw $a2, 0x144($s1) -/* 4E2D64 80218624 8E270148 */ lw $a3, 0x148($s1) -/* 4E2D68 80218628 0C052757 */ jal sfx_play_sound_at_position -/* 4E2D6C 8021862C 0000282D */ daddu $a1, $zero, $zero -.L80218630: -/* 4E2D70 80218630 C6000000 */ lwc1 $f0, ($s0) -/* 4E2D74 80218634 C6020014 */ lwc1 $f2, 0x14($s0) -/* 4E2D78 80218638 46020000 */ add.s $f0, $f0, $f2 -/* 4E2D7C 8021863C E6000000 */ swc1 $f0, ($s0) -/* 4E2D80 80218640 82220210 */ lb $v0, 0x210($s1) -/* 4E2D84 80218644 1454000D */ bne $v0, $s4, .L8021867C -/* 4E2D88 80218648 46000021 */ cvt.d.s $f0, $f0 -/* 4E2D8C 8021864C 3C014004 */ lui $at, 0x4004 -/* 4E2D90 80218650 44811800 */ mtc1 $at, $f3 -/* 4E2D94 80218654 44801000 */ mtc1 $zero, $f2 -/* 4E2D98 80218658 00000000 */ nop -/* 4E2D9C 8021865C 4622003C */ c.lt.d $f0, $f2 -/* 4E2DA0 80218660 00000000 */ nop -/* 4E2DA4 80218664 45000012 */ bc1f .L802186B0 -/* 4E2DA8 80218668 4600A306 */ mov.s $f12, $f20 -/* 4E2DAC 8021866C 3C014020 */ lui $at, 0x4020 -/* 4E2DB0 80218670 44810000 */ mtc1 $at, $f0 -/* 4E2DB4 80218674 080861AA */ j .L802186A8 -/* 4E2DB8 80218678 AE000014 */ sw $zero, 0x14($s0) -.L8021867C: -/* 4E2DBC 8021867C 3C014014 */ lui $at, 0x4014 -/* 4E2DC0 80218680 44811800 */ mtc1 $at, $f3 -/* 4E2DC4 80218684 44801000 */ mtc1 $zero, $f2 -/* 4E2DC8 80218688 00000000 */ nop -/* 4E2DCC 8021868C 4622003C */ c.lt.d $f0, $f2 -/* 4E2DD0 80218690 00000000 */ nop -/* 4E2DD4 80218694 45000006 */ bc1f .L802186B0 -/* 4E2DD8 80218698 4600A306 */ mov.s $f12, $f20 -/* 4E2DDC 8021869C 3C0140A0 */ lui $at, 0x40a0 -/* 4E2DE0 802186A0 44810000 */ mtc1 $at, $f0 -/* 4E2DE4 802186A4 AE000014 */ sw $zero, 0x14($s0) -.L802186A8: -/* 4E2DE8 802186A8 E6000000 */ swc1 $f0, ($s0) -/* 4E2DEC 802186AC 4600A306 */ mov.s $f12, $f20 -.L802186B0: -/* 4E2DF0 802186B0 8E460000 */ lw $a2, ($s2) -/* 4E2DF4 802186B4 8E070000 */ lw $a3, ($s0) -/* 4E2DF8 802186B8 0C00A7B5 */ jal dist2D -/* 4E2DFC 802186BC 4600B386 */ mov.s $f14, $f22 -/* 4E2E00 802186C0 4600A306 */ mov.s $f12, $f20 -/* 4E2E04 802186C4 4600B386 */ mov.s $f14, $f22 -/* 4E2E08 802186C8 8E460000 */ lw $a2, ($s2) -/* 4E2E0C 802186CC 8E070000 */ lw $a3, ($s0) -/* 4E2E10 802186D0 0C00A720 */ jal atan2 -/* 4E2E14 802186D4 46000506 */ mov.s $f20, $f0 -/* 4E2E18 802186D8 C6020028 */ lwc1 $f2, 0x28($s0) -/* 4E2E1C 802186DC 4614103E */ c.le.s $f2, $f20 -/* 4E2E20 802186E0 00000000 */ nop -/* 4E2E24 802186E4 45000012 */ bc1f .L80218730 -/* 4E2E28 802186E8 46000586 */ mov.s $f22, $f0 -/* 4E2E2C 802186EC 4602A081 */ sub.s $f2, $f20, $f2 -/* 4E2E30 802186F0 4406B000 */ mfc1 $a2, $f22 -/* 4E2E34 802186F4 44051000 */ mfc1 $a1, $f2 -/* 4E2E38 802186F8 0C086116 */ jal b_area_isk_part_1_stone_chomp_ChompChainUpdateHelperFunc2 -/* 4E2E3C 802186FC 27A40018 */ addiu $a0, $sp, 0x18 -/* 4E2E40 80218700 C7A00018 */ lwc1 $f0, 0x18($sp) -/* 4E2E44 80218704 3C013FE0 */ lui $at, 0x3fe0 -/* 4E2E48 80218708 44811800 */ mtc1 $at, $f3 -/* 4E2E4C 8021870C 44801000 */ mtc1 $zero, $f2 -/* 4E2E50 80218710 46000021 */ cvt.d.s $f0, $f0 -/* 4E2E54 80218714 46220002 */ mul.d $f0, $f0, $f2 -/* 4E2E58 80218718 00000000 */ nop -/* 4E2E5C 8021871C C6020014 */ lwc1 $f2, 0x14($s0) -/* 4E2E60 80218720 460010A1 */ cvt.d.s $f2, $f2 -/* 4E2E64 80218724 46201080 */ add.d $f2, $f2, $f0 -/* 4E2E68 80218728 462010A0 */ cvt.s.d $f2, $f2 -/* 4E2E6C 8021872C E6020014 */ swc1 $f2, 0x14($s0) -.L80218730: -/* 4E2E70 80218730 C6000024 */ lwc1 $f0, 0x24($s0) -/* 4E2E74 80218734 4614003E */ c.le.s $f0, $f20 -/* 4E2E78 80218738 00000000 */ nop -/* 4E2E7C 8021873C 4500000F */ bc1f .L8021877C -/* 4E2E80 80218740 00000000 */ nop -/* 4E2E84 80218744 C6000020 */ lwc1 $f0, 0x20($s0) -/* 4E2E88 80218748 4614003E */ c.le.s $f0, $f20 -/* 4E2E8C 8021874C 00000000 */ nop -/* 4E2E90 80218750 45000003 */ bc1f .L80218760 -/* 4E2E94 80218754 00000000 */ nop -/* 4E2E98 80218758 080861DC */ j .L80218770 -/* 4E2E9C 8021875C 4600A001 */ sub.s $f0, $f20, $f0 -.L80218760: -/* 4E2EA0 80218760 C6000018 */ lwc1 $f0, 0x18($s0) -/* 4E2EA4 80218764 C602001C */ lwc1 $f2, 0x1c($s0) -/* 4E2EA8 80218768 46020000 */ add.s $f0, $f0, $f2 -/* 4E2EAC 8021876C E6000018 */ swc1 $f0, 0x18($s0) -.L80218770: -/* 4E2EB0 80218770 44050000 */ mfc1 $a1, $f0 -/* 4E2EB4 80218774 080861F2 */ j .L802187C8 -/* 4E2EB8 80218778 00000000 */ nop -.L8021877C: -/* 4E2EBC 8021877C C602001C */ lwc1 $f2, 0x1c($s0) -/* 4E2EC0 80218780 3C018022 */ lui $at, %hi(D_80224920_4EF060) -/* 4E2EC4 80218784 D4204920 */ ldc1 $f0, %lo(D_80224920_4EF060)($at) -/* 4E2EC8 80218788 460010A1 */ cvt.d.s $f2, $f2 -/* 4E2ECC 8021878C 46201082 */ mul.d $f2, $f2, $f0 -/* 4E2ED0 80218790 00000000 */ nop -/* 4E2ED4 80218794 C6000018 */ lwc1 $f0, 0x18($s0) -/* 4E2ED8 80218798 46000021 */ cvt.d.s $f0, $f0 -/* 4E2EDC 8021879C 46220001 */ sub.d $f0, $f0, $f2 -/* 4E2EE0 802187A0 44802000 */ mtc1 $zero, $f4 -/* 4E2EE4 802187A4 44802800 */ mtc1 $zero, $f5 -/* 4E2EE8 802187A8 46200020 */ cvt.s.d $f0, $f0 -/* 4E2EEC 802187AC 460000A1 */ cvt.d.s $f2, $f0 -/* 4E2EF0 802187B0 4624103C */ c.lt.d $f2, $f4 -/* 4E2EF4 802187B4 00000000 */ nop -/* 4E2EF8 802187B8 45000002 */ bc1f .L802187C4 -/* 4E2EFC 802187BC E6000018 */ swc1 $f0, 0x18($s0) -/* 4E2F00 802187C0 AE000018 */ sw $zero, 0x18($s0) -.L802187C4: -/* 4E2F04 802187C4 8E050018 */ lw $a1, 0x18($s0) -.L802187C8: -/* 4E2F08 802187C8 4406B000 */ mfc1 $a2, $f22 -/* 4E2F0C 802187CC 0C0860F0 */ jal b_area_isk_part_1_stone_chomp_ChompChainUpdateHelperFunc -/* 4E2F10 802187D0 0240202D */ daddu $a0, $s2, $zero -/* 4E2F14 802187D4 C6000018 */ lwc1 $f0, 0x18($s0) -/* 4E2F18 802187D8 3C014010 */ lui $at, 0x4010 -/* 4E2F1C 802187DC 44811800 */ mtc1 $at, $f3 -/* 4E2F20 802187E0 44801000 */ mtc1 $zero, $f2 -/* 4E2F24 802187E4 46000021 */ cvt.d.s $f0, $f0 -/* 4E2F28 802187E8 4620103C */ c.lt.d $f2, $f0 -/* 4E2F2C 802187EC 00000000 */ nop -/* 4E2F30 802187F0 45000005 */ bc1f .L80218808 -/* 4E2F34 802187F4 0220202D */ daddu $a0, $s1, $zero -/* 4E2F38 802187F8 3C014080 */ lui $at, 0x4080 -/* 4E2F3C 802187FC 44810000 */ mtc1 $at, $f0 -/* 4E2F40 80218800 00000000 */ nop -/* 4E2F44 80218804 E6000018 */ swc1 $f0, 0x18($s0) -.L80218808: -/* 4E2F48 80218808 0C099117 */ jal get_actor_part -/* 4E2F4C 8021880C 02B32821 */ addu $a1, $s5, $s3 -/* 4E2F50 80218810 C6400000 */ lwc1 $f0, ($s2) -/* 4E2F54 80218814 0040182D */ daddu $v1, $v0, $zero -/* 4E2F58 80218818 E460002C */ swc1 $f0, 0x2c($v1) -/* 4E2F5C 8021881C C6000000 */ lwc1 $f0, ($s0) -/* 4E2F60 80218820 E4600030 */ swc1 $f0, 0x30($v1) -/* 4E2F64 80218824 C6000004 */ lwc1 $f0, 4($s0) -/* 4E2F68 80218828 E4600034 */ swc1 $f0, 0x34($v1) -/* 4E2F6C 8021882C 82220210 */ lb $v0, 0x210($s1) -/* 4E2F70 80218830 54540007 */ bnel $v0, $s4, .L80218850 -/* 4E2F74 80218834 E478004C */ swc1 $f24, 0x4c($v1) -/* 4E2F78 80218838 3C013F00 */ lui $at, 0x3f00 -/* 4E2F7C 8021883C 44810000 */ mtc1 $at, $f0 -/* 4E2F80 80218840 E4780054 */ swc1 $f24, 0x54($v1) -/* 4E2F84 80218844 E460004C */ swc1 $f0, 0x4c($v1) -/* 4E2F88 80218848 08086216 */ j .L80218858 -/* 4E2F8C 8021884C E4600050 */ swc1 $f0, 0x50($v1) -.L80218850: -/* 4E2F90 80218850 E4780050 */ swc1 $f24, 0x50($v1) -/* 4E2F94 80218854 E4780054 */ swc1 $f24, 0x54($v1) -.L80218858: -/* 4E2F98 80218858 26730001 */ addiu $s3, $s3, 1 -/* 4E2F9C 8021885C C6160000 */ lwc1 $f22, ($s0) -/* 4E2FA0 80218860 26100030 */ addiu $s0, $s0, 0x30 -/* 4E2FA4 80218864 C6540000 */ lwc1 $f20, ($s2) -/* 4E2FA8 80218868 2A620008 */ slti $v0, $s3, 8 -/* 4E2FAC 8021886C 1440FF52 */ bnez $v0, .L802185B8 -/* 4E2FB0 80218870 26520030 */ addiu $s2, $s2, 0x30 -/* 4E2FB4 80218874 24020002 */ addiu $v0, $zero, 2 -.L80218878: -/* 4E2FB8 80218878 8FBF0038 */ lw $ra, 0x38($sp) -/* 4E2FBC 8021887C 8FB50034 */ lw $s5, 0x34($sp) -/* 4E2FC0 80218880 8FB40030 */ lw $s4, 0x30($sp) -/* 4E2FC4 80218884 8FB3002C */ lw $s3, 0x2c($sp) -/* 4E2FC8 80218888 8FB20028 */ lw $s2, 0x28($sp) -/* 4E2FCC 8021888C 8FB10024 */ lw $s1, 0x24($sp) -/* 4E2FD0 80218890 8FB00020 */ lw $s0, 0x20($sp) -/* 4E2FD4 80218894 D7BC0060 */ ldc1 $f28, 0x60($sp) -/* 4E2FD8 80218898 D7BA0058 */ ldc1 $f26, 0x58($sp) -/* 4E2FDC 8021889C D7B80050 */ ldc1 $f24, 0x50($sp) -/* 4E2FE0 802188A0 D7B60048 */ ldc1 $f22, 0x48($sp) -/* 4E2FE4 802188A4 D7B40040 */ ldc1 $f20, 0x40($sp) -/* 4E2FE8 802188A8 03E00008 */ jr $ra -/* 4E2FEC 802188AC 27BD0068 */ addiu $sp, $sp, 0x68 diff --git a/ver/us/asm/nonmatchings/battle/area_isk_part_2/4EF4A0/b_area_isk_part_2_chain_chomp_ChompChainUpdate.s b/ver/us/asm/nonmatchings/battle/area_isk_part_2/4EF4A0/b_area_isk_part_2_chain_chomp_ChompChainUpdate.s deleted file mode 100644 index 2d29b7e892..0000000000 --- a/ver/us/asm/nonmatchings/battle/area_isk_part_2/4EF4A0/b_area_isk_part_2_chain_chomp_ChompChainUpdate.s +++ /dev/null @@ -1,289 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata -dlabel D_802204E0_4F7980 -.double 0.2, 0.0 - -.section .text - -glabel b_area_isk_part_2_chain_chomp_ChompChainUpdate -/* 4EF6FC 8021825C 27BDFFA0 */ addiu $sp, $sp, -0x60 -/* 4EF700 80218260 AFB00020 */ sw $s0, 0x20($sp) -/* 4EF704 80218264 0080802D */ daddu $s0, $a0, $zero -/* 4EF708 80218268 AFBF003C */ sw $ra, 0x3c($sp) -/* 4EF70C 8021826C AFB60038 */ sw $s6, 0x38($sp) -/* 4EF710 80218270 AFB50034 */ sw $s5, 0x34($sp) -/* 4EF714 80218274 AFB40030 */ sw $s4, 0x30($sp) -/* 4EF718 80218278 AFB3002C */ sw $s3, 0x2c($sp) -/* 4EF71C 8021827C AFB20028 */ sw $s2, 0x28($sp) -/* 4EF720 80218280 AFB10024 */ sw $s1, 0x24($sp) -/* 4EF724 80218284 F7BA0058 */ sdc1 $f26, 0x58($sp) -/* 4EF728 80218288 F7B80050 */ sdc1 $f24, 0x50($sp) -/* 4EF72C 8021828C F7B60048 */ sdc1 $f22, 0x48($sp) -/* 4EF730 80218290 F7B40040 */ sdc1 $f20, 0x40($sp) -/* 4EF734 80218294 8E040148 */ lw $a0, 0x148($s0) -/* 4EF738 80218298 0C09A75B */ jal get_actor -/* 4EF73C 8021829C 8E12000C */ lw $s2, 0xc($s0) -/* 4EF740 802182A0 0040882D */ daddu $s1, $v0, $zero -/* 4EF744 802182A4 122000E3 */ beqz $s1, .L80218634 -/* 4EF748 802182A8 0000102D */ daddu $v0, $zero, $zero -/* 4EF74C 802182AC 8E450000 */ lw $a1, ($s2) -/* 4EF750 802182B0 0C0B1EAF */ jal evt_get_variable -/* 4EF754 802182B4 0200202D */ daddu $a0, $s0, $zero -/* 4EF758 802182B8 0040A82D */ daddu $s5, $v0, $zero -/* 4EF75C 802182BC 2402000A */ addiu $v0, $zero, 0xa -/* 4EF760 802182C0 82230210 */ lb $v1, 0x210($s1) -/* 4EF764 802182C4 8E320078 */ lw $s2, 0x78($s1) -/* 4EF768 802182C8 1462000D */ bne $v1, $v0, .L80218300 -/* 4EF76C 802182CC 24160003 */ addiu $s6, $zero, 3 -/* 4EF770 802182D0 C6220144 */ lwc1 $f2, 0x144($s1) -/* 4EF774 802182D4 3C014018 */ lui $at, 0x4018 -/* 4EF778 802182D8 44810800 */ mtc1 $at, $f1 -/* 4EF77C 802182DC 44800000 */ mtc1 $zero, $f0 -/* 4EF780 802182E0 460010A1 */ cvt.d.s $f2, $f2 -/* 4EF784 802182E4 46201080 */ add.d $f2, $f2, $f0 -/* 4EF788 802182E8 C6200148 */ lwc1 $f0, 0x148($s1) -/* 4EF78C 802182EC 3C014004 */ lui $at, 0x4004 -/* 4EF790 802182F0 44812800 */ mtc1 $at, $f5 -/* 4EF794 802182F4 44802000 */ mtc1 $zero, $f4 -/* 4EF798 802182F8 080860CB */ j .L8021832C -/* 4EF79C 802182FC 46000021 */ cvt.d.s $f0, $f0 -.L80218300: -/* 4EF7A0 80218300 C6220144 */ lwc1 $f2, 0x144($s1) -/* 4EF7A4 80218304 3C014028 */ lui $at, 0x4028 -/* 4EF7A8 80218308 44810800 */ mtc1 $at, $f1 -/* 4EF7AC 8021830C 44800000 */ mtc1 $zero, $f0 -/* 4EF7B0 80218310 460010A1 */ cvt.d.s $f2, $f2 -/* 4EF7B4 80218314 46201080 */ add.d $f2, $f2, $f0 -/* 4EF7B8 80218318 C6200148 */ lwc1 $f0, 0x148($s1) -/* 4EF7BC 8021831C 3C014014 */ lui $at, 0x4014 -/* 4EF7C0 80218320 44812800 */ mtc1 $at, $f5 -/* 4EF7C4 80218324 44802000 */ mtc1 $zero, $f4 -/* 4EF7C8 80218328 46000021 */ cvt.d.s $f0, $f0 -.L8021832C: -/* 4EF7CC 8021832C 46240000 */ add.d $f0, $f0, $f4 -/* 4EF7D0 80218330 46201520 */ cvt.s.d $f20, $f2 -/* 4EF7D4 80218334 462005A0 */ cvt.s.d $f22, $f0 -/* 4EF7D8 80218338 0000982D */ daddu $s3, $zero, $zero -/* 4EF7DC 8021833C 2414000A */ addiu $s4, $zero, 0xa -/* 4EF7E0 80218340 26500004 */ addiu $s0, $s2, 4 -/* 4EF7E4 80218344 3C014060 */ lui $at, 0x4060 -/* 4EF7E8 80218348 4481D000 */ mtc1 $at, $f26 -/* 4EF7EC 8021834C 3C013F80 */ lui $at, 0x3f80 -/* 4EF7F0 80218350 4481C000 */ mtc1 $at, $f24 -.L80218354: -/* 4EF7F4 80218354 82220210 */ lb $v0, 0x210($s1) -/* 4EF7F8 80218358 14540005 */ bne $v0, $s4, .L80218370 -/* 4EF7FC 8021835C 00000000 */ nop -/* 4EF800 80218360 E61A0020 */ swc1 $f26, 0x20($s0) -/* 4EF804 80218364 E61A0028 */ swc1 $f26, 0x28($s0) -/* 4EF808 80218368 080860E2 */ j .L80218388 -/* 4EF80C 8021836C E61A0024 */ swc1 $f26, 0x24($s0) -.L80218370: -/* 4EF810 80218370 3C0140E0 */ lui $at, 0x40e0 -/* 4EF814 80218374 44810000 */ mtc1 $at, $f0 -/* 4EF818 80218378 00000000 */ nop -/* 4EF81C 8021837C E6000020 */ swc1 $f0, 0x20($s0) -/* 4EF820 80218380 E6000028 */ swc1 $f0, 0x28($s0) -/* 4EF824 80218384 E6000024 */ swc1 $f0, 0x24($s0) -.L80218388: -/* 4EF828 80218388 C6020014 */ lwc1 $f2, 0x14($s0) -/* 4EF82C 8021838C C6000010 */ lwc1 $f0, 0x10($s0) -/* 4EF830 80218390 46001081 */ sub.s $f2, $f2, $f0 -/* 4EF834 80218394 46000007 */ neg.s $f0, $f0 -/* 4EF838 80218398 46000000 */ add.s $f0, $f0, $f0 -/* 4EF83C 8021839C 4600103C */ c.lt.s $f2, $f0 -/* 4EF840 802183A0 00000000 */ nop -/* 4EF844 802183A4 4500000D */ bc1f .L802183DC -/* 4EF848 802183A8 E6020014 */ swc1 $f2, 0x14($s0) -/* 4EF84C 802183AC E6000014 */ swc1 $f0, 0x14($s0) -/* 4EF850 802183B0 8E2200A8 */ lw $v0, 0xa8($s1) -/* 4EF854 802183B4 10400009 */ beqz $v0, .L802183DC -/* 4EF858 802183B8 00000000 */ nop -/* 4EF85C 802183BC 16600007 */ bnez $s3, .L802183DC -/* 4EF860 802183C0 24042063 */ addiu $a0, $zero, 0x2063 -/* 4EF864 802183C4 C620014C */ lwc1 $f0, 0x14c($s1) -/* 4EF868 802183C8 E7A00010 */ swc1 $f0, 0x10($sp) -/* 4EF86C 802183CC 8E260144 */ lw $a2, 0x144($s1) -/* 4EF870 802183D0 8E270148 */ lw $a3, 0x148($s1) -/* 4EF874 802183D4 0C052757 */ jal sfx_play_sound_at_position -/* 4EF878 802183D8 0000282D */ daddu $a1, $zero, $zero -.L802183DC: -/* 4EF87C 802183DC C6000000 */ lwc1 $f0, ($s0) -/* 4EF880 802183E0 C6020014 */ lwc1 $f2, 0x14($s0) -/* 4EF884 802183E4 46020000 */ add.s $f0, $f0, $f2 -/* 4EF888 802183E8 E6000000 */ swc1 $f0, ($s0) -/* 4EF88C 802183EC 82220210 */ lb $v0, 0x210($s1) -/* 4EF890 802183F0 1454000D */ bne $v0, $s4, .L80218428 -/* 4EF894 802183F4 46000021 */ cvt.d.s $f0, $f0 -/* 4EF898 802183F8 3C014004 */ lui $at, 0x4004 -/* 4EF89C 802183FC 44811800 */ mtc1 $at, $f3 -/* 4EF8A0 80218400 44801000 */ mtc1 $zero, $f2 -/* 4EF8A4 80218404 00000000 */ nop -/* 4EF8A8 80218408 4622003C */ c.lt.d $f0, $f2 -/* 4EF8AC 8021840C 00000000 */ nop -/* 4EF8B0 80218410 45000012 */ bc1f .L8021845C -/* 4EF8B4 80218414 4600A306 */ mov.s $f12, $f20 -/* 4EF8B8 80218418 3C014020 */ lui $at, 0x4020 -/* 4EF8BC 8021841C 44810000 */ mtc1 $at, $f0 -/* 4EF8C0 80218420 08086115 */ j .L80218454 -/* 4EF8C4 80218424 AE000014 */ sw $zero, 0x14($s0) -.L80218428: -/* 4EF8C8 80218428 3C014014 */ lui $at, 0x4014 -/* 4EF8CC 8021842C 44811800 */ mtc1 $at, $f3 -/* 4EF8D0 80218430 44801000 */ mtc1 $zero, $f2 -/* 4EF8D4 80218434 00000000 */ nop -/* 4EF8D8 80218438 4622003C */ c.lt.d $f0, $f2 -/* 4EF8DC 8021843C 00000000 */ nop -/* 4EF8E0 80218440 45000006 */ bc1f .L8021845C -/* 4EF8E4 80218444 4600A306 */ mov.s $f12, $f20 -/* 4EF8E8 80218448 3C0140A0 */ lui $at, 0x40a0 -/* 4EF8EC 8021844C 44810000 */ mtc1 $at, $f0 -/* 4EF8F0 80218450 AE000014 */ sw $zero, 0x14($s0) -.L80218454: -/* 4EF8F4 80218454 E6000000 */ swc1 $f0, ($s0) -/* 4EF8F8 80218458 4600A306 */ mov.s $f12, $f20 -.L8021845C: -/* 4EF8FC 8021845C 8E460000 */ lw $a2, ($s2) -/* 4EF900 80218460 8E070000 */ lw $a3, ($s0) -/* 4EF904 80218464 0C00A7B5 */ jal dist2D -/* 4EF908 80218468 4600B386 */ mov.s $f14, $f22 -/* 4EF90C 8021846C 4600A306 */ mov.s $f12, $f20 -/* 4EF910 80218470 4600B386 */ mov.s $f14, $f22 -/* 4EF914 80218474 8E460000 */ lw $a2, ($s2) -/* 4EF918 80218478 8E070000 */ lw $a3, ($s0) -/* 4EF91C 8021847C 0C00A720 */ jal atan2 -/* 4EF920 80218480 46000506 */ mov.s $f20, $f0 -/* 4EF924 80218484 C6020028 */ lwc1 $f2, 0x28($s0) -/* 4EF928 80218488 4614103E */ c.le.s $f2, $f20 -/* 4EF92C 8021848C 00000000 */ nop -/* 4EF930 80218490 45000012 */ bc1f .L802184DC -/* 4EF934 80218494 46000586 */ mov.s $f22, $f0 -/* 4EF938 80218498 4602A081 */ sub.s $f2, $f20, $f2 -/* 4EF93C 8021849C 4406B000 */ mfc1 $a2, $f22 -/* 4EF940 802184A0 44051000 */ mfc1 $a1, $f2 -/* 4EF944 802184A4 0C08607A */ jal b_area_isk_part_2_chain_chomp_ChompChainUpdateHelperFunc2 -/* 4EF948 802184A8 27A40018 */ addiu $a0, $sp, 0x18 -/* 4EF94C 802184AC C7A00018 */ lwc1 $f0, 0x18($sp) -/* 4EF950 802184B0 3C013FE0 */ lui $at, 0x3fe0 -/* 4EF954 802184B4 44811800 */ mtc1 $at, $f3 -/* 4EF958 802184B8 44801000 */ mtc1 $zero, $f2 -/* 4EF95C 802184BC 46000021 */ cvt.d.s $f0, $f0 -/* 4EF960 802184C0 46220002 */ mul.d $f0, $f0, $f2 -/* 4EF964 802184C4 00000000 */ nop -/* 4EF968 802184C8 C6020014 */ lwc1 $f2, 0x14($s0) -/* 4EF96C 802184CC 460010A1 */ cvt.d.s $f2, $f2 -/* 4EF970 802184D0 46201080 */ add.d $f2, $f2, $f0 -/* 4EF974 802184D4 462010A0 */ cvt.s.d $f2, $f2 -/* 4EF978 802184D8 E6020014 */ swc1 $f2, 0x14($s0) -.L802184DC: -/* 4EF97C 802184DC C6000024 */ lwc1 $f0, 0x24($s0) -/* 4EF980 802184E0 4614003E */ c.le.s $f0, $f20 -/* 4EF984 802184E4 00000000 */ nop -/* 4EF988 802184E8 4500000F */ bc1f .L80218528 -/* 4EF98C 802184EC 00000000 */ nop -/* 4EF990 802184F0 C6000020 */ lwc1 $f0, 0x20($s0) -/* 4EF994 802184F4 4614003E */ c.le.s $f0, $f20 -/* 4EF998 802184F8 00000000 */ nop -/* 4EF99C 802184FC 45000003 */ bc1f .L8021850C -/* 4EF9A0 80218500 00000000 */ nop -/* 4EF9A4 80218504 08086147 */ j .L8021851C -/* 4EF9A8 80218508 4600A001 */ sub.s $f0, $f20, $f0 -.L8021850C: -/* 4EF9AC 8021850C C6000018 */ lwc1 $f0, 0x18($s0) -/* 4EF9B0 80218510 C602001C */ lwc1 $f2, 0x1c($s0) -/* 4EF9B4 80218514 46020000 */ add.s $f0, $f0, $f2 -/* 4EF9B8 80218518 E6000018 */ swc1 $f0, 0x18($s0) -.L8021851C: -/* 4EF9BC 8021851C 44050000 */ mfc1 $a1, $f0 -/* 4EF9C0 80218520 0808615D */ j .L80218574 -/* 4EF9C4 80218524 00000000 */ nop -.L80218528: -/* 4EF9C8 80218528 C602001C */ lwc1 $f2, 0x1c($s0) -/* 4EF9CC 8021852C 3C018022 */ lui $at, %hi(D_802204E0_4F7980) -/* 4EF9D0 80218530 D42004E0 */ ldc1 $f0, %lo(D_802204E0_4F7980)($at) -/* 4EF9D4 80218534 460010A1 */ cvt.d.s $f2, $f2 -/* 4EF9D8 80218538 46201082 */ mul.d $f2, $f2, $f0 -/* 4EF9DC 8021853C 00000000 */ nop -/* 4EF9E0 80218540 C6000018 */ lwc1 $f0, 0x18($s0) -/* 4EF9E4 80218544 46000021 */ cvt.d.s $f0, $f0 -/* 4EF9E8 80218548 46220001 */ sub.d $f0, $f0, $f2 -/* 4EF9EC 8021854C 44802000 */ mtc1 $zero, $f4 -/* 4EF9F0 80218550 44802800 */ mtc1 $zero, $f5 -/* 4EF9F4 80218554 46200020 */ cvt.s.d $f0, $f0 -/* 4EF9F8 80218558 460000A1 */ cvt.d.s $f2, $f0 -/* 4EF9FC 8021855C 4624103C */ c.lt.d $f2, $f4 -/* 4EFA00 80218560 00000000 */ nop -/* 4EFA04 80218564 45000002 */ bc1f .L80218570 -/* 4EFA08 80218568 E6000018 */ swc1 $f0, 0x18($s0) -/* 4EFA0C 8021856C AE000018 */ sw $zero, 0x18($s0) -.L80218570: -/* 4EFA10 80218570 8E050018 */ lw $a1, 0x18($s0) -.L80218574: -/* 4EFA14 80218574 4406B000 */ mfc1 $a2, $f22 -/* 4EFA18 80218578 0C086054 */ jal b_area_isk_part_2_chain_chomp_ChompChainUpdateHelperFunc -/* 4EFA1C 8021857C 0240202D */ daddu $a0, $s2, $zero -/* 4EFA20 80218580 C6000018 */ lwc1 $f0, 0x18($s0) -/* 4EFA24 80218584 3C014010 */ lui $at, 0x4010 -/* 4EFA28 80218588 44811800 */ mtc1 $at, $f3 -/* 4EFA2C 8021858C 44801000 */ mtc1 $zero, $f2 -/* 4EFA30 80218590 46000021 */ cvt.d.s $f0, $f0 -/* 4EFA34 80218594 4620103C */ c.lt.d $f2, $f0 -/* 4EFA38 80218598 00000000 */ nop -/* 4EFA3C 8021859C 45000005 */ bc1f .L802185B4 -/* 4EFA40 802185A0 0220202D */ daddu $a0, $s1, $zero -/* 4EFA44 802185A4 3C014080 */ lui $at, 0x4080 -/* 4EFA48 802185A8 44810000 */ mtc1 $at, $f0 -/* 4EFA4C 802185AC 00000000 */ nop -/* 4EFA50 802185B0 E6000018 */ swc1 $f0, 0x18($s0) -.L802185B4: -/* 4EFA54 802185B4 02D32821 */ addu $a1, $s6, $s3 -/* 4EFA58 802185B8 44950000 */ mtc1 $s5, $f0 -/* 4EFA5C 802185BC 00000000 */ nop -/* 4EFA60 802185C0 46800020 */ cvt.s.w $f0, $f0 -/* 4EFA64 802185C4 0C099117 */ jal get_actor_part -/* 4EFA68 802185C8 E6000004 */ swc1 $f0, 4($s0) -/* 4EFA6C 802185CC C6400000 */ lwc1 $f0, ($s2) -/* 4EFA70 802185D0 0040182D */ daddu $v1, $v0, $zero -/* 4EFA74 802185D4 E460002C */ swc1 $f0, 0x2c($v1) -/* 4EFA78 802185D8 C6000000 */ lwc1 $f0, ($s0) -/* 4EFA7C 802185DC E4600030 */ swc1 $f0, 0x30($v1) -/* 4EFA80 802185E0 C6000004 */ lwc1 $f0, 4($s0) -/* 4EFA84 802185E4 E4600034 */ swc1 $f0, 0x34($v1) -/* 4EFA88 802185E8 82220210 */ lb $v0, 0x210($s1) -/* 4EFA8C 802185EC 54540007 */ bnel $v0, $s4, .L8021860C -/* 4EFA90 802185F0 E478004C */ swc1 $f24, 0x4c($v1) -/* 4EFA94 802185F4 3C013F00 */ lui $at, 0x3f00 -/* 4EFA98 802185F8 44810000 */ mtc1 $at, $f0 -/* 4EFA9C 802185FC E4780054 */ swc1 $f24, 0x54($v1) -/* 4EFAA0 80218600 E460004C */ swc1 $f0, 0x4c($v1) -/* 4EFAA4 80218604 08086185 */ j .L80218614 -/* 4EFAA8 80218608 E4600050 */ swc1 $f0, 0x50($v1) -.L8021860C: -/* 4EFAAC 8021860C E4780050 */ swc1 $f24, 0x50($v1) -/* 4EFAB0 80218610 E4780054 */ swc1 $f24, 0x54($v1) -.L80218614: -/* 4EFAB4 80218614 26730001 */ addiu $s3, $s3, 1 -/* 4EFAB8 80218618 C6160000 */ lwc1 $f22, ($s0) -/* 4EFABC 8021861C 26100030 */ addiu $s0, $s0, 0x30 -/* 4EFAC0 80218620 C6540000 */ lwc1 $f20, ($s2) -/* 4EFAC4 80218624 2A620008 */ slti $v0, $s3, 8 -/* 4EFAC8 80218628 1440FF4A */ bnez $v0, .L80218354 -/* 4EFACC 8021862C 26520030 */ addiu $s2, $s2, 0x30 -/* 4EFAD0 80218630 24020002 */ addiu $v0, $zero, 2 -.L80218634: -/* 4EFAD4 80218634 8FBF003C */ lw $ra, 0x3c($sp) -/* 4EFAD8 80218638 8FB60038 */ lw $s6, 0x38($sp) -/* 4EFADC 8021863C 8FB50034 */ lw $s5, 0x34($sp) -/* 4EFAE0 80218640 8FB40030 */ lw $s4, 0x30($sp) -/* 4EFAE4 80218644 8FB3002C */ lw $s3, 0x2c($sp) -/* 4EFAE8 80218648 8FB20028 */ lw $s2, 0x28($sp) -/* 4EFAEC 8021864C 8FB10024 */ lw $s1, 0x24($sp) -/* 4EFAF0 80218650 8FB00020 */ lw $s0, 0x20($sp) -/* 4EFAF4 80218654 D7BA0058 */ ldc1 $f26, 0x58($sp) -/* 4EFAF8 80218658 D7B80050 */ ldc1 $f24, 0x50($sp) -/* 4EFAFC 8021865C D7B60048 */ ldc1 $f22, 0x48($sp) -/* 4EFB00 80218660 D7B40040 */ ldc1 $f20, 0x40($sp) -/* 4EFB04 80218664 03E00008 */ jr $ra -/* 4EFB08 80218668 27BD0060 */ addiu $sp, $sp, 0x60 diff --git a/ver/us/asm/nonmatchings/battle/star/refresh/78B600/func_802A1518_78BB18.s b/ver/us/asm/nonmatchings/battle/star/refresh/78B600/func_802A1518_78BB18.s deleted file mode 100644 index bf3cff7fe5..0000000000 --- a/ver/us/asm/nonmatchings/battle/star/refresh/78B600/func_802A1518_78BB18.s +++ /dev/null @@ -1,192 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_802A1518_78BB18 -/* 78BB18 802A1518 27BDFFD8 */ addiu $sp, $sp, -0x28 -/* 78BB1C 802A151C AFB1001C */ sw $s1, 0x1c($sp) -/* 78BB20 802A1520 0080882D */ daddu $s1, $a0, $zero -/* 78BB24 802A1524 AFBF0024 */ sw $ra, 0x24($sp) -/* 78BB28 802A1528 AFB20020 */ sw $s2, 0x20($sp) -/* 78BB2C 802A152C AFB00018 */ sw $s0, 0x18($sp) -/* 78BB30 802A1530 8E24000C */ lw $a0, 0xc($s1) -/* 78BB34 802A1534 54A00001 */ bnel $a1, $zero, .L802A153C -/* 78BB38 802A1538 AE200070 */ sw $zero, 0x70($s1) -.L802A153C: -/* 78BB3C 802A153C 24120001 */ addiu $s2, $zero, 1 -/* 78BB40 802A1540 8E230070 */ lw $v1, 0x70($s1) -/* 78BB44 802A1544 8E300074 */ lw $s0, 0x74($s1) -/* 78BB48 802A1548 10720027 */ beq $v1, $s2, .L802A15E8 -/* 78BB4C 802A154C 28620002 */ slti $v0, $v1, 2 -/* 78BB50 802A1550 10400005 */ beqz $v0, .L802A1568 -/* 78BB54 802A1554 24020002 */ addiu $v0, $zero, 2 -/* 78BB58 802A1558 10600007 */ beqz $v1, .L802A1578 -/* 78BB5C 802A155C 0000102D */ daddu $v0, $zero, $zero -/* 78BB60 802A1560 080A85EF */ j .L802A17BC -/* 78BB64 802A1564 00000000 */ nop -.L802A1568: -/* 78BB68 802A1568 10620091 */ beq $v1, $v0, .L802A17B0 -/* 78BB6C 802A156C 0000102D */ daddu $v0, $zero, $zero -/* 78BB70 802A1570 080A85EF */ j .L802A17BC -/* 78BB74 802A1574 00000000 */ nop -.L802A1578: -/* 78BB78 802A1578 8C850000 */ lw $a1, ($a0) -/* 78BB7C 802A157C 0C0B1EAF */ jal evt_get_variable -/* 78BB80 802A1580 0220202D */ daddu $a0, $s1, $zero -/* 78BB84 802A1584 0C00EABB */ jal get_npc_unsafe -/* 78BB88 802A1588 0040202D */ daddu $a0, $v0, $zero -/* 78BB8C 802A158C 3C01BFC0 */ lui $at, 0xbfc0 -/* 78BB90 802A1590 44810000 */ mtc1 $at, $f0 -/* 78BB94 802A1594 3C013CA3 */ lui $at, 0x3ca3 -/* 78BB98 802A1598 3421D70A */ ori $at, $at, 0xd70a -/* 78BB9C 802A159C 44811000 */ mtc1 $at, $f2 -/* 78BBA0 802A15A0 3C013F80 */ lui $at, 0x3f80 -/* 78BBA4 802A15A4 44812000 */ mtc1 $at, $f4 -/* 78BBA8 802A15A8 0040802D */ daddu $s0, $v0, $zero -/* 78BBAC 802A15AC AE300074 */ sw $s0, 0x74($s1) -/* 78BBB0 802A15B0 C6060038 */ lwc1 $f6, 0x38($s0) -/* 78BBB4 802A15B4 C608003C */ lwc1 $f8, 0x3c($s0) -/* 78BBB8 802A15B8 C60A0040 */ lwc1 $f10, 0x40($s0) -/* 78BBBC 802A15BC AE000010 */ sw $zero, 0x10($s0) -/* 78BBC0 802A15C0 AE00000C */ sw $zero, 0xc($s0) -/* 78BBC4 802A15C4 A600008E */ sh $zero, 0x8e($s0) -/* 78BBC8 802A15C8 E600001C */ swc1 $f0, 0x1c($s0) -/* 78BBCC 802A15CC E6020014 */ swc1 $f2, 0x14($s0) -/* 78BBD0 802A15D0 E6040018 */ swc1 $f4, 0x18($s0) -/* 78BBD4 802A15D4 E6060060 */ swc1 $f6, 0x60($s0) -/* 78BBD8 802A15D8 E6080064 */ swc1 $f8, 0x64($s0) -/* 78BBDC 802A15DC E60A0068 */ swc1 $f10, 0x68($s0) -/* 78BBE0 802A15E0 080A85EE */ j .L802A17B8 -/* 78BBE4 802A15E4 AE320070 */ sw $s2, 0x70($s1) -.L802A15E8: -/* 78BBE8 802A15E8 C602001C */ lwc1 $f2, 0x1c($s0) -/* 78BBEC 802A15EC 44800000 */ mtc1 $zero, $f0 -/* 78BBF0 802A15F0 00000000 */ nop -/* 78BBF4 802A15F4 4600103C */ c.lt.s $f2, $f0 -/* 78BBF8 802A15F8 00000000 */ nop -/* 78BBFC 802A15FC 4500000D */ bc1f .L802A1634 -/* 78BC00 802A1600 00000000 */ nop -/* 78BC04 802A1604 C6000010 */ lwc1 $f0, 0x10($s0) -/* 78BC08 802A1608 3C014008 */ lui $at, 0x4008 -/* 78BC0C 802A160C 44811800 */ mtc1 $at, $f3 -/* 78BC10 802A1610 44801000 */ mtc1 $zero, $f2 -/* 78BC14 802A1614 46000021 */ cvt.d.s $f0, $f0 -/* 78BC18 802A1618 46220000 */ add.d $f0, $f0, $f2 -/* 78BC1C 802A161C 3C014220 */ lui $at, 0x4220 -/* 78BC20 802A1620 44811000 */ mtc1 $at, $f2 -/* 78BC24 802A1624 46200020 */ cvt.s.d $f0, $f0 -/* 78BC28 802A1628 4600103C */ c.lt.s $f2, $f0 -/* 78BC2C 802A162C 080A8598 */ j .L802A1660 -/* 78BC30 802A1630 E6000010 */ swc1 $f0, 0x10($s0) -.L802A1634: -/* 78BC34 802A1634 C6000010 */ lwc1 $f0, 0x10($s0) -/* 78BC38 802A1638 3C014000 */ lui $at, 0x4000 -/* 78BC3C 802A163C 44811800 */ mtc1 $at, $f3 -/* 78BC40 802A1640 44801000 */ mtc1 $zero, $f2 -/* 78BC44 802A1644 46000021 */ cvt.d.s $f0, $f0 -/* 78BC48 802A1648 46220001 */ sub.d $f0, $f0, $f2 -/* 78BC4C 802A164C 3C0141A0 */ lui $at, 0x41a0 -/* 78BC50 802A1650 44811000 */ mtc1 $at, $f2 -/* 78BC54 802A1654 46200020 */ cvt.s.d $f0, $f0 -/* 78BC58 802A1658 4602003C */ c.lt.s $f0, $f2 -/* 78BC5C 802A165C E6000010 */ swc1 $f0, 0x10($s0) -.L802A1660: -/* 78BC60 802A1660 45030001 */ bc1tl .L802A1668 -/* 78BC64 802A1664 E6020010 */ swc1 $f2, 0x10($s0) -.L802A1668: -/* 78BC68 802A1668 C6000018 */ lwc1 $f0, 0x18($s0) -/* 78BC6C 802A166C 3C013FE8 */ lui $at, 0x3fe8 -/* 78BC70 802A1670 44811800 */ mtc1 $at, $f3 -/* 78BC74 802A1674 44801000 */ mtc1 $zero, $f2 -/* 78BC78 802A1678 C604001C */ lwc1 $f4, 0x1c($s0) -/* 78BC7C 802A167C 46000021 */ cvt.d.s $f0, $f0 -/* 78BC80 802A1680 46220000 */ add.d $f0, $f0, $f2 -/* 78BC84 802A1684 C6020014 */ lwc1 $f2, 0x14($s0) -/* 78BC88 802A1688 3C014204 */ lui $at, 0x4204 -/* 78BC8C 802A168C 44813000 */ mtc1 $at, $f6 -/* 78BC90 802A1690 46022100 */ add.s $f4, $f4, $f2 -/* 78BC94 802A1694 C602003C */ lwc1 $f2, 0x3c($s0) -/* 78BC98 802A1698 46200020 */ cvt.s.d $f0, $f0 -/* 78BC9C 802A169C 4600303C */ c.lt.s $f6, $f0 -/* 78BCA0 802A16A0 46041080 */ add.s $f2, $f2, $f4 -/* 78BCA4 802A16A4 E6000018 */ swc1 $f0, 0x18($s0) -/* 78BCA8 802A16A8 E604001C */ swc1 $f4, 0x1c($s0) -/* 78BCAC 802A16AC 45000002 */ bc1f .L802A16B8 -/* 78BCB0 802A16B0 E602003C */ swc1 $f2, 0x3c($s0) -/* 78BCB4 802A16B4 E6060018 */ swc1 $f6, 0x18($s0) -.L802A16B8: -/* 78BCB8 802A16B8 C602000C */ lwc1 $f2, 0xc($s0) -/* 78BCBC 802A16BC C6000018 */ lwc1 $f0, 0x18($s0) -/* 78BCC0 802A16C0 8E060010 */ lw $a2, 0x10($s0) -/* 78BCC4 802A16C4 46001080 */ add.s $f2, $f2, $f0 -/* 78BCC8 802A16C8 C6000060 */ lwc1 $f0, 0x60($s0) -/* 78BCCC 802A16CC 26040038 */ addiu $a0, $s0, 0x38 -/* 78BCD0 802A16D0 E602000C */ swc1 $f2, 0xc($s0) -/* 78BCD4 802A16D4 44071000 */ mfc1 $a3, $f2 -/* 78BCD8 802A16D8 C6020068 */ lwc1 $f2, 0x68($s0) -/* 78BCDC 802A16DC 26050040 */ addiu $a1, $s0, 0x40 -/* 78BCE0 802A16E0 E6000038 */ swc1 $f0, 0x38($s0) -/* 78BCE4 802A16E4 0C00A7E7 */ jal add_vec2D_polar -/* 78BCE8 802A16E8 E6020040 */ swc1 $f2, 0x40($s0) -/* 78BCEC 802A16EC 3C039249 */ lui $v1, 0x9249 -/* 78BCF0 802A16F0 9602008E */ lhu $v0, 0x8e($s0) -/* 78BCF4 802A16F4 34632493 */ ori $v1, $v1, 0x2493 -/* 78BCF8 802A16F8 00021400 */ sll $v0, $v0, 0x10 -/* 78BCFC 802A16FC 00022403 */ sra $a0, $v0, 0x10 -/* 78BD00 802A1700 00830018 */ mult $a0, $v1 -/* 78BD04 802A1704 000217C3 */ sra $v0, $v0, 0x1f -/* 78BD08 802A1708 00004010 */ mfhi $t0 -/* 78BD0C 802A170C 01041821 */ addu $v1, $t0, $a0 -/* 78BD10 802A1710 000318C3 */ sra $v1, $v1, 3 -/* 78BD14 802A1714 00621823 */ subu $v1, $v1, $v0 -/* 78BD18 802A1718 000310C0 */ sll $v0, $v1, 3 -/* 78BD1C 802A171C 00431023 */ subu $v0, $v0, $v1 -/* 78BD20 802A1720 00021040 */ sll $v0, $v0, 1 -/* 78BD24 802A1724 00822023 */ subu $a0, $a0, $v0 -/* 78BD28 802A1728 00042400 */ sll $a0, $a0, 0x10 -/* 78BD2C 802A172C 1480000A */ bnez $a0, .L802A1758 -/* 78BD30 802A1730 00000000 */ nop -/* 78BD34 802A1734 3C0141F0 */ lui $at, 0x41f0 -/* 78BD38 802A1738 44810000 */ mtc1 $at, $f0 -/* 78BD3C 802A173C 00000000 */ nop -/* 78BD40 802A1740 E7A00010 */ swc1 $f0, 0x10($sp) -/* 78BD44 802A1744 8E050038 */ lw $a1, 0x38($s0) -/* 78BD48 802A1748 8E06003C */ lw $a2, 0x3c($s0) -/* 78BD4C 802A174C 8E070040 */ lw $a3, 0x40($s0) -/* 78BD50 802A1750 0C01BFBC */ jal fx_sparkles -/* 78BD54 802A1754 0000202D */ daddu $a0, $zero, $zero -.L802A1758: -/* 78BD58 802A1758 9602008E */ lhu $v0, 0x8e($s0) -/* 78BD5C 802A175C 24420001 */ addiu $v0, $v0, 1 -/* 78BD60 802A1760 A602008E */ sh $v0, 0x8e($s0) -/* 78BD64 802A1764 00021400 */ sll $v0, $v0, 0x10 -/* 78BD68 802A1768 00021403 */ sra $v0, $v0, 0x10 -/* 78BD6C 802A176C 28420029 */ slti $v0, $v0, 0x29 -/* 78BD70 802A1770 14400005 */ bnez $v0, .L802A1788 -/* 78BD74 802A1774 00000000 */ nop -/* 78BD78 802A1778 3C013F00 */ lui $at, 0x3f00 -/* 78BD7C 802A177C 44810000 */ mtc1 $at, $f0 -/* 78BD80 802A1780 00000000 */ nop -/* 78BD84 802A1784 E6000014 */ swc1 $f0, 0x14($s0) -.L802A1788: -/* 78BD88 802A1788 C602003C */ lwc1 $f2, 0x3c($s0) -/* 78BD8C 802A178C 3C014348 */ lui $at, 0x4348 -/* 78BD90 802A1790 44810000 */ mtc1 $at, $f0 -/* 78BD94 802A1794 00000000 */ nop -/* 78BD98 802A1798 4602003C */ c.lt.s $f0, $f2 -/* 78BD9C 802A179C 00000000 */ nop -/* 78BDA0 802A17A0 45000005 */ bc1f .L802A17B8 -/* 78BDA4 802A17A4 24020002 */ addiu $v0, $zero, 2 -/* 78BDA8 802A17A8 080A85EE */ j .L802A17B8 -/* 78BDAC 802A17AC AE220070 */ sw $v0, 0x70($s1) -.L802A17B0: -/* 78BDB0 802A17B0 080A85EF */ j .L802A17BC -/* 78BDB4 802A17B4 24020002 */ addiu $v0, $zero, 2 -.L802A17B8: -/* 78BDB8 802A17B8 0000102D */ daddu $v0, $zero, $zero -.L802A17BC: -/* 78BDBC 802A17BC 8FBF0024 */ lw $ra, 0x24($sp) -/* 78BDC0 802A17C0 8FB20020 */ lw $s2, 0x20($sp) -/* 78BDC4 802A17C4 8FB1001C */ lw $s1, 0x1c($sp) -/* 78BDC8 802A17C8 8FB00018 */ lw $s0, 0x18($sp) -/* 78BDCC 802A17CC 03E00008 */ jr $ra -/* 78BDD0 802A17D0 27BD0028 */ addiu $sp, $sp, 0x28 diff --git a/ver/us/asm/nonmatchings/d0a70_len_4fe0/func_8013DAB4.s b/ver/us/asm/nonmatchings/d0a70_len_4fe0/func_8013DAB4.s index ab7401edbb..997a9b6d10 100644 --- a/ver/us/asm/nonmatchings/d0a70_len_4fe0/func_8013DAB4.s +++ b/ver/us/asm/nonmatchings/d0a70_len_4fe0/func_8013DAB4.s @@ -331,7 +331,7 @@ glabel func_8013DAB4 /* D46B0 8013DFB0 24E7FF00 */ addiu $a3, $a3, -0x100 /* D46B4 8013DFB4 AFAE0020 */ sw $t6, 0x20($sp) /* D46B8 8013DFB8 AFAF0024 */ sw $t7, 0x24($sp) -/* D46BC 8013DFBC 0C052071 */ jal render_shaded_sprite +/* D46BC 8013DFBC 0C052071 */ jal create_shading_palette /* D46C0 8013DFC0 AFA20018 */ sw $v0, 0x18($sp) /* D46C4 8013DFC4 8FAE0020 */ lw $t6, 0x20($sp) /* D46C8 8013DFC8 8FAF0024 */ lw $t7, 0x24($sp) diff --git a/ver/us/asm/nonmatchings/d0a70_len_4fe0/func_8013E2F0.s b/ver/us/asm/nonmatchings/d0a70_len_4fe0/func_8013E2F0.s index 6a214589e2..c3ee02a4d3 100644 --- a/ver/us/asm/nonmatchings/d0a70_len_4fe0/func_8013E2F0.s +++ b/ver/us/asm/nonmatchings/d0a70_len_4fe0/func_8013E2F0.s @@ -275,7 +275,7 @@ glabel func_8013E2F0 /* D4E14 8013E714 AFA20010 */ sw $v0, 0x10($sp) /* D4E18 8013E718 8E620078 */ lw $v0, 0x78($s3) /* D4E1C 8013E71C 00A0302D */ daddu $a2, $a1, $zero -/* D4E20 8013E720 0C052071 */ jal render_shaded_sprite +/* D4E20 8013E720 0C052071 */ jal create_shading_palette /* D4E24 8013E724 AFA20018 */ sw $v0, 0x18($sp) /* D4E28 8013E728 0804FA25 */ j .L8013E894 /* D4E2C 8013E72C 3C07D838 */ lui $a3, 0xd838 diff --git a/ver/us/asm/nonmatchings/de740_len_23f0/appendGfx_shaded_sprite.s b/ver/us/asm/nonmatchings/de740_len_23f0/appendGfx_shading_palette.s similarity index 99% rename from ver/us/asm/nonmatchings/de740_len_23f0/appendGfx_shaded_sprite.s rename to ver/us/asm/nonmatchings/de740_len_23f0/appendGfx_shading_palette.s index b8edd0abba..5803acf745 100644 --- a/ver/us/asm/nonmatchings/de740_len_23f0/appendGfx_shaded_sprite.s +++ b/ver/us/asm/nonmatchings/de740_len_23f0/appendGfx_shading_palette.s @@ -1,7 +1,7 @@ .set noat # allow manual use of $at .set noreorder # don't insert nops after branches -glabel appendGfx_shaded_sprite +glabel appendGfx_shading_palette /* DF0B8 801489B8 27BDFF90 */ addiu $sp, $sp, -0x70 /* DF0BC 801489BC F7B60048 */ sdc1 $f22, 0x48($sp) /* DF0C0 801489C0 C7B60088 */ lwc1 $f22, 0x88($sp) diff --git a/ver/us/asm/nonmatchings/de740_len_23f0/render_shaded_sprite.s b/ver/us/asm/nonmatchings/de740_len_23f0/render_shaded_sprite.s deleted file mode 100644 index 56ed9061d4..0000000000 --- a/ver/us/asm/nonmatchings/de740_len_23f0/render_shaded_sprite.s +++ /dev/null @@ -1,538 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel render_shaded_sprite -/* DE8C4 801481C4 27BDFF08 */ addiu $sp, $sp, -0xf8 -/* DE8C8 801481C8 AFB300AC */ sw $s3, 0xac($sp) -/* DE8CC 801481CC 0080982D */ daddu $s3, $a0, $zero -/* DE8D0 801481D0 3C01BF80 */ lui $at, 0xbf80 -/* DE8D4 801481D4 44819000 */ mtc1 $at, $f18 -/* DE8D8 801481D8 3C038007 */ lui $v1, %hi(gCurrentCameraID) -/* DE8DC 801481DC 8C637410 */ lw $v1, %lo(gCurrentCameraID)($v1) -/* DE8E0 801481E0 3C04800B */ lui $a0, %hi(gCameras) -/* DE8E4 801481E4 24841D80 */ addiu $a0, $a0, %lo(gCameras) -/* DE8E8 801481E8 AFBF00C4 */ sw $ra, 0xc4($sp) -/* DE8EC 801481EC AFBE00C0 */ sw $fp, 0xc0($sp) -/* DE8F0 801481F0 AFB700BC */ sw $s7, 0xbc($sp) -/* DE8F4 801481F4 AFB600B8 */ sw $s6, 0xb8($sp) -/* DE8F8 801481F8 AFB500B4 */ sw $s5, 0xb4($sp) -/* DE8FC 801481FC AFB400B0 */ sw $s4, 0xb0($sp) -/* DE900 80148200 AFB200A8 */ sw $s2, 0xa8($sp) -/* DE904 80148204 AFB100A4 */ sw $s1, 0xa4($sp) -/* DE908 80148208 AFB000A0 */ sw $s0, 0xa0($sp) -/* DE90C 8014820C F7BE00F0 */ sdc1 $f30, 0xf0($sp) -/* DE910 80148210 F7BC00E8 */ sdc1 $f28, 0xe8($sp) -/* DE914 80148214 F7BA00E0 */ sdc1 $f26, 0xe0($sp) -/* DE918 80148218 F7B800D8 */ sdc1 $f24, 0xd8($sp) -/* DE91C 8014821C F7B600D0 */ sdc1 $f22, 0xd0($sp) -/* DE920 80148220 F7B400C8 */ sdc1 $f20, 0xc8($sp) -/* DE924 80148224 AFA70104 */ sw $a3, 0x104($sp) -/* DE928 80148228 AFA0004C */ sw $zero, 0x4c($sp) -/* DE92C 8014822C 00031080 */ sll $v0, $v1, 2 -/* DE930 80148230 00431021 */ addu $v0, $v0, $v1 -/* DE934 80148234 00021080 */ sll $v0, $v0, 2 -/* DE938 80148238 00431023 */ subu $v0, $v0, $v1 -/* DE93C 8014823C 000218C0 */ sll $v1, $v0, 3 -/* DE940 80148240 00431021 */ addu $v0, $v0, $v1 -/* DE944 80148244 E7B20060 */ swc1 $f18, 0x60($sp) -/* DE948 80148248 C7B2004C */ lwc1 $f18, 0x4c($sp) -/* DE94C 8014824C 000210C0 */ sll $v0, $v0, 3 -/* DE950 80148250 E7B20048 */ swc1 $f18, 0x48($sp) -/* DE954 80148254 E7B20050 */ swc1 $f18, 0x50($sp) -/* DE958 80148258 E7B2007C */ swc1 $f18, 0x7c($sp) -/* DE95C 8014825C E7B20078 */ swc1 $f18, 0x78($sp) -/* DE960 80148260 E7B20080 */ swc1 $f18, 0x80($sp) -/* DE964 80148264 E7B20084 */ swc1 $f18, 0x84($sp) -/* DE968 80148268 E7B20088 */ swc1 $f18, 0x88($sp) -/* DE96C 8014826C C6720008 */ lwc1 $f18, 8($s3) -/* DE970 80148270 00441021 */ addu $v0, $v0, $a0 -/* DE974 80148274 46009087 */ neg.s $f2, $f18 -/* DE978 80148278 E7B20064 */ swc1 $f18, 0x64($sp) -/* DE97C 8014827C C7B20080 */ lwc1 $f18, 0x80($sp) -/* DE980 80148280 C44000DC */ lwc1 $f0, 0xdc($v0) -/* DE984 80148284 E7B2008C */ swc1 $f18, 0x8c($sp) -/* DE988 80148288 C6720028 */ lwc1 $f18, 0x28($s3) -/* DE98C 8014828C 46001082 */ mul.s $f2, $f2, $f0 -/* DE990 80148290 00000000 */ nop -/* DE994 80148294 E7B20068 */ swc1 $f18, 0x68($sp) -/* DE998 80148298 C44000FC */ lwc1 $f0, 0xfc($v0) -/* DE99C 8014829C C7B20080 */ lwc1 $f18, 0x80($sp) -/* DE9A0 801482A0 3C028015 */ lui $v0, %hi(D_80151328) -/* DE9A4 801482A4 8C421328 */ lw $v0, %lo(D_80151328)($v0) -/* DE9A8 801482A8 8FB40108 */ lw $s4, 0x108($sp) -/* DE9AC 801482AC E7B20090 */ swc1 $f18, 0x90($sp) -/* DE9B0 801482B0 C7B20068 */ lwc1 $f18, 0x68($sp) -/* DE9B4 801482B4 8FB5010C */ lw $s5, 0x10c($sp) -/* DE9B8 801482B8 46009002 */ mul.s $f0, $f18, $f0 -/* DE9BC 801482BC 00000000 */ nop -/* DE9C0 801482C0 C7B20080 */ lwc1 $f18, 0x80($sp) -/* DE9C4 801482C4 E7B20094 */ swc1 $f18, 0x94($sp) -/* DE9C8 801482C8 904300AC */ lbu $v1, 0xac($v0) -/* DE9CC 801482CC E7B20098 */ swc1 $f18, 0x98($sp) -/* DE9D0 801482D0 44839000 */ mtc1 $v1, $f18 -/* DE9D4 801482D4 00000000 */ nop -/* DE9D8 801482D8 468094A0 */ cvt.s.w $f18, $f18 -/* DE9DC 801482DC E7B2006C */ swc1 $f18, 0x6c($sp) -/* DE9E0 801482E0 904300AD */ lbu $v1, 0xad($v0) -/* DE9E4 801482E4 904200AE */ lbu $v0, 0xae($v0) -/* DE9E8 801482E8 44839000 */ mtc1 $v1, $f18 -/* DE9EC 801482EC 00000000 */ nop -/* DE9F0 801482F0 468094A0 */ cvt.s.w $f18, $f18 -/* DE9F4 801482F4 E7B20070 */ swc1 $f18, 0x70($sp) -/* DE9F8 801482F8 44829000 */ mtc1 $v0, $f18 -/* DE9FC 801482FC 00000000 */ nop -/* DEA00 80148300 468094A0 */ cvt.s.w $f18, $f18 -/* DEA04 80148304 E7B20074 */ swc1 $f18, 0x74($sp) -/* DEA08 80148308 46001080 */ add.s $f2, $f2, $f0 -/* DEA0C 8014830C C7B20098 */ lwc1 $f18, 0x98($sp) -/* DEA10 80148310 8FB60110 */ lw $s6, 0x110($sp) -/* DEA14 80148314 4612103C */ c.lt.s $f2, $f18 -/* DEA18 80148318 C6720030 */ lwc1 $f18, 0x30($s3) -/* DEA1C 8014831C E7B20054 */ swc1 $f18, 0x54($sp) -/* DEA20 80148320 C6720034 */ lwc1 $f18, 0x34($s3) -/* DEA24 80148324 00A0B82D */ daddu $s7, $a1, $zero -/* DEA28 80148328 E7B20058 */ swc1 $f18, 0x58($sp) -/* DEA2C 8014832C C6720038 */ lwc1 $f18, 0x38($s3) -/* DEA30 80148330 E7B2005C */ swc1 $f18, 0x5c($sp) -/* DEA34 80148334 C67E0018 */ lwc1 $f30, 0x18($s3) -/* DEA38 80148338 45000005 */ bc1f .L80148350 -/* DEA3C 8014833C 00C0F02D */ daddu $fp, $a2, $zero -/* DEA40 80148340 3C013F80 */ lui $at, 0x3f80 -/* DEA44 80148344 44819000 */ mtc1 $at, $f18 -/* DEA48 80148348 00000000 */ nop -/* DEA4C 8014834C E7B20060 */ swc1 $f18, 0x60($sp) -.L80148350: -/* DEA50 80148350 0000902D */ daddu $s2, $zero, $zero -/* DEA54 80148354 C7BC0098 */ lwc1 $f28, 0x98($sp) -/* DEA58 80148358 24110004 */ addiu $s1, $zero, 4 -.L8014835C: -/* DEA5C 8014835C 3C028015 */ lui $v0, %hi(D_80151328) -/* DEA60 80148360 8C421328 */ lw $v0, %lo(D_80151328)($v0) -/* DEA64 80148364 00518021 */ addu $s0, $v0, $s1 -/* DEA68 80148368 92020000 */ lbu $v0, ($s0) -/* DEA6C 8014836C 30420001 */ andi $v0, $v0, 1 -/* DEA70 80148370 504000F5 */ beql $v0, $zero, .L80148748 -/* DEA74 80148374 26520001 */ addiu $s2, $s2, 1 -/* DEA78 80148378 C6000004 */ lwc1 $f0, 4($s0) -/* DEA7C 8014837C C7B20054 */ lwc1 $f18, 0x54($sp) -/* DEA80 80148380 46009681 */ sub.s $f26, $f18, $f0 -/* DEA84 80148384 461AD082 */ mul.s $f2, $f26, $f26 -/* DEA88 80148388 00000000 */ nop -/* DEA8C 8014838C C6000008 */ lwc1 $f0, 8($s0) -/* DEA90 80148390 C7B20058 */ lwc1 $f18, 0x58($sp) -/* DEA94 80148394 46009601 */ sub.s $f24, $f18, $f0 -/* DEA98 80148398 4618C102 */ mul.s $f4, $f24, $f24 -/* DEA9C 8014839C 00000000 */ nop -/* DEAA0 801483A0 C600000C */ lwc1 $f0, 0xc($s0) -/* DEAA4 801483A4 C7B2005C */ lwc1 $f18, 0x5c($sp) -/* DEAA8 801483A8 46009581 */ sub.s $f22, $f18, $f0 -/* DEAAC 801483AC 4616B002 */ mul.s $f0, $f22, $f22 -/* DEAB0 801483B0 00000000 */ nop -/* DEAB4 801483B4 46041080 */ add.s $f2, $f2, $f4 -/* DEAB8 801483B8 46001500 */ add.s $f20, $f2, $f0 -/* DEABC 801483BC 461CA032 */ c.eq.s $f20, $f28 -/* DEAC0 801483C0 00000000 */ nop -/* DEAC4 801483C4 4501000D */ bc1t .L801483FC -/* DEAC8 801483C8 4600E086 */ mov.s $f2, $f28 -/* DEACC 801483CC 4600A004 */ sqrt.s $f0, $f20 -/* DEAD0 801483D0 46000032 */ c.eq.s $f0, $f0 -/* DEAD4 801483D4 00000000 */ nop -/* DEAD8 801483D8 45010003 */ bc1t .L801483E8 -/* DEADC 801483DC 00000000 */ nop -/* DEAE0 801483E0 0C0187BC */ jal sqrtf -/* DEAE4 801483E4 4600A306 */ mov.s $f12, $f20 -.L801483E8: -/* DEAE8 801483E8 3C013F80 */ lui $at, 0x3f80 -/* DEAEC 801483EC 44819000 */ mtc1 $at, $f18 -/* DEAF0 801483F0 46000086 */ mov.s $f2, $f0 -/* DEAF4 801483F4 08052100 */ j .L80148400 -/* DEAF8 801483F8 46029003 */ div.s $f0, $f18, $f2 -.L801483FC: -/* DEAFC 801483FC 4600E006 */ mov.s $f0, $f28 -.L80148400: -/* DEB00 80148400 4600D682 */ mul.s $f26, $f26, $f0 -/* DEB04 80148404 00000000 */ nop -/* DEB08 80148408 4600C602 */ mul.s $f24, $f24, $f0 -/* DEB0C 8014840C 00000000 */ nop -/* DEB10 80148410 92030000 */ lbu $v1, ($s0) -/* DEB14 80148414 4600B582 */ mul.s $f22, $f22, $f0 -/* DEB18 80148418 00000000 */ nop -/* DEB1C 8014841C 30620004 */ andi $v0, $v1, 4 -/* DEB20 80148420 5040000E */ beql $v0, $zero, .L8014845C -/* DEB24 80148424 30620008 */ andi $v0, $v1, 8 -/* DEB28 80148428 461C1032 */ c.eq.s $f2, $f28 -/* DEB2C 8014842C 00000000 */ nop -/* DEB30 80148430 45000006 */ bc1f .L8014844C -/* DEB34 80148434 00000000 */ nop -/* DEB38 80148438 C6000010 */ lwc1 $f0, 0x10($s0) -/* DEB3C 8014843C 461C0032 */ c.eq.s $f0, $f28 -/* DEB40 80148440 00000000 */ nop -/* DEB44 80148444 4501001E */ bc1t .L801484C0 -/* DEB48 80148448 00000000 */ nop -.L8014844C: -/* DEB4C 8014844C C6000010 */ lwc1 $f0, 0x10($s0) -/* DEB50 80148450 46001002 */ mul.s $f0, $f2, $f0 -/* DEB54 80148454 08052125 */ j .L80148494 -/* DEB58 80148458 00000000 */ nop -.L8014845C: -/* DEB5C 8014845C 10400018 */ beqz $v0, .L801484C0 -/* DEB60 80148460 00000000 */ nop -/* DEB64 80148464 461CA032 */ c.eq.s $f20, $f28 -/* DEB68 80148468 00000000 */ nop -/* DEB6C 8014846C 45000006 */ bc1f .L80148488 -/* DEB70 80148470 00000000 */ nop -/* DEB74 80148474 C6000010 */ lwc1 $f0, 0x10($s0) -/* DEB78 80148478 461C0032 */ c.eq.s $f0, $f28 -/* DEB7C 8014847C 00000000 */ nop -/* DEB80 80148480 4501000F */ bc1t .L801484C0 -/* DEB84 80148484 00000000 */ nop -.L80148488: -/* DEB88 80148488 C6000010 */ lwc1 $f0, 0x10($s0) -/* DEB8C 8014848C 4600A002 */ mul.s $f0, $f20, $f0 -/* DEB90 80148490 00000000 */ nop -.L80148494: -/* DEB94 80148494 3C013F80 */ lui $at, 0x3f80 -/* DEB98 80148498 44819000 */ mtc1 $at, $f18 -/* DEB9C 8014849C 00000000 */ nop -/* DEBA0 801484A0 46009203 */ div.s $f8, $f18, $f0 -/* DEBA4 801484A4 4608D682 */ mul.s $f26, $f26, $f8 -/* DEBA8 801484A8 00000000 */ nop -/* DEBAC 801484AC 4608C602 */ mul.s $f24, $f24, $f8 -/* DEBB0 801484B0 00000000 */ nop -/* DEBB4 801484B4 4608B582 */ mul.s $f22, $f22, $f8 -/* DEBB8 801484B8 08052132 */ j .L801484C8 -/* DEBBC 801484BC 00000000 */ nop -.L801484C0: -/* DEBC0 801484C0 3C013F80 */ lui $at, 0x3f80 -/* DEBC4 801484C4 44814000 */ mtc1 $at, $f8 -.L801484C8: -/* DEBC8 801484C8 3C013F80 */ lui $at, 0x3f80 -/* DEBCC 801484CC 44819000 */ mtc1 $at, $f18 -/* DEBD0 801484D0 00000000 */ nop -/* DEBD4 801484D4 4608903C */ c.lt.s $f18, $f8 -/* DEBD8 801484D8 00000000 */ nop -/* DEBDC 801484DC 45030001 */ bc1tl .L801484E4 -/* DEBE0 801484E0 46009206 */ mov.s $f8, $f18 -.L801484E4: -/* DEBE4 801484E4 C7B20048 */ lwc1 $f18, 0x48($sp) -/* DEBE8 801484E8 461A9480 */ add.s $f18, $f18, $f26 -/* DEBEC 801484EC E7B20048 */ swc1 $f18, 0x48($sp) -/* DEBF0 801484F0 C7B2004C */ lwc1 $f18, 0x4c($sp) -/* DEBF4 801484F4 46189480 */ add.s $f18, $f18, $f24 -/* DEBF8 801484F8 E7B2004C */ swc1 $f18, 0x4c($sp) -/* DEBFC 801484FC C7B20050 */ lwc1 $f18, 0x50($sp) -/* DEC00 80148500 46169480 */ add.s $f18, $f18, $f22 -/* DEC04 80148504 E7B20050 */ swc1 $f18, 0x50($sp) -/* DEC08 80148508 C7B20060 */ lwc1 $f18, 0x60($sp) -/* DEC0C 8014850C 461C903C */ c.lt.s $f18, $f28 -/* DEC10 80148510 00000000 */ nop -/* DEC14 80148514 45000005 */ bc1f .L8014852C -/* DEC18 80148518 4600F086 */ mov.s $f2, $f30 -/* DEC1C 8014851C C7B20068 */ lwc1 $f18, 0x68($sp) -/* DEC20 80148520 C7A00064 */ lwc1 $f0, 0x64($sp) -/* DEC24 80148524 0805214E */ j .L80148538 -/* DEC28 80148528 46009107 */ neg.s $f4, $f18 -.L8014852C: -/* DEC2C 8014852C C7B20064 */ lwc1 $f18, 0x64($sp) -/* DEC30 80148530 C7A40068 */ lwc1 $f4, 0x68($sp) -/* DEC34 80148534 46009007 */ neg.s $f0, $f18 -.L80148538: -/* DEC38 80148538 461A0002 */ mul.s $f0, $f0, $f26 -/* DEC3C 8014853C 00000000 */ nop -/* DEC40 80148540 46181082 */ mul.s $f2, $f2, $f24 -/* DEC44 80148544 00000000 */ nop -/* DEC48 80148548 46162102 */ mul.s $f4, $f4, $f22 -/* DEC4C 8014854C 00000000 */ nop -/* DEC50 80148550 46020000 */ add.s $f0, $f0, $f2 -/* DEC54 80148554 C7B20060 */ lwc1 $f18, 0x60($sp) -/* DEC58 80148558 461C903C */ c.lt.s $f18, $f28 -/* DEC5C 8014855C 00000000 */ nop -/* DEC60 80148560 45000005 */ bc1f .L80148578 -/* DEC64 80148564 46040280 */ add.s $f10, $f0, $f4 -/* DEC68 80148568 C7A20068 */ lwc1 $f2, 0x68($sp) -/* DEC6C 8014856C C7A60064 */ lwc1 $f6, 0x64($sp) -/* DEC70 80148570 08052163 */ j .L8014858C -/* DEC74 80148574 4600F106 */ mov.s $f4, $f30 -.L80148578: -/* DEC78 80148578 C7B20068 */ lwc1 $f18, 0x68($sp) -/* DEC7C 8014857C 46009087 */ neg.s $f2, $f18 -/* DEC80 80148580 C7B20064 */ lwc1 $f18, 0x64($sp) -/* DEC84 80148584 4600F106 */ mov.s $f4, $f30 -/* DEC88 80148588 46009187 */ neg.s $f6, $f18 -.L8014858C: -/* DEC8C 8014858C 461A1082 */ mul.s $f2, $f2, $f26 -/* DEC90 80148590 00000000 */ nop -/* DEC94 80148594 46182102 */ mul.s $f4, $f4, $f24 -/* DEC98 80148598 00000000 */ nop -/* DEC9C 8014859C 46163182 */ mul.s $f6, $f6, $f22 -/* DECA0 801485A0 00000000 */ nop -/* DECA4 801485A4 46005005 */ abs.s $f0, $f10 -/* DECA8 801485A8 46004302 */ mul.s $f12, $f8, $f0 -/* DECAC 801485AC 00000000 */ nop -/* DECB0 801485B0 46041080 */ add.s $f2, $f2, $f4 -/* DECB4 801485B4 46061400 */ add.s $f16, $f2, $f6 -/* DECB8 801485B8 460AE03C */ c.lt.s $f28, $f10 -/* DECBC 801485BC 46008005 */ abs.s $f0, $f16 -/* DECC0 801485C0 46004182 */ mul.s $f6, $f8, $f0 -/* DECC4 801485C4 00000000 */ nop -/* DECC8 801485C8 45000021 */ bc1f .L80148650 -/* DECCC 801485CC 46008506 */ mov.s $f20, $f16 -/* DECD0 801485D0 92020001 */ lbu $v0, 1($s0) -/* DECD4 801485D4 44827000 */ mtc1 $v0, $f14 -/* DECD8 801485D8 00000000 */ nop -/* DECDC 801485DC 468073A0 */ cvt.s.w $f14, $f14 -/* DECE0 801485E0 460C7102 */ mul.s $f4, $f14, $f12 -/* DECE4 801485E4 00000000 */ nop -/* DECE8 801485E8 C7B20078 */ lwc1 $f18, 0x78($sp) -/* DECEC 801485EC 92020002 */ lbu $v0, 2($s0) -/* DECF0 801485F0 46049480 */ add.s $f18, $f18, $f4 -/* DECF4 801485F4 44825000 */ mtc1 $v0, $f10 -/* DECF8 801485F8 00000000 */ nop -/* DECFC 801485FC 468052A0 */ cvt.s.w $f10, $f10 -/* DED00 80148600 92020003 */ lbu $v0, 3($s0) -/* DED04 80148604 460C5082 */ mul.s $f2, $f10, $f12 -/* DED08 80148608 00000000 */ nop -/* DED0C 8014860C E7B20078 */ swc1 $f18, 0x78($sp) -/* DED10 80148610 C7B2007C */ lwc1 $f18, 0x7c($sp) -/* DED14 80148614 46029480 */ add.s $f18, $f18, $f2 -/* DED18 80148618 44824000 */ mtc1 $v0, $f8 -/* DED1C 8014861C 00000000 */ nop -/* DED20 80148620 46804220 */ cvt.s.w $f8, $f8 -/* DED24 80148624 460C4002 */ mul.s $f0, $f8, $f12 -/* DED28 80148628 00000000 */ nop -/* DED2C 8014862C E7B2007C */ swc1 $f18, 0x7c($sp) -/* DED30 80148630 C7B20080 */ lwc1 $f18, 0x80($sp) -/* DED34 80148634 46009480 */ add.s $f18, $f18, $f0 -/* DED38 80148638 4610E03C */ c.lt.s $f28, $f16 -/* DED3C 8014863C 00000000 */ nop -/* DED40 80148640 45010021 */ bc1t .L801486C8 -/* DED44 80148644 E7B20080 */ swc1 $f18, 0x80($sp) -/* DED48 80148648 080521C2 */ j .L80148708 -/* DED4C 8014864C 00000000 */ nop -.L80148650: -/* DED50 80148650 92020001 */ lbu $v0, 1($s0) -/* DED54 80148654 44827000 */ mtc1 $v0, $f14 -/* DED58 80148658 00000000 */ nop -/* DED5C 8014865C 468073A0 */ cvt.s.w $f14, $f14 -/* DED60 80148660 460C7102 */ mul.s $f4, $f14, $f12 -/* DED64 80148664 00000000 */ nop -/* DED68 80148668 C7B2006C */ lwc1 $f18, 0x6c($sp) -/* DED6C 8014866C 92020002 */ lbu $v0, 2($s0) -/* DED70 80148670 46049480 */ add.s $f18, $f18, $f4 -/* DED74 80148674 44825000 */ mtc1 $v0, $f10 -/* DED78 80148678 00000000 */ nop -/* DED7C 8014867C 468052A0 */ cvt.s.w $f10, $f10 -/* DED80 80148680 92020003 */ lbu $v0, 3($s0) -/* DED84 80148684 460C5082 */ mul.s $f2, $f10, $f12 -/* DED88 80148688 00000000 */ nop -/* DED8C 8014868C E7B2006C */ swc1 $f18, 0x6c($sp) -/* DED90 80148690 C7B20070 */ lwc1 $f18, 0x70($sp) -/* DED94 80148694 46029480 */ add.s $f18, $f18, $f2 -/* DED98 80148698 44824000 */ mtc1 $v0, $f8 -/* DED9C 8014869C 00000000 */ nop -/* DEDA0 801486A0 46804220 */ cvt.s.w $f8, $f8 -/* DEDA4 801486A4 460C4002 */ mul.s $f0, $f8, $f12 -/* DEDA8 801486A8 00000000 */ nop -/* DEDAC 801486AC E7B20070 */ swc1 $f18, 0x70($sp) -/* DEDB0 801486B0 C7B20074 */ lwc1 $f18, 0x74($sp) -/* DEDB4 801486B4 46009480 */ add.s $f18, $f18, $f0 -/* DEDB8 801486B8 4614E03C */ c.lt.s $f28, $f20 -/* DEDBC 801486BC 00000000 */ nop -/* DEDC0 801486C0 45000011 */ bc1f .L80148708 -/* DEDC4 801486C4 E7B20074 */ swc1 $f18, 0x74($sp) -.L801486C8: -/* DEDC8 801486C8 46067002 */ mul.s $f0, $f14, $f6 -/* DEDCC 801486CC 00000000 */ nop -/* DEDD0 801486D0 C7B20084 */ lwc1 $f18, 0x84($sp) -/* DEDD4 801486D4 46009480 */ add.s $f18, $f18, $f0 -/* DEDD8 801486D8 46065082 */ mul.s $f2, $f10, $f6 -/* DEDDC 801486DC 00000000 */ nop -/* DEDE0 801486E0 E7B20084 */ swc1 $f18, 0x84($sp) -/* DEDE4 801486E4 C7B20088 */ lwc1 $f18, 0x88($sp) -/* DEDE8 801486E8 46029480 */ add.s $f18, $f18, $f2 -/* DEDEC 801486EC 46064102 */ mul.s $f4, $f8, $f6 -/* DEDF0 801486F0 00000000 */ nop -/* DEDF4 801486F4 E7B20088 */ swc1 $f18, 0x88($sp) -/* DEDF8 801486F8 C7B2008C */ lwc1 $f18, 0x8c($sp) -/* DEDFC 801486FC 46049480 */ add.s $f18, $f18, $f4 -/* DEE00 80148700 080521D1 */ j .L80148744 -/* DEE04 80148704 E7B2008C */ swc1 $f18, 0x8c($sp) -.L80148708: -/* DEE08 80148708 46067002 */ mul.s $f0, $f14, $f6 -/* DEE0C 8014870C 00000000 */ nop -/* DEE10 80148710 C7B20090 */ lwc1 $f18, 0x90($sp) -/* DEE14 80148714 46009480 */ add.s $f18, $f18, $f0 -/* DEE18 80148718 46065082 */ mul.s $f2, $f10, $f6 -/* DEE1C 8014871C 00000000 */ nop -/* DEE20 80148720 E7B20090 */ swc1 $f18, 0x90($sp) -/* DEE24 80148724 C7B20094 */ lwc1 $f18, 0x94($sp) -/* DEE28 80148728 46029480 */ add.s $f18, $f18, $f2 -/* DEE2C 8014872C 46064102 */ mul.s $f4, $f8, $f6 -/* DEE30 80148730 00000000 */ nop -/* DEE34 80148734 E7B20094 */ swc1 $f18, 0x94($sp) -/* DEE38 80148738 C7B20098 */ lwc1 $f18, 0x98($sp) -/* DEE3C 8014873C 46049480 */ add.s $f18, $f18, $f4 -/* DEE40 80148740 E7B20098 */ swc1 $f18, 0x98($sp) -.L80148744: -/* DEE44 80148744 26520001 */ addiu $s2, $s2, 1 -.L80148748: -/* DEE48 80148748 2A420007 */ slti $v0, $s2, 7 -/* DEE4C 8014874C 1440FF03 */ bnez $v0, .L8014835C -/* DEE50 80148750 26310018 */ addiu $s1, $s1, 0x18 -/* DEE54 80148754 44800000 */ mtc1 $zero, $f0 -/* DEE58 80148758 C7B20060 */ lwc1 $f18, 0x60($sp) -/* DEE5C 8014875C 4600903C */ c.lt.s $f18, $f0 -/* DEE60 80148760 00000000 */ nop -/* DEE64 80148764 45000004 */ bc1f .L80148778 -/* DEE68 80148768 4600F086 */ mov.s $f2, $f30 -/* DEE6C 8014876C C7A00068 */ lwc1 $f0, 0x68($sp) -/* DEE70 80148770 080521E2 */ j .L80148788 -/* DEE74 80148774 C7A40064 */ lwc1 $f4, 0x64($sp) -.L80148778: -/* DEE78 80148778 C7B20068 */ lwc1 $f18, 0x68($sp) -/* DEE7C 8014877C 46009007 */ neg.s $f0, $f18 -/* DEE80 80148780 C7B20064 */ lwc1 $f18, 0x64($sp) -/* DEE84 80148784 46009107 */ neg.s $f4, $f18 -.L80148788: -/* DEE88 80148788 C7B20048 */ lwc1 $f18, 0x48($sp) -/* DEE8C 8014878C 46120002 */ mul.s $f0, $f0, $f18 -/* DEE90 80148790 00000000 */ nop -/* DEE94 80148794 C7B2004C */ lwc1 $f18, 0x4c($sp) -/* DEE98 80148798 46121082 */ mul.s $f2, $f2, $f18 -/* DEE9C 8014879C 00000000 */ nop -/* DEEA0 801487A0 C7B20050 */ lwc1 $f18, 0x50($sp) -/* DEEA4 801487A4 46122102 */ mul.s $f4, $f4, $f18 -/* DEEA8 801487A8 00000000 */ nop -/* DEEAC 801487AC 46020000 */ add.s $f0, $f0, $f2 -/* DEEB0 801487B0 46040000 */ add.s $f0, $f0, $f4 -/* DEEB4 801487B4 44801000 */ mtc1 $zero, $f2 -/* DEEB8 801487B8 00000000 */ nop -/* DEEBC 801487BC 4600103C */ c.lt.s $f2, $f0 -/* DEEC0 801487C0 00000000 */ nop -/* DEEC4 801487C4 45000031 */ bc1f .L8014888C -/* DEEC8 801487C8 00000000 */ nop -/* DEECC 801487CC C7B2006C */ lwc1 $f18, 0x6c($sp) -/* DEED0 801487D0 4600948D */ trunc.w.s $f18, $f18 -/* DEED4 801487D4 E7B20024 */ swc1 $f18, 0x24($sp) -/* DEED8 801487D8 C7B20070 */ lwc1 $f18, 0x70($sp) -/* DEEDC 801487DC 4600948D */ trunc.w.s $f18, $f18 -/* DEEE0 801487E0 E7B20028 */ swc1 $f18, 0x28($sp) -/* DEEE4 801487E4 C7B20074 */ lwc1 $f18, 0x74($sp) -/* DEEE8 801487E8 3C038015 */ lui $v1, %hi(D_80151328) -/* DEEEC 801487EC 8C631328 */ lw $v1, %lo(D_80151328)($v1) -/* DEEF0 801487F0 4600948D */ trunc.w.s $f18, $f18 -/* DEEF4 801487F4 E7B2002C */ swc1 $f18, 0x2c($sp) -/* DEEF8 801487F8 C7B20048 */ lwc1 $f18, 0x48($sp) -/* DEEFC 801487FC E7B20018 */ swc1 $f18, 0x18($sp) -/* DEF00 80148800 C7B2004C */ lwc1 $f18, 0x4c($sp) -/* DEF04 80148804 E7B2001C */ swc1 $f18, 0x1c($sp) -/* DEF08 80148808 C7B20050 */ lwc1 $f18, 0x50($sp) -/* DEF0C 8014880C AFB40010 */ sw $s4, 0x10($sp) -/* DEF10 80148810 AFB50014 */ sw $s5, 0x14($sp) -/* DEF14 80148814 E7B20020 */ swc1 $f18, 0x20($sp) -/* DEF18 80148818 906200AC */ lbu $v0, 0xac($v1) -/* DEF1C 8014881C C7B20078 */ lwc1 $f18, 0x78($sp) -/* DEF20 80148820 44820000 */ mtc1 $v0, $f0 -/* DEF24 80148824 00000000 */ nop -/* DEF28 80148828 46800020 */ cvt.s.w $f0, $f0 -/* DEF2C 8014882C 46120000 */ add.s $f0, $f0, $f18 -/* DEF30 80148830 C7B20084 */ lwc1 $f18, 0x84($sp) -/* DEF34 80148834 46120000 */ add.s $f0, $f0, $f18 -/* DEF38 80148838 4600048D */ trunc.w.s $f18, $f0 -/* DEF3C 8014883C E7B20030 */ swc1 $f18, 0x30($sp) -/* DEF40 80148840 906200AD */ lbu $v0, 0xad($v1) -/* DEF44 80148844 C7B2007C */ lwc1 $f18, 0x7c($sp) -/* DEF48 80148848 44820000 */ mtc1 $v0, $f0 -/* DEF4C 8014884C 00000000 */ nop -/* DEF50 80148850 46800020 */ cvt.s.w $f0, $f0 -/* DEF54 80148854 46120000 */ add.s $f0, $f0, $f18 -/* DEF58 80148858 C7B20088 */ lwc1 $f18, 0x88($sp) -/* DEF5C 8014885C 46120000 */ add.s $f0, $f0, $f18 -/* DEF60 80148860 4600048D */ trunc.w.s $f18, $f0 -/* DEF64 80148864 E7B20034 */ swc1 $f18, 0x34($sp) -/* DEF68 80148868 906200AE */ lbu $v0, 0xae($v1) -/* DEF6C 8014886C C7B20080 */ lwc1 $f18, 0x80($sp) -/* DEF70 80148870 44820000 */ mtc1 $v0, $f0 -/* DEF74 80148874 00000000 */ nop -/* DEF78 80148878 46800020 */ cvt.s.w $f0, $f0 -/* DEF7C 8014887C 46120000 */ add.s $f0, $f0, $f18 -/* DEF80 80148880 C7B2008C */ lwc1 $f18, 0x8c($sp) -/* DEF84 80148884 08052252 */ j .L80148948 -/* DEF88 80148888 46120000 */ add.s $f0, $f0, $f18 -.L8014888C: -/* DEF8C 8014888C C7B2006C */ lwc1 $f18, 0x6c($sp) -/* DEF90 80148890 4600948D */ trunc.w.s $f18, $f18 -/* DEF94 80148894 E7B20024 */ swc1 $f18, 0x24($sp) -/* DEF98 80148898 C7B20070 */ lwc1 $f18, 0x70($sp) -/* DEF9C 8014889C 4600948D */ trunc.w.s $f18, $f18 -/* DEFA0 801488A0 E7B20028 */ swc1 $f18, 0x28($sp) -/* DEFA4 801488A4 C7B20074 */ lwc1 $f18, 0x74($sp) -/* DEFA8 801488A8 3C038015 */ lui $v1, %hi(D_80151328) -/* DEFAC 801488AC 8C631328 */ lw $v1, %lo(D_80151328)($v1) -/* DEFB0 801488B0 4600948D */ trunc.w.s $f18, $f18 -/* DEFB4 801488B4 E7B2002C */ swc1 $f18, 0x2c($sp) -/* DEFB8 801488B8 C7B20048 */ lwc1 $f18, 0x48($sp) -/* DEFBC 801488BC E7B20018 */ swc1 $f18, 0x18($sp) -/* DEFC0 801488C0 C7B2004C */ lwc1 $f18, 0x4c($sp) -/* DEFC4 801488C4 E7B2001C */ swc1 $f18, 0x1c($sp) -/* DEFC8 801488C8 C7B20050 */ lwc1 $f18, 0x50($sp) -/* DEFCC 801488CC AFB40010 */ sw $s4, 0x10($sp) -/* DEFD0 801488D0 AFB50014 */ sw $s5, 0x14($sp) -/* DEFD4 801488D4 E7B20020 */ swc1 $f18, 0x20($sp) -/* DEFD8 801488D8 906200AC */ lbu $v0, 0xac($v1) -/* DEFDC 801488DC C7B20078 */ lwc1 $f18, 0x78($sp) -/* DEFE0 801488E0 44820000 */ mtc1 $v0, $f0 -/* DEFE4 801488E4 00000000 */ nop -/* DEFE8 801488E8 46800020 */ cvt.s.w $f0, $f0 -/* DEFEC 801488EC 46120000 */ add.s $f0, $f0, $f18 -/* DEFF0 801488F0 C7B20090 */ lwc1 $f18, 0x90($sp) -/* DEFF4 801488F4 46120000 */ add.s $f0, $f0, $f18 -/* DEFF8 801488F8 4600048D */ trunc.w.s $f18, $f0 -/* DEFFC 801488FC E7B20030 */ swc1 $f18, 0x30($sp) -/* DF000 80148900 906200AD */ lbu $v0, 0xad($v1) -/* DF004 80148904 C7B2007C */ lwc1 $f18, 0x7c($sp) -/* DF008 80148908 44820000 */ mtc1 $v0, $f0 -/* DF00C 8014890C 00000000 */ nop -/* DF010 80148910 46800020 */ cvt.s.w $f0, $f0 -/* DF014 80148914 46120000 */ add.s $f0, $f0, $f18 -/* DF018 80148918 C7B20094 */ lwc1 $f18, 0x94($sp) -/* DF01C 8014891C 46120000 */ add.s $f0, $f0, $f18 -/* DF020 80148920 4600048D */ trunc.w.s $f18, $f0 -/* DF024 80148924 E7B20034 */ swc1 $f18, 0x34($sp) -/* DF028 80148928 906200AE */ lbu $v0, 0xae($v1) -/* DF02C 8014892C C7B20080 */ lwc1 $f18, 0x80($sp) -/* DF030 80148930 44820000 */ mtc1 $v0, $f0 -/* DF034 80148934 00000000 */ nop -/* DF038 80148938 46800020 */ cvt.s.w $f0, $f0 -/* DF03C 8014893C 46120000 */ add.s $f0, $f0, $f18 -/* DF040 80148940 C7B20098 */ lwc1 $f18, 0x98($sp) -/* DF044 80148944 46120000 */ add.s $f0, $f0, $f18 -.L80148948: -/* DF048 80148948 0260202D */ daddu $a0, $s3, $zero -/* DF04C 8014894C 02E0282D */ daddu $a1, $s7, $zero -/* DF050 80148950 4600048D */ trunc.w.s $f18, $f0 -/* DF054 80148954 E7B20038 */ swc1 $f18, 0x38($sp) -/* DF058 80148958 906200AF */ lbu $v0, 0xaf($v1) -/* DF05C 8014895C 8FA70104 */ lw $a3, 0x104($sp) -/* DF060 80148960 03C0302D */ daddu $a2, $fp, $zero -/* DF064 80148964 AFB60040 */ sw $s6, 0x40($sp) -/* DF068 80148968 0C05226E */ jal appendGfx_shaded_sprite -/* DF06C 8014896C AFA2003C */ sw $v0, 0x3c($sp) -/* DF070 80148970 8FBF00C4 */ lw $ra, 0xc4($sp) -/* DF074 80148974 8FBE00C0 */ lw $fp, 0xc0($sp) -/* DF078 80148978 8FB700BC */ lw $s7, 0xbc($sp) -/* DF07C 8014897C 8FB600B8 */ lw $s6, 0xb8($sp) -/* DF080 80148980 8FB500B4 */ lw $s5, 0xb4($sp) -/* DF084 80148984 8FB400B0 */ lw $s4, 0xb0($sp) -/* DF088 80148988 8FB300AC */ lw $s3, 0xac($sp) -/* DF08C 8014898C 8FB200A8 */ lw $s2, 0xa8($sp) -/* DF090 80148990 8FB100A4 */ lw $s1, 0xa4($sp) -/* DF094 80148994 8FB000A0 */ lw $s0, 0xa0($sp) -/* DF098 80148998 D7BE00F0 */ ldc1 $f30, 0xf0($sp) -/* DF09C 8014899C D7BC00E8 */ ldc1 $f28, 0xe8($sp) -/* DF0A0 801489A0 D7BA00E0 */ ldc1 $f26, 0xe0($sp) -/* DF0A4 801489A4 D7B800D8 */ ldc1 $f24, 0xd8($sp) -/* DF0A8 801489A8 D7B600D0 */ ldc1 $f22, 0xd0($sp) -/* DF0AC 801489AC D7B400C8 */ ldc1 $f20, 0xc8($sp) -/* DF0B0 801489B0 03E00008 */ jr $ra -/* DF0B4 801489B4 27BD00F8 */ addiu $sp, $sp, 0xf8 diff --git a/ver/us/asm/nonmatchings/sprite/spr_appendGfx_component_flat.s b/ver/us/asm/nonmatchings/sprite/spr_appendGfx_component_flat.s index f26dc3e3d1..7daf0ab47c 100644 --- a/ver/us/asm/nonmatchings/sprite/spr_appendGfx_component_flat.s +++ b/ver/us/asm/nonmatchings/sprite/spr_appendGfx_component_flat.s @@ -255,7 +255,7 @@ glabel spr_appendGfx_component_flat /* FF4C4 802DC3D4 8FA40050 */ lw $a0, 0x50($sp) /* FF4C8 802DC3D8 0000282D */ daddu $a1, $zero, $zero /* FF4CC 802DC3DC 00A0302D */ daddu $a2, $a1, $zero -/* FF4D0 802DC3E0 0C052071 */ jal render_shaded_sprite +/* FF4D0 802DC3E0 0C052071 */ jal create_shading_palette /* FF4D4 802DC3E4 01A0382D */ daddu $a3, $t5, $zero /* FF4D8 802DC3E8 080B71E2 */ j .L802DC788 /* FF4DC 802DC3EC 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_jan/jan_05/B4ADC0/func_80240350_B4ADC0.s b/ver/us/asm/nonmatchings/world/area_jan/jan_05/B4ADC0/func_80240350_B4ADC0.s deleted file mode 100644 index 4d910e543f..0000000000 --- a/ver/us/asm/nonmatchings/world/area_jan/jan_05/B4ADC0/func_80240350_B4ADC0.s +++ /dev/null @@ -1,91 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_80240350_B4ADC0 -/* B4ADC0 80240350 27BDFFC0 */ addiu $sp, $sp, -0x40 -/* B4ADC4 80240354 AFB10034 */ sw $s1, 0x34($sp) -/* B4ADC8 80240358 0080882D */ daddu $s1, $a0, $zero -/* B4ADCC 8024035C AFBF0038 */ sw $ra, 0x38($sp) -/* B4ADD0 80240360 AFB00030 */ sw $s0, 0x30($sp) -/* B4ADD4 80240364 10A00016 */ beqz $a1, .L802403C0 -/* B4ADD8 80240368 8E30000C */ lw $s0, 0xc($s1) -/* B4ADDC 8024036C 8E050000 */ lw $a1, ($s0) -/* B4ADE0 80240370 0C0B1EAF */ jal evt_get_variable -/* B4ADE4 80240374 26100004 */ addiu $s0, $s0, 4 -/* B4ADE8 80240378 8E030000 */ lw $v1, ($s0) -/* B4ADEC 8024037C 0040202D */ daddu $a0, $v0, $zero -/* B4ADF0 80240380 0C046C04 */ jal get_model_list_index_from_tree_index -/* B4ADF4 80240384 AE23007C */ sw $v1, 0x7c($s1) -/* B4ADF8 80240388 0C046B4C */ jal get_model_from_list_index -/* B4ADFC 8024038C 0040202D */ daddu $a0, $v0, $zero -/* B4AE00 80240390 0040802D */ daddu $s0, $v0, $zero -/* B4AE04 80240394 0000202D */ daddu $a0, $zero, $zero -/* B4AE08 80240398 AE300074 */ sw $s0, 0x74($s1) -/* B4AE0C 8024039C 8E050098 */ lw $a1, 0x98($s0) -/* B4AE10 802403A0 8E0700A0 */ lw $a3, 0xa0($s0) -/* B4AE14 802403A4 0C044898 */ jal create_shadow_type -/* B4AE18 802403A8 0000302D */ daddu $a2, $zero, $zero -/* B4AE1C 802403AC 0220202D */ daddu $a0, $s1, $zero -/* B4AE20 802403B0 8E25007C */ lw $a1, 0x7c($s1) -/* B4AE24 802403B4 0000302D */ daddu $a2, $zero, $zero -/* B4AE28 802403B8 0C0B2026 */ jal evt_set_variable -/* B4AE2C 802403BC AE220078 */ sw $v0, 0x78($s1) -.L802403C0: -/* B4AE30 802403C0 8E25007C */ lw $a1, 0x7c($s1) -/* B4AE34 802403C4 0C0B1EAF */ jal evt_get_variable -/* B4AE38 802403C8 0220202D */ daddu $a0, $s1, $zero -/* B4AE3C 802403CC 1440002A */ bnez $v0, .L80240478 -/* B4AE40 802403D0 00000000 */ nop -/* B4AE44 802403D4 8E240078 */ lw $a0, 0x78($s1) -/* B4AE48 802403D8 0C044181 */ jal get_shadow_by_index -/* B4AE4C 802403DC 8E300074 */ lw $s0, 0x74($s1) -/* B4AE50 802403E0 27A40018 */ addiu $a0, $sp, 0x18 -/* B4AE54 802403E4 27A5001C */ addiu $a1, $sp, 0x1c -/* B4AE58 802403E8 27A60020 */ addiu $a2, $sp, 0x20 -/* B4AE5C 802403EC 27A70024 */ addiu $a3, $sp, 0x24 -/* B4AE60 802403F0 27A30028 */ addiu $v1, $sp, 0x28 -/* B4AE64 802403F4 C6000098 */ lwc1 $f0, 0x98($s0) -/* B4AE68 802403F8 C602009C */ lwc1 $f2, 0x9c($s0) -/* B4AE6C 802403FC C60400A0 */ lwc1 $f4, 0xa0($s0) -/* B4AE70 80240400 0040802D */ daddu $s0, $v0, $zero -/* B4AE74 80240404 E7A00018 */ swc1 $f0, 0x18($sp) -/* B4AE78 80240408 E7A2001C */ swc1 $f2, 0x1c($sp) -/* B4AE7C 8024040C E7A40020 */ swc1 $f4, 0x20($sp) -/* B4AE80 80240410 AFA30010 */ sw $v1, 0x10($sp) -/* B4AE84 80240414 27A3002C */ addiu $v1, $sp, 0x2c -/* B4AE88 80240418 0C04497A */ jal entity_raycast_down -/* B4AE8C 8024041C AFA30014 */ sw $v1, 0x14($sp) -/* B4AE90 80240420 8FA5002C */ lw $a1, 0x2c($sp) -/* B4AE94 80240424 0C044A17 */ jal set_standard_shadow_scale -/* B4AE98 80240428 0200202D */ daddu $a0, $s0, $zero -/* B4AE9C 8024042C C7A00018 */ lwc1 $f0, 0x18($sp) -/* B4AEA0 80240430 C7A2001C */ lwc1 $f2, 0x1c($sp) -/* B4AEA4 80240434 C7A60020 */ lwc1 $f6, 0x20($sp) -/* B4AEA8 80240438 C7A80024 */ lwc1 $f8, 0x24($sp) -/* B4AEAC 8024043C C604001C */ lwc1 $f4, 0x1c($s0) -/* B4AEB0 80240440 0000102D */ daddu $v0, $zero, $zero -/* B4AEB4 80240444 AE00002C */ sw $zero, 0x2c($s0) -/* B4AEB8 80240448 E6000010 */ swc1 $f0, 0x10($s0) -/* B4AEBC 8024044C C6000024 */ lwc1 $f0, 0x24($s0) -/* B4AEC0 80240450 46042100 */ add.s $f4, $f4, $f4 -/* B4AEC4 80240454 E6020014 */ swc1 $f2, 0x14($s0) -/* B4AEC8 80240458 E6060018 */ swc1 $f6, 0x18($s0) -/* B4AECC 8024045C E6080028 */ swc1 $f8, 0x28($s0) -/* B4AED0 80240460 C7A20028 */ lwc1 $f2, 0x28($sp) -/* B4AED4 80240464 46000000 */ add.s $f0, $f0, $f0 -/* B4AED8 80240468 E6020030 */ swc1 $f2, 0x30($s0) -/* B4AEDC 8024046C E604001C */ swc1 $f4, 0x1c($s0) -/* B4AEE0 80240470 08090122 */ j .L80240488 -/* B4AEE4 80240474 E6000024 */ swc1 $f0, 0x24($s0) -.L80240478: -/* B4AEE8 80240478 8E240078 */ lw $a0, 0x78($s1) -/* B4AEEC 8024047C 0C0448CA */ jal delete_shadow -/* B4AEF0 80240480 00000000 */ nop -/* B4AEF4 80240484 24020002 */ addiu $v0, $zero, 2 -.L80240488: -/* B4AEF8 80240488 8FBF0038 */ lw $ra, 0x38($sp) -/* B4AEFC 8024048C 8FB10034 */ lw $s1, 0x34($sp) -/* B4AF00 80240490 8FB00030 */ lw $s0, 0x30($sp) -/* B4AF04 80240494 03E00008 */ jr $ra -/* B4AF08 80240498 27BD0040 */ addiu $sp, $sp, 0x40 -/* B4AF0C 8024049C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_jan/jan_06/B52BE0/func_802403B0_B52BE0.s b/ver/us/asm/nonmatchings/world/area_jan/jan_06/B52BE0/func_802403B0_B52BE0.s deleted file mode 100644 index 141e469d0c..0000000000 --- a/ver/us/asm/nonmatchings/world/area_jan/jan_06/B52BE0/func_802403B0_B52BE0.s +++ /dev/null @@ -1,91 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_802403B0_B52BE0 -/* B52BE0 802403B0 27BDFFC0 */ addiu $sp, $sp, -0x40 -/* B52BE4 802403B4 AFB10034 */ sw $s1, 0x34($sp) -/* B52BE8 802403B8 0080882D */ daddu $s1, $a0, $zero -/* B52BEC 802403BC AFBF0038 */ sw $ra, 0x38($sp) -/* B52BF0 802403C0 AFB00030 */ sw $s0, 0x30($sp) -/* B52BF4 802403C4 10A00016 */ beqz $a1, .L80240420 -/* B52BF8 802403C8 8E30000C */ lw $s0, 0xc($s1) -/* B52BFC 802403CC 8E050000 */ lw $a1, ($s0) -/* B52C00 802403D0 0C0B1EAF */ jal evt_get_variable -/* B52C04 802403D4 26100004 */ addiu $s0, $s0, 4 -/* B52C08 802403D8 8E030000 */ lw $v1, ($s0) -/* B52C0C 802403DC 0040202D */ daddu $a0, $v0, $zero -/* B52C10 802403E0 0C046C04 */ jal get_model_list_index_from_tree_index -/* B52C14 802403E4 AE23007C */ sw $v1, 0x7c($s1) -/* B52C18 802403E8 0C046B4C */ jal get_model_from_list_index -/* B52C1C 802403EC 0040202D */ daddu $a0, $v0, $zero -/* B52C20 802403F0 0040802D */ daddu $s0, $v0, $zero -/* B52C24 802403F4 0000202D */ daddu $a0, $zero, $zero -/* B52C28 802403F8 AE300074 */ sw $s0, 0x74($s1) -/* B52C2C 802403FC 8E050098 */ lw $a1, 0x98($s0) -/* B52C30 80240400 8E0700A0 */ lw $a3, 0xa0($s0) -/* B52C34 80240404 0C044898 */ jal create_shadow_type -/* B52C38 80240408 0000302D */ daddu $a2, $zero, $zero -/* B52C3C 8024040C 0220202D */ daddu $a0, $s1, $zero -/* B52C40 80240410 8E25007C */ lw $a1, 0x7c($s1) -/* B52C44 80240414 0000302D */ daddu $a2, $zero, $zero -/* B52C48 80240418 0C0B2026 */ jal evt_set_variable -/* B52C4C 8024041C AE220078 */ sw $v0, 0x78($s1) -.L80240420: -/* B52C50 80240420 8E25007C */ lw $a1, 0x7c($s1) -/* B52C54 80240424 0C0B1EAF */ jal evt_get_variable -/* B52C58 80240428 0220202D */ daddu $a0, $s1, $zero -/* B52C5C 8024042C 1440002A */ bnez $v0, .L802404D8 -/* B52C60 80240430 00000000 */ nop -/* B52C64 80240434 8E240078 */ lw $a0, 0x78($s1) -/* B52C68 80240438 0C044181 */ jal get_shadow_by_index -/* B52C6C 8024043C 8E300074 */ lw $s0, 0x74($s1) -/* B52C70 80240440 27A40018 */ addiu $a0, $sp, 0x18 -/* B52C74 80240444 27A5001C */ addiu $a1, $sp, 0x1c -/* B52C78 80240448 27A60020 */ addiu $a2, $sp, 0x20 -/* B52C7C 8024044C 27A70024 */ addiu $a3, $sp, 0x24 -/* B52C80 80240450 27A30028 */ addiu $v1, $sp, 0x28 -/* B52C84 80240454 C6000098 */ lwc1 $f0, 0x98($s0) -/* B52C88 80240458 C602009C */ lwc1 $f2, 0x9c($s0) -/* B52C8C 8024045C C60400A0 */ lwc1 $f4, 0xa0($s0) -/* B52C90 80240460 0040802D */ daddu $s0, $v0, $zero -/* B52C94 80240464 E7A00018 */ swc1 $f0, 0x18($sp) -/* B52C98 80240468 E7A2001C */ swc1 $f2, 0x1c($sp) -/* B52C9C 8024046C E7A40020 */ swc1 $f4, 0x20($sp) -/* B52CA0 80240470 AFA30010 */ sw $v1, 0x10($sp) -/* B52CA4 80240474 27A3002C */ addiu $v1, $sp, 0x2c -/* B52CA8 80240478 0C04497A */ jal entity_raycast_down -/* B52CAC 8024047C AFA30014 */ sw $v1, 0x14($sp) -/* B52CB0 80240480 8FA5002C */ lw $a1, 0x2c($sp) -/* B52CB4 80240484 0C044A17 */ jal set_standard_shadow_scale -/* B52CB8 80240488 0200202D */ daddu $a0, $s0, $zero -/* B52CBC 8024048C C7A00018 */ lwc1 $f0, 0x18($sp) -/* B52CC0 80240490 C7A2001C */ lwc1 $f2, 0x1c($sp) -/* B52CC4 80240494 C7A60020 */ lwc1 $f6, 0x20($sp) -/* B52CC8 80240498 C7A80024 */ lwc1 $f8, 0x24($sp) -/* B52CCC 8024049C C604001C */ lwc1 $f4, 0x1c($s0) -/* B52CD0 802404A0 0000102D */ daddu $v0, $zero, $zero -/* B52CD4 802404A4 AE00002C */ sw $zero, 0x2c($s0) -/* B52CD8 802404A8 E6000010 */ swc1 $f0, 0x10($s0) -/* B52CDC 802404AC C6000024 */ lwc1 $f0, 0x24($s0) -/* B52CE0 802404B0 46042100 */ add.s $f4, $f4, $f4 -/* B52CE4 802404B4 E6020014 */ swc1 $f2, 0x14($s0) -/* B52CE8 802404B8 E6060018 */ swc1 $f6, 0x18($s0) -/* B52CEC 802404BC E6080028 */ swc1 $f8, 0x28($s0) -/* B52CF0 802404C0 C7A20028 */ lwc1 $f2, 0x28($sp) -/* B52CF4 802404C4 46000000 */ add.s $f0, $f0, $f0 -/* B52CF8 802404C8 E6020030 */ swc1 $f2, 0x30($s0) -/* B52CFC 802404CC E604001C */ swc1 $f4, 0x1c($s0) -/* B52D00 802404D0 0809013A */ j .L802404E8 -/* B52D04 802404D4 E6000024 */ swc1 $f0, 0x24($s0) -.L802404D8: -/* B52D08 802404D8 8E240078 */ lw $a0, 0x78($s1) -/* B52D0C 802404DC 0C0448CA */ jal delete_shadow -/* B52D10 802404E0 00000000 */ nop -/* B52D14 802404E4 24020002 */ addiu $v0, $zero, 2 -.L802404E8: -/* B52D18 802404E8 8FBF0038 */ lw $ra, 0x38($sp) -/* B52D1C 802404EC 8FB10034 */ lw $s1, 0x34($sp) -/* B52D20 802404F0 8FB00030 */ lw $s0, 0x30($sp) -/* B52D24 802404F4 03E00008 */ jr $ra -/* B52D28 802404F8 27BD0040 */ addiu $sp, $sp, 0x40 -/* B52D2C 802404FC 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_jan/jan_10/B6D4C0/func_80241130_B6D4C0.s b/ver/us/asm/nonmatchings/world/area_jan/jan_10/B6D4C0/func_80241130_B6D4C0.s deleted file mode 100644 index a14c6e30e1..0000000000 --- a/ver/us/asm/nonmatchings/world/area_jan/jan_10/B6D4C0/func_80241130_B6D4C0.s +++ /dev/null @@ -1,91 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_80241130_B6D4C0 -/* B6D4C0 80241130 27BDFFC0 */ addiu $sp, $sp, -0x40 -/* B6D4C4 80241134 AFB10034 */ sw $s1, 0x34($sp) -/* B6D4C8 80241138 0080882D */ daddu $s1, $a0, $zero -/* B6D4CC 8024113C AFBF0038 */ sw $ra, 0x38($sp) -/* B6D4D0 80241140 AFB00030 */ sw $s0, 0x30($sp) -/* B6D4D4 80241144 10A00016 */ beqz $a1, .L802411A0 -/* B6D4D8 80241148 8E30000C */ lw $s0, 0xc($s1) -/* B6D4DC 8024114C 8E050000 */ lw $a1, ($s0) -/* B6D4E0 80241150 0C0B1EAF */ jal evt_get_variable -/* B6D4E4 80241154 26100004 */ addiu $s0, $s0, 4 -/* B6D4E8 80241158 8E030000 */ lw $v1, ($s0) -/* B6D4EC 8024115C 0040202D */ daddu $a0, $v0, $zero -/* B6D4F0 80241160 0C046C04 */ jal get_model_list_index_from_tree_index -/* B6D4F4 80241164 AE23007C */ sw $v1, 0x7c($s1) -/* B6D4F8 80241168 0C046B4C */ jal get_model_from_list_index -/* B6D4FC 8024116C 0040202D */ daddu $a0, $v0, $zero -/* B6D500 80241170 0040802D */ daddu $s0, $v0, $zero -/* B6D504 80241174 0000202D */ daddu $a0, $zero, $zero -/* B6D508 80241178 AE300074 */ sw $s0, 0x74($s1) -/* B6D50C 8024117C 8E050098 */ lw $a1, 0x98($s0) -/* B6D510 80241180 8E0700A0 */ lw $a3, 0xa0($s0) -/* B6D514 80241184 0C044898 */ jal create_shadow_type -/* B6D518 80241188 0000302D */ daddu $a2, $zero, $zero -/* B6D51C 8024118C 0220202D */ daddu $a0, $s1, $zero -/* B6D520 80241190 8E25007C */ lw $a1, 0x7c($s1) -/* B6D524 80241194 0000302D */ daddu $a2, $zero, $zero -/* B6D528 80241198 0C0B2026 */ jal evt_set_variable -/* B6D52C 8024119C AE220078 */ sw $v0, 0x78($s1) -.L802411A0: -/* B6D530 802411A0 8E25007C */ lw $a1, 0x7c($s1) -/* B6D534 802411A4 0C0B1EAF */ jal evt_get_variable -/* B6D538 802411A8 0220202D */ daddu $a0, $s1, $zero -/* B6D53C 802411AC 1440002A */ bnez $v0, .L80241258 -/* B6D540 802411B0 00000000 */ nop -/* B6D544 802411B4 8E240078 */ lw $a0, 0x78($s1) -/* B6D548 802411B8 0C044181 */ jal get_shadow_by_index -/* B6D54C 802411BC 8E300074 */ lw $s0, 0x74($s1) -/* B6D550 802411C0 27A40018 */ addiu $a0, $sp, 0x18 -/* B6D554 802411C4 27A5001C */ addiu $a1, $sp, 0x1c -/* B6D558 802411C8 27A60020 */ addiu $a2, $sp, 0x20 -/* B6D55C 802411CC 27A70024 */ addiu $a3, $sp, 0x24 -/* B6D560 802411D0 27A30028 */ addiu $v1, $sp, 0x28 -/* B6D564 802411D4 C6000098 */ lwc1 $f0, 0x98($s0) -/* B6D568 802411D8 C602009C */ lwc1 $f2, 0x9c($s0) -/* B6D56C 802411DC C60400A0 */ lwc1 $f4, 0xa0($s0) -/* B6D570 802411E0 0040802D */ daddu $s0, $v0, $zero -/* B6D574 802411E4 E7A00018 */ swc1 $f0, 0x18($sp) -/* B6D578 802411E8 E7A2001C */ swc1 $f2, 0x1c($sp) -/* B6D57C 802411EC E7A40020 */ swc1 $f4, 0x20($sp) -/* B6D580 802411F0 AFA30010 */ sw $v1, 0x10($sp) -/* B6D584 802411F4 27A3002C */ addiu $v1, $sp, 0x2c -/* B6D588 802411F8 0C04497A */ jal entity_raycast_down -/* B6D58C 802411FC AFA30014 */ sw $v1, 0x14($sp) -/* B6D590 80241200 8FA5002C */ lw $a1, 0x2c($sp) -/* B6D594 80241204 0C044A17 */ jal set_standard_shadow_scale -/* B6D598 80241208 0200202D */ daddu $a0, $s0, $zero -/* B6D59C 8024120C C7A00018 */ lwc1 $f0, 0x18($sp) -/* B6D5A0 80241210 C7A2001C */ lwc1 $f2, 0x1c($sp) -/* B6D5A4 80241214 C7A60020 */ lwc1 $f6, 0x20($sp) -/* B6D5A8 80241218 C7A80024 */ lwc1 $f8, 0x24($sp) -/* B6D5AC 8024121C C604001C */ lwc1 $f4, 0x1c($s0) -/* B6D5B0 80241220 0000102D */ daddu $v0, $zero, $zero -/* B6D5B4 80241224 AE00002C */ sw $zero, 0x2c($s0) -/* B6D5B8 80241228 E6000010 */ swc1 $f0, 0x10($s0) -/* B6D5BC 8024122C C6000024 */ lwc1 $f0, 0x24($s0) -/* B6D5C0 80241230 46042100 */ add.s $f4, $f4, $f4 -/* B6D5C4 80241234 E6020014 */ swc1 $f2, 0x14($s0) -/* B6D5C8 80241238 E6060018 */ swc1 $f6, 0x18($s0) -/* B6D5CC 8024123C E6080028 */ swc1 $f8, 0x28($s0) -/* B6D5D0 80241240 C7A20028 */ lwc1 $f2, 0x28($sp) -/* B6D5D4 80241244 46000000 */ add.s $f0, $f0, $f0 -/* B6D5D8 80241248 E6020030 */ swc1 $f2, 0x30($s0) -/* B6D5DC 8024124C E604001C */ swc1 $f4, 0x1c($s0) -/* B6D5E0 80241250 0809049A */ j .L80241268 -/* B6D5E4 80241254 E6000024 */ swc1 $f0, 0x24($s0) -.L80241258: -/* B6D5E8 80241258 8E240078 */ lw $a0, 0x78($s1) -/* B6D5EC 8024125C 0C0448CA */ jal delete_shadow -/* B6D5F0 80241260 00000000 */ nop -/* B6D5F4 80241264 24020002 */ addiu $v0, $zero, 2 -.L80241268: -/* B6D5F8 80241268 8FBF0038 */ lw $ra, 0x38($sp) -/* B6D5FC 8024126C 8FB10034 */ lw $s1, 0x34($sp) -/* B6D600 80241270 8FB00030 */ lw $s0, 0x30($sp) -/* B6D604 80241274 03E00008 */ jr $ra -/* B6D608 80241278 27BD0040 */ addiu $sp, $sp, 0x40 -/* B6D60C 8024127C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_08/A4CA20/func_8024001C_A4CA3C.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_08/A4CA20/func_8024001C_A4CA3C.s deleted file mode 100644 index 3721579a04..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_08/A4CA20/func_8024001C_A4CA3C.s +++ /dev/null @@ -1,38 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_8024001C_A4CA3C -/* A4CA3C 8024001C 27BDFFE0 */ addiu $sp, $sp, -0x20 -/* A4CA40 80240020 AFB10014 */ sw $s1, 0x14($sp) -/* A4CA44 80240024 0080882D */ daddu $s1, $a0, $zero -/* A4CA48 80240028 AFBF0018 */ sw $ra, 0x18($sp) -/* A4CA4C 8024002C AFB00010 */ sw $s0, 0x10($sp) -/* A4CA50 80240030 8E30000C */ lw $s0, 0xc($s1) -/* A4CA54 80240034 8E050000 */ lw $a1, ($s0) -/* A4CA58 80240038 0C0B1EAF */ jal evt_get_variable -/* A4CA5C 8024003C 26100004 */ addiu $s0, $s0, 4 -/* A4CA60 80240040 0220202D */ daddu $a0, $s1, $zero -/* A4CA64 80240044 8E050000 */ lw $a1, ($s0) -/* A4CA68 80240048 0C0B1EAF */ jal evt_get_variable -/* A4CA6C 8024004C 0040802D */ daddu $s0, $v0, $zero -/* A4CA70 80240050 0040182D */ daddu $v1, $v0, $zero -/* A4CA74 80240054 3C028016 */ lui $v0, %hi(gCollisionStatus+0x2) -/* A4CA78 80240058 8442A552 */ lh $v0, %lo(gCollisionStatus+0x2)($v0) -/* A4CA7C 8024005C 16020009 */ bne $s0, $v0, .L80240084 -/* A4CA80 80240060 00000000 */ nop -/* A4CA84 80240064 8E220084 */ lw $v0, 0x84($s1) -/* A4CA88 80240068 00431021 */ addu $v0, $v0, $v1 -/* A4CA8C 8024006C 44820000 */ mtc1 $v0, $f0 -/* A4CA90 80240070 00000000 */ nop -/* A4CA94 80240074 46800020 */ cvt.s.w $f0, $f0 -/* A4CA98 80240078 3C028011 */ lui $v0, %hi(gPlayerStatus) -/* A4CA9C 8024007C 2442EFC8 */ addiu $v0, $v0, %lo(gPlayerStatus) -/* A4CAA0 80240080 E440002C */ swc1 $f0, 0x2c($v0) -.L80240084: -/* A4CAA4 80240084 8FBF0018 */ lw $ra, 0x18($sp) -/* A4CAA8 80240088 8FB10014 */ lw $s1, 0x14($sp) -/* A4CAAC 8024008C 8FB00010 */ lw $s0, 0x10($sp) -/* A4CAB0 80240090 24020002 */ addiu $v0, $zero, 2 -/* A4CAB4 80240094 03E00008 */ jr $ra -/* A4CAB8 80240098 27BD0020 */ addiu $sp, $sp, 0x20 -/* A4CABC 8024009C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_09/A4F000/func_8024001C_A4F01C.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_09/A4F000/func_8024001C_A4F01C.s deleted file mode 100644 index 853fd8349e..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_09/A4F000/func_8024001C_A4F01C.s +++ /dev/null @@ -1,38 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_8024001C_A4F01C -/* A4F01C 8024001C 27BDFFE0 */ addiu $sp, $sp, -0x20 -/* A4F020 80240020 AFB10014 */ sw $s1, 0x14($sp) -/* A4F024 80240024 0080882D */ daddu $s1, $a0, $zero -/* A4F028 80240028 AFBF0018 */ sw $ra, 0x18($sp) -/* A4F02C 8024002C AFB00010 */ sw $s0, 0x10($sp) -/* A4F030 80240030 8E30000C */ lw $s0, 0xc($s1) -/* A4F034 80240034 8E050000 */ lw $a1, ($s0) -/* A4F038 80240038 0C0B1EAF */ jal evt_get_variable -/* A4F03C 8024003C 26100004 */ addiu $s0, $s0, 4 -/* A4F040 80240040 0220202D */ daddu $a0, $s1, $zero -/* A4F044 80240044 8E050000 */ lw $a1, ($s0) -/* A4F048 80240048 0C0B1EAF */ jal evt_get_variable -/* A4F04C 8024004C 0040802D */ daddu $s0, $v0, $zero -/* A4F050 80240050 0040182D */ daddu $v1, $v0, $zero -/* A4F054 80240054 3C028016 */ lui $v0, %hi(gCollisionStatus+0x2) -/* A4F058 80240058 8442A552 */ lh $v0, %lo(gCollisionStatus+0x2)($v0) -/* A4F05C 8024005C 16020009 */ bne $s0, $v0, .L80240084 -/* A4F060 80240060 00000000 */ nop -/* A4F064 80240064 8E220084 */ lw $v0, 0x84($s1) -/* A4F068 80240068 00431021 */ addu $v0, $v0, $v1 -/* A4F06C 8024006C 44820000 */ mtc1 $v0, $f0 -/* A4F070 80240070 00000000 */ nop -/* A4F074 80240074 46800020 */ cvt.s.w $f0, $f0 -/* A4F078 80240078 3C028011 */ lui $v0, %hi(gPlayerStatus) -/* A4F07C 8024007C 2442EFC8 */ addiu $v0, $v0, %lo(gPlayerStatus) -/* A4F080 80240080 E440002C */ swc1 $f0, 0x2c($v0) -.L80240084: -/* A4F084 80240084 8FBF0018 */ lw $ra, 0x18($sp) -/* A4F088 80240088 8FB10014 */ lw $s1, 0x14($sp) -/* A4F08C 8024008C 8FB00010 */ lw $s0, 0x10($sp) -/* A4F090 80240090 24020002 */ addiu $v0, $zero, 2 -/* A4F094 80240094 03E00008 */ jr $ra -/* A4F098 80240098 27BD0020 */ addiu $sp, $sp, 0x20 -/* A4F09C 8024009C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_100/A93160/func_80240000_A93160.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_100/A93160/func_80240000_A93160.s deleted file mode 100644 index 9ba6c51254..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_100/A93160/func_80240000_A93160.s +++ /dev/null @@ -1,34 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel D_802402B0_A93410 -.ascii "kpa_117_shape\0\0\0" - -dlabel D_802402C0_A93420 -.ascii "kpa_117_hit\0kpa_08\0\0\0\0\0\0\0\0\0\0\0\0\0\0" - -.section .text - -glabel func_80240000_A93160 -/* A93160 80240000 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* A93164 80240004 3C04800E */ lui $a0, %hi(wMapShapeName) -/* A93168 80240008 24849230 */ addiu $a0, $a0, %lo(wMapShapeName) -/* A9316C 8024000C 3C058024 */ lui $a1, %hi(D_802402B0_A93410) -/* A93170 80240010 24A502B0 */ addiu $a1, $a1, %lo(D_802402B0_A93410) -/* A93174 80240014 AFBF0010 */ sw $ra, 0x10($sp) -/* A93178 80240018 0C01953C */ jal sprintf -/* A9317C 8024001C 00000000 */ nop -/* A93180 80240020 3C04800E */ lui $a0, %hi(wMapHitName) -/* A93184 80240024 248491E0 */ addiu $a0, $a0, %lo(wMapHitName) -/* A93188 80240028 3C058024 */ lui $a1, %hi(D_802402C0_A93420) -/* A9318C 8024002C 0C01953C */ jal sprintf -/* A93190 80240030 24A502C0 */ addiu $a1, $a1, %lo(D_802402C0_A93420) -/* A93194 80240034 8FBF0010 */ lw $ra, 0x10($sp) -/* A93198 80240038 0000102D */ daddu $v0, $zero, $zero -/* A9319C 8024003C 03E00008 */ jr $ra -/* A931A0 80240040 27BD0018 */ addiu $sp, $sp, 0x18 -/* A931A4 80240044 00000000 */ nop -/* A931A8 80240048 00000000 */ nop -/* A931AC 8024004C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_101/A93440/func_80240000_A93440.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_101/A93440/func_80240000_A93440.s deleted file mode 100644 index 6aafdb7dc0..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_101/A93440/func_80240000_A93440.s +++ /dev/null @@ -1,34 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel D_802402D0_A93710 -.ascii "kpa_119_shape\0\0\0" - -dlabel D_802402E0_A93720 -.ascii "kpa_119_hit\0kpa_09\0\0\0\0\0\0\0\0\0\0\0\0\0\0" - -.section .text - -glabel func_80240000_A93440 -/* A93440 80240000 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* A93444 80240004 3C04800E */ lui $a0, %hi(wMapShapeName) -/* A93448 80240008 24849230 */ addiu $a0, $a0, %lo(wMapShapeName) -/* A9344C 8024000C 3C058024 */ lui $a1, %hi(D_802402D0_A93710) -/* A93450 80240010 24A502D0 */ addiu $a1, $a1, %lo(D_802402D0_A93710) -/* A93454 80240014 AFBF0010 */ sw $ra, 0x10($sp) -/* A93458 80240018 0C01953C */ jal sprintf -/* A9345C 8024001C 00000000 */ nop -/* A93460 80240020 3C04800E */ lui $a0, %hi(wMapHitName) -/* A93464 80240024 248491E0 */ addiu $a0, $a0, %lo(wMapHitName) -/* A93468 80240028 3C058024 */ lui $a1, %hi(D_802402E0_A93720) -/* A9346C 8024002C 0C01953C */ jal sprintf -/* A93470 80240030 24A502E0 */ addiu $a1, $a1, %lo(D_802402E0_A93720) -/* A93474 80240034 8FBF0010 */ lw $ra, 0x10($sp) -/* A93478 80240038 0000102D */ daddu $v0, $zero, $zero -/* A9347C 8024003C 03E00008 */ jr $ra -/* A93480 80240040 27BD0018 */ addiu $sp, $sp, 0x18 -/* A93484 80240044 00000000 */ nop -/* A93488 80240048 00000000 */ nop -/* A9348C 8024004C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_12/A54950/func_80240000_A54950.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_12/A54950/func_80240000_A54950.s deleted file mode 100644 index 25985dcd77..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_12/A54950/func_80240000_A54950.s +++ /dev/null @@ -1,21 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_80240000_A54950 -/* A54950 80240000 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* A54954 80240004 AFBF0010 */ sw $ra, 0x10($sp) -/* A54958 80240008 3C05F840 */ lui $a1, 0xf840 -/* A5495C 8024000C 34A56194 */ ori $a1, $a1, 0x6194 -/* A54960 80240010 0C0B1EAF */ jal evt_get_variable -/* A54964 80240014 0000202D */ daddu $a0, $zero, $zero -/* A54968 80240018 0040182D */ daddu $v1, $v0, $zero -/* A5496C 8024001C 3C020019 */ lui $v0, 0x19 -/* A54970 80240020 10600003 */ beqz $v1, .L80240030 -/* A54974 80240024 34420160 */ ori $v0, $v0, 0x160 -/* A54978 80240028 3C020019 */ lui $v0, 0x19 -/* A5497C 8024002C 34420161 */ ori $v0, $v0, 0x161 -.L80240030: -/* A54980 80240030 8FBF0010 */ lw $ra, 0x10($sp) -/* A54984 80240034 03E00008 */ jr $ra -/* A54988 80240038 27BD0018 */ addiu $sp, $sp, 0x18 -/* A5498C 8024003C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_12/A54CA0/func_8024037C_A54CCC.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_12/A54CA0/func_8024037C_A54CCC.s deleted file mode 100644 index e77cf6c430..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_12/A54CA0/func_8024037C_A54CCC.s +++ /dev/null @@ -1,57 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_8024037C_A54CCC -/* A54CCC 8024037C 27BDFFE0 */ addiu $sp, $sp, -0x20 -/* A54CD0 80240380 AFB10014 */ sw $s1, 0x14($sp) -/* A54CD4 80240384 0080882D */ daddu $s1, $a0, $zero -/* A54CD8 80240388 AFBF0018 */ sw $ra, 0x18($sp) -/* A54CDC 8024038C AFB00010 */ sw $s0, 0x10($sp) -/* A54CE0 80240390 8E30000C */ lw $s0, 0xc($s1) -/* A54CE4 80240394 8E050000 */ lw $a1, ($s0) -/* A54CE8 80240398 0C0B1EAF */ jal evt_get_variable -/* A54CEC 8024039C 26100004 */ addiu $s0, $s0, 4 -/* A54CF0 802403A0 0220202D */ daddu $a0, $s1, $zero -/* A54CF4 802403A4 8E050000 */ lw $a1, ($s0) -/* A54CF8 802403A8 0C0B1EAF */ jal evt_get_variable -/* A54CFC 802403AC 0040882D */ daddu $s1, $v0, $zero -/* A54D00 802403B0 0040802D */ daddu $s0, $v0, $zero -/* A54D04 802403B4 3C038016 */ lui $v1, %hi(gCollisionStatus) -/* A54D08 802403B8 2463A550 */ addiu $v1, $v1, %lo(gCollisionStatus) -/* A54D0C 802403BC 84620002 */ lh $v0, 2($v1) -/* A54D10 802403C0 10500004 */ beq $v0, $s0, .L802403D4 -/* A54D14 802403C4 00000000 */ nop -/* A54D18 802403C8 84620004 */ lh $v0, 4($v1) -/* A54D1C 802403CC 14500007 */ bne $v0, $s0, .L802403EC -/* A54D20 802403D0 00000000 */ nop -.L802403D4: -/* A54D24 802403D4 44910000 */ mtc1 $s1, $f0 -/* A54D28 802403D8 00000000 */ nop -/* A54D2C 802403DC 46800020 */ cvt.s.w $f0, $f0 -/* A54D30 802403E0 3C028011 */ lui $v0, %hi(gPlayerStatus) -/* A54D34 802403E4 2442EFC8 */ addiu $v0, $v0, %lo(gPlayerStatus) -/* A54D38 802403E8 E440001C */ swc1 $f0, 0x1c($v0) -.L802403EC: -/* A54D3C 802403EC 3C028011 */ lui $v0, %hi(gPlayerData+0x12) -/* A54D40 802403F0 8042F2A2 */ lb $v0, %lo(gPlayerData+0x12)($v0) -/* A54D44 802403F4 1040000D */ beqz $v0, .L8024042C -/* A54D48 802403F8 00000000 */ nop -/* A54D4C 802403FC 0C00EABB */ jal get_npc_unsafe -/* A54D50 80240400 2404FFFC */ addiu $a0, $zero, -4 -/* A54D54 80240404 0040182D */ daddu $v1, $v0, $zero -/* A54D58 80240408 84620084 */ lh $v0, 0x84($v1) -/* A54D5C 8024040C 14500007 */ bne $v0, $s0, .L8024042C -/* A54D60 80240410 00000000 */ nop -/* A54D64 80240414 C4600038 */ lwc1 $f0, 0x38($v1) -/* A54D68 80240418 44911000 */ mtc1 $s1, $f2 -/* A54D6C 8024041C 00000000 */ nop -/* A54D70 80240420 468010A0 */ cvt.s.w $f2, $f2 -/* A54D74 80240424 46020000 */ add.s $f0, $f0, $f2 -/* A54D78 80240428 E4600038 */ swc1 $f0, 0x38($v1) -.L8024042C: -/* A54D7C 8024042C 8FBF0018 */ lw $ra, 0x18($sp) -/* A54D80 80240430 8FB10014 */ lw $s1, 0x14($sp) -/* A54D84 80240434 8FB00010 */ lw $s0, 0x10($sp) -/* A54D88 80240438 24020002 */ addiu $v0, $zero, 2 -/* A54D8C 8024043C 03E00008 */ jr $ra -/* A54D90 80240440 27BD0020 */ addiu $sp, $sp, 0x20 diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_13/A55F20/func_80240000_A55F20.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_13/A55F20/func_80240000_A55F20.s deleted file mode 100644 index 31b19c16a6..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_13/A55F20/func_80240000_A55F20.s +++ /dev/null @@ -1,21 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_80240000_A55F20 -/* A55F20 80240000 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* A55F24 80240004 AFBF0010 */ sw $ra, 0x10($sp) -/* A55F28 80240008 3C05F840 */ lui $a1, 0xf840 -/* A55F2C 8024000C 34A56194 */ ori $a1, $a1, 0x6194 -/* A55F30 80240010 0C0B1EAF */ jal evt_get_variable -/* A55F34 80240014 0000202D */ daddu $a0, $zero, $zero -/* A55F38 80240018 0040182D */ daddu $v1, $v0, $zero -/* A55F3C 8024001C 3C020019 */ lui $v0, 0x19 -/* A55F40 80240020 10600003 */ beqz $v1, .L80240030 -/* A55F44 80240024 34420162 */ ori $v0, $v0, 0x162 -/* A55F48 80240028 3C020019 */ lui $v0, 0x19 -/* A55F4C 8024002C 34420163 */ ori $v0, $v0, 0x163 -.L80240030: -/* A55F50 80240030 8FBF0010 */ lw $ra, 0x10($sp) -/* A55F54 80240034 03E00008 */ jr $ra -/* A55F58 80240038 27BD0018 */ addiu $sp, $sp, 0x18 -/* A55F5C 8024003C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_13/A56270/func_8024037C_A5629C.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_13/A56270/func_8024037C_A5629C.s deleted file mode 100644 index 782a5c2a38..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_13/A56270/func_8024037C_A5629C.s +++ /dev/null @@ -1,57 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_8024037C_A5629C -/* A5629C 8024037C 27BDFFE0 */ addiu $sp, $sp, -0x20 -/* A562A0 80240380 AFB10014 */ sw $s1, 0x14($sp) -/* A562A4 80240384 0080882D */ daddu $s1, $a0, $zero -/* A562A8 80240388 AFBF0018 */ sw $ra, 0x18($sp) -/* A562AC 8024038C AFB00010 */ sw $s0, 0x10($sp) -/* A562B0 80240390 8E30000C */ lw $s0, 0xc($s1) -/* A562B4 80240394 8E050000 */ lw $a1, ($s0) -/* A562B8 80240398 0C0B1EAF */ jal evt_get_variable -/* A562BC 8024039C 26100004 */ addiu $s0, $s0, 4 -/* A562C0 802403A0 0220202D */ daddu $a0, $s1, $zero -/* A562C4 802403A4 8E050000 */ lw $a1, ($s0) -/* A562C8 802403A8 0C0B1EAF */ jal evt_get_variable -/* A562CC 802403AC 0040882D */ daddu $s1, $v0, $zero -/* A562D0 802403B0 0040802D */ daddu $s0, $v0, $zero -/* A562D4 802403B4 3C038016 */ lui $v1, %hi(gCollisionStatus) -/* A562D8 802403B8 2463A550 */ addiu $v1, $v1, %lo(gCollisionStatus) -/* A562DC 802403BC 84620002 */ lh $v0, 2($v1) -/* A562E0 802403C0 10500004 */ beq $v0, $s0, .L802403D4 -/* A562E4 802403C4 00000000 */ nop -/* A562E8 802403C8 84620004 */ lh $v0, 4($v1) -/* A562EC 802403CC 14500007 */ bne $v0, $s0, .L802403EC -/* A562F0 802403D0 00000000 */ nop -.L802403D4: -/* A562F4 802403D4 44910000 */ mtc1 $s1, $f0 -/* A562F8 802403D8 00000000 */ nop -/* A562FC 802403DC 46800020 */ cvt.s.w $f0, $f0 -/* A56300 802403E0 3C028011 */ lui $v0, %hi(gPlayerStatus) -/* A56304 802403E4 2442EFC8 */ addiu $v0, $v0, %lo(gPlayerStatus) -/* A56308 802403E8 E440001C */ swc1 $f0, 0x1c($v0) -.L802403EC: -/* A5630C 802403EC 3C028011 */ lui $v0, %hi(gPlayerData+0x12) -/* A56310 802403F0 8042F2A2 */ lb $v0, %lo(gPlayerData+0x12)($v0) -/* A56314 802403F4 1040000D */ beqz $v0, .L8024042C -/* A56318 802403F8 00000000 */ nop -/* A5631C 802403FC 0C00EABB */ jal get_npc_unsafe -/* A56320 80240400 2404FFFC */ addiu $a0, $zero, -4 -/* A56324 80240404 0040182D */ daddu $v1, $v0, $zero -/* A56328 80240408 84620084 */ lh $v0, 0x84($v1) -/* A5632C 8024040C 14500007 */ bne $v0, $s0, .L8024042C -/* A56330 80240410 00000000 */ nop -/* A56334 80240414 C4600038 */ lwc1 $f0, 0x38($v1) -/* A56338 80240418 44911000 */ mtc1 $s1, $f2 -/* A5633C 8024041C 00000000 */ nop -/* A56340 80240420 468010A0 */ cvt.s.w $f2, $f2 -/* A56344 80240424 46020000 */ add.s $f0, $f0, $f2 -/* A56348 80240428 E4600038 */ swc1 $f0, 0x38($v1) -.L8024042C: -/* A5634C 8024042C 8FBF0018 */ lw $ra, 0x18($sp) -/* A56350 80240430 8FB10014 */ lw $s1, 0x14($sp) -/* A56354 80240434 8FB00010 */ lw $s0, 0x10($sp) -/* A56358 80240438 24020002 */ addiu $v0, $zero, 2 -/* A5635C 8024043C 03E00008 */ jr $ra -/* A56360 80240440 27BD0020 */ addiu $sp, $sp, 0x20 diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_133/AA7790/func_80240310_AA7790.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_133/AA7790/func_80240310_AA7790.s deleted file mode 100644 index ebb1e0e7bc..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_133/AA7790/func_80240310_AA7790.s +++ /dev/null @@ -1,48 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_80240310_AA7790 -/* AA7790 80240310 27BDFFE0 */ addiu $sp, $sp, -0x20 -/* AA7794 80240314 AFB20018 */ sw $s2, 0x18($sp) -/* AA7798 80240318 0080902D */ daddu $s2, $a0, $zero -/* AA779C 8024031C 0000202D */ daddu $a0, $zero, $zero -/* AA77A0 80240320 3C05FD05 */ lui $a1, 0xfd05 -/* AA77A4 80240324 AFBF001C */ sw $ra, 0x1c($sp) -/* AA77A8 80240328 AFB10014 */ sw $s1, 0x14($sp) -/* AA77AC 8024032C AFB00010 */ sw $s0, 0x10($sp) -/* AA77B0 80240330 8E50000C */ lw $s0, 0xc($s2) -/* AA77B4 80240334 0C0B1EAF */ jal evt_get_variable -/* AA77B8 80240338 34A50F80 */ ori $a1, $a1, 0xf80 -/* AA77BC 8024033C 0C04417A */ jal get_entity_by_index -/* AA77C0 80240340 0040202D */ daddu $a0, $v0, $zero -/* AA77C4 80240344 0240202D */ daddu $a0, $s2, $zero -/* AA77C8 80240348 0040882D */ daddu $s1, $v0, $zero -/* AA77CC 8024034C 8E050000 */ lw $a1, ($s0) -/* AA77D0 80240350 0C0B1EAF */ jal evt_get_variable -/* AA77D4 80240354 26100004 */ addiu $s0, $s0, 4 -/* AA77D8 80240358 44820000 */ mtc1 $v0, $f0 -/* AA77DC 8024035C 00000000 */ nop -/* AA77E0 80240360 46800020 */ cvt.s.w $f0, $f0 -/* AA77E4 80240364 E6200060 */ swc1 $f0, 0x60($s1) -/* AA77E8 80240368 8E050000 */ lw $a1, ($s0) -/* AA77EC 8024036C 26100004 */ addiu $s0, $s0, 4 -/* AA77F0 80240370 0C0B1EAF */ jal evt_get_variable -/* AA77F4 80240374 0240202D */ daddu $a0, $s2, $zero -/* AA77F8 80240378 44820000 */ mtc1 $v0, $f0 -/* AA77FC 8024037C 00000000 */ nop -/* AA7800 80240380 46800020 */ cvt.s.w $f0, $f0 -/* AA7804 80240384 E6200064 */ swc1 $f0, 0x64($s1) -/* AA7808 80240388 8E050000 */ lw $a1, ($s0) -/* AA780C 8024038C 0C0B1EAF */ jal evt_get_variable -/* AA7810 80240390 0240202D */ daddu $a0, $s2, $zero -/* AA7814 80240394 44820000 */ mtc1 $v0, $f0 -/* AA7818 80240398 00000000 */ nop -/* AA781C 8024039C 46800020 */ cvt.s.w $f0, $f0 -/* AA7820 802403A0 E6200068 */ swc1 $f0, 0x68($s1) -/* AA7824 802403A4 8FBF001C */ lw $ra, 0x1c($sp) -/* AA7828 802403A8 8FB20018 */ lw $s2, 0x18($sp) -/* AA782C 802403AC 8FB10014 */ lw $s1, 0x14($sp) -/* AA7830 802403B0 8FB00010 */ lw $s0, 0x10($sp) -/* AA7834 802403B4 24020002 */ addiu $v0, $zero, 2 -/* AA7838 802403B8 03E00008 */ jr $ra -/* AA783C 802403BC 27BD0020 */ addiu $sp, $sp, 0x20 diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_133/AA7790/func_802403C0_AA7840.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_133/AA7790/func_802403C0_AA7840.s deleted file mode 100644 index c5d3f7f9cd..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_133/AA7790/func_802403C0_AA7840.s +++ /dev/null @@ -1,48 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_802403C0_AA7840 -/* AA7840 802403C0 27BDFFE0 */ addiu $sp, $sp, -0x20 -/* AA7844 802403C4 AFB20018 */ sw $s2, 0x18($sp) -/* AA7848 802403C8 0080902D */ daddu $s2, $a0, $zero -/* AA784C 802403CC 0000202D */ daddu $a0, $zero, $zero -/* AA7850 802403D0 3C05FD05 */ lui $a1, 0xfd05 -/* AA7854 802403D4 AFBF001C */ sw $ra, 0x1c($sp) -/* AA7858 802403D8 AFB10014 */ sw $s1, 0x14($sp) -/* AA785C 802403DC AFB00010 */ sw $s0, 0x10($sp) -/* AA7860 802403E0 8E50000C */ lw $s0, 0xc($s2) -/* AA7864 802403E4 0C0B1EAF */ jal evt_get_variable -/* AA7868 802403E8 34A50F80 */ ori $a1, $a1, 0xf80 -/* AA786C 802403EC 0C04417A */ jal get_entity_by_index -/* AA7870 802403F0 0040202D */ daddu $a0, $v0, $zero -/* AA7874 802403F4 0240202D */ daddu $a0, $s2, $zero -/* AA7878 802403F8 0040882D */ daddu $s1, $v0, $zero -/* AA787C 802403FC 8E050000 */ lw $a1, ($s0) -/* AA7880 80240400 0C0B1EAF */ jal evt_get_variable -/* AA7884 80240404 26100004 */ addiu $s0, $s0, 4 -/* AA7888 80240408 44820000 */ mtc1 $v0, $f0 -/* AA788C 8024040C 00000000 */ nop -/* AA7890 80240410 46800020 */ cvt.s.w $f0, $f0 -/* AA7894 80240414 E6200048 */ swc1 $f0, 0x48($s1) -/* AA7898 80240418 8E050000 */ lw $a1, ($s0) -/* AA789C 8024041C 26100004 */ addiu $s0, $s0, 4 -/* AA78A0 80240420 0C0B1EAF */ jal evt_get_variable -/* AA78A4 80240424 0240202D */ daddu $a0, $s2, $zero -/* AA78A8 80240428 44820000 */ mtc1 $v0, $f0 -/* AA78AC 8024042C 00000000 */ nop -/* AA78B0 80240430 46800020 */ cvt.s.w $f0, $f0 -/* AA78B4 80240434 E620004C */ swc1 $f0, 0x4c($s1) -/* AA78B8 80240438 8E050000 */ lw $a1, ($s0) -/* AA78BC 8024043C 0C0B1EAF */ jal evt_get_variable -/* AA78C0 80240440 0240202D */ daddu $a0, $s2, $zero -/* AA78C4 80240444 44820000 */ mtc1 $v0, $f0 -/* AA78C8 80240448 00000000 */ nop -/* AA78CC 8024044C 46800020 */ cvt.s.w $f0, $f0 -/* AA78D0 80240450 E6200050 */ swc1 $f0, 0x50($s1) -/* AA78D4 80240454 8FBF001C */ lw $ra, 0x1c($sp) -/* AA78D8 80240458 8FB20018 */ lw $s2, 0x18($sp) -/* AA78DC 8024045C 8FB10014 */ lw $s1, 0x14($sp) -/* AA78E0 80240460 8FB00010 */ lw $s0, 0x10($sp) -/* AA78E4 80240464 24020002 */ addiu $v0, $zero, 2 -/* AA78E8 80240468 03E00008 */ jr $ra -/* AA78EC 8024046C 27BD0020 */ addiu $sp, $sp, 0x20 diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_14/A574B0/func_80240000_A574B0.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_14/A574B0/func_80240000_A574B0.s deleted file mode 100644 index e00e5dc696..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_14/A574B0/func_80240000_A574B0.s +++ /dev/null @@ -1,21 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_80240000_A574B0 -/* A574B0 80240000 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* A574B4 80240004 AFBF0010 */ sw $ra, 0x10($sp) -/* A574B8 80240008 3C05F840 */ lui $a1, 0xf840 -/* A574BC 8024000C 34A56194 */ ori $a1, $a1, 0x6194 -/* A574C0 80240010 0C0B1EAF */ jal evt_get_variable -/* A574C4 80240014 0000202D */ daddu $a0, $zero, $zero -/* A574C8 80240018 0040182D */ daddu $v1, $v0, $zero -/* A574CC 8024001C 3C020019 */ lui $v0, 0x19 -/* A574D0 80240020 10600003 */ beqz $v1, .L80240030 -/* A574D4 80240024 34420164 */ ori $v0, $v0, 0x164 -/* A574D8 80240028 3C020019 */ lui $v0, 0x19 -/* A574DC 8024002C 34420165 */ ori $v0, $v0, 0x165 -.L80240030: -/* A574E0 80240030 8FBF0010 */ lw $ra, 0x10($sp) -/* A574E4 80240034 03E00008 */ jr $ra -/* A574E8 80240038 27BD0018 */ addiu $sp, $sp, 0x18 -/* A574EC 8024003C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_14/A57830/func_8024073C_A57BEC.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_14/A57830/func_8024073C_A57BEC.s deleted file mode 100644 index e31b256578..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_14/A57830/func_8024073C_A57BEC.s +++ /dev/null @@ -1,72 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_8024073C_A57BEC -/* A57BEC 8024073C 27BDFFE0 */ addiu $sp, $sp, -0x20 -/* A57BF0 80240740 AFB10014 */ sw $s1, 0x14($sp) -/* A57BF4 80240744 0080882D */ daddu $s1, $a0, $zero -/* A57BF8 80240748 AFBF001C */ sw $ra, 0x1c($sp) -/* A57BFC 8024074C AFB20018 */ sw $s2, 0x18($sp) -/* A57C00 80240750 AFB00010 */ sw $s0, 0x10($sp) -/* A57C04 80240754 8E30000C */ lw $s0, 0xc($s1) -/* A57C08 80240758 8E050000 */ lw $a1, ($s0) -/* A57C0C 8024075C 0C0B1EAF */ jal evt_get_variable -/* A57C10 80240760 26100004 */ addiu $s0, $s0, 4 -/* A57C14 80240764 8E050000 */ lw $a1, ($s0) -/* A57C18 80240768 26100004 */ addiu $s0, $s0, 4 -/* A57C1C 8024076C 0220202D */ daddu $a0, $s1, $zero -/* A57C20 80240770 0C0B1EAF */ jal evt_get_variable -/* A57C24 80240774 0040902D */ daddu $s2, $v0, $zero -/* A57C28 80240778 0220202D */ daddu $a0, $s1, $zero -/* A57C2C 8024077C 8E050000 */ lw $a1, ($s0) -/* A57C30 80240780 0C0B1EAF */ jal evt_get_variable -/* A57C34 80240784 0040802D */ daddu $s0, $v0, $zero -/* A57C38 80240788 0040202D */ daddu $a0, $v0, $zero -/* A57C3C 8024078C 3C038016 */ lui $v1, %hi(gCollisionStatus) -/* A57C40 80240790 2463A550 */ addiu $v1, $v1, %lo(gCollisionStatus) -/* A57C44 80240794 84620002 */ lh $v0, 2($v1) -/* A57C48 80240798 3C058011 */ lui $a1, %hi(gPlayerStatus) -/* A57C4C 8024079C 24A5EFC8 */ addiu $a1, $a1, %lo(gPlayerStatus) -/* A57C50 802407A0 10500004 */ beq $v0, $s0, .L802407B4 -/* A57C54 802407A4 00000000 */ nop -/* A57C58 802407A8 84620004 */ lh $v0, 4($v1) -/* A57C5C 802407AC 1450000D */ bne $v0, $s0, .L802407E4 -/* A57C60 802407B0 00000000 */ nop -.L802407B4: -/* A57C64 802407B4 80A300B4 */ lb $v1, 0xb4($a1) -/* A57C68 802407B8 2402000F */ addiu $v0, $zero, 0xf -/* A57C6C 802407BC 10620009 */ beq $v1, $v0, .L802407E4 -/* A57C70 802407C0 2402000D */ addiu $v0, $zero, 0xd -/* A57C74 802407C4 10620007 */ beq $v1, $v0, .L802407E4 -/* A57C78 802407C8 00000000 */ nop -/* A57C7C 802407CC 14800005 */ bnez $a0, .L802407E4 -/* A57C80 802407D0 00000000 */ nop -/* A57C84 802407D4 44920000 */ mtc1 $s2, $f0 -/* A57C88 802407D8 00000000 */ nop -/* A57C8C 802407DC 46800020 */ cvt.s.w $f0, $f0 -/* A57C90 802407E0 E4A0001C */ swc1 $f0, 0x1c($a1) -.L802407E4: -/* A57C94 802407E4 3C028011 */ lui $v0, %hi(gPlayerData+0x12) -/* A57C98 802407E8 8042F2A2 */ lb $v0, %lo(gPlayerData+0x12)($v0) -/* A57C9C 802407EC 1040000D */ beqz $v0, .L80240824 -/* A57CA0 802407F0 00000000 */ nop -/* A57CA4 802407F4 0C00EABB */ jal get_npc_unsafe -/* A57CA8 802407F8 2404FFFC */ addiu $a0, $zero, -4 -/* A57CAC 802407FC 0040182D */ daddu $v1, $v0, $zero -/* A57CB0 80240800 84620084 */ lh $v0, 0x84($v1) -/* A57CB4 80240804 14500007 */ bne $v0, $s0, .L80240824 -/* A57CB8 80240808 00000000 */ nop -/* A57CBC 8024080C C4600038 */ lwc1 $f0, 0x38($v1) -/* A57CC0 80240810 44921000 */ mtc1 $s2, $f2 -/* A57CC4 80240814 00000000 */ nop -/* A57CC8 80240818 468010A0 */ cvt.s.w $f2, $f2 -/* A57CCC 8024081C 46020000 */ add.s $f0, $f0, $f2 -/* A57CD0 80240820 E4600038 */ swc1 $f0, 0x38($v1) -.L80240824: -/* A57CD4 80240824 8FBF001C */ lw $ra, 0x1c($sp) -/* A57CD8 80240828 8FB20018 */ lw $s2, 0x18($sp) -/* A57CDC 8024082C 8FB10014 */ lw $s1, 0x14($sp) -/* A57CE0 80240830 8FB00010 */ lw $s0, 0x10($sp) -/* A57CE4 80240834 24020002 */ addiu $v0, $zero, 2 -/* A57CE8 80240838 03E00008 */ jr $ra -/* A57CEC 8024083C 27BD0020 */ addiu $sp, $sp, 0x20 diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_51/A64090/func_80240000_A64090.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_51/A64090/func_80240000_A64090.s deleted file mode 100644 index 1672c75c67..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_51/A64090/func_80240000_A64090.s +++ /dev/null @@ -1,34 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel D_80242F20_A66FB0 -.ascii "kpa_50_shape\0\0\0\0" - -dlabel D_80242F30_A66FC0 -.ascii "kpa_50_hit\0\0kpa_32\0\0kpa_133\0\0\0\0\0" - -.section .text - -glabel func_80240000_A64090 -/* A64090 80240000 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* A64094 80240004 3C04800E */ lui $a0, %hi(wMapShapeName) -/* A64098 80240008 24849230 */ addiu $a0, $a0, %lo(wMapShapeName) -/* A6409C 8024000C 3C058024 */ lui $a1, %hi(D_80242F20_A66FB0) -/* A640A0 80240010 24A52F20 */ addiu $a1, $a1, %lo(D_80242F20_A66FB0) -/* A640A4 80240014 AFBF0010 */ sw $ra, 0x10($sp) -/* A640A8 80240018 0C01953C */ jal sprintf -/* A640AC 8024001C 00000000 */ nop -/* A640B0 80240020 3C04800E */ lui $a0, %hi(wMapHitName) -/* A640B4 80240024 248491E0 */ addiu $a0, $a0, %lo(wMapHitName) -/* A640B8 80240028 3C058024 */ lui $a1, %hi(D_80242F30_A66FC0) -/* A640BC 8024002C 0C01953C */ jal sprintf -/* A640C0 80240030 24A52F30 */ addiu $a1, $a1, %lo(D_80242F30_A66FC0) -/* A640C4 80240034 8FBF0010 */ lw $ra, 0x10($sp) -/* A640C8 80240038 0000102D */ daddu $v0, $zero, $zero -/* A640CC 8024003C 03E00008 */ jr $ra -/* A640D0 80240040 27BD0018 */ addiu $sp, $sp, 0x18 -/* A640D4 80240044 00000000 */ nop -/* A640D8 80240048 00000000 */ nop -/* A640DC 8024004C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_53/A6ACA0/func_80240000_A6ACA0.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_53/A6ACA0/func_80240000_A6ACA0.s deleted file mode 100644 index cd840bc185..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_53/A6ACA0/func_80240000_A6ACA0.s +++ /dev/null @@ -1,34 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel D_80241E20_A6CAC0 -.ascii "kpa_50_shape\0\0\0\0" - -dlabel D_80241E30_A6CAD0 -.ascii "kpa_50_hit\0\0kpa_102\0kpa_83\0\0\0\0\0\0" - -.section .text - -glabel func_80240000_A6ACA0 -/* A6ACA0 80240000 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* A6ACA4 80240004 3C04800E */ lui $a0, %hi(wMapShapeName) -/* A6ACA8 80240008 24849230 */ addiu $a0, $a0, %lo(wMapShapeName) -/* A6ACAC 8024000C 3C058024 */ lui $a1, %hi(D_80241E20_A6CAC0) -/* A6ACB0 80240010 24A51E20 */ addiu $a1, $a1, %lo(D_80241E20_A6CAC0) -/* A6ACB4 80240014 3C038007 */ lui $v1, %hi(gGameStatusPtr) -/* A6ACB8 80240018 8C63419C */ lw $v1, %lo(gGameStatusPtr)($v1) -/* A6ACBC 8024001C 24020002 */ addiu $v0, $zero, 2 -/* A6ACC0 80240020 AFBF0010 */ sw $ra, 0x10($sp) -/* A6ACC4 80240024 0C01953C */ jal sprintf -/* A6ACC8 80240028 A0620084 */ sb $v0, 0x84($v1) -/* A6ACCC 8024002C 3C04800E */ lui $a0, %hi(wMapHitName) -/* A6ACD0 80240030 248491E0 */ addiu $a0, $a0, %lo(wMapHitName) -/* A6ACD4 80240034 3C058024 */ lui $a1, %hi(D_80241E30_A6CAD0) -/* A6ACD8 80240038 0C01953C */ jal sprintf -/* A6ACDC 8024003C 24A51E30 */ addiu $a1, $a1, %lo(D_80241E30_A6CAD0) -/* A6ACE0 80240040 8FBF0010 */ lw $ra, 0x10($sp) -/* A6ACE4 80240044 0000102D */ daddu $v0, $zero, $zero -/* A6ACE8 80240048 03E00008 */ jr $ra -/* A6ACEC 8024004C 27BD0018 */ addiu $sp, $sp, 0x18 diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_53/A6ACA0/func_80240050_A6ACF0.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_53/A6ACA0/func_80240050_A6ACF0.s deleted file mode 100644 index 4796214221..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_53/A6ACA0/func_80240050_A6ACF0.s +++ /dev/null @@ -1,86 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel D_80241E50_A6CAF0 -.double 0.85, 0.0 - -.section .text - -glabel func_80240050_A6ACF0 -/* A6ACF0 80240050 27BDFFE0 */ addiu $sp, $sp, -0x20 -/* A6ACF4 80240054 AFB10014 */ sw $s1, 0x14($sp) -/* A6ACF8 80240058 0080882D */ daddu $s1, $a0, $zero -/* A6ACFC 8024005C AFBF001C */ sw $ra, 0x1c($sp) -/* A6AD00 80240060 AFB20018 */ sw $s2, 0x18($sp) -/* A6AD04 80240064 AFB00010 */ sw $s0, 0x10($sp) -/* A6AD08 80240068 8E30000C */ lw $s0, 0xc($s1) -/* A6AD0C 8024006C 8E050000 */ lw $a1, ($s0) -/* A6AD10 80240070 0C0B1EAF */ jal evt_get_variable -/* A6AD14 80240074 26100004 */ addiu $s0, $s0, 4 -/* A6AD18 80240078 0220202D */ daddu $a0, $s1, $zero -/* A6AD1C 8024007C 8E120000 */ lw $s2, ($s0) -/* A6AD20 80240080 0C0B36B0 */ jal resolve_npc -/* A6AD24 80240084 0040282D */ daddu $a1, $v0, $zero -/* A6AD28 80240088 3C108011 */ lui $s0, %hi(gPlayerStatus) -/* A6AD2C 8024008C 2610EFC8 */ addiu $s0, $s0, %lo(gPlayerStatus) -/* A6AD30 80240090 0040182D */ daddu $v1, $v0, $zero -/* A6AD34 80240094 1060002F */ beqz $v1, .L80240154 -/* A6AD38 80240098 24020002 */ addiu $v0, $zero, 2 -/* A6AD3C 8024009C C6000028 */ lwc1 $f0, 0x28($s0) -/* A6AD40 802400A0 3C018024 */ lui $at, %hi(D_80241E50_A6CAF0) -/* A6AD44 802400A4 D4221E50 */ ldc1 $f2, %lo(D_80241E50_A6CAF0)($at) -/* A6AD48 802400A8 4600010D */ trunc.w.s $f4, $f0 -/* A6AD4C 802400AC 44022000 */ mfc1 $v0, $f4 -/* A6AD50 802400B0 00000000 */ nop -/* A6AD54 802400B4 2442FD44 */ addiu $v0, $v0, -0x2bc -/* A6AD58 802400B8 44820000 */ mtc1 $v0, $f0 -/* A6AD5C 802400BC 00000000 */ nop -/* A6AD60 802400C0 46800021 */ cvt.d.w $f0, $f0 -/* A6AD64 802400C4 46220002 */ mul.d $f0, $f0, $f2 -/* A6AD68 802400C8 00000000 */ nop -/* A6AD6C 802400CC 4620010D */ trunc.w.d $f4, $f0 -/* A6AD70 802400D0 44022000 */ mfc1 $v0, $f4 -/* A6AD74 802400D4 00000000 */ nop -/* A6AD78 802400D8 244202FD */ addiu $v0, $v0, 0x2fd -/* A6AD7C 802400DC 44820000 */ mtc1 $v0, $f0 -/* A6AD80 802400E0 00000000 */ nop -/* A6AD84 802400E4 46800020 */ cvt.s.w $f0, $f0 -/* A6AD88 802400E8 E4600038 */ swc1 $f0, 0x38($v1) -/* A6AD8C 802400EC C6020054 */ lwc1 $f2, 0x54($s0) -/* A6AD90 802400F0 44800000 */ mtc1 $zero, $f0 -/* A6AD94 802400F4 00000000 */ nop -/* A6AD98 802400F8 46001032 */ c.eq.s $f2, $f0 -/* A6AD9C 802400FC 00000000 */ nop -/* A6ADA0 80240100 45000003 */ bc1f .L80240110 -/* A6ADA4 80240104 3C02000A */ lui $v0, 0xa -/* A6ADA8 80240108 0809004D */ j .L80240134 -/* A6ADAC 8024010C 34420001 */ ori $v0, $v0, 1 -.L80240110: -/* A6ADB0 80240110 3C014000 */ lui $at, 0x4000 -/* A6ADB4 80240114 44810000 */ mtc1 $at, $f0 -/* A6ADB8 80240118 00000000 */ nop -/* A6ADBC 8024011C 4600103C */ c.lt.s $f2, $f0 -/* A6ADC0 80240120 00000000 */ nop -/* A6ADC4 80240124 45000003 */ bc1f .L80240134 -/* A6ADC8 80240128 34420003 */ ori $v0, $v0, 3 -/* A6ADCC 8024012C 3C02000A */ lui $v0, 0xa -/* A6ADD0 80240130 34420002 */ ori $v0, $v0, 2 -.L80240134: -/* A6ADD4 80240134 0220202D */ daddu $a0, $s1, $zero -/* A6ADD8 80240138 AC620028 */ sw $v0, 0x28($v1) -/* A6ADDC 8024013C C6000080 */ lwc1 $f0, 0x80($s0) -/* A6ADE0 80240140 4600010D */ trunc.w.s $f4, $f0 -/* A6ADE4 80240144 44062000 */ mfc1 $a2, $f4 -/* A6ADE8 80240148 0C0B2026 */ jal evt_set_variable -/* A6ADEC 8024014C 0240282D */ daddu $a1, $s2, $zero -/* A6ADF0 80240150 24020002 */ addiu $v0, $zero, 2 -.L80240154: -/* A6ADF4 80240154 8FBF001C */ lw $ra, 0x1c($sp) -/* A6ADF8 80240158 8FB20018 */ lw $s2, 0x18($sp) -/* A6ADFC 8024015C 8FB10014 */ lw $s1, 0x14($sp) -/* A6AE00 80240160 8FB00010 */ lw $s0, 0x10($sp) -/* A6AE04 80240164 03E00008 */ jr $ra -/* A6AE08 80240168 27BD0020 */ addiu $sp, $sp, 0x20 -/* A6AE0C 8024016C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_63/A735B0/func_80240000_A735B0.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_63/A735B0/func_80240000_A735B0.s deleted file mode 100644 index 382074ef75..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_63/A735B0/func_80240000_A735B0.s +++ /dev/null @@ -1,111 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_80240000_A735B0 -/* A735B0 80240000 27BDFFC0 */ addiu $sp, $sp, -0x40 -/* A735B4 80240004 AFB10014 */ sw $s1, 0x14($sp) -/* A735B8 80240008 0080882D */ daddu $s1, $a0, $zero -/* A735BC 8024000C AFBF0018 */ sw $ra, 0x18($sp) -/* A735C0 80240010 AFB00010 */ sw $s0, 0x10($sp) -/* A735C4 80240014 F7BA0038 */ sdc1 $f26, 0x38($sp) -/* A735C8 80240018 F7B80030 */ sdc1 $f24, 0x30($sp) -/* A735CC 8024001C F7B60028 */ sdc1 $f22, 0x28($sp) -/* A735D0 80240020 F7B40020 */ sdc1 $f20, 0x20($sp) -/* A735D4 80240024 10A0001E */ beqz $a1, .L802400A0 -/* A735D8 80240028 8E30000C */ lw $s0, 0xc($s1) -/* A735DC 8024002C 8E050000 */ lw $a1, ($s0) -/* A735E0 80240030 0C0B1EAF */ jal evt_get_variable -/* A735E4 80240034 26100004 */ addiu $s0, $s0, 4 -/* A735E8 80240038 AE220070 */ sw $v0, 0x70($s1) -/* A735EC 8024003C 8E050000 */ lw $a1, ($s0) -/* A735F0 80240040 26100004 */ addiu $s0, $s0, 4 -/* A735F4 80240044 0C0B1EAF */ jal evt_get_variable -/* A735F8 80240048 0220202D */ daddu $a0, $s1, $zero -/* A735FC 8024004C 8E050000 */ lw $a1, ($s0) -/* A73600 80240050 4482D000 */ mtc1 $v0, $f26 -/* A73604 80240054 00000000 */ nop -/* A73608 80240058 4680D6A0 */ cvt.s.w $f26, $f26 -/* A7360C 8024005C 0C0B1EAF */ jal evt_get_variable -/* A73610 80240060 0220202D */ daddu $a0, $s1, $zero -/* A73614 80240064 8E230070 */ lw $v1, 0x70($s1) -/* A73618 80240068 4482B000 */ mtc1 $v0, $f22 -/* A7361C 8024006C 00000000 */ nop -/* A73620 80240070 4680B5A0 */ cvt.s.w $f22, $f22 -/* A73624 80240074 10600005 */ beqz $v1, .L8024008C -/* A73628 80240078 24020001 */ addiu $v0, $zero, 1 -/* A7362C 8024007C 10620006 */ beq $v1, $v0, .L80240098 -/* A73630 80240080 00000000 */ nop -/* A73634 80240084 08090028 */ j .L802400A0 -/* A73638 80240088 00000000 */ nop -.L8024008C: -/* A7363C 8024008C 4480A000 */ mtc1 $zero, $f20 -/* A73640 80240090 08090028 */ j .L802400A0 -/* A73644 80240094 00000000 */ nop -.L80240098: -/* A73648 80240098 3C0140A0 */ lui $at, 0x40a0 -/* A7364C 8024009C 4481A000 */ mtc1 $at, $f20 -.L802400A0: -/* A73650 802400A0 0C00A8BB */ jal sin_deg -/* A73654 802400A4 4600B306 */ mov.s $f12, $f22 -/* A73658 802400A8 46140002 */ mul.s $f0, $f0, $f20 -/* A7365C 802400AC 00000000 */ nop -/* A73660 802400B0 3C01C2F0 */ lui $at, 0xc2f0 -/* A73664 802400B4 44811000 */ mtc1 $at, $f2 -/* A73668 802400B8 00000000 */ nop -/* A7366C 802400BC 46020600 */ add.s $f24, $f0, $f2 -/* A73670 802400C0 3C014130 */ lui $at, 0x4130 -/* A73674 802400C4 44810000 */ mtc1 $at, $f0 -/* A73678 802400C8 00000000 */ nop -/* A7367C 802400CC 4600D681 */ sub.s $f26, $f26, $f0 -/* A73680 802400D0 0C00A8D4 */ jal cos_deg -/* A73684 802400D4 4600B306 */ mov.s $f12, $f22 -/* A73688 802400D8 46140002 */ mul.s $f0, $f0, $f20 -/* A7368C 802400DC 00000000 */ nop -/* A73690 802400E0 3C014361 */ lui $at, 0x4361 -/* A73694 802400E4 44811000 */ mtc1 $at, $f2 -/* A73698 802400E8 8E240070 */ lw $a0, 0x70($s1) -/* A7369C 802400EC 10800006 */ beqz $a0, .L80240108 -/* A736A0 802400F0 46020500 */ add.s $f20, $f0, $f2 -/* A736A4 802400F4 24020001 */ addiu $v0, $zero, 1 -/* A736A8 802400F8 10820009 */ beq $a0, $v0, .L80240120 -/* A736AC 802400FC 24020002 */ addiu $v0, $zero, 2 -/* A736B0 80240100 0809005A */ j .L80240168 -/* A736B4 80240104 00000000 */ nop -.L80240108: -/* A736B8 80240108 3C028011 */ lui $v0, %hi(gPlayerStatus) -/* A736BC 8024010C 2442EFC8 */ addiu $v0, $v0, %lo(gPlayerStatus) -/* A736C0 80240110 E4580028 */ swc1 $f24, 0x28($v0) -/* A736C4 80240114 E45A002C */ swc1 $f26, 0x2c($v0) -/* A736C8 80240118 08090059 */ j .L80240164 -/* A736CC 8024011C E4540030 */ swc1 $f20, 0x30($v0) -.L80240120: -/* A736D0 80240120 0C00EAD2 */ jal get_npc_safe -/* A736D4 80240124 2404FFFC */ addiu $a0, $zero, -4 -/* A736D8 80240128 0040202D */ daddu $a0, $v0, $zero -/* A736DC 8024012C 1080000D */ beqz $a0, .L80240164 -/* A736E0 80240130 4600C006 */ mov.s $f0, $f24 -/* A736E4 80240134 E4980038 */ swc1 $f24, 0x38($a0) -/* A736E8 80240138 E49A003C */ swc1 $f26, 0x3c($a0) -/* A736EC 8024013C 4600D086 */ mov.s $f2, $f26 -/* A736F0 80240140 E4940040 */ swc1 $f20, 0x40($a0) -/* A736F4 80240144 4600A106 */ mov.s $f4, $f20 -/* A736F8 80240148 8C820000 */ lw $v0, ($a0) -/* A736FC 8024014C 3C030001 */ lui $v1, 1 -/* A73700 80240150 E480006C */ swc1 $f0, 0x6c($a0) -/* A73704 80240154 E4820070 */ swc1 $f2, 0x70($a0) -/* A73708 80240158 E4840074 */ swc1 $f4, 0x74($a0) -/* A7370C 8024015C 00431025 */ or $v0, $v0, $v1 -/* A73710 80240160 AC820000 */ sw $v0, ($a0) -.L80240164: -/* A73714 80240164 24020002 */ addiu $v0, $zero, 2 -.L80240168: -/* A73718 80240168 8FBF0018 */ lw $ra, 0x18($sp) -/* A7371C 8024016C 8FB10014 */ lw $s1, 0x14($sp) -/* A73720 80240170 8FB00010 */ lw $s0, 0x10($sp) -/* A73724 80240174 D7BA0038 */ ldc1 $f26, 0x38($sp) -/* A73728 80240178 D7B80030 */ ldc1 $f24, 0x30($sp) -/* A7372C 8024017C D7B60028 */ ldc1 $f22, 0x28($sp) -/* A73730 80240180 D7B40020 */ ldc1 $f20, 0x20($sp) -/* A73734 80240184 03E00008 */ jr $ra -/* A73738 80240188 27BD0040 */ addiu $sp, $sp, 0x40 -/* A7373C 8024018C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_81/A784C0/func_80240000_A784C0.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_81/A784C0/func_80240000_A784C0.s deleted file mode 100644 index 991ab637eb..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_81/A784C0/func_80240000_A784C0.s +++ /dev/null @@ -1,34 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel D_80242000_A7A4C0 -.ascii "kpa_80_shape\0\0\0\0" - -dlabel D_80242010_A7A4D0 -.ascii "kpa_80_hit\0\0kpa_50\0\0kpa_32\0\0kpa_04\0\0kpa_17\0\0\0\0\0\0" - -.section .text - -glabel func_80240000_A784C0 -/* A784C0 80240000 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* A784C4 80240004 3C04800E */ lui $a0, %hi(wMapShapeName) -/* A784C8 80240008 24849230 */ addiu $a0, $a0, %lo(wMapShapeName) -/* A784CC 8024000C 3C058024 */ lui $a1, %hi(D_80242000_A7A4C0) -/* A784D0 80240010 24A52000 */ addiu $a1, $a1, %lo(D_80242000_A7A4C0) -/* A784D4 80240014 AFBF0010 */ sw $ra, 0x10($sp) -/* A784D8 80240018 0C01953C */ jal sprintf -/* A784DC 8024001C 00000000 */ nop -/* A784E0 80240020 3C04800E */ lui $a0, %hi(wMapHitName) -/* A784E4 80240024 248491E0 */ addiu $a0, $a0, %lo(wMapHitName) -/* A784E8 80240028 3C058024 */ lui $a1, %hi(D_80242010_A7A4D0) -/* A784EC 8024002C 0C01953C */ jal sprintf -/* A784F0 80240030 24A52010 */ addiu $a1, $a1, %lo(D_80242010_A7A4D0) -/* A784F4 80240034 8FBF0010 */ lw $ra, 0x10($sp) -/* A784F8 80240038 0000102D */ daddu $v0, $zero, $zero -/* A784FC 8024003C 03E00008 */ jr $ra -/* A78500 80240040 27BD0018 */ addiu $sp, $sp, 0x18 -/* A78504 80240044 00000000 */ nop -/* A78508 80240048 00000000 */ nop -/* A7850C 8024004C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_82/A7A500/func_80240000_A7A500.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_82/A7A500/func_80240000_A7A500.s deleted file mode 100644 index 64036747e2..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_82/A7A500/func_80240000_A7A500.s +++ /dev/null @@ -1,34 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel D_80248F60_A83460 -.ascii "kpa_80_shape\0\0\0\0" - -dlabel D_80248F70_A83470 -.ascii "kpa_80_hit\0\0kpa_113\0kpa_61\0\0\0\0\0\0" - -.section .text - -glabel func_80240000_A7A500 -/* A7A500 80240000 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* A7A504 80240004 3C04800E */ lui $a0, %hi(wMapShapeName) -/* A7A508 80240008 24849230 */ addiu $a0, $a0, %lo(wMapShapeName) -/* A7A50C 8024000C 3C058025 */ lui $a1, %hi(D_80248F60_A83460) -/* A7A510 80240010 24A58F60 */ addiu $a1, $a1, %lo(D_80248F60_A83460) -/* A7A514 80240014 AFBF0010 */ sw $ra, 0x10($sp) -/* A7A518 80240018 0C01953C */ jal sprintf -/* A7A51C 8024001C 00000000 */ nop -/* A7A520 80240020 3C04800E */ lui $a0, %hi(wMapHitName) -/* A7A524 80240024 248491E0 */ addiu $a0, $a0, %lo(wMapHitName) -/* A7A528 80240028 3C058025 */ lui $a1, %hi(D_80248F70_A83470) -/* A7A52C 8024002C 0C01953C */ jal sprintf -/* A7A530 80240030 24A58F70 */ addiu $a1, $a1, %lo(D_80248F70_A83470) -/* A7A534 80240034 8FBF0010 */ lw $ra, 0x10($sp) -/* A7A538 80240038 0000102D */ daddu $v0, $zero, $zero -/* A7A53C 8024003C 03E00008 */ jr $ra -/* A7A540 80240040 27BD0018 */ addiu $sp, $sp, 0x18 -/* A7A544 80240044 00000000 */ nop -/* A7A548 80240048 00000000 */ nop -/* A7A54C 8024004C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/area_kpa/kpa_83/A83490/func_80240000_A83490.s b/ver/us/asm/nonmatchings/world/area_kpa/kpa_83/A83490/func_80240000_A83490.s deleted file mode 100644 index 8311f3a2f7..0000000000 --- a/ver/us/asm/nonmatchings/world/area_kpa/kpa_83/A83490/func_80240000_A83490.s +++ /dev/null @@ -1,34 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.section .rodata - -dlabel D_802432F0_A86780 -.ascii "kpa_80_shape\0\0\0\0" - -dlabel D_80243300_A86790 -.ascii "kpa_80_hit\0\0kpa_53\0\0kpa_121\0\0\0\0\0" - -.section .text - -glabel func_80240000_A83490 -/* A83490 80240000 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* A83494 80240004 3C04800E */ lui $a0, %hi(wMapShapeName) -/* A83498 80240008 24849230 */ addiu $a0, $a0, %lo(wMapShapeName) -/* A8349C 8024000C 3C058024 */ lui $a1, %hi(D_802432F0_A86780) -/* A834A0 80240010 24A532F0 */ addiu $a1, $a1, %lo(D_802432F0_A86780) -/* A834A4 80240014 AFBF0010 */ sw $ra, 0x10($sp) -/* A834A8 80240018 0C01953C */ jal sprintf -/* A834AC 8024001C 00000000 */ nop -/* A834B0 80240020 3C04800E */ lui $a0, %hi(wMapHitName) -/* A834B4 80240024 248491E0 */ addiu $a0, $a0, %lo(wMapHitName) -/* A834B8 80240028 3C058024 */ lui $a1, %hi(D_80243300_A86790) -/* A834BC 8024002C 0C01953C */ jal sprintf -/* A834C0 80240030 24A53300 */ addiu $a1, $a1, %lo(D_80243300_A86790) -/* A834C4 80240034 8FBF0010 */ lw $ra, 0x10($sp) -/* A834C8 80240038 0000102D */ daddu $v0, $zero, $zero -/* A834CC 8024003C 03E00008 */ jr $ra -/* A834D0 80240040 27BD0018 */ addiu $sp, $sp, 0x18 -/* A834D4 80240044 00000000 */ nop -/* A834D8 80240048 00000000 */ nop -/* A834DC 8024004C 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/partner/goombario/func_802BD5D8_3174F8.s b/ver/us/asm/nonmatchings/world/partner/goombario/func_802BD5D8_3174F8.s index 27815ddfd1..168241e4a2 100644 --- a/ver/us/asm/nonmatchings/world/partner/goombario/func_802BD5D8_3174F8.s +++ b/ver/us/asm/nonmatchings/world/partner/goombario/func_802BD5D8_3174F8.s @@ -3,8 +3,8 @@ .section .rodata -dlabel D_802BDE88_317DA8 -.word 0x802BD8EC, 0x802BD90C, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD858, 0x802BD870, 0x802BD974, 0x802BD858, 0x802BD870, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD88C, 0x802BD8BC, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD974, 0x802BD92C, 0x802BD94C +dlabel jtbl_802BDE88_317DA8 +.word .L802BD8EC, .L802BD90C, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD858, .L802BD870, .L802BD974, .L802BD858, .L802BD870, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD88C, .L802BD8BC, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD974, .L802BD92C, .L802BD94C .section .text @@ -163,8 +163,8 @@ glabel func_802BD5D8_3174F8 /* 31771C 802BD7FC 10500066 */ beq $v0, $s0, .L802BD998 /* 317720 802BD800 24A4FFF7 */ addiu $a0, $a1, -9 /* 317724 802BD804 0060A02D */ daddu $s4, $v1, $zero -/* 317728 802BD808 3C03802C */ lui $v1, %hi(D_802BDE88_317DA8) -/* 31772C 802BD80C 2463DE88 */ addiu $v1, $v1, %lo(D_802BDE88_317DA8) +/* 317728 802BD808 3C03802C */ lui $v1, %hi(jtbl_802BDE88_317DA8) +/* 31772C 802BD80C 2463DE88 */ addiu $v1, $v1, %lo(jtbl_802BDE88_317DA8) /* 317730 802BD810 00041080 */ sll $v0, $a0, 2 /* 317734 802BD814 00434821 */ addu $t1, $v0, $v1 /* 317738 802BD818 3C068011 */ lui $a2, %hi(gPlayerData) @@ -184,12 +184,14 @@ glabel func_802BD5D8_3174F8 /* 31776C 802BD84C 8D220000 */ lw $v0, ($t1) /* 317770 802BD850 00400008 */ jr $v0 /* 317774 802BD854 00000000 */ nop +.L802BD858: /* 317778 802BD858 80C20001 */ lb $v0, 1($a2) /* 31777C 802BD85C 18400045 */ blez $v0, .L802BD974 /* 317780 802BD860 00000000 */ nop /* 317784 802BD864 3C10001B */ lui $s0, 0x1b /* 317788 802BD868 080AF65D */ j .L802BD974 /* 31778C 802BD86C 36100002 */ ori $s0, $s0, 2 +.L802BD870: /* 317790 802BD870 80C20001 */ lb $v0, 1($a2) /* 317794 802BD874 28420002 */ slti $v0, $v0, 2 /* 317798 802BD878 1440003E */ bnez $v0, .L802BD974 @@ -197,6 +199,7 @@ glabel func_802BD5D8_3174F8 /* 3177A0 802BD880 3C10001B */ lui $s0, 0x1b /* 3177A4 802BD884 080AF65D */ j .L802BD974 /* 3177A8 802BD888 36100004 */ ori $s0, $s0, 4 +.L802BD88C: /* 3177AC 802BD88C 3C028011 */ lui $v0, %hi(gPlayerData) /* 3177B0 802BD890 8042F290 */ lb $v0, %lo(gPlayerData)($v0) /* 3177B4 802BD894 14470004 */ bne $v0, $a3, .L802BD8A8 @@ -210,6 +213,7 @@ glabel func_802BD5D8_3174F8 /* 3177D0 802BD8B0 3C10001B */ lui $s0, 0x1b /* 3177D4 802BD8B4 080AF65D */ j .L802BD974 /* 3177D8 802BD8B8 36100019 */ ori $s0, $s0, 0x19 +.L802BD8BC: /* 3177DC 802BD8BC 3C028011 */ lui $v0, %hi(gPlayerData) /* 3177E0 802BD8C0 8042F290 */ lb $v0, %lo(gPlayerData)($v0) /* 3177E4 802BD8C4 14470004 */ bne $v0, $a3, .L802BD8D8 @@ -223,6 +227,7 @@ glabel func_802BD5D8_3174F8 /* 317800 802BD8E0 3C10001B */ lui $s0, 0x1b /* 317804 802BD8E4 080AF65D */ j .L802BD974 /* 317808 802BD8E8 3610001C */ ori $s0, $s0, 0x1c +.L802BD8EC: /* 31780C 802BD8EC 3C028011 */ lui $v0, %hi(gPlayerData) /* 317810 802BD8F0 8042F290 */ lb $v0, %lo(gPlayerData)($v0) /* 317814 802BD8F4 28420002 */ slti $v0, $v0, 2 @@ -231,6 +236,7 @@ glabel func_802BD5D8_3174F8 /* 317820 802BD900 3C10001B */ lui $s0, 0x1b /* 317824 802BD904 080AF65D */ j .L802BD974 /* 317828 802BD908 3610000D */ ori $s0, $s0, 0xd +.L802BD90C: /* 31782C 802BD90C 3C028011 */ lui $v0, %hi(gPlayerData) /* 317830 802BD910 8042F290 */ lb $v0, %lo(gPlayerData)($v0) /* 317834 802BD914 28420002 */ slti $v0, $v0, 2 @@ -239,6 +245,7 @@ glabel func_802BD5D8_3174F8 /* 317840 802BD920 3C10001B */ lui $s0, 0x1b /* 317844 802BD924 080AF65D */ j .L802BD974 /* 317848 802BD928 3610000F */ ori $s0, $s0, 0xf +.L802BD92C: /* 31784C 802BD92C 3C028011 */ lui $v0, %hi(gPlayerData) /* 317850 802BD930 8042F290 */ lb $v0, %lo(gPlayerData)($v0) /* 317854 802BD934 28420002 */ slti $v0, $v0, 2 @@ -247,6 +254,7 @@ glabel func_802BD5D8_3174F8 /* 317860 802BD940 3C10001B */ lui $s0, 0x1b /* 317864 802BD944 080AF65D */ j .L802BD974 /* 317868 802BD948 3610001E */ ori $s0, $s0, 0x1e +.L802BD94C: /* 31786C 802BD94C 3C04802C */ lui $a0, %hi(GoombarioGetTattleID) /* 317870 802BD950 8C84DF60 */ lw $a0, %lo(GoombarioGetTattleID)($a0) /* 317874 802BD954 0C04417A */ jal get_entity_by_index diff --git a/ver/us/asm/nonmatchings/world/partner/watt/func_802BD1AC_31CD1C.s b/ver/us/asm/nonmatchings/world/partner/watt/func_802BD1AC_31CD1C.s deleted file mode 100644 index f95f802d91..0000000000 --- a/ver/us/asm/nonmatchings/world/partner/watt/func_802BD1AC_31CD1C.s +++ /dev/null @@ -1,42 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_802BD1AC_31CD1C -/* 31CD1C 802BD1AC 3C02802C */ lui $v0, %hi(WattStaticEffect) -/* 31CD20 802BD1B0 8C42E310 */ lw $v0, %lo(WattStaticEffect)($v0) -/* 31CD24 802BD1B4 3C013F00 */ lui $at, 0x3f00 -/* 31CD28 802BD1B8 44810000 */ mtc1 $at, $f0 -/* 31CD2C 802BD1BC 8C45000C */ lw $a1, 0xc($v0) -/* 31CD30 802BD1C0 24030001 */ addiu $v1, $zero, 1 -/* 31CD34 802BD1C4 ACA40000 */ sw $a0, ($a1) -/* 31CD38 802BD1C8 00042080 */ sll $a0, $a0, 2 -/* 31CD3C 802BD1CC 3C01802C */ lui $at, %hi(D_802BE250_31DDC0) -/* 31CD40 802BD1D0 00240821 */ addu $at, $at, $a0 -/* 31CD44 802BD1D4 C422E250 */ lwc1 $f2, %lo(D_802BE250_31DDC0)($at) -/* 31CD48 802BD1D8 468010A0 */ cvt.s.w $f2, $f2 -/* 31CD4C 802BD1DC 8C420008 */ lw $v0, 8($v0) -/* 31CD50 802BD1E0 46001082 */ mul.s $f2, $f2, $f0 -/* 31CD54 802BD1E4 00000000 */ nop -/* 31CD58 802BD1E8 2444FFFF */ addiu $a0, $v0, -1 -/* 31CD5C 802BD1EC 0064102A */ slt $v0, $v1, $a0 -/* 31CD60 802BD1F0 10400010 */ beqz $v0, .L802BD234 -/* 31CD64 802BD1F4 24A50038 */ addiu $a1, $a1, 0x38 -/* 31CD68 802BD1F8 3C01BF80 */ lui $at, 0xbf80 -/* 31CD6C 802BD1FC 44812000 */ mtc1 $at, $f4 -.L802BD200: -/* 31CD70 802BD200 30620001 */ andi $v0, $v1, 1 -/* 31CD74 802BD204 44820000 */ mtc1 $v0, $f0 -/* 31CD78 802BD208 00000000 */ nop -/* 31CD7C 802BD20C 46800020 */ cvt.s.w $f0, $f0 -/* 31CD80 802BD210 46001002 */ mul.s $f0, $f2, $f0 -/* 31CD84 802BD214 00000000 */ nop -/* 31CD88 802BD218 46002001 */ sub.s $f0, $f4, $f0 -/* 31CD8C 802BD21C 24630001 */ addiu $v1, $v1, 1 -/* 31CD90 802BD220 0064102A */ slt $v0, $v1, $a0 -/* 31CD94 802BD224 4600018D */ trunc.w.s $f6, $f0 -/* 31CD98 802BD228 E4A60020 */ swc1 $f6, 0x20($a1) -/* 31CD9C 802BD22C 1440FFF4 */ bnez $v0, .L802BD200 -/* 31CDA0 802BD230 24A50038 */ addiu $a1, $a1, 0x38 -.L802BD234: -/* 31CDA4 802BD234 03E00008 */ jr $ra -/* 31CDA8 802BD238 00000000 */ nop diff --git a/ver/us/asm/nonmatchings/world/partner/watt/func_802BD754_31D2C4.s b/ver/us/asm/nonmatchings/world/partner/watt/func_802BD754_31D2C4.s deleted file mode 100644 index e90f1fecdd..0000000000 --- a/ver/us/asm/nonmatchings/world/partner/watt/func_802BD754_31D2C4.s +++ /dev/null @@ -1,391 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel WattUseAbility -/* 31D2C4 802BD754 27BDFFD0 */ addiu $sp, $sp, -0x30 -/* 31D2C8 802BD758 AFB3001C */ sw $s3, 0x1c($sp) -/* 31D2CC 802BD75C 0080982D */ daddu $s3, $a0, $zero -/* 31D2D0 802BD760 AFB20018 */ sw $s2, 0x18($sp) -/* 31D2D4 802BD764 3C128011 */ lui $s2, %hi(gPlayerStatus) -/* 31D2D8 802BD768 2652EFC8 */ addiu $s2, $s2, %lo(gPlayerStatus) -/* 31D2DC 802BD76C AFB50024 */ sw $s5, 0x24($sp) -/* 31D2E0 802BD770 3C158011 */ lui $s5, %hi(gPartnerActionStatus) -/* 31D2E4 802BD774 26B5EBB0 */ addiu $s5, $s5, %lo(gPartnerActionStatus) -/* 31D2E8 802BD778 AFBF0028 */ sw $ra, 0x28($sp) -/* 31D2EC 802BD77C AFB40020 */ sw $s4, 0x20($sp) -/* 31D2F0 802BD780 AFB10014 */ sw $s1, 0x14($sp) -/* 31D2F4 802BD784 AFB00010 */ sw $s0, 0x10($sp) -/* 31D2F8 802BD788 10A0003B */ beqz $a1, .L802BD878 -/* 31D2FC 802BD78C 8E71014C */ lw $s1, 0x14c($s3) -/* 31D300 802BD790 0C0AF5C4 */ jal func_802BD710_31D280 -/* 31D304 802BD794 0220202D */ daddu $a0, $s1, $zero -/* 31D308 802BD798 8E430004 */ lw $v1, 4($s2) -/* 31D30C 802BD79C 3C020010 */ lui $v0, 0x10 -/* 31D310 802BD7A0 00621024 */ and $v0, $v1, $v0 -/* 31D314 802BD7A4 14400150 */ bnez $v0, .L802BDCE8 -/* 31D318 802BD7A8 24020002 */ addiu $v0, $zero, 2 -/* 31D31C 802BD7AC 82A20001 */ lb $v0, 1($s5) -/* 31D320 802BD7B0 14400026 */ bnez $v0, .L802BD84C -/* 31D324 802BD7B4 34620003 */ ori $v0, $v1, 3 -/* 31D328 802BD7B8 82A20000 */ lb $v0, ($s5) -/* 31D32C 802BD7BC 14400009 */ bnez $v0, .L802BD7E4 -/* 31D330 802BD7C0 00000000 */ nop -/* 31D334 802BD7C4 0C03A94B */ jal func_800EA52C -/* 31D338 802BD7C8 24040006 */ addiu $a0, $zero, 6 -/* 31D33C 802BD7CC 10400146 */ beqz $v0, .L802BDCE8 -/* 31D340 802BD7D0 24020002 */ addiu $v0, $zero, 2 -/* 31D344 802BD7D4 0C011052 */ jal is_starting_conversation -/* 31D348 802BD7D8 00000000 */ nop -/* 31D34C 802BD7DC 14400142 */ bnez $v0, .L802BDCE8 -/* 31D350 802BD7E0 24020002 */ addiu $v0, $zero, 2 -.L802BD7E4: -/* 31D354 802BD7E4 3C028007 */ lui $v0, %hi(gGameStatusPtr) -/* 31D358 802BD7E8 8C42419C */ lw $v0, %lo(gGameStatusPtr)($v0) -/* 31D35C 802BD7EC 8042007D */ lb $v0, 0x7d($v0) -/* 31D360 802BD7F0 10400009 */ beqz $v0, .L802BD818 -/* 31D364 802BD7F4 00000000 */ nop -/* 31D368 802BD7F8 8E420004 */ lw $v0, 4($s2) -/* 31D36C 802BD7FC 30420003 */ andi $v0, $v0, 3 -/* 31D370 802BD800 1040000D */ beqz $v0, .L802BD838 -/* 31D374 802BD804 24020014 */ addiu $v0, $zero, 0x14 -/* 31D378 802BD808 3C01802C */ lui $at, %hi(D_802BE304) -/* 31D37C 802BD80C AC22E304 */ sw $v0, %lo(D_802BE304)($at) -/* 31D380 802BD810 080AF61E */ j .L802BD878 -/* 31D384 802BD814 00000000 */ nop -.L802BD818: -/* 31D388 802BD818 8E420004 */ lw $v0, 4($s2) -/* 31D38C 802BD81C 30420001 */ andi $v0, $v0, 1 -/* 31D390 802BD820 10400005 */ beqz $v0, .L802BD838 -/* 31D394 802BD824 24020002 */ addiu $v0, $zero, 2 -/* 31D398 802BD828 3C01802C */ lui $at, %hi(D_802BE304) -/* 31D39C 802BD82C AC22E304 */ sw $v0, %lo(D_802BE304)($at) -/* 31D3A0 802BD830 080AF61E */ j .L802BD878 -/* 31D3A4 802BD834 00000000 */ nop -.L802BD838: -/* 31D3A8 802BD838 24020028 */ addiu $v0, $zero, 0x28 -/* 31D3AC 802BD83C 3C01802C */ lui $at, %hi(D_802BE304) -/* 31D3B0 802BD840 AC22E304 */ sw $v0, %lo(D_802BE304)($at) -/* 31D3B4 802BD844 080AF61E */ j .L802BD878 -/* 31D3B8 802BD848 00000000 */ nop -.L802BD84C: -/* 31D3BC 802BD84C A2A00001 */ sb $zero, 1($s5) -/* 31D3C0 802BD850 0C0AF805 */ jal func_802BE014_31DB84 -/* 31D3C4 802BD854 AE420004 */ sw $v0, 4($s2) -/* 31D3C8 802BD858 3C020006 */ lui $v0, 6 -/* 31D3CC 802BD85C 34420001 */ ori $v0, $v0, 1 -/* 31D3D0 802BD860 AE220028 */ sw $v0, 0x28($s1) -/* 31D3D4 802BD864 24020001 */ addiu $v0, $zero, 1 -/* 31D3D8 802BD868 3C01802C */ lui $at, %hi(D_802BE304) -/* 31D3DC 802BD86C AC22E304 */ sw $v0, %lo(D_802BE304)($at) -/* 31D3E0 802BD870 24020002 */ addiu $v0, $zero, 2 -/* 31D3E4 802BD874 AE620074 */ sw $v0, 0x74($s3) -.L802BD878: -/* 31D3E8 802BD878 3C10802C */ lui $s0, %hi(D_802BE304) -/* 31D3EC 802BD87C 2610E304 */ addiu $s0, $s0, %lo(D_802BE304) -/* 31D3F0 802BD880 8E030000 */ lw $v1, ($s0) -/* 31D3F4 802BD884 24020028 */ addiu $v0, $zero, 0x28 -/* 31D3F8 802BD888 10620005 */ beq $v1, $v0, .L802BD8A0 -/* 31D3FC 802BD88C 24020029 */ addiu $v0, $zero, 0x29 -/* 31D400 802BD890 1062000E */ beq $v1, $v0, .L802BD8CC -/* 31D404 802BD894 00000000 */ nop -/* 31D408 802BD898 080AF64C */ j .L802BD930 -/* 31D40C 802BD89C 00000000 */ nop -.L802BD8A0: -/* 31D410 802BD8A0 82420015 */ lb $v0, 0x15($s2) -/* 31D414 802BD8A4 10400003 */ beqz $v0, .L802BD8B4 -/* 31D418 802BD8A8 24020003 */ addiu $v0, $zero, 3 -/* 31D41C 802BD8AC 080AF73A */ j .L802BDCE8 -/* 31D420 802BD8B0 24020002 */ addiu $v0, $zero, 2 -.L802BD8B4: -/* 31D424 802BD8B4 AE620074 */ sw $v0, 0x74($s3) -/* 31D428 802BD8B8 82430015 */ lb $v1, 0x15($s2) -/* 31D42C 802BD8BC 24020029 */ addiu $v0, $zero, 0x29 -/* 31D430 802BD8C0 AE020000 */ sw $v0, ($s0) -/* 31D434 802BD8C4 080AF64C */ j .L802BD930 -/* 31D438 802BD8C8 AE630078 */ sw $v1, 0x78($s3) -.L802BD8CC: -/* 31D43C 802BD8CC 8E620074 */ lw $v0, 0x74($s3) -/* 31D440 802BD8D0 14400016 */ bnez $v0, .L802BD92C -/* 31D444 802BD8D4 2442FFFF */ addiu $v0, $v0, -1 -/* 31D448 802BD8D8 82430015 */ lb $v1, 0x15($s2) -/* 31D44C 802BD8DC 8E620078 */ lw $v0, 0x78($s3) -/* 31D450 802BD8E0 0043102A */ slt $v0, $v0, $v1 -/* 31D454 802BD8E4 14400100 */ bnez $v0, .L802BDCE8 -/* 31D458 802BD8E8 24020002 */ addiu $v0, $zero, 2 -/* 31D45C 802BD8EC 8E420004 */ lw $v0, 4($s2) -/* 31D460 802BD8F0 3C030010 */ lui $v1, 0x10 -/* 31D464 802BD8F4 00431024 */ and $v0, $v0, $v1 -/* 31D468 802BD8F8 144000FB */ bnez $v0, .L802BDCE8 -/* 31D46C 802BD8FC 24020002 */ addiu $v0, $zero, 2 -/* 31D470 802BD900 0C03A94B */ jal func_800EA52C -/* 31D474 802BD904 24040006 */ addiu $a0, $zero, 6 -/* 31D478 802BD908 104000F7 */ beqz $v0, .L802BDCE8 -/* 31D47C 802BD90C 24020002 */ addiu $v0, $zero, 2 -/* 31D480 802BD910 0C011052 */ jal is_starting_conversation -/* 31D484 802BD914 00000000 */ nop -/* 31D488 802BD918 144000F3 */ bnez $v0, .L802BDCE8 -/* 31D48C 802BD91C 24020002 */ addiu $v0, $zero, 2 -/* 31D490 802BD920 24020014 */ addiu $v0, $zero, 0x14 -/* 31D494 802BD924 080AF64C */ j .L802BD930 -/* 31D498 802BD928 AE020000 */ sw $v0, ($s0) -.L802BD92C: -/* 31D49C 802BD92C AE620074 */ sw $v0, 0x74($s3) -.L802BD930: -/* 31D4A0 802BD930 3C14802C */ lui $s4, %hi(D_802BE304) -/* 31D4A4 802BD934 2694E304 */ addiu $s4, $s4, %lo(D_802BE304) -/* 31D4A8 802BD938 8E830000 */ lw $v1, ($s4) -/* 31D4AC 802BD93C 24020014 */ addiu $v0, $zero, 0x14 -/* 31D4B0 802BD940 1062000C */ beq $v1, $v0, .L802BD974 -/* 31D4B4 802BD944 28620015 */ slti $v0, $v1, 0x15 -/* 31D4B8 802BD948 10400005 */ beqz $v0, .L802BD960 -/* 31D4BC 802BD94C 24020001 */ addiu $v0, $zero, 1 -/* 31D4C0 802BD950 10620099 */ beq $v1, $v0, .L802BDBB8 -/* 31D4C4 802BD954 00000000 */ nop -/* 31D4C8 802BD958 080AF707 */ j .L802BDC1C -/* 31D4CC 802BD95C 00000000 */ nop -.L802BD960: -/* 31D4D0 802BD960 24020015 */ addiu $v0, $zero, 0x15 -/* 31D4D4 802BD964 10620062 */ beq $v1, $v0, .L802BDAF0 -/* 31D4D8 802BD968 00000000 */ nop -/* 31D4DC 802BD96C 080AF707 */ j .L802BDC1C -/* 31D4E0 802BD970 00000000 */ nop -.L802BD974: -/* 31D4E4 802BD974 3C058007 */ lui $a1, %hi(gGameStatusPtr) -/* 31D4E8 802BD978 8CA5419C */ lw $a1, %lo(gGameStatusPtr)($a1) -/* 31D4EC 802BD97C 80A2007D */ lb $v0, 0x7d($a1) -/* 31D4F0 802BD980 10400030 */ beqz $v0, .L802BDA44 -/* 31D4F4 802BD984 24100001 */ addiu $s0, $zero, 1 -/* 31D4F8 802BD988 8E420004 */ lw $v0, 4($s2) -/* 31D4FC 802BD98C 3C0140A0 */ lui $at, 0x40a0 -/* 31D500 802BD990 44811000 */ mtc1 $at, $f2 -/* 31D504 802BD994 34420001 */ ori $v0, $v0, 1 -/* 31D508 802BD998 AE420004 */ sw $v0, 4($s2) -/* 31D50C 802BD99C 8E220000 */ lw $v0, ($s1) -/* 31D510 802BD9A0 2403F5FF */ addiu $v1, $zero, -0xa01 -/* 31D514 802BD9A4 3C01802C */ lui $at, %hi(D_802BE30C) -/* 31D518 802BD9A8 AC30E30C */ sw $s0, %lo(D_802BE30C)($at) -/* 31D51C 802BD9AC 34420108 */ ori $v0, $v0, 0x108 -/* 31D520 802BD9B0 00431024 */ and $v0, $v0, $v1 -/* 31D524 802BD9B4 AE220000 */ sw $v0, ($s1) -/* 31D528 802BD9B8 A0A0007D */ sb $zero, 0x7d($a1) -/* 31D52C 802BD9BC A2B00000 */ sb $s0, ($s5) -/* 31D530 802BD9C0 C6400028 */ lwc1 $f0, 0x28($s2) -/* 31D534 802BD9C4 24020006 */ addiu $v0, $zero, 6 -/* 31D538 802BD9C8 A2A20003 */ sb $v0, 3($s5) -/* 31D53C 802BD9CC E6200060 */ swc1 $f0, 0x60($s1) -/* 31D540 802BD9D0 C640002C */ lwc1 $f0, 0x2c($s2) -/* 31D544 802BD9D4 26240060 */ addiu $a0, $s1, 0x60 -/* 31D548 802BD9D8 46020000 */ add.s $f0, $f0, $f2 -/* 31D54C 802BD9DC 3C064170 */ lui $a2, 0x4170 -/* 31D550 802BD9E0 3C020006 */ lui $v0, 6 -/* 31D554 802BD9E4 E6200064 */ swc1 $f0, 0x64($s1) -/* 31D558 802BD9E8 C6400030 */ lwc1 $f0, 0x30($s2) -/* 31D55C 802BD9EC 34420002 */ ori $v0, $v0, 2 -/* 31D560 802BD9F0 AE220028 */ sw $v0, 0x28($s1) -/* 31D564 802BD9F4 E6200068 */ swc1 $f0, 0x68($s1) -/* 31D568 802BD9F8 8E470080 */ lw $a3, 0x80($s2) -/* 31D56C 802BD9FC 0C00A7E7 */ jal add_vec2D_polar -/* 31D570 802BDA00 26250068 */ addiu $a1, $s1, 0x68 -/* 31D574 802BDA04 3C020006 */ lui $v0, 6 -/* 31D578 802BDA08 C6400080 */ lwc1 $f0, 0x80($s2) -/* 31D57C 802BDA0C 00501025 */ or $v0, $v0, $s0 -/* 31D580 802BDA10 AE220028 */ sw $v0, 0x28($s1) -/* 31D584 802BDA14 E620000C */ swc1 $f0, 0xc($s1) -/* 31D588 802BDA18 8E420004 */ lw $v0, 4($s2) -/* 31D58C 802BDA1C 34420002 */ ori $v0, $v0, 2 -/* 31D590 802BDA20 0C0AF805 */ jal func_802BE014_31DB84 -/* 31D594 802BDA24 AE420004 */ sw $v0, 4($s2) -/* 31D598 802BDA28 0220202D */ daddu $a0, $s1, $zero -/* 31D59C 802BDA2C 0C00ECF4 */ jal npc_set_palswap_mode_A -/* 31D5A0 802BDA30 0200282D */ daddu $a1, $s0, $zero -/* 31D5A4 802BDA34 24020002 */ addiu $v0, $zero, 2 -/* 31D5A8 802BDA38 AE620074 */ sw $v0, 0x74($s3) -/* 31D5AC 802BDA3C 080AF707 */ j .L802BDC1C -/* 31D5B0 802BDA40 AE900000 */ sw $s0, ($s4) -.L802BDA44: -/* 31D5B4 802BDA44 8E420004 */ lw $v0, 4($s2) -/* 31D5B8 802BDA48 24040001 */ addiu $a0, $zero, 1 -/* 31D5BC 802BDA4C 00441025 */ or $v0, $v0, $a0 -/* 31D5C0 802BDA50 AE420004 */ sw $v0, 4($s2) -/* 31D5C4 802BDA54 8E220000 */ lw $v0, ($s1) -/* 31D5C8 802BDA58 2403F5FF */ addiu $v1, $zero, -0xa01 -/* 31D5CC 802BDA5C 3C01802C */ lui $at, %hi(D_802BE30C) -/* 31D5D0 802BDA60 AC24E30C */ sw $a0, %lo(D_802BE30C)($at) -/* 31D5D4 802BDA64 00431024 */ and $v0, $v0, $v1 -/* 31D5D8 802BDA68 AE220000 */ sw $v0, ($s1) -/* 31D5DC 802BDA6C 24020006 */ addiu $v0, $zero, 6 -/* 31D5E0 802BDA70 A0A0007D */ sb $zero, 0x7d($a1) -/* 31D5E4 802BDA74 A2A40000 */ sb $a0, ($s5) -/* 31D5E8 802BDA78 0C03BD38 */ jal func_800EF4E0 -/* 31D5EC 802BDA7C A2A20003 */ sb $v0, 3($s5) -/* 31D5F0 802BDA80 C6400028 */ lwc1 $f0, 0x28($s2) -/* 31D5F4 802BDA84 3C0140A0 */ lui $at, 0x40a0 -/* 31D5F8 802BDA88 44811000 */ mtc1 $at, $f2 -/* 31D5FC 802BDA8C E6200060 */ swc1 $f0, 0x60($s1) -/* 31D600 802BDA90 C640002C */ lwc1 $f0, 0x2c($s2) -/* 31D604 802BDA94 3C020006 */ lui $v0, 6 -/* 31D608 802BDA98 46020000 */ add.s $f0, $f0, $f2 -/* 31D60C 802BDA9C 3C064170 */ lui $a2, 0x4170 -/* 31D610 802BDAA0 34420002 */ ori $v0, $v0, 2 -/* 31D614 802BDAA4 E6200064 */ swc1 $f0, 0x64($s1) -/* 31D618 802BDAA8 C6400030 */ lwc1 $f0, 0x30($s2) -/* 31D61C 802BDAAC 26240060 */ addiu $a0, $s1, 0x60 -/* 31D620 802BDAB0 AE220028 */ sw $v0, 0x28($s1) -/* 31D624 802BDAB4 E6200068 */ swc1 $f0, 0x68($s1) -/* 31D628 802BDAB8 8E470080 */ lw $a3, 0x80($s2) -/* 31D62C 802BDABC 0C00A7E7 */ jal add_vec2D_polar -/* 31D630 802BDAC0 26250068 */ addiu $a1, $s1, 0x68 -/* 31D634 802BDAC4 24020008 */ addiu $v0, $zero, 8 -/* 31D638 802BDAC8 A622008E */ sh $v0, 0x8e($s1) -/* 31D63C 802BDACC 8E460028 */ lw $a2, 0x28($s2) -/* 31D640 802BDAD0 8E470030 */ lw $a3, 0x30($s2) -/* 31D644 802BDAD4 C62C0038 */ lwc1 $f12, 0x38($s1) -/* 31D648 802BDAD8 0C00A720 */ jal atan2 -/* 31D64C 802BDADC C62E0040 */ lwc1 $f14, 0x40($s1) -/* 31D650 802BDAE0 8E820000 */ lw $v0, ($s4) -/* 31D654 802BDAE4 E620000C */ swc1 $f0, 0xc($s1) -/* 31D658 802BDAE8 080AF706 */ j .L802BDC18 -/* 31D65C 802BDAEC 24420001 */ addiu $v0, $v0, 1 -.L802BDAF0: -/* 31D660 802BDAF0 C6200060 */ lwc1 $f0, 0x60($s1) -/* 31D664 802BDAF4 C62A0038 */ lwc1 $f10, 0x38($s1) -/* 31D668 802BDAF8 8622008E */ lh $v0, 0x8e($s1) -/* 31D66C 802BDAFC C6240064 */ lwc1 $f4, 0x64($s1) -/* 31D670 802BDB00 C628003C */ lwc1 $f8, 0x3c($s1) -/* 31D674 802BDB04 C6260040 */ lwc1 $f6, 0x40($s1) -/* 31D678 802BDB08 44821000 */ mtc1 $v0, $f2 -/* 31D67C 802BDB0C 00000000 */ nop -/* 31D680 802BDB10 468010A0 */ cvt.s.w $f2, $f2 -/* 31D684 802BDB14 0040202D */ daddu $a0, $v0, $zero -/* 31D688 802BDB18 460A0001 */ sub.s $f0, $f0, $f10 -/* 31D68C 802BDB1C 0080182D */ daddu $v1, $a0, $zero -/* 31D690 802BDB20 9622008E */ lhu $v0, 0x8e($s1) -/* 31D694 802BDB24 46082101 */ sub.s $f4, $f4, $f8 -/* 31D698 802BDB28 2442FFFF */ addiu $v0, $v0, -1 -/* 31D69C 802BDB2C A622008E */ sh $v0, 0x8e($s1) -/* 31D6A0 802BDB30 46020003 */ div.s $f0, $f0, $f2 -/* 31D6A4 802BDB34 46005280 */ add.s $f10, $f10, $f0 -/* 31D6A8 802BDB38 C6220068 */ lwc1 $f2, 0x68($s1) -/* 31D6AC 802BDB3C 00021400 */ sll $v0, $v0, 0x10 -/* 31D6B0 802BDB40 46061081 */ sub.s $f2, $f2, $f6 -/* 31D6B4 802BDB44 44840000 */ mtc1 $a0, $f0 -/* 31D6B8 802BDB48 00000000 */ nop -/* 31D6BC 802BDB4C 46800020 */ cvt.s.w $f0, $f0 -/* 31D6C0 802BDB50 46002103 */ div.s $f4, $f4, $f0 -/* 31D6C4 802BDB54 46044200 */ add.s $f8, $f8, $f4 -/* 31D6C8 802BDB58 44830000 */ mtc1 $v1, $f0 -/* 31D6CC 802BDB5C 00000000 */ nop -/* 31D6D0 802BDB60 46800020 */ cvt.s.w $f0, $f0 -/* 31D6D4 802BDB64 46001083 */ div.s $f2, $f2, $f0 -/* 31D6D8 802BDB68 46023180 */ add.s $f6, $f6, $f2 -/* 31D6DC 802BDB6C E62A0038 */ swc1 $f10, 0x38($s1) -/* 31D6E0 802BDB70 E628003C */ swc1 $f8, 0x3c($s1) -/* 31D6E4 802BDB74 14400029 */ bnez $v0, .L802BDC1C -/* 31D6E8 802BDB78 E6260040 */ swc1 $f6, 0x40($s1) -/* 31D6EC 802BDB7C 3C020006 */ lui $v0, 6 -/* 31D6F0 802BDB80 C6400080 */ lwc1 $f0, 0x80($s2) -/* 31D6F4 802BDB84 34420001 */ ori $v0, $v0, 1 -/* 31D6F8 802BDB88 AE220028 */ sw $v0, 0x28($s1) -/* 31D6FC 802BDB8C E620000C */ swc1 $f0, 0xc($s1) -/* 31D700 802BDB90 8E420004 */ lw $v0, 4($s2) -/* 31D704 802BDB94 24030006 */ addiu $v1, $zero, 6 -/* 31D708 802BDB98 A2A30003 */ sb $v1, 3($s5) -/* 31D70C 802BDB9C 34420002 */ ori $v0, $v0, 2 -/* 31D710 802BDBA0 0C0AF805 */ jal func_802BE014_31DB84 -/* 31D714 802BDBA4 AE420004 */ sw $v0, 4($s2) -/* 31D718 802BDBA8 24020002 */ addiu $v0, $zero, 2 -/* 31D71C 802BDBAC AE620074 */ sw $v0, 0x74($s3) -/* 31D720 802BDBB0 080AF706 */ j .L802BDC18 -/* 31D724 802BDBB4 24020001 */ addiu $v0, $zero, 1 -.L802BDBB8: -/* 31D728 802BDBB8 0C0AF81C */ jal func_802BE070_31DBE0 -/* 31D72C 802BDBBC 00000000 */ nop -/* 31D730 802BDBC0 8E420000 */ lw $v0, ($s2) -/* 31D734 802BDBC4 30420800 */ andi $v0, $v0, 0x800 -/* 31D738 802BDBC8 14400013 */ bnez $v0, .L802BDC18 -/* 31D73C 802BDBCC 24020002 */ addiu $v0, $zero, 2 -/* 31D740 802BDBD0 824300B4 */ lb $v1, 0xb4($s2) -/* 31D744 802BDBD4 2402001D */ addiu $v0, $zero, 0x1d -/* 31D748 802BDBD8 10620010 */ beq $v1, $v0, .L802BDC1C -/* 31D74C 802BDBDC 00000000 */ nop -/* 31D750 802BDBE0 8E620074 */ lw $v0, 0x74($s3) -/* 31D754 802BDBE4 10400003 */ beqz $v0, .L802BDBF4 -/* 31D758 802BDBE8 2442FFFF */ addiu $v0, $v0, -1 -/* 31D75C 802BDBEC 080AF707 */ j .L802BDC1C -/* 31D760 802BDBF0 AE620074 */ sw $v0, 0x74($s3) -.L802BDBF4: -/* 31D764 802BDBF4 2C620003 */ sltiu $v0, $v1, 3 -/* 31D768 802BDBF8 14400003 */ bnez $v0, .L802BDC08 -/* 31D76C 802BDBFC 2402000A */ addiu $v0, $zero, 0xa -/* 31D770 802BDC00 14620006 */ bne $v1, $v0, .L802BDC1C -/* 31D774 802BDC04 00000000 */ nop -.L802BDC08: -/* 31D778 802BDC08 8EA2000C */ lw $v0, 0xc($s5) -/* 31D77C 802BDC0C 30424000 */ andi $v0, $v0, 0x4000 -/* 31D780 802BDC10 10400002 */ beqz $v0, .L802BDC1C -/* 31D784 802BDC14 24020002 */ addiu $v0, $zero, 2 -.L802BDC18: -/* 31D788 802BDC18 AE820000 */ sw $v0, ($s4) -.L802BDC1C: -/* 31D78C 802BDC1C 3C10802C */ lui $s0, %hi(D_802BE304) -/* 31D790 802BDC20 2610E304 */ addiu $s0, $s0, %lo(D_802BE304) -/* 31D794 802BDC24 8E030000 */ lw $v1, ($s0) -/* 31D798 802BDC28 24020002 */ addiu $v0, $zero, 2 -/* 31D79C 802BDC2C 1462001D */ bne $v1, $v0, .L802BDCA4 -/* 31D7A0 802BDC30 3C050006 */ lui $a1, 6 -/* 31D7A4 802BDC34 34A50001 */ ori $a1, $a1, 1 -/* 31D7A8 802BDC38 0220202D */ daddu $a0, $s1, $zero -/* 31D7AC 802BDC3C 8E420004 */ lw $v0, 4($s2) -/* 31D7B0 802BDC40 2403FFFC */ addiu $v1, $zero, -4 -/* 31D7B4 802BDC44 00431024 */ and $v0, $v0, $v1 -/* 31D7B8 802BDC48 AE420004 */ sw $v0, 4($s2) -/* 31D7BC 802BDC4C 0C03BD17 */ jal partner_clear_player_tracking -/* 31D7C0 802BDC50 AE250028 */ sw $a1, 0x28($s1) -/* 31D7C4 802BDC54 0220202D */ daddu $a0, $s1, $zero -/* 31D7C8 802BDC58 3C028007 */ lui $v0, %hi(gGameStatusPtr) -/* 31D7CC 802BDC5C 8C42419C */ lw $v0, %lo(gGameStatusPtr)($v0) -/* 31D7D0 802BDC60 0000282D */ daddu $a1, $zero, $zero -/* 31D7D4 802BDC64 3C01802C */ lui $at, %hi(D_802BE30C) -/* 31D7D8 802BDC68 AC20E30C */ sw $zero, %lo(D_802BE30C)($at) -/* 31D7DC 802BDC6C A2A00003 */ sb $zero, 3($s5) -/* 31D7E0 802BDC70 A2A00000 */ sb $zero, ($s5) -/* 31D7E4 802BDC74 A040007D */ sb $zero, 0x7d($v0) -/* 31D7E8 802BDC78 24020014 */ addiu $v0, $zero, 0x14 -/* 31D7EC 802BDC7C 0C00ECF4 */ jal npc_set_palswap_mode_A -/* 31D7F0 802BDC80 AE020000 */ sw $v0, ($s0) -/* 31D7F4 802BDC84 8E420000 */ lw $v0, ($s2) -/* 31D7F8 802BDC88 30420800 */ andi $v0, $v0, 0x800 -/* 31D7FC 802BDC8C 14400016 */ bnez $v0, .L802BDCE8 -/* 31D800 802BDC90 24020001 */ addiu $v0, $zero, 1 -/* 31D804 802BDC94 0C039769 */ jal set_action_state -/* 31D808 802BDC98 0000202D */ daddu $a0, $zero, $zero -/* 31D80C 802BDC9C 080AF73A */ j .L802BDCE8 -/* 31D810 802BDCA0 24020001 */ addiu $v0, $zero, 1 -.L802BDCA4: -/* 31D814 802BDCA4 3C03802C */ lui $v1, %hi(WattStaticEffect) -/* 31D818 802BDCA8 8C63E310 */ lw $v1, %lo(WattStaticEffect)($v1) -/* 31D81C 802BDCAC 1060000E */ beqz $v1, .L802BDCE8 -/* 31D820 802BDCB0 0000102D */ daddu $v0, $zero, $zero -/* 31D824 802BDCB4 8C62000C */ lw $v0, 0xc($v1) -/* 31D828 802BDCB8 C6200038 */ lwc1 $f0, 0x38($s1) -/* 31D82C 802BDCBC 3C014150 */ lui $at, 0x4150 -/* 31D830 802BDCC0 44811000 */ mtc1 $at, $f2 -/* 31D834 802BDCC4 E4400004 */ swc1 $f0, 4($v0) -/* 31D838 802BDCC8 C620003C */ lwc1 $f0, 0x3c($s1) -/* 31D83C 802BDCCC 46020000 */ add.s $f0, $f0, $f2 -/* 31D840 802BDCD0 8C62000C */ lw $v0, 0xc($v1) -/* 31D844 802BDCD4 E4400008 */ swc1 $f0, 8($v0) -/* 31D848 802BDCD8 8C62000C */ lw $v0, 0xc($v1) -/* 31D84C 802BDCDC C6200040 */ lwc1 $f0, 0x40($s1) -/* 31D850 802BDCE0 E440000C */ swc1 $f0, 0xc($v0) -/* 31D854 802BDCE4 0000102D */ daddu $v0, $zero, $zero -.L802BDCE8: -/* 31D858 802BDCE8 8FBF0028 */ lw $ra, 0x28($sp) -/* 31D85C 802BDCEC 8FB50024 */ lw $s5, 0x24($sp) -/* 31D860 802BDCF0 8FB40020 */ lw $s4, 0x20($sp) -/* 31D864 802BDCF4 8FB3001C */ lw $s3, 0x1c($sp) -/* 31D868 802BDCF8 8FB20018 */ lw $s2, 0x18($sp) -/* 31D86C 802BDCFC 8FB10014 */ lw $s1, 0x14($sp) -/* 31D870 802BDD00 8FB00010 */ lw $s0, 0x10($sp) -/* 31D874 802BDD04 03E00008 */ jr $ra -/* 31D878 802BDD08 27BD0030 */ addiu $sp, $sp, 0x30 diff --git a/ver/us/asm/nonmatchings/world/partners/partner_get_out.s b/ver/us/asm/nonmatchings/world/partners/partner_get_out.s deleted file mode 100644 index e072b6789c..0000000000 --- a/ver/us/asm/nonmatchings/world/partners/partner_get_out.s +++ /dev/null @@ -1,411 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel partner_get_out -/* 88198 800EECE8 27BDFF90 */ addiu $sp, $sp, -0x70 -/* 8819C 800EECEC AFB00030 */ sw $s0, 0x30($sp) -/* 881A0 800EECF0 0080802D */ daddu $s0, $a0, $zero -/* 881A4 800EECF4 AFB10034 */ sw $s1, 0x34($sp) -/* 881A8 800EECF8 3C118011 */ lui $s1, %hi(gPlayerStatus) -/* 881AC 800EECFC 2631EFC8 */ addiu $s1, $s1, %lo(gPlayerStatus) -/* 881B0 800EED00 3C038007 */ lui $v1, %hi(gCurrentCameraID) -/* 881B4 800EED04 8C637410 */ lw $v1, %lo(gCurrentCameraID)($v1) -/* 881B8 800EED08 3C04800B */ lui $a0, %hi(gCameras) -/* 881BC 800EED0C 24841D80 */ addiu $a0, $a0, %lo(gCameras) -/* 881C0 800EED10 AFB3003C */ sw $s3, 0x3c($sp) -/* 881C4 800EED14 3C138011 */ lui $s3, %hi(D_8010CFC8) -/* 881C8 800EED18 2673CFC8 */ addiu $s3, $s3, %lo(D_8010CFC8) -/* 881CC 800EED1C AFBF0048 */ sw $ra, 0x48($sp) -/* 881D0 800EED20 AFB50044 */ sw $s5, 0x44($sp) -/* 881D4 800EED24 AFB40040 */ sw $s4, 0x40($sp) -/* 881D8 800EED28 AFB20038 */ sw $s2, 0x38($sp) -/* 881DC 800EED2C F7BA0068 */ sdc1 $f26, 0x68($sp) -/* 881E0 800EED30 F7B80060 */ sdc1 $f24, 0x60($sp) -/* 881E4 800EED34 F7B60058 */ sdc1 $f22, 0x58($sp) -/* 881E8 800EED38 F7B40050 */ sdc1 $f20, 0x50($sp) -/* 881EC 800EED3C 00031080 */ sll $v0, $v1, 2 -/* 881F0 800EED40 00431021 */ addu $v0, $v0, $v1 -/* 881F4 800EED44 00021080 */ sll $v0, $v0, 2 -/* 881F8 800EED48 00431023 */ subu $v0, $v0, $v1 -/* 881FC 800EED4C 000218C0 */ sll $v1, $v0, 3 -/* 88200 800EED50 00431021 */ addu $v0, $v0, $v1 -/* 88204 800EED54 000210C0 */ sll $v0, $v0, 3 -/* 88208 800EED58 00449021 */ addu $s2, $v0, $a0 -/* 8820C 800EED5C 86630000 */ lh $v1, ($s3) -/* 88210 800EED60 24020001 */ addiu $v0, $zero, 1 -/* 88214 800EED64 106200E6 */ beq $v1, $v0, .L800EF100 -/* 88218 800EED68 28620002 */ slti $v0, $v1, 2 -/* 8821C 800EED6C 10400005 */ beqz $v0, .L800EED84 -/* 88220 800EED70 24020002 */ addiu $v0, $zero, 2 -/* 88224 800EED74 10600007 */ beqz $v1, .L800EED94 -/* 88228 800EED78 0000102D */ daddu $v0, $zero, $zero -/* 8822C 800EED7C 0803BCB3 */ j .L800EF2CC -/* 88230 800EED80 00000000 */ nop -.L800EED84: -/* 88234 800EED84 10620123 */ beq $v1, $v0, .L800EF214 -/* 88238 800EED88 0000102D */ daddu $v0, $zero, $zero -/* 8823C 800EED8C 0803BCB3 */ j .L800EF2CC -/* 88240 800EED90 00000000 */ nop -.L800EED94: -/* 88244 800EED94 0C00A6C9 */ jal clamp_angle -/* 88248 800EED98 C62C00A8 */ lwc1 $f12, 0xa8($s1) -/* 8824C 800EED9C 3C014334 */ lui $at, 0x4334 -/* 88250 800EEDA0 44811000 */ mtc1 $at, $f2 -/* 88254 800EEDA4 00000000 */ nop -/* 88258 800EEDA8 4602003C */ c.lt.s $f0, $f2 -/* 8825C 800EEDAC 00000000 */ nop -/* 88260 800EEDB0 45000006 */ bc1f .L800EEDCC -/* 88264 800EEDB4 00000000 */ nop -/* 88268 800EEDB8 C640006C */ lwc1 $f0, 0x6c($s2) -/* 8826C 800EEDBC 3C0142B4 */ lui $at, 0x42b4 -/* 88270 800EEDC0 44816000 */ mtc1 $at, $f12 -/* 88274 800EEDC4 0803BB78 */ j .L800EEDE0 -/* 88278 800EEDC8 460C0300 */ add.s $f12, $f0, $f12 -.L800EEDCC: -/* 8827C 800EEDCC C640006C */ lwc1 $f0, 0x6c($s2) -/* 88280 800EEDD0 3C0142B4 */ lui $at, 0x42b4 -/* 88284 800EEDD4 44816000 */ mtc1 $at, $f12 -/* 88288 800EEDD8 00000000 */ nop -/* 8828C 800EEDDC 460C0301 */ sub.s $f12, $f0, $f12 -.L800EEDE0: -/* 88290 800EEDE0 0C00A6C9 */ jal clamp_angle -/* 88294 800EEDE4 00000000 */ nop -/* 88298 800EEDE8 E600000C */ swc1 $f0, 0xc($s0) -/* 8829C 800EEDEC C6200028 */ lwc1 $f0, 0x28($s1) -/* 882A0 800EEDF0 3C128011 */ lui $s2, %hi(wPartner) -/* 882A4 800EEDF4 2652CFEC */ addiu $s2, $s2, %lo(wPartner) -/* 882A8 800EEDF8 E6000060 */ swc1 $f0, 0x60($s0) -/* 882AC 800EEDFC C620002C */ lwc1 $f0, 0x2c($s1) -/* 882B0 800EEE00 8E420000 */ lw $v0, ($s2) -/* 882B4 800EEE04 E6000064 */ swc1 $f0, 0x64($s0) -/* 882B8 800EEE08 8C42000C */ lw $v0, 0xc($v0) -/* 882BC 800EEE0C 10400003 */ beqz $v0, .L800EEE1C -/* 882C0 800EEE10 26040060 */ addiu $a0, $s0, 0x60 -/* 882C4 800EEE14 C620002C */ lwc1 $f0, 0x2c($s1) -/* 882C8 800EEE18 E6000064 */ swc1 $f0, 0x64($s0) -.L800EEE1C: -/* 882CC 800EEE1C C6200030 */ lwc1 $f0, 0x30($s1) -/* 882D0 800EEE20 E6000068 */ swc1 $f0, 0x68($s0) -/* 882D4 800EEE24 862200B2 */ lh $v0, 0xb2($s1) -/* 882D8 800EEE28 8E07000C */ lw $a3, 0xc($s0) -/* 882DC 800EEE2C 44825000 */ mtc1 $v0, $f10 -/* 882E0 800EEE30 00000000 */ nop -/* 882E4 800EEE34 468052A0 */ cvt.s.w $f10, $f10 -/* 882E8 800EEE38 44065000 */ mfc1 $a2, $f10 -/* 882EC 800EEE3C 0C00A7E7 */ jal add_vec2D_polar -/* 882F0 800EEE40 26050068 */ addiu $a1, $s0, 0x68 -/* 882F4 800EEE44 C6160060 */ lwc1 $f22, 0x60($s0) -/* 882F8 800EEE48 8E420000 */ lw $v0, ($s2) -/* 882FC 800EEE4C C61A0064 */ lwc1 $f26, 0x64($s0) -/* 88300 800EEE50 8C42000C */ lw $v0, 0xc($v0) -/* 88304 800EEE54 C6140068 */ lwc1 $f20, 0x68($s0) -/* 88308 800EEE58 14400052 */ bnez $v0, .L800EEFA4 -/* 8830C 800EEE5C 27B20020 */ addiu $s2, $sp, 0x20 -/* 88310 800EEE60 0240202D */ daddu $a0, $s2, $zero -/* 88314 800EEE64 27B30024 */ addiu $s3, $sp, 0x24 -/* 88318 800EEE68 0260282D */ daddu $a1, $s3, $zero -/* 8831C 800EEE6C 3C158007 */ lui $s5, %hi(gCurrentCameraID) -/* 88320 800EEE70 26B57410 */ addiu $s5, $s5, %lo(gCurrentCameraID) -/* 88324 800EEE74 8EA30000 */ lw $v1, ($s5) -/* 88328 800EEE78 3C014000 */ lui $at, 0x4000 -/* 8832C 800EEE7C 4481C000 */ mtc1 $at, $f24 -/* 88330 800EEE80 00031080 */ sll $v0, $v1, 2 -/* 88334 800EEE84 00431021 */ addu $v0, $v0, $v1 -/* 88338 800EEE88 00021080 */ sll $v0, $v0, 2 -/* 8833C 800EEE8C 00431023 */ subu $v0, $v0, $v1 -/* 88340 800EEE90 000218C0 */ sll $v1, $v0, 3 -/* 88344 800EEE94 00431021 */ addu $v0, $v0, $v1 -/* 88348 800EEE98 000210C0 */ sll $v0, $v0, 3 -/* 8834C 800EEE9C 4406C000 */ mfc1 $a2, $f24 -/* 88350 800EEEA0 860300A8 */ lh $v1, 0xa8($s0) -/* 88354 800EEEA4 3C07800B */ lui $a3, %hi(gCameras+0x6C) -/* 88358 800EEEA8 00E23821 */ addu $a3, $a3, $v0 -/* 8835C 800EEEAC 8CE71DEC */ lw $a3, %lo(gCameras+0x6C)($a3) -/* 88360 800EEEB0 44830000 */ mtc1 $v1, $f0 -/* 88364 800EEEB4 00000000 */ nop -/* 88368 800EEEB8 46800020 */ cvt.s.w $f0, $f0 -/* 8836C 800EEEBC 4600D000 */ add.s $f0, $f26, $f0 -/* 88370 800EEEC0 E7B60020 */ swc1 $f22, 0x20($sp) -/* 88374 800EEEC4 E7B40024 */ swc1 $f20, 0x24($sp) -/* 88378 800EEEC8 0C00A7E7 */ jal add_vec2D_polar -/* 8837C 800EEECC E7A00028 */ swc1 $f0, 0x28($sp) -/* 88380 800EEED0 3C040001 */ lui $a0, 1 -/* 88384 800EEED4 0240282D */ daddu $a1, $s2, $zero -/* 88388 800EEED8 27A2002C */ addiu $v0, $sp, 0x2c -/* 8838C 800EEEDC 3C01447A */ lui $at, 0x447a -/* 88390 800EEEE0 44810000 */ mtc1 $at, $f0 -/* 88394 800EEEE4 27A60028 */ addiu $a2, $sp, 0x28 -/* 88398 800EEEE8 E7A0002C */ swc1 $f0, 0x2c($sp) -/* 8839C 800EEEEC AFA20010 */ sw $v0, 0x10($sp) -/* 883A0 800EEEF0 C600000C */ lwc1 $f0, 0xc($s0) -/* 883A4 800EEEF4 0260382D */ daddu $a3, $s3, $zero -/* 883A8 800EEEF8 E7A00014 */ swc1 $f0, 0x14($sp) -/* 883AC 800EEEFC 860200A6 */ lh $v0, 0xa6($s0) -/* 883B0 800EEF00 3C14800B */ lui $s4, %hi(gCameras) -/* 883B4 800EEF04 26941D80 */ addiu $s4, $s4, %lo(gCameras) -/* 883B8 800EEF08 44820000 */ mtc1 $v0, $f0 -/* 883BC 800EEF0C 00000000 */ nop -/* 883C0 800EEF10 46800020 */ cvt.s.w $f0, $f0 -/* 883C4 800EEF14 0C0371DE */ jal npc_raycast_down_around -/* 883C8 800EEF18 E7A00018 */ swc1 $f0, 0x18($sp) -/* 883CC 800EEF1C 10400011 */ beqz $v0, .L800EEF64 -/* 883D0 800EEF20 0240202D */ daddu $a0, $s2, $zero -/* 883D4 800EEF24 3C048011 */ lui $a0, %hi(D_8010C978) -/* 883D8 800EEF28 8C84C978 */ lw $a0, %lo(D_8010C978)($a0) -/* 883DC 800EEF2C 0C016F6A */ jal get_collider_type_by_id -/* 883E0 800EEF30 00000000 */ nop -/* 883E4 800EEF34 2442FFFE */ addiu $v0, $v0, -2 -/* 883E8 800EEF38 2C420002 */ sltiu $v0, $v0, 2 -/* 883EC 800EEF3C 14400009 */ bnez $v0, .L800EEF64 -/* 883F0 800EEF40 0240202D */ daddu $a0, $s2, $zero -/* 883F4 800EEF44 C7A2002C */ lwc1 $f2, 0x2c($sp) -/* 883F8 800EEF48 3C0142C8 */ lui $at, 0x42c8 -/* 883FC 800EEF4C 44810000 */ mtc1 $at, $f0 -/* 88400 800EEF50 00000000 */ nop -/* 88404 800EEF54 4602003C */ c.lt.s $f0, $f2 -/* 88408 800EEF58 00000000 */ nop -/* 8840C 800EEF5C 45000011 */ bc1f .L800EEFA4 -/* 88410 800EEF60 00000000 */ nop -.L800EEF64: -/* 88414 800EEF64 C6360028 */ lwc1 $f22, 0x28($s1) -/* 88418 800EEF68 C63A002C */ lwc1 $f26, 0x2c($s1) -/* 8841C 800EEF6C 8EA20000 */ lw $v0, ($s5) -/* 88420 800EEF70 4406C000 */ mfc1 $a2, $f24 -/* 88424 800EEF74 00021880 */ sll $v1, $v0, 2 -/* 88428 800EEF78 00621821 */ addu $v1, $v1, $v0 -/* 8842C 800EEF7C 00031880 */ sll $v1, $v1, 2 -/* 88430 800EEF80 00621823 */ subu $v1, $v1, $v0 -/* 88434 800EEF84 000310C0 */ sll $v0, $v1, 3 -/* 88438 800EEF88 00621821 */ addu $v1, $v1, $v0 -/* 8843C 800EEF8C 000318C0 */ sll $v1, $v1, 3 -/* 88440 800EEF90 00741821 */ addu $v1, $v1, $s4 -/* 88444 800EEF94 8C67006C */ lw $a3, 0x6c($v1) -/* 88448 800EEF98 C6340030 */ lwc1 $f20, 0x30($s1) -/* 8844C 800EEF9C 0C00A7E7 */ jal add_vec2D_polar -/* 88450 800EEFA0 0260282D */ daddu $a1, $s3, $zero -.L800EEFA4: -/* 88454 800EEFA4 C62C0028 */ lwc1 $f12, 0x28($s1) -/* 88458 800EEFA8 4406B000 */ mfc1 $a2, $f22 -/* 8845C 800EEFAC 4407A000 */ mfc1 $a3, $f20 -/* 88460 800EEFB0 3C013F99 */ lui $at, 0x3f99 -/* 88464 800EEFB4 3421999A */ ori $at, $at, 0x999a -/* 88468 800EEFB8 44812000 */ mtc1 $at, $f4 -/* 8846C 800EEFBC E60C0038 */ swc1 $f12, 0x38($s0) -/* 88470 800EEFC0 962200B0 */ lhu $v0, 0xb0($s1) -/* 88474 800EEFC4 C622002C */ lwc1 $f2, 0x2c($s1) -/* 88478 800EEFC8 00021400 */ sll $v0, $v0, 0x10 -/* 8847C 800EEFCC 00021C03 */ sra $v1, $v0, 0x10 -/* 88480 800EEFD0 000217C2 */ srl $v0, $v0, 0x1f -/* 88484 800EEFD4 00621821 */ addu $v1, $v1, $v0 -/* 88488 800EEFD8 00031843 */ sra $v1, $v1, 1 -/* 8848C 800EEFDC 44830000 */ mtc1 $v1, $f0 -/* 88490 800EEFE0 00000000 */ nop -/* 88494 800EEFE4 46800020 */ cvt.s.w $f0, $f0 -/* 88498 800EEFE8 46001080 */ add.s $f2, $f2, $f0 -/* 8849C 800EEFEC 3C014080 */ lui $at, 0x4080 -/* 884A0 800EEFF0 44810000 */ mtc1 $at, $f0 -/* 884A4 800EEFF4 E602003C */ swc1 $f2, 0x3c($s0) -/* 884A8 800EEFF8 C62E0030 */ lwc1 $f14, 0x30($s1) -/* 884AC 800EEFFC E7AC0020 */ swc1 $f12, 0x20($sp) -/* 884B0 800EF000 E7A20028 */ swc1 $f2, 0x28($sp) -/* 884B4 800EF004 E6000018 */ swc1 $f0, 0x18($s0) -/* 884B8 800EF008 E6040014 */ swc1 $f4, 0x14($s0) -/* 884BC 800EF00C E60E0040 */ swc1 $f14, 0x40($s0) -/* 884C0 800EF010 0C00A7B5 */ jal dist2D -/* 884C4 800EF014 E7AE0024 */ swc1 $f14, 0x24($sp) -/* 884C8 800EF018 C7AC0020 */ lwc1 $f12, 0x20($sp) -/* 884CC 800EF01C C7AE0024 */ lwc1 $f14, 0x24($sp) -/* 884D0 800EF020 4406B000 */ mfc1 $a2, $f22 -/* 884D4 800EF024 4407A000 */ mfc1 $a3, $f20 -/* 884D8 800EF028 0C00A720 */ jal atan2 -/* 884DC 800EF02C E6000010 */ swc1 $f0, 0x10($s0) -/* 884E0 800EF030 C6020010 */ lwc1 $f2, 0x10($s0) -/* 884E4 800EF034 C6040018 */ lwc1 $f4, 0x18($s0) -/* 884E8 800EF038 E600000C */ swc1 $f0, 0xc($s0) -/* 884EC 800EF03C 46041083 */ div.s $f2, $f2, $f4 -/* 884F0 800EF040 4600128D */ trunc.w.s $f10, $f2 -/* 884F4 800EF044 44025000 */ mfc1 $v0, $f10 -/* 884F8 800EF048 00000000 */ nop -/* 884FC 800EF04C A602008E */ sh $v0, 0x8e($s0) -/* 88500 800EF050 00021400 */ sll $v0, $v0, 0x10 -/* 88504 800EF054 00021403 */ sra $v0, $v0, 0x10 -/* 88508 800EF058 2842000A */ slti $v0, $v0, 0xa -/* 8850C 800EF05C 10400007 */ beqz $v0, .L800EF07C -/* 88510 800EF060 2402000A */ addiu $v0, $zero, 0xa -/* 88514 800EF064 3C014120 */ lui $at, 0x4120 -/* 88518 800EF068 44810000 */ mtc1 $at, $f0 -/* 8851C 800EF06C C6020010 */ lwc1 $f2, 0x10($s0) -/* 88520 800EF070 A602008E */ sh $v0, 0x8e($s0) -/* 88524 800EF074 46001083 */ div.s $f2, $f2, $f0 -/* 88528 800EF078 E6020018 */ swc1 $f2, 0x18($s0) -.L800EF07C: -/* 8852C 800EF07C 8602008E */ lh $v0, 0x8e($s0) -/* 88530 800EF080 C6000014 */ lwc1 $f0, 0x14($s0) -/* 88534 800EF084 44822000 */ mtc1 $v0, $f4 -/* 88538 800EF088 00000000 */ nop -/* 8853C 800EF08C 46802120 */ cvt.s.w $f4, $f4 -/* 88540 800EF090 46040002 */ mul.s $f0, $f0, $f4 -/* 88544 800EF094 00000000 */ nop -/* 88548 800EF098 46040002 */ mul.s $f0, $f0, $f4 -/* 8854C 800EF09C 00000000 */ nop -/* 88550 800EF0A0 3C013F00 */ lui $at, 0x3f00 -/* 88554 800EF0A4 44811000 */ mtc1 $at, $f2 -/* 88558 800EF0A8 00000000 */ nop -/* 8855C 800EF0AC 46020002 */ mul.s $f0, $f0, $f2 -/* 88560 800EF0B0 00000000 */ nop -/* 88564 800EF0B4 C7A20028 */ lwc1 $f2, 0x28($sp) -/* 88568 800EF0B8 3C038011 */ lui $v1, %hi(D_8010CFD8) -/* 8856C 800EF0BC 8C63CFD8 */ lw $v1, %lo(D_8010CFD8)($v1) -/* 88570 800EF0C0 4602D081 */ sub.s $f2, $f26, $f2 -/* 88574 800EF0C4 000310C0 */ sll $v0, $v1, 3 -/* 88578 800EF0C8 46001000 */ add.s $f0, $f2, $f0 -/* 8857C 800EF0CC 00431021 */ addu $v0, $v0, $v1 -/* 88580 800EF0D0 00021080 */ sll $v0, $v0, 2 -/* 88584 800EF0D4 46040003 */ div.s $f0, $f0, $f4 -/* 88588 800EF0D8 E600001C */ swc1 $f0, 0x1c($s0) -/* 8858C 800EF0DC 3C038010 */ lui $v1, %hi(gPartnerAnimations+0x8) -/* 88590 800EF0E0 00621821 */ addu $v1, $v1, $v0 -/* 88594 800EF0E4 8C638350 */ lw $v1, %lo(gPartnerAnimations+0x8)($v1) -/* 88598 800EF0E8 24020001 */ addiu $v0, $zero, 1 -/* 8859C 800EF0EC 3C018011 */ lui $at, %hi(D_8010CFC8) -/* 885A0 800EF0F0 A422CFC8 */ sh $v0, %lo(D_8010CFC8)($at) -/* 885A4 800EF0F4 E7A20028 */ swc1 $f2, 0x28($sp) -/* 885A8 800EF0F8 0803BCB2 */ j .L800EF2C8 -/* 885AC 800EF0FC AE030028 */ sw $v1, 0x28($s0) -.L800EF100: -/* 885B0 800EF100 C602001C */ lwc1 $f2, 0x1c($s0) -/* 885B4 800EF104 44800000 */ mtc1 $zero, $f0 -/* 885B8 800EF108 00000000 */ nop -/* 885BC 800EF10C 4600103C */ c.lt.s $f2, $f0 -/* 885C0 800EF110 00000000 */ nop -/* 885C4 800EF114 45000009 */ bc1f .L800EF13C -/* 885C8 800EF118 00000000 */ nop -/* 885CC 800EF11C 46001085 */ abs.s $f2, $f2 -/* 885D0 800EF120 44051000 */ mfc1 $a1, $f2 -/* 885D4 800EF124 0C00E5FA */ jal func_800397E8 -/* 885D8 800EF128 0200202D */ daddu $a0, $s0, $zero -/* 885DC 800EF12C 10400003 */ beqz $v0, .L800EF13C -/* 885E0 800EF130 24020002 */ addiu $v0, $zero, 2 -/* 885E4 800EF134 0803BCB2 */ j .L800EF2C8 -/* 885E8 800EF138 A6620000 */ sh $v0, ($s3) -.L800EF13C: -/* 885EC 800EF13C C600001C */ lwc1 $f0, 0x1c($s0) -/* 885F0 800EF140 C6020014 */ lwc1 $f2, 0x14($s0) -/* 885F4 800EF144 46020001 */ sub.s $f0, $f0, $f2 -/* 885F8 800EF148 C602003C */ lwc1 $f2, 0x3c($s0) -/* 885FC 800EF14C E600001C */ swc1 $f0, 0x1c($s0) -/* 88600 800EF150 46000106 */ mov.s $f4, $f0 -/* 88604 800EF154 46001080 */ add.s $f2, $f2, $f0 -/* 88608 800EF158 44800000 */ mtc1 $zero, $f0 -/* 8860C 800EF15C 00000000 */ nop -/* 88610 800EF160 4600203E */ c.le.s $f4, $f0 -/* 88614 800EF164 00000000 */ nop -/* 88618 800EF168 4500000A */ bc1f .L800EF194 -/* 8861C 800EF16C E602003C */ swc1 $f2, 0x3c($s0) -/* 88620 800EF170 3C028011 */ lui $v0, %hi(D_8010CFD8) -/* 88624 800EF174 8C42CFD8 */ lw $v0, %lo(D_8010CFD8)($v0) -/* 88628 800EF178 000218C0 */ sll $v1, $v0, 3 -/* 8862C 800EF17C 00621821 */ addu $v1, $v1, $v0 -/* 88630 800EF180 00031880 */ sll $v1, $v1, 2 -/* 88634 800EF184 3C028010 */ lui $v0, %hi(gPartnerAnimations+0xC) -/* 88638 800EF188 00431021 */ addu $v0, $v0, $v1 -/* 8863C 800EF18C 8C428354 */ lw $v0, %lo(gPartnerAnimations+0xC)($v0) -/* 88640 800EF190 AE020028 */ sw $v0, 0x28($s0) -.L800EF194: -/* 88644 800EF194 8E050018 */ lw $a1, 0x18($s0) -/* 88648 800EF198 8E06000C */ lw $a2, 0xc($s0) -/* 8864C 800EF19C 0C00EA95 */ jal npc_move_heading -/* 88650 800EF1A0 0200202D */ daddu $a0, $s0, $zero -/* 88654 800EF1A4 0C00E2BF */ jal npc_do_world_collision -/* 88658 800EF1A8 0200202D */ daddu $a0, $s0, $zero -/* 8865C 800EF1AC 8602008E */ lh $v0, 0x8e($s0) -/* 88660 800EF1B0 3C014120 */ lui $at, 0x4120 -/* 88664 800EF1B4 44811000 */ mtc1 $at, $f2 -/* 88668 800EF1B8 44820000 */ mtc1 $v0, $f0 -/* 8866C 800EF1BC 00000000 */ nop -/* 88670 800EF1C0 46800020 */ cvt.s.w $f0, $f0 -/* 88674 800EF1C4 4600103C */ c.lt.s $f2, $f0 -/* 88678 800EF1C8 00000000 */ nop -/* 8867C 800EF1CC 45030001 */ bc1tl .L800EF1D4 -/* 88680 800EF1D0 46001006 */ mov.s $f0, $f2 -.L800EF1D4: -/* 88684 800EF1D4 9602008E */ lhu $v0, 0x8e($s0) -/* 88688 800EF1D8 46001001 */ sub.s $f0, $f2, $f0 -/* 8868C 800EF1DC 2442FFFF */ addiu $v0, $v0, -1 -/* 88690 800EF1E0 A602008E */ sh $v0, 0x8e($s0) -/* 88694 800EF1E4 00021400 */ sll $v0, $v0, 0x10 -/* 88698 800EF1E8 46020003 */ div.s $f0, $f0, $f2 -/* 8869C 800EF1EC E6000054 */ swc1 $f0, 0x54($s0) -/* 886A0 800EF1F0 46000086 */ mov.s $f2, $f0 -/* 886A4 800EF1F4 E6000058 */ swc1 $f0, 0x58($s0) -/* 886A8 800EF1F8 04410033 */ bgez $v0, .L800EF2C8 -/* 886AC 800EF1FC E602005C */ swc1 $f2, 0x5c($s0) -/* 886B0 800EF200 24020002 */ addiu $v0, $zero, 2 -/* 886B4 800EF204 3C018011 */ lui $at, %hi(D_8010CFC8) -/* 886B8 800EF208 A422CFC8 */ sh $v0, %lo(D_8010CFC8)($at) -/* 886BC 800EF20C 0803BCB3 */ j .L800EF2CC -/* 886C0 800EF210 0000102D */ daddu $v0, $zero, $zero -.L800EF214: -/* 886C4 800EF214 C6000064 */ lwc1 $f0, 0x64($s0) -/* 886C8 800EF218 C6060038 */ lwc1 $f6, 0x38($s0) -/* 886CC 800EF21C C6020040 */ lwc1 $f2, 0x40($s0) -/* 886D0 800EF220 E600003C */ swc1 $f0, 0x3c($s0) -/* 886D4 800EF224 3C013F80 */ lui $at, 0x3f80 -/* 886D8 800EF228 44810000 */ mtc1 $at, $f0 -/* 886DC 800EF22C C608003C */ lwc1 $f8, 0x3c($s0) -/* 886E0 800EF230 3C128011 */ lui $s2, %hi(wPartner) -/* 886E4 800EF234 2652CFEC */ addiu $s2, $s2, %lo(wPartner) -/* 886E8 800EF238 AE00001C */ sw $zero, 0x1c($s0) -/* 886EC 800EF23C E6060060 */ swc1 $f6, 0x60($s0) -/* 886F0 800EF240 E6020068 */ swc1 $f2, 0x68($s0) -/* 886F4 800EF244 E6000054 */ swc1 $f0, 0x54($s0) -/* 886F8 800EF248 E6000058 */ swc1 $f0, 0x58($s0) -/* 886FC 800EF24C E600005C */ swc1 $f0, 0x5c($s0) -/* 88700 800EF250 E6080064 */ swc1 $f8, 0x64($s0) -/* 88704 800EF254 C620002C */ lwc1 $f0, 0x2c($s1) -/* 88708 800EF258 8E420000 */ lw $v0, ($s2) -/* 8870C 800EF25C E600003C */ swc1 $f0, 0x3c($s0) -/* 88710 800EF260 8C42000C */ lw $v0, 0xc($v0) -/* 88714 800EF264 10400003 */ beqz $v0, .L800EF274 -/* 88718 800EF268 46003106 */ mov.s $f4, $f6 -/* 8871C 800EF26C C620002C */ lwc1 $f0, 0x2c($s1) -/* 88720 800EF270 E600003C */ swc1 $f0, 0x3c($s0) -.L800EF274: -/* 88724 800EF274 C6000040 */ lwc1 $f0, 0x40($s0) -/* 88728 800EF278 0C03BD17 */ jal partner_clear_player_tracking -/* 8872C 800EF27C 0200202D */ daddu $a0, $s0, $zero -/* 88730 800EF280 C6000060 */ lwc1 $f0, 0x60($s0) -/* 88734 800EF284 C6020064 */ lwc1 $f2, 0x64($s0) -/* 88738 800EF288 8E020000 */ lw $v0, ($s0) -/* 8873C 800EF28C C6040068 */ lwc1 $f4, 0x68($s0) -/* 88740 800EF290 30421000 */ andi $v0, $v0, 0x1000 -/* 88744 800EF294 E6000038 */ swc1 $f0, 0x38($s0) -/* 88748 800EF298 E602003C */ swc1 $f2, 0x3c($s0) -/* 8874C 800EF29C 10400008 */ beqz $v0, .L800EF2C0 -/* 88750 800EF2A0 E6040040 */ swc1 $f4, 0x40($s0) -/* 88754 800EF2A4 8E420000 */ lw $v0, ($s2) -/* 88758 800EF2A8 8C42000C */ lw $v0, 0xc($v0) -/* 8875C 800EF2AC 14400007 */ bnez $v0, .L800EF2CC -/* 88760 800EF2B0 24020001 */ addiu $v0, $zero, 1 -/* 88764 800EF2B4 0200202D */ daddu $a0, $s0, $zero -/* 88768 800EF2B8 0C00F598 */ jal func_8003D660 -/* 8876C 800EF2BC 24050002 */ addiu $a1, $zero, 2 -.L800EF2C0: -/* 88770 800EF2C0 0803BCB3 */ j .L800EF2CC -/* 88774 800EF2C4 24020001 */ addiu $v0, $zero, 1 -.L800EF2C8: -/* 88778 800EF2C8 0000102D */ daddu $v0, $zero, $zero -.L800EF2CC: -/* 8877C 800EF2CC 8FBF0048 */ lw $ra, 0x48($sp) -/* 88780 800EF2D0 8FB50044 */ lw $s5, 0x44($sp) -/* 88784 800EF2D4 8FB40040 */ lw $s4, 0x40($sp) -/* 88788 800EF2D8 8FB3003C */ lw $s3, 0x3c($sp) -/* 8878C 800EF2DC 8FB20038 */ lw $s2, 0x38($sp) -/* 88790 800EF2E0 8FB10034 */ lw $s1, 0x34($sp) -/* 88794 800EF2E4 8FB00030 */ lw $s0, 0x30($sp) -/* 88798 800EF2E8 D7BA0068 */ ldc1 $f26, 0x68($sp) -/* 8879C 800EF2EC D7B80060 */ ldc1 $f24, 0x60($sp) -/* 887A0 800EF2F0 D7B60058 */ ldc1 $f22, 0x58($sp) -/* 887A4 800EF2F4 D7B40050 */ ldc1 $f20, 0x50($sp) -/* 887A8 800EF2F8 03E00008 */ jr $ra -/* 887AC 800EF2FC 27BD0070 */ addiu $sp, $sp, 0x70 diff --git a/ver/us/asm/nonmatchings/world/partners/partner_move_to_goal.s b/ver/us/asm/nonmatchings/world/partners/partner_move_to_goal.s deleted file mode 100644 index 75b392d7d9..0000000000 --- a/ver/us/asm/nonmatchings/world/partners/partner_move_to_goal.s +++ /dev/null @@ -1,329 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel partner_move_to_goal -/* 88CDC 800EF82C 27BDFFB8 */ addiu $sp, $sp, -0x48 -/* 88CE0 800EF830 AFB20038 */ sw $s2, 0x38($sp) -/* 88CE4 800EF834 0080902D */ daddu $s2, $a0, $zero -/* 88CE8 800EF838 AFB40040 */ sw $s4, 0x40($sp) -/* 88CEC 800EF83C 00A0A02D */ daddu $s4, $a1, $zero -/* 88CF0 800EF840 AFB3003C */ sw $s3, 0x3c($sp) -/* 88CF4 800EF844 3C138011 */ lui $s3, %hi(gPlayerStatus) -/* 88CF8 800EF848 2673EFC8 */ addiu $s3, $s3, %lo(gPlayerStatus) -/* 88CFC 800EF84C 3C058011 */ lui $a1, %hi(D_8010CFCE) -/* 88D00 800EF850 24A5CFCE */ addiu $a1, $a1, %lo(D_8010CFCE) -/* 88D04 800EF854 24020001 */ addiu $v0, $zero, 1 -/* 88D08 800EF858 AFBF0044 */ sw $ra, 0x44($sp) -/* 88D0C 800EF85C AFB10034 */ sw $s1, 0x34($sp) -/* 88D10 800EF860 AFB00030 */ sw $s0, 0x30($sp) -/* 88D14 800EF864 84A30000 */ lh $v1, ($a1) -/* 88D18 800EF868 94A40000 */ lhu $a0, ($a1) -/* 88D1C 800EF86C 10620044 */ beq $v1, $v0, .L800EF980 -/* 88D20 800EF870 28620002 */ slti $v0, $v1, 2 -/* 88D24 800EF874 10400118 */ beqz $v0, .L800EFCD8 -/* 88D28 800EF878 00000000 */ nop -/* 88D2C 800EF87C 14600116 */ bnez $v1, .L800EFCD8 -/* 88D30 800EF880 24820001 */ addiu $v0, $a0, 1 -/* 88D34 800EF884 C662002C */ lwc1 $f2, 0x2c($s3) -/* 88D38 800EF888 3C018010 */ lui $at, %hi(wPartnerMoveGoalX) -/* 88D3C 800EF88C C4208024 */ lwc1 $f0, %lo(wPartnerMoveGoalX)($at) -/* 88D40 800EF890 46800020 */ cvt.s.w $f0, $f0 -/* 88D44 800EF894 E6400060 */ swc1 $f0, 0x60($s2) -/* 88D48 800EF898 44060000 */ mfc1 $a2, $f0 -/* 88D4C 800EF89C 3C018010 */ lui $at, %hi(wPartnerMoveGoalZ) -/* 88D50 800EF8A0 C4208028 */ lwc1 $f0, %lo(wPartnerMoveGoalZ)($at) -/* 88D54 800EF8A4 46800020 */ cvt.s.w $f0, $f0 -/* 88D58 800EF8A8 26500060 */ addiu $s0, $s2, 0x60 -/* 88D5C 800EF8AC C64C0038 */ lwc1 $f12, 0x38($s2) -/* 88D60 800EF8B0 C64E0040 */ lwc1 $f14, 0x40($s2) -/* 88D64 800EF8B4 44070000 */ mfc1 $a3, $f0 -/* 88D68 800EF8B8 26510068 */ addiu $s1, $s2, 0x68 -/* 88D6C 800EF8BC A4A20000 */ sh $v0, ($a1) -/* 88D70 800EF8C0 AE470068 */ sw $a3, 0x68($s2) -/* 88D74 800EF8C4 0C00A720 */ jal atan2 -/* 88D78 800EF8C8 E6420064 */ swc1 $f2, 0x64($s2) -/* 88D7C 800EF8CC 0200202D */ daddu $a0, $s0, $zero -/* 88D80 800EF8D0 3C0640A0 */ lui $a2, 0x40a0 -/* 88D84 800EF8D4 44070000 */ mfc1 $a3, $f0 -/* 88D88 800EF8D8 0220282D */ daddu $a1, $s1, $zero -/* 88D8C 800EF8DC 3C018010 */ lui $at, %hi(D_800F8034) -/* 88D90 800EF8E0 AC278034 */ sw $a3, %lo(D_800F8034)($at) -/* 88D94 800EF8E4 0C00A7E7 */ jal add_vec2D_polar -/* 88D98 800EF8E8 AE47000C */ sw $a3, 0xc($s2) -/* 88D9C 800EF8EC 3C108010 */ lui $s0, %hi(wPartnerMoveTime) -/* 88DA0 800EF8F0 2610802C */ addiu $s0, $s0, %lo(wPartnerMoveTime) -/* 88DA4 800EF8F4 C64C0038 */ lwc1 $f12, 0x38($s2) -/* 88DA8 800EF8F8 C64E0040 */ lwc1 $f14, 0x40($s2) -/* 88DAC 800EF8FC 8E460060 */ lw $a2, 0x60($s2) -/* 88DB0 800EF900 8E470068 */ lw $a3, 0x68($s2) -/* 88DB4 800EF904 24020012 */ addiu $v0, $zero, 0x12 -/* 88DB8 800EF908 0C00A7B5 */ jal dist2D -/* 88DBC 800EF90C AE020000 */ sw $v0, ($s0) -/* 88DC0 800EF910 E7A0002C */ swc1 $f0, 0x2c($sp) -/* 88DC4 800EF914 C6020000 */ lwc1 $f2, ($s0) -/* 88DC8 800EF918 468010A0 */ cvt.s.w $f2, $f2 -/* 88DCC 800EF91C 46020003 */ div.s $f0, $f0, $f2 -/* 88DD0 800EF920 3C018010 */ lui $at, %hi(wPartnerMoveSpeed) -/* 88DD4 800EF924 E4208030 */ swc1 $f0, %lo(wPartnerMoveSpeed)($at) -/* 88DD8 800EF928 E6400018 */ swc1 $f0, 0x18($s2) -/* 88DDC 800EF92C 46000021 */ cvt.d.s $f0, $f0 -/* 88DE0 800EF930 26440028 */ addiu $a0, $s2, 0x28 -/* 88DE4 800EF934 3C038011 */ lui $v1, %hi(D_8010CFD8) -/* 88DE8 800EF938 8C63CFD8 */ lw $v1, %lo(D_8010CFD8)($v1) -/* 88DEC 800EF93C 3C014010 */ lui $at, 0x4010 -/* 88DF0 800EF940 44811800 */ mtc1 $at, $f3 -/* 88DF4 800EF944 44801000 */ mtc1 $zero, $f2 -/* 88DF8 800EF948 000310C0 */ sll $v0, $v1, 3 -/* 88DFC 800EF94C 00431021 */ addu $v0, $v0, $v1 -/* 88E00 800EF950 4620103E */ c.le.d $f2, $f0 -/* 88E04 800EF954 00000000 */ nop -/* 88E08 800EF958 45000003 */ bc1f .L800EF968 -/* 88E0C 800EF95C 00021080 */ sll $v0, $v0, 2 -/* 88E10 800EF960 0803BE5B */ j .L800EF96C -/* 88E14 800EF964 24430018 */ addiu $v1, $v0, 0x18 -.L800EF968: -/* 88E18 800EF968 24430004 */ addiu $v1, $v0, 4 -.L800EF96C: -/* 88E1C 800EF96C 3C028010 */ lui $v0, %hi(gPartnerAnimations) -/* 88E20 800EF970 24428348 */ addiu $v0, $v0, %lo(gPartnerAnimations) -/* 88E24 800EF974 00431021 */ addu $v0, $v0, $v1 -/* 88E28 800EF978 8C420000 */ lw $v0, ($v0) -/* 88E2C 800EF97C AC820000 */ sw $v0, ($a0) -.L800EF980: -/* 88E30 800EF980 3C038010 */ lui $v1, %hi(wPartnerMoveTime) -/* 88E34 800EF984 2463802C */ addiu $v1, $v1, %lo(wPartnerMoveTime) -/* 88E38 800EF988 8C620000 */ lw $v0, ($v1) -/* 88E3C 800EF98C 104000C0 */ beqz $v0, .L800EFC90 -/* 88E40 800EF990 2442FFFF */ addiu $v0, $v0, -1 -/* 88E44 800EF994 16800092 */ bnez $s4, .L800EFBE0 -/* 88E48 800EF998 AC620000 */ sw $v0, ($v1) -/* 88E4C 800EF99C 8E420000 */ lw $v0, ($s2) -/* 88E50 800EF9A0 30421000 */ andi $v0, $v0, 0x1000 -/* 88E54 800EF9A4 14400003 */ bnez $v0, .L800EF9B4 -/* 88E58 800EF9A8 00000000 */ nop -/* 88E5C 800EF9AC C660002C */ lwc1 $f0, 0x2c($s3) -/* 88E60 800EF9B0 E640003C */ swc1 $f0, 0x3c($s2) -.L800EF9B4: -/* 88E64 800EF9B4 C642001C */ lwc1 $f2, 0x1c($s2) -/* 88E68 800EF9B8 44802000 */ mtc1 $zero, $f4 -/* 88E6C 800EF9BC 00000000 */ nop -/* 88E70 800EF9C0 46041032 */ c.eq.s $f2, $f4 -/* 88E74 800EF9C4 00000000 */ nop -/* 88E78 800EF9C8 45010060 */ bc1t .L800EFB4C -/* 88E7C 800EF9CC 00000000 */ nop -/* 88E80 800EF9D0 C6400014 */ lwc1 $f0, 0x14($s2) -/* 88E84 800EF9D4 46001001 */ sub.s $f0, $f2, $f0 -/* 88E88 800EF9D8 C642003C */ lwc1 $f2, 0x3c($s2) -/* 88E8C 800EF9DC 46001080 */ add.s $f2, $f2, $f0 -/* 88E90 800EF9E0 E640001C */ swc1 $f0, 0x1c($s2) -/* 88E94 800EF9E4 4604003E */ c.le.s $f0, $f4 -/* 88E98 800EF9E8 00000000 */ nop -/* 88E9C 800EF9EC 4500000A */ bc1f .L800EFA18 -/* 88EA0 800EF9F0 E642003C */ swc1 $f2, 0x3c($s2) -/* 88EA4 800EF9F4 3C028011 */ lui $v0, %hi(D_8010CFD8) -/* 88EA8 800EF9F8 8C42CFD8 */ lw $v0, %lo(D_8010CFD8)($v0) -/* 88EAC 800EF9FC 000218C0 */ sll $v1, $v0, 3 -/* 88EB0 800EFA00 00621821 */ addu $v1, $v1, $v0 -/* 88EB4 800EFA04 00031880 */ sll $v1, $v1, 2 -/* 88EB8 800EFA08 3C028010 */ lui $v0, %hi(gPartnerAnimations+0xC) -/* 88EBC 800EFA0C 00431021 */ addu $v0, $v0, $v1 -/* 88EC0 800EFA10 8C428354 */ lw $v0, %lo(gPartnerAnimations+0xC)($v0) -/* 88EC4 800EFA14 AE420028 */ sw $v0, 0x28($s2) -.L800EFA18: -/* 88EC8 800EFA18 C642001C */ lwc1 $f2, 0x1c($s2) -/* 88ECC 800EFA1C 4604103E */ c.le.s $f2, $f4 -/* 88ED0 800EFA20 00000000 */ nop -/* 88ED4 800EFA24 45000049 */ bc1f .L800EFB4C -/* 88ED8 800EFA28 27A50020 */ addiu $a1, $sp, 0x20 -/* 88EDC 800EFA2C C6400038 */ lwc1 $f0, 0x38($s2) -/* 88EE0 800EFA30 46001085 */ abs.s $f2, $f2 -/* 88EE4 800EFA34 E7A00020 */ swc1 $f0, 0x20($sp) -/* 88EE8 800EFA38 864200A8 */ lh $v0, 0xa8($s2) -/* 88EEC 800EFA3C C6440040 */ lwc1 $f4, 0x40($s2) -/* 88EF0 800EFA40 0040182D */ daddu $v1, $v0, $zero -/* 88EF4 800EFA44 44820000 */ mtc1 $v0, $f0 -/* 88EF8 800EFA48 00000000 */ nop -/* 88EFC 800EFA4C 46800020 */ cvt.s.w $f0, $f0 -/* 88F00 800EFA50 44833000 */ mtc1 $v1, $f6 -/* 88F04 800EFA54 00000000 */ nop -/* 88F08 800EFA58 468031A0 */ cvt.s.w $f6, $f6 -/* 88F0C 800EFA5C 46001080 */ add.s $f2, $f2, $f0 -/* 88F10 800EFA60 C640003C */ lwc1 $f0, 0x3c($s2) -/* 88F14 800EFA64 27A2002C */ addiu $v0, $sp, 0x2c -/* 88F18 800EFA68 46060000 */ add.s $f0, $f0, $f6 -/* 88F1C 800EFA6C E7A40028 */ swc1 $f4, 0x28($sp) -/* 88F20 800EFA70 E7A2002C */ swc1 $f2, 0x2c($sp) -/* 88F24 800EFA74 E7A00024 */ swc1 $f0, 0x24($sp) -/* 88F28 800EFA78 AFA20010 */ sw $v0, 0x10($sp) -/* 88F2C 800EFA7C C640000C */ lwc1 $f0, 0xc($s2) -/* 88F30 800EFA80 E7A00014 */ swc1 $f0, 0x14($sp) -/* 88F34 800EFA84 864200A6 */ lh $v0, 0xa6($s2) -/* 88F38 800EFA88 27A60024 */ addiu $a2, $sp, 0x24 -/* 88F3C 800EFA8C 44820000 */ mtc1 $v0, $f0 -/* 88F40 800EFA90 00000000 */ nop -/* 88F44 800EFA94 46800020 */ cvt.s.w $f0, $f0 -/* 88F48 800EFA98 E7A00018 */ swc1 $f0, 0x18($sp) -/* 88F4C 800EFA9C 8E440080 */ lw $a0, 0x80($s2) -/* 88F50 800EFAA0 0C0371DE */ jal npc_raycast_down_around -/* 88F54 800EFAA4 27A70028 */ addiu $a3, $sp, 0x28 -/* 88F58 800EFAA8 10400028 */ beqz $v0, .L800EFB4C -/* 88F5C 800EFAAC 00000000 */ nop -/* 88F60 800EFAB0 C640001C */ lwc1 $f0, 0x1c($s2) -/* 88F64 800EFAB4 3C0141B0 */ lui $at, 0x41b0 -/* 88F68 800EFAB8 44811000 */ mtc1 $at, $f2 -/* 88F6C 800EFABC 46000005 */ abs.s $f0, $f0 -/* 88F70 800EFAC0 46020000 */ add.s $f0, $f0, $f2 -/* 88F74 800EFAC4 C7A2002C */ lwc1 $f2, 0x2c($sp) -/* 88F78 800EFAC8 4600103E */ c.le.s $f2, $f0 -/* 88F7C 800EFACC 00000000 */ nop -/* 88F80 800EFAD0 4500001E */ bc1f .L800EFB4C -/* 88F84 800EFAD4 26440028 */ addiu $a0, $s2, 0x28 -/* 88F88 800EFAD8 C6400018 */ lwc1 $f0, 0x18($s2) -/* 88F8C 800EFADC 3C014010 */ lui $at, 0x4010 -/* 88F90 800EFAE0 44811800 */ mtc1 $at, $f3 -/* 88F94 800EFAE4 44801000 */ mtc1 $zero, $f2 -/* 88F98 800EFAE8 3C038011 */ lui $v1, %hi(D_8010CFD8) -/* 88F9C 800EFAEC 8C63CFD8 */ lw $v1, %lo(D_8010CFD8)($v1) -/* 88FA0 800EFAF0 46000021 */ cvt.d.s $f0, $f0 -/* 88FA4 800EFAF4 000310C0 */ sll $v0, $v1, 3 -/* 88FA8 800EFAF8 00431021 */ addu $v0, $v0, $v1 -/* 88FAC 800EFAFC 4620103E */ c.le.d $f2, $f0 -/* 88FB0 800EFB00 00000000 */ nop -/* 88FB4 800EFB04 45000003 */ bc1f .L800EFB14 -/* 88FB8 800EFB08 00021080 */ sll $v0, $v0, 2 -/* 88FBC 800EFB0C 0803BEC6 */ j .L800EFB18 -/* 88FC0 800EFB10 24430018 */ addiu $v1, $v0, 0x18 -.L800EFB14: -/* 88FC4 800EFB14 24430004 */ addiu $v1, $v0, 4 -.L800EFB18: -/* 88FC8 800EFB18 3C028010 */ lui $v0, %hi(gPartnerAnimations) -/* 88FCC 800EFB1C 24428348 */ addiu $v0, $v0, %lo(gPartnerAnimations) -/* 88FD0 800EFB20 00431021 */ addu $v0, $v0, $v1 -/* 88FD4 800EFB24 8C420000 */ lw $v0, ($v0) -/* 88FD8 800EFB28 C7A00024 */ lwc1 $f0, 0x24($sp) -/* 88FDC 800EFB2C AC820000 */ sw $v0, ($a0) -/* 88FE0 800EFB30 8E420000 */ lw $v0, ($s2) -/* 88FE4 800EFB34 2403F7FF */ addiu $v1, $zero, -0x801 -/* 88FE8 800EFB38 AE400014 */ sw $zero, 0x14($s2) -/* 88FEC 800EFB3C AE40001C */ sw $zero, 0x1c($s2) -/* 88FF0 800EFB40 E640003C */ swc1 $f0, 0x3c($s2) -/* 88FF4 800EFB44 00431024 */ and $v0, $v0, $v1 -/* 88FF8 800EFB48 AE420000 */ sw $v0, ($s2) -.L800EFB4C: -/* 88FFC 800EFB4C 3C018010 */ lui $at, %hi(wPartnerMoveSpeed) -/* 89000 800EFB50 C4208030 */ lwc1 $f0, %lo(wPartnerMoveSpeed)($at) -/* 89004 800EFB54 E6400018 */ swc1 $f0, 0x18($s2) -/* 89008 800EFB58 3C018010 */ lui $at, %hi(D_800F8034) -/* 8900C 800EFB5C C4208034 */ lwc1 $f0, %lo(D_800F8034)($at) -/* 89010 800EFB60 8E450018 */ lw $a1, 0x18($s2) -/* 89014 800EFB64 44060000 */ mfc1 $a2, $f0 -/* 89018 800EFB68 0240202D */ daddu $a0, $s2, $zero -/* 8901C 800EFB6C 0C00EA95 */ jal npc_move_heading -/* 89020 800EFB70 AE46000C */ sw $a2, 0xc($s2) -/* 89024 800EFB74 26450028 */ addiu $a1, $s2, 0x28 -/* 89028 800EFB78 C6400018 */ lwc1 $f0, 0x18($s2) -/* 8902C 800EFB7C 3C014010 */ lui $at, 0x4010 -/* 89030 800EFB80 44811800 */ mtc1 $at, $f3 -/* 89034 800EFB84 44801000 */ mtc1 $zero, $f2 -/* 89038 800EFB88 3C038011 */ lui $v1, %hi(D_8010CFD8) -/* 8903C 800EFB8C 8C63CFD8 */ lw $v1, %lo(D_8010CFD8)($v1) -/* 89040 800EFB90 46000021 */ cvt.d.s $f0, $f0 -/* 89044 800EFB94 000310C0 */ sll $v0, $v1, 3 -/* 89048 800EFB98 00431021 */ addu $v0, $v0, $v1 -/* 8904C 800EFB9C 00021080 */ sll $v0, $v0, 2 -/* 89050 800EFBA0 4620103E */ c.le.d $f2, $f0 -/* 89054 800EFBA4 00000000 */ nop -/* 89058 800EFBA8 45000003 */ bc1f .L800EFBB8 -/* 8905C 800EFBAC 0040182D */ daddu $v1, $v0, $zero -/* 89060 800EFBB0 0803BEEF */ j .L800EFBBC -/* 89064 800EFBB4 24430018 */ addiu $v1, $v0, 0x18 -.L800EFBB8: -/* 89068 800EFBB8 24630004 */ addiu $v1, $v1, 4 -.L800EFBBC: -/* 8906C 800EFBBC 3C028010 */ lui $v0, %hi(gPartnerAnimations) -/* 89070 800EFBC0 24428348 */ addiu $v0, $v0, %lo(gPartnerAnimations) -/* 89074 800EFBC4 00431021 */ addu $v0, $v0, $v1 -/* 89078 800EFBC8 8C420000 */ lw $v0, ($v0) -/* 8907C 800EFBCC 0240202D */ daddu $a0, $s2, $zero -/* 89080 800EFBD0 0C00E2BF */ jal npc_do_world_collision -/* 89084 800EFBD4 ACA20000 */ sw $v0, ($a1) -/* 89088 800EFBD8 0803BF17 */ j .L800EFC5C -/* 8908C 800EFBDC 24050001 */ addiu $a1, $zero, 1 -.L800EFBE0: -/* 89090 800EFBE0 C644003C */ lwc1 $f4, 0x3c($s2) -/* 89094 800EFBE4 C666002C */ lwc1 $f6, 0x2c($s3) -/* 89098 800EFBE8 46062001 */ sub.s $f0, $f4, $f6 -/* 8909C 800EFBEC 3C014014 */ lui $at, 0x4014 -/* 890A0 800EFBF0 44811800 */ mtc1 $at, $f3 -/* 890A4 800EFBF4 44801000 */ mtc1 $zero, $f2 -/* 890A8 800EFBF8 46000021 */ cvt.d.s $f0, $f0 -/* 890AC 800EFBFC 46200005 */ abs.d $f0, $f0 -/* 890B0 800EFC00 4620103C */ c.lt.d $f2, $f0 -/* 890B4 800EFC04 00000000 */ nop -/* 890B8 800EFC08 45000009 */ bc1f .L800EFC30 -/* 890BC 800EFC0C 00000000 */ nop -/* 890C0 800EFC10 46043001 */ sub.s $f0, $f6, $f4 -/* 890C4 800EFC14 3C013F00 */ lui $at, 0x3f00 -/* 890C8 800EFC18 44811000 */ mtc1 $at, $f2 -/* 890CC 800EFC1C 00000000 */ nop -/* 890D0 800EFC20 46020002 */ mul.s $f0, $f0, $f2 -/* 890D4 800EFC24 00000000 */ nop -/* 890D8 800EFC28 46002000 */ add.s $f0, $f4, $f0 -/* 890DC 800EFC2C E640003C */ swc1 $f0, 0x3c($s2) -.L800EFC30: -/* 890E0 800EFC30 3C018010 */ lui $at, %hi(wPartnerMoveSpeed) -/* 890E4 800EFC34 C4208030 */ lwc1 $f0, %lo(wPartnerMoveSpeed)($at) -/* 890E8 800EFC38 E6400018 */ swc1 $f0, 0x18($s2) -/* 890EC 800EFC3C 3C018010 */ lui $at, %hi(D_800F8034) -/* 890F0 800EFC40 C4208034 */ lwc1 $f0, %lo(D_800F8034)($at) -/* 890F4 800EFC44 8E450018 */ lw $a1, 0x18($s2) -/* 890F8 800EFC48 44060000 */ mfc1 $a2, $f0 -/* 890FC 800EFC4C 0240202D */ daddu $a0, $s2, $zero -/* 89100 800EFC50 0C00EA95 */ jal npc_move_heading -/* 89104 800EFC54 AE46000C */ sw $a2, 0xc($s2) -/* 89108 800EFC58 24050001 */ addiu $a1, $zero, 1 -.L800EFC5C: -/* 8910C 800EFC5C C6400018 */ lwc1 $f0, 0x18($s2) -/* 89110 800EFC60 3C014010 */ lui $at, 0x4010 -/* 89114 800EFC64 44811800 */ mtc1 $at, $f3 -/* 89118 800EFC68 44801000 */ mtc1 $zero, $f2 -/* 8911C 800EFC6C 46000021 */ cvt.d.s $f0, $f0 -/* 89120 800EFC70 4622003C */ c.lt.d $f0, $f2 -/* 89124 800EFC74 00000000 */ nop -/* 89128 800EFC78 45030001 */ bc1tl .L800EFC80 -/* 8912C 800EFC7C 0000282D */ daddu $a1, $zero, $zero -.L800EFC80: -/* 89130 800EFC80 0C00F598 */ jal func_8003D660 -/* 89134 800EFC84 0240202D */ daddu $a0, $s2, $zero -/* 89138 800EFC88 0803BF36 */ j .L800EFCD8 -/* 8913C 800EFC8C 00000000 */ nop -.L800EFC90: -/* 89140 800EFC90 2403FFBF */ addiu $v1, $zero, -0x41 -/* 89144 800EFC94 8E420000 */ lw $v0, ($s2) -/* 89148 800EFC98 3C048011 */ lui $a0, %hi(D_8010CFD8) -/* 8914C 800EFC9C 8C84CFD8 */ lw $a0, %lo(D_8010CFD8)($a0) -/* 89150 800EFCA0 00431024 */ and $v0, $v0, $v1 -/* 89154 800EFCA4 000418C0 */ sll $v1, $a0, 3 -/* 89158 800EFCA8 00641821 */ addu $v1, $v1, $a0 -/* 8915C 800EFCAC 00031880 */ sll $v1, $v1, 2 -/* 89160 800EFCB0 3C048011 */ lui $a0, %hi(D_8010CFCE) -/* 89164 800EFCB4 2484CFCE */ addiu $a0, $a0, %lo(D_8010CFCE) -/* 89168 800EFCB8 AE420000 */ sw $v0, ($s2) -/* 8916C 800EFCBC 94820000 */ lhu $v0, ($a0) -/* 89170 800EFCC0 3C018010 */ lui $at, %hi(gPartnerAnimations+0x14) -/* 89174 800EFCC4 00230821 */ addu $at, $at, $v1 -/* 89178 800EFCC8 8C23835C */ lw $v1, %lo(gPartnerAnimations+0x14)($at) -/* 8917C 800EFCCC 24420001 */ addiu $v0, $v0, 1 -/* 89180 800EFCD0 A4820000 */ sh $v0, ($a0) -/* 89184 800EFCD4 AE430028 */ sw $v1, 0x28($s2) -.L800EFCD8: -/* 89188 800EFCD8 8FBF0044 */ lw $ra, 0x44($sp) -/* 8918C 800EFCDC 8FB40040 */ lw $s4, 0x40($sp) -/* 89190 800EFCE0 8FB3003C */ lw $s3, 0x3c($sp) -/* 89194 800EFCE4 8FB20038 */ lw $s2, 0x38($sp) -/* 89198 800EFCE8 8FB10034 */ lw $s1, 0x34($sp) -/* 8919C 800EFCEC 8FB00030 */ lw $s0, 0x30($sp) -/* 891A0 800EFCF0 03E00008 */ jr $ra -/* 891A4 800EFCF4 27BD0048 */ addiu $sp, $sp, 0x48 -/* 891A8 800EFCF8 00000000 */ nop -/* 891AC 800EFCFC 00000000 */ nop diff --git a/ver/us/symbol_addrs.txt b/ver/us/symbol_addrs.txt index 4dc9d97f01..c138abf1fb 100644 --- a/ver/us/symbol_addrs.txt +++ b/ver/us/symbol_addrs.txt @@ -3142,7 +3142,8 @@ D_800F7B48 = 0x800F7B48; // type:data rom:0x90FF8 D_800F7B4C = 0x800F7B4C; // type:data rom:0x90FFC GravityParamsStartJump = 0x800F7B50; // type:data rom:0x91000 GravityParamsStartFall = 0x800F7B60; // type:data rom:0x91010 -DefaultMoveSpeeds = 0x800F7B70; // type:data rom:0x91020 +D_800F7B70 = 0x800F7B70; // type:data rom:0x91020 +DefaultMoveSpeeds = 0x800F7B74; // type:data rom:0x91024 D_800F7B80 = 0x800F7B80; // type:data rom:0x91030 D_800F7B84 = 0x800F7B84; // type:data rom:0x91034 D_800F7B90 = 0x800F7B90; // type:data rom:0x91040 @@ -4452,8 +4453,8 @@ setup_pause_menu_tab = 0x80147F30; // type:func rom:0xDE630 clear_sprite_shading_data = 0x80148040; // type:func rom:0xDE740 init_sprite_shading_data = 0x801480F0; // type:func rom:0xDE7F0 sprite_shading_set_light_source = 0x80148154; // type:func rom:0xDE854 -render_shaded_sprite = 0x801481C4; // type:func rom:0xDE8C4 -appendGfx_shaded_sprite = 0x801489B8; // type:func rom:0xDF0B8 +create_shading_palette = 0x801481C4; // type:func rom:0xDE8C4 +appendGfx_shading_palette = 0x801489B8; // type:func rom:0xDF0B8 func_801491E4 = 0x801491E4; // type:func rom:0xDF8E4 sfx_compute_spatialized_sound_params_2 = 0x80149250; // type:func rom:0xDF950 sfx_reset_door_sounds = 0x80149600; // type:func rom:0xDFD00 @@ -7660,7 +7661,7 @@ world_goombario_update = 0x802BDD8C; // type:data rom:0x317CAC world_goombario_use_ability = 0x802BDDA8; // type:data rom:0x317CC8 world_goombario_put_away = 0x802BDE60; // type:data rom:0x317D80 D_802BDE80_317DA0 = 0x802BDE80; // type:data rom:0x317DA0 -D_802BDE88_317DA8 = 0x802BDE88; // type:data rom:0x317DA8 +jtbl_802BDE88_317DA8 = 0x802BDE88; // type:data rom:0x317DA8 func_802BD100_317E50 = 0x802BD100; // type:func rom:0x317E50 D_802BDF34 = 0x802BDF34; // type:data rom:0x317E54 D_802BDF38 = 0x802BDF38; // type:data rom:0x317E58 @@ -7760,7 +7761,7 @@ world_watt_init = 0x802BD23C; // type:func rom:0x31CDAC func_802BD27C_31CDEC = 0x802BD27C; // type:func rom:0x31CDEC WattUpdate = 0x802BD2B4; // type:func rom:0x31CE24 func_802BD710_31D280 = 0x802BD710; // type:func rom:0x31D280 -WattUseAbility = 0x802BD754; // type:func rom:0x31D2C4 +func_802BD754_31D2C4 = 0x802BD754; // type:func rom:0x31D2C4 WattPutAway = 0x802BDD0C; // type:func rom:0x31D87C world_watt_pre_battle = 0x802BDD9C; // type:func rom:0x31D90C world_watt_post_battle = 0x802BDE10; // type:func rom:0x31D980