diff --git a/audio/engine.asm b/audio/engine.asm index 6b0fe1a63..748e17361 100644 --- a/audio/engine.asm +++ b/audio/engine.asm @@ -1364,7 +1364,7 @@ ParseMusicCommand: jp hl MusicCommands: -; entries correspond to macros/sound.asm enumeration +; entries correspond to macros/scripts/audio.asm enumeration dw Music_Octave8 ; octave 8 dw Music_Octave7 ; octave 7 dw Music_Octave6 ; octave 6 diff --git a/engine/events/map_name_sign.asm b/engine/events/map_name_sign.asm index 6162378a9..0cb8ce97a 100644 --- a/engine/events/map_name_sign.asm +++ b/engine/events/map_name_sign.asm @@ -15,13 +15,13 @@ ReturnFromMapSetupScript:: call GetWorldMapLocation ld [wCurLandmark], a call .CheckNationalParkGate - jr z, .nationalparkgate + jr z, .gate call GetMapEnvironment cp GATE jr nz, .not_gate -.nationalparkgate +.gate ld a, -1 ld [wCurLandmark], a @@ -70,7 +70,7 @@ ReturnFromMapSetupScript:: ; These landmarks do not get pop-up signs. cp -1 ret z - cp SPECIAL_MAP + cp SPECIAL_MAP ; redundant check ret z cp RADIO_TOWER ret z @@ -105,11 +105,11 @@ PlaceMapNameSign:: cp 60 ret z cp 59 - jr nz, .skip2 + jr nz, .already_initialized call InitMapNameFrame call PlaceMapNameCenterAlign farcall HDMATransfer_OnlyTopFourRows -.skip2 +.already_initialized ld a, $80 ld a, $70 ldh [rWY], a diff --git a/engine/overworld/warp_connection.asm b/engine/overworld/warp_connection.asm index 2b36d1e42..bf28ab35e 100644 --- a/engine/overworld/warp_connection.asm +++ b/engine/overworld/warp_connection.asm @@ -1,4 +1,3 @@ - HandleNewMap: call ClearUnusedMapBuffer call ResetMapBufferEventFlags diff --git a/home/map.asm b/home/map.asm index b3ef17da8..617ac135a 100644 --- a/home/map.asm +++ b/home/map.asm @@ -330,7 +330,7 @@ CopyWarpData:: ld bc, 2 ; warp number add hl, bc ld a, [hli] - cp $ff + cp -1 jr nz, .skip ld hl, wBackupWarpNumber ld a, [hli] @@ -679,7 +679,7 @@ endr ld [wXCoord], a ; destination warp number ld a, [hli] - cp $ff + cp -1 jr nz, .skip call .backup diff --git a/mobile/mobile_5f.asm b/mobile/mobile_5f.asm index d4a7fcd62..c4fae15ac 100644 --- a/mobile/mobile_5f.asm +++ b/mobile/mobile_5f.asm @@ -3615,8 +3615,8 @@ _RunMobileScript: dw Function17f220 ; 5 dw Function17f27b ; 6 dw Function17f2cb ; 7 - dw Function17f2ff ; 8 - dw Function17f334 ; 9 + dw MobileScript_PlayerName ; 8 + dw MobileScript_Prefecture ; 9 dw Function17f382 ; a dw Function17f3c9 ; b dw Function17f3f0 ; c @@ -4068,7 +4068,7 @@ Function17f2cb: and a ret -Function17f2ff: +MobileScript_PlayerName: pop hl push bc ld a, [hli] @@ -4080,7 +4080,7 @@ Function17f2ff: ldh [rSVBK], a ld hl, wPlayerName ld de, wc608 - ld bc, $6 + ld bc, NAME_LENGTH_JAPANESE call CopyBytes ld a, $4 ldh [rSVBK], a @@ -4097,7 +4097,7 @@ Function17f2ff: and a ret -Function17f334: +MobileScript_Prefecture: pop hl push bc ld a, [hli] @@ -4118,9 +4118,9 @@ Function17f334: jr .asm_17f35d .asm_17f355 - ld a, $5 + ld a, BANK(s5_b2f3) call GetSRAMBank - ld a, [$b2f3] + ld a, [s5_b2f3] .asm_17f35d ld c, a @@ -4161,9 +4161,9 @@ Function17f382: jr .asm_17f3ab .asm_17f3a3 - ld a, $5 + ld a, BANK(s5_b2f4) call GetSRAMBank - ld de, $b2f4 + ld de, s5_b2f4 .asm_17f3ab ld a, PRINTNUM_LEADINGZEROS | 2 @@ -4195,7 +4195,7 @@ Function17f3c9: push hl ld hl, wc708 ld de, wcd36 - ld bc, $c + ld bc, 12 call CopyBytes pop bc pop de diff --git a/sram.asm b/sram.asm index 7c4cd9edd..f01df74df 100644 --- a/sram.asm +++ b/sram.asm @@ -348,7 +348,12 @@ s5_aa8e:: ds 7 * $cc ; aa8e s5_b023:: ds 105 ; b023 s5_b08c:: ds 4 ; b08c - ds $269 + ds $263 + +s5_b2f3:: db ; b2f3 +s5_b2f4:: db ; b2f4 + + ds 4 s5_b2f9:: db ; b2f9 s5_b2fa:: db ; b2fa