diff options
Diffstat (limited to 'scripts/oakslab.asm')
-rwxr-xr-x | scripts/oakslab.asm | 44 |
1 files changed, 21 insertions, 23 deletions
diff --git a/scripts/oakslab.asm b/scripts/oakslab.asm index 5b10668e..5a6b9456 100755 --- a/scripts/oakslab.asm +++ b/scripts/oakslab.asm @@ -1,4 +1,4 @@ -OaksLabScript: ; 1cb0e (7:4b0e) +OaksLabScript: CheckEvent EVENT_PALLET_AFTER_GETTING_POKEBALLS_2 call nz, OaksLabScript_1d076 ld a, $1 @@ -10,7 +10,7 @@ OaksLabScript: ; 1cb0e (7:4b0e) call JumpTable ret -OaksLabScriptPointers: ; 1cb28 (7:4b28) +OaksLabScriptPointers: dw OaksLabScript0 dw OaksLabScript1 dw OaksLabScript2 @@ -35,7 +35,7 @@ OaksLabScriptPointers: ; 1cb28 (7:4b28) dw OaksLabScript21 dw OaksLabScript22 -OaksLabScript0: ; 1cb4e (7:4b4e) +OaksLabScript0: CheckEvent EVENT_OAK_APPEARED_IN_PALLET ret z ld a, [wNPCMovementScriptFunctionNum] @@ -51,7 +51,7 @@ OaksLabScript0: ; 1cb4e (7:4b4e) ld [wOaksLabCurScript], a ret -OaksLabScript1: ; 1cb6e (7:4b6e) +OaksLabScript1: ld a, $6 ld [H_SPRITEINDEX], a ld de, OakEntryMovement @@ -61,13 +61,13 @@ OaksLabScript1: ; 1cb6e (7:4b6e) ld [wOaksLabCurScript], a ret -OakEntryMovement: ; 1cb7e (7:4b7e) +OakEntryMovement: db NPC_MOVEMENT_UP db NPC_MOVEMENT_UP db NPC_MOVEMENT_UP db $FF -OaksLabScript2: ; 1cb82 (7:4b82) +OaksLabScript2: ld a, [wd730] bit 0, a ret nz @@ -82,7 +82,7 @@ OaksLabScript2: ; 1cb82 (7:4b82) ld [wOaksLabCurScript], a ret -OaksLabScript3: ; 1cba2 (7:4ba2) +OaksLabScript3: call Delay3 ld hl, wSimulatedJoypadStatesEnd ld de, PlayerEntryMovementRLE @@ -105,11 +105,11 @@ OaksLabScript3: ; 1cba2 (7:4ba2) ld [wOaksLabCurScript], a ret -PlayerEntryMovementRLE: ; 1cbcf (7:4bcf) +PlayerEntryMovementRLE: db D_UP,$8 db $ff -OaksLabScript4: ; 1cbd2 (7:445f) +OaksLabScript4: ld a, [wSimulatedJoypadStatesIndex] and a ret nz @@ -128,9 +128,8 @@ OaksLabScript4: ; 1cbd2 (7:445f) ld [wOaksLabCurScript], a ret -OaksLabScript5: ; 1cbfd (7:4bfd) - ld hl, wd74b - set 1, [hl] +OaksLabScript5: + SetEvent EVENT_OAK_ASKED_TO_CHOOSE_MON ld a, $fc ld [wJoyIgnore], a ld a, $d @@ -159,7 +158,7 @@ OaksLabScript5: ; 1cbfd (7:4bfd) ld [wOaksLabCurScript], a ret -OaksLabScript6: ; 1cc36 (7:4c36) +OaksLabScript6: ld a, [wYCoord] cp $6 ret nz @@ -189,7 +188,7 @@ OaksLabScript6: ; 1cc36 (7:4c36) ld [wOaksLabCurScript], a ret -OaksLabScript7: ; 1cc72 (7:4c72) +OaksLabScript7: ld a, [wSimulatedJoypadStatesIndex] and a ret nz @@ -199,7 +198,7 @@ OaksLabScript7: ; 1cc72 (7:4c72) ld [wOaksLabCurScript], a ret -OaksLabScript8: ; 1cc80 (7:4c80) +OaksLabScript8: ld a, $1 ld [hSpriteIndexOrTextID], a ld de, .SonyPushesPlayerAwayFromEeveeBall @@ -215,7 +214,7 @@ OaksLabScript8: ; 1cc80 (7:4c80) db $07 db $FF -OaksLabScript9: ; 1cd00 (7:4d00) +OaksLabScript9: ld a, [wd730] bit 0, a jr nz, .asm_1c564 @@ -259,7 +258,7 @@ OaksLabScript9: ; 1cd00 (7:4d00) call StartSimulatingJoypadStates ret -OaksLabScript10: ; 1cd6d (7:4d6d) +OaksLabScript10: ld a, [wYCoord] cp $4 jr z, .asm_1c599 @@ -392,8 +391,7 @@ OaksLabScript14: xor a ld [wSpriteStateData1 + 1 * $10 + 9], a predef HealParty - ld hl, wd74b - set 3, [hl] + SetEvent EVENT_BATTLED_RIVAL_IN_OAKS_LAB ld a, $f ld [wOaksLabCurScript], a ret @@ -466,15 +464,15 @@ OaksLabScript16: ret nz xor a .asm_1c707 - ld [wSpriteStateData1 + 9], a + ld [wPlayerFacingDirection], a ret OaksLabScript17: ; Pikachu comes out ld a, SPRITE_FACING_UP - ld [wSpriteStateData1 + 9], a + ld [wPlayerFacingDirection], a ld a, $2 - ld [wd431], a + ld [wPikachuSpawnState], a callba Func_fc4fa call Func_1525 ld a, $1a @@ -707,7 +705,7 @@ OaksLabScript_1d076: ld [wMapTextPtr + 1], a ret -OaksLabTextPointers: ; 1d082 (7:5082) +OaksLabTextPointers: dw OaksLabText1 dw OaksLabText2 dw OaksLabText3 |