diff options
Diffstat (limited to 'scripts/pallettown.asm')
-rwxr-xr-x | scripts/pallettown.asm | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/scripts/pallettown.asm b/scripts/pallettown.asm index d625a7be..5b042066 100755 --- a/scripts/pallettown.asm +++ b/scripts/pallettown.asm @@ -33,7 +33,7 @@ PalletTownScript0: ; 18e81 (6:4e81) ld a,$FF call PlaySound ; stop music ld a, BANK(Music_MeetProfOak) - ld c,a ; song bank + ld c,a ld a, MUSIC_MEET_PROF_OAK ; “oak appears” music call PlayMusic ld a,$FC @@ -50,7 +50,7 @@ PalletTownScript1: ; 18eb2 (6:4eb2) xor a ld [wcf0d],a ld a,1 - ld [$FF8C],a + ld [hSpriteIndexOrTextID],a call DisplayTextID ld a,$FF ld [wJoyIgnore],a @@ -65,25 +65,25 @@ PalletTownScript1: ; 18eb2 (6:4eb2) PalletTownScript2: ; 18ed2 (6:4ed2) ld a,1 - ld [$FF8C],a - ld a,4 + ld [H_SPRITEINDEX],a + ld a,SPRITE_FACING_UP ld [$FF8D],a call SetSpriteFacingDirectionAndDelay call Delay3 ld a,1 ld [W_YCOORD],a ld a,1 - ld [$FF9B],a + ld [hNPCPlayerRelativePosPerspective],a ld a,1 swap a - ld [$FF95],a + ld [hNPCSpriteOffset],a predef CalcPositionOfPlayerRelativeToNPC - ld hl,$FF95 + ld hl,hNPCPlayerYDistance dec [hl] predef FindPathToPlayer ; load Oak’s movement into wNPCMovementDirections2 ld de,wNPCMovementDirections2 ld a,1 ; oak - ld [$FF8C],a + ld [H_SPRITEINDEX],a call MoveSprite ld a,$FF ld [wJoyIgnore],a @@ -104,8 +104,9 @@ PalletTownScript3: ; 18f12 (6:4f12) ld a,$FC ld [wJoyIgnore],a ld a,1 - ld [$FF8C],a + ld [hSpriteIndexOrTextID],a call DisplayTextID +; set up movement script that causes the player to follow Oak to his lab ld a,$FF ld [wJoyIgnore],a ld a,1 @@ -124,7 +125,7 @@ PalletTownScript3: ; 18f12 (6:4f12) PalletTownScript4: ; 18f4b (6:4f4b) ld a,[wNPCMovementScriptPointerTableNum] - and a + and a ; is the movement script over? ret nz ; trigger the next script @@ -186,9 +187,9 @@ OakAppearsText: ; 18fb0 (6:4fb0) ld c,10 call DelayFrames xor a - ld [wcd4f],a - ld [wcd50],a - predef EmotionBubble ; display ! over head + ld [wEmotionBubbleSpriteIndex],a ; player's sprite + ld [wWhichEmotionBubble],a ; EXCLAMATION_BUBBLE + predef EmotionBubble ld a,4 ld [wd528],a jp TextScriptEnd |