diff --git a/asm/nonmatchings/battle/partner/twink_714CF0/func_80238000_714CF0.s b/asm/nonmatchings/battle/partner/twink_714CF0/func_80238000_714CF0.s deleted file mode 100644 index d19fa4d381..0000000000 --- a/asm/nonmatchings/battle/partner/twink_714CF0/func_80238000_714CF0.s +++ /dev/null @@ -1,16 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_80238000_714CF0 -/* 714CF0 80238000 3C02800E */ lui $v0, %hi(gBattleStatus+0x4) -/* 714CF4 80238004 8C42C074 */ lw $v0, %lo(gBattleStatus+0x4)($v0) -/* 714CF8 80238008 30420040 */ andi $v0, $v0, 0x40 -/* 714CFC 8023800C 10400003 */ beqz $v0, .L8023801C -/* 714D00 80238010 24020001 */ addiu $v0, $zero, 1 -/* 714D04 80238014 0808E008 */ j .L80238020 -/* 714D08 80238018 AC820084 */ sw $v0, 0x84($a0) -.L8023801C: -/* 714D0C 8023801C AC800084 */ sw $zero, 0x84($a0) -.L80238020: -/* 714D10 80238020 03E00008 */ jr $ra -/* 714D14 80238024 24020002 */ addiu $v0, $zero, 2 diff --git a/asm/nonmatchings/code_714CF0/func_80238000_714CF0.s b/asm/nonmatchings/code_714CF0/func_80238000_714CF0.s deleted file mode 100644 index d19fa4d381..0000000000 --- a/asm/nonmatchings/code_714CF0/func_80238000_714CF0.s +++ /dev/null @@ -1,16 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_80238000_714CF0 -/* 714CF0 80238000 3C02800E */ lui $v0, %hi(gBattleStatus+0x4) -/* 714CF4 80238004 8C42C074 */ lw $v0, %lo(gBattleStatus+0x4)($v0) -/* 714CF8 80238008 30420040 */ andi $v0, $v0, 0x40 -/* 714CFC 8023800C 10400003 */ beqz $v0, .L8023801C -/* 714D00 80238010 24020001 */ addiu $v0, $zero, 1 -/* 714D04 80238014 0808E008 */ j .L80238020 -/* 714D08 80238018 AC820084 */ sw $v0, 0x84($a0) -.L8023801C: -/* 714D0C 8023801C AC800084 */ sw $zero, 0x84($a0) -.L80238020: -/* 714D10 80238020 03E00008 */ jr $ra -/* 714D14 80238024 24020002 */ addiu $v0, $zero, 2 diff --git a/asm/nonmatchings/code_EF2650/func_80240040_EF2650.s b/asm/nonmatchings/code_EF2650/func_80240040_EF2650.s deleted file mode 100644 index 14d8a4a504..0000000000 --- a/asm/nonmatchings/code_EF2650/func_80240040_EF2650.s +++ /dev/null @@ -1,16 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -glabel func_80240040_EF2650 -/* EF2650 80240040 27BDFFE8 */ addiu $sp, $sp, -0x18 -/* EF2654 80240044 AFBF0010 */ sw $ra, 0x10($sp) -/* EF2658 80240048 8C82000C */ lw $v0, 0xc($a0) -/* EF265C 8024004C 3C068017 */ lui $a2, %hi(D_80169B16) -/* EF2660 80240050 84C69B16 */ lh $a2, %lo(D_80169B16)($a2) -/* EF2664 80240054 0C0B551A */ jal func_802D5468 -/* EF2668 80240058 8C450000 */ lw $a1, ($v0) -/* EF266C 8024005C 8FBF0010 */ lw $ra, 0x10($sp) -/* EF2670 80240060 24020002 */ addiu $v0, $zero, 2 -/* EF2674 80240064 03E00008 */ jr $ra -/* EF2678 80240068 27BD0018 */ addiu $sp, $sp, 0x18 -/* EF267C 8024006C 00000000 */ nop diff --git a/src/battle/partner/twink_714CF0.c b/src/battle/partner/twink_714CF0.c index 84df7c87e0..a3c8f8ee37 100644 --- a/src/battle/partner/twink_714CF0.c +++ b/src/battle/partner/twink_714CF0.c @@ -1,5 +1,15 @@ #include "common.h" -INCLUDE_ASM(s32, "battle/partner/twink_714CF0", func_80238000_714CF0); +ApiStatus func_80238000_714CF0(ScriptInstance* script, s32 isInitialCall) { + BattleStatus* battleStatus = BATTLE_STATUS; + + if (battleStatus->flags2 & 0x40) { + script->varTable[0] = 1; + } else { + script->varTable[0] = 0; + } + + return ApiStatus_DONE2; +} INCLUDE_ASM(s32, "battle/partner/twink_714CF0", func_80238028_714D18); diff --git a/src/code_EF2650.c b/src/code_EF2650.c index 9909ad6690..0a2b0e3851 100644 --- a/src/code_EF2650.c +++ b/src/code_EF2650.c @@ -1,3 +1,8 @@ #include "common.h" -INCLUDE_ASM(s32, "code_EF2650", func_80240040_EF2650); +extern s16 D_80169B16; + +ApiStatus func_80240040_EF2650(ScriptInstance* script, s32 isInitialCall) { + func_802D5468(script, *script->ptrReadPos, D_80169B16); + return ApiStatus_DONE2; +}