diff options
Diffstat (limited to 'engine/overworld')
-rw-r--r-- | engine/overworld/decorations.asm | 80 | ||||
-rw-r--r-- | engine/overworld/events.asm | 45 | ||||
-rw-r--r-- | engine/overworld/map_objects.asm | 26 | ||||
-rw-r--r-- | engine/overworld/map_objects_2.asm | 2 | ||||
-rw-r--r-- | engine/overworld/map_setup.asm | 73 | ||||
-rw-r--r-- | engine/overworld/npc_movement.asm | 4 | ||||
-rw-r--r-- | engine/overworld/overworld.asm | 2 | ||||
-rw-r--r-- | engine/overworld/player_movement.asm | 16 | ||||
-rw-r--r-- | engine/overworld/player_object.asm | 16 | ||||
-rw-r--r-- | engine/overworld/scripting.asm | 20 | ||||
-rw-r--r-- | engine/overworld/select_menu.asm | 8 | ||||
-rw-r--r-- | engine/overworld/spawn_points.asm | 2 | ||||
-rw-r--r-- | engine/overworld/warp_connection.asm | 15 | ||||
-rw-r--r-- | engine/overworld/wildmons.asm | 5 |
14 files changed, 150 insertions, 164 deletions
diff --git a/engine/overworld/decorations.asm b/engine/overworld/decorations.asm index 3b40641f3..67a07e5db 100644 --- a/engine/overworld/decorations.asm +++ b/engine/overworld/decorations.asm @@ -378,12 +378,11 @@ PopulateDecoCategoryMenu: ret .empty - ld hl, .Text_nothing_to_choose + ld hl, .NothingToChooseText call MenuTextboxBackup ret -.Text_nothing_to_choose: - ; There's nothing to choose. +.NothingToChooseText: text_far _NothingToChooseText text_end @@ -674,7 +673,7 @@ DecoAction_SetItUp: ld a, [wBuffer1] ld hl, wStringBuffer3 call GetDecorationName - ld hl, DecoText_PutAwayAndSetUp + ld hl, PutAwayAndSetUpText call MenuTextboxBackup xor a ret @@ -683,13 +682,13 @@ DecoAction_SetItUp: ld a, [wMenuSelection] ld hl, wStringBuffer3 call GetDecorationName - ld hl, DecoText_SetUpTheDeco + ld hl, SetUpTheDecoText call MenuTextboxBackup xor a ret .alreadythere - ld hl, DecoText_AlreadySetUp + ld hl, AlreadySetUpText call MenuTextboxBackup scf ret @@ -710,19 +709,19 @@ DecoAction_TryPutItAway: ld [wMenuSelection], a ld hl, wStringBuffer3 call GetDecorationName - ld hl, DecoText_PutAwayTheDeco + ld hl, PutAwayTheDecoText call MenuTextboxBackup xor a ret .nothingthere - ld hl, DecoText_NothingToPutAway + ld hl, NothingToPutAwayText call MenuTextboxBackup xor a ret DecoAction_setupornament: - ld hl, UnknownText_0x26e41 + ld hl, WhichSidePutOnText call DecoAction_AskWhichSide jr c, .cancel call DecoAction_SetItUp_Ornament @@ -736,7 +735,7 @@ DecoAction_setupornament: ret DecoAction_putawayornament: - ld hl, DecoText_WhichSide + ld hl, WhichSidePutAwayText call DecoAction_AskWhichSide jr nc, .incave xor a @@ -771,7 +770,7 @@ DecoAction_SetItUp_Ornament: ld a, [wMenuSelection] ld [wSelectedDecoration], a call .getwhichside - ld hl, DecoText_PutAwayAndSetUp + ld hl, PutAwayAndSetUpText call MenuTextboxBackup xor a ret @@ -783,13 +782,13 @@ DecoAction_SetItUp_Ornament: ld a, [wMenuSelection] ld hl, wStringBuffer3 call GetDecorationName - ld hl, DecoText_SetUpTheDeco + ld hl, SetUpTheDecoText call MenuTextboxBackup xor a ret .failed - ld hl, DecoText_AlreadySetUp + ld hl, AlreadySetUpText call MenuTextboxBackup scf ret @@ -804,8 +803,7 @@ DecoAction_SetItUp_Ornament: ld [wOtherDecoration], a ret -UnknownText_0x26e41: - ; Which side do you want to put it on? +WhichSidePutOnText: text_far _WhichSidePutOnText text_end @@ -819,19 +817,18 @@ DecoAction_PutItAway_Ornament: ld [wBuffer5], a xor a ld [wSelectedDecoration], a - ld hl, DecoText_PutAwayTheDeco + ld hl, PutAwayTheDecoText call MenuTextboxBackup xor a ret .nothingthere - ld hl, DecoText_NothingToPutAway + ld hl, NothingToPutAwayText call MenuTextboxBackup xor a ret -DecoText_WhichSide: - ; Which side do you want to put away? +WhichSidePutAwayText: text_far _WhichSidePutAwayText text_end @@ -883,28 +880,23 @@ MenuData_0x26eb3: db "LEFT SIDE@" db "CANCEL@" -DecoText_PutAwayTheDeco: - ; Put away the @ . +PutAwayTheDecoText: text_far _PutAwayTheDecoText text_end -DecoText_NothingToPutAway: - ; There's nothing to put away. +NothingToPutAwayText: text_far _NothingToPutAwayText text_end -DecoText_SetUpTheDeco: - ; Set up the @ . +SetUpTheDecoText: text_far _SetUpTheDecoText text_end -DecoText_PutAwayAndSetUp: - ; Put away the @ and set up the @ . +PutAwayAndSetUpText: text_far _PutAwayAndSetUpText text_end -DecoText_AlreadySetUp: - ; That's already set up. +AlreadySetUpText: text_far _AlreadySetUpText text_end @@ -1005,38 +997,34 @@ DecorationDesc_PosterPointers: DecorationDesc_TownMapPoster: opentext - writetext .TownMapText + writetext .LookTownMapText waitbutton special OverworldTownMap closetext end -.TownMapText: - ; It's the TOWN MAP. +.LookTownMapText: text_far _LookTownMapText text_end DecorationDesc_PikachuPoster: - jumptext .PikaPosterText + jumptext .LookPikachuPosterText -.PikaPosterText: - ; It's a poster of a cute PIKACHU. +.LookPikachuPosterText: text_far _LookPikachuPosterText text_end DecorationDesc_ClefairyPoster: - jumptext .ClefairyPosterText + jumptext .LookClefairyPosterText -.ClefairyPosterText: - ; It's a poster of a cute CLEFAIRY. +.LookClefairyPosterText: text_far _LookClefairyPosterText text_end DecorationDesc_JigglypuffPoster: - jumptext .JigglypuffPosterText + jumptext .LookJigglypuffPosterText -.JigglypuffPosterText: - ; It's a poster of a cute JIGGLYPUFF. +.LookJigglypuffPosterText: text_far _LookJigglypuffPosterText text_end @@ -1064,10 +1052,9 @@ DecorationDesc_OrnamentOrConsole: ret .OrnamentConsoleScript: - jumptext .OrnamentConsoleText + jumptext .LookAdorableDecoText -.OrnamentConsoleText: - ; It's an adorable @ . +.LookAdorableDecoText: text_far _LookAdorableDecoText text_end @@ -1077,10 +1064,9 @@ DecorationDesc_GiantOrnament: ret .BigDollScript: - jumptext .BigDollText + jumptext .LookGiantDecoText -.BigDollText: - ; A giant doll! It's fluffy and cuddly. +.LookGiantDecoText: text_far _LookGiantDecoText text_end diff --git a/engine/overworld/events.asm b/engine/overworld/events.asm index 178a889a3..d4c6ec0bf 100644 --- a/engine/overworld/events.asm +++ b/engine/overworld/events.asm @@ -759,40 +759,41 @@ PlayerMovement: ret .pointers - dw .zero - dw .one - dw .two - dw .three - dw .four - dw .five - dw .six - dw .seven - -.zero -.four +; entries correspond to PLAYERMOVEMENT_* constants + dw .normal + dw .warp + dw .turn + dw .force_turn + dw .finish + dw .continue + dw .exit_water + dw .jump + +.normal: +.finish: xor a ld c, a ret -.seven +.jump: call ret_968d7 ; mobile xor a ld c, a ret -.one - ld a, 5 +.warp: + ld a, PLAYEREVENT_WARP ld c, a scf ret -.two - ld a, 9 +.turn: + ld a, PLAYEREVENT_JOYCHANGEFACING ld c, a scf ret -.three +.force_turn: ; force the player to move in some direction ld a, BANK(Script_ForcedMovement) ld hl, Script_ForcedMovement @@ -802,8 +803,8 @@ PlayerMovement: scf ret -.five -.six +.continue: +.exit_water: ld a, -1 ld c, a and a @@ -923,13 +924,13 @@ CountStep: ret .hatch - ld a, 8 + ld a, PLAYEREVENT_HATCH scf ret ; unused .unreferenced - ld a, 7 + ld a, PLAYEREVENT_WHITEOUT scf ret @@ -1626,7 +1627,7 @@ CmdQueue_StoneTable: jr c, .fall_down_hole .next - ld hl, OBJECT_STRUCT_LENGTH + ld hl, OBJECT_LENGTH add hl, de ld d, h ld e, l diff --git a/engine/overworld/map_objects.asm b/engine/overworld/map_objects.asm index cf532fea6..16562213b 100644 --- a/engine/overworld/map_objects.asm +++ b/engine/overworld/map_objects.asm @@ -10,7 +10,7 @@ DeleteMapObject:: push af ld h, b ld l, c - ld bc, OBJECT_STRUCT_LENGTH + ld bc, OBJECT_LENGTH xor a call ByteFill pop af @@ -430,7 +430,7 @@ RestoreDefaultMovement: ret .ok - ld a, SPRITEMOVEFN_STANDING + ld a, SPRITEMOVEDATA_STANDING_DOWN ret ClearObjectMovementByteIndex: @@ -2082,11 +2082,11 @@ DespawnEmote: jr z, .next push bc xor a - ld bc, OBJECT_STRUCT_LENGTH + ld bc, OBJECT_LENGTH call ByteFill pop bc .next - ld hl, OBJECT_STRUCT_LENGTH + ld hl, OBJECT_LENGTH add hl, de ld d, h ld e, l @@ -2149,7 +2149,7 @@ Function55e0:: jr z, .ok call Function565c .ok - ld hl, OBJECT_STRUCT_LENGTH + ld hl, OBJECT_LENGTH add hl, bc ld b, h ld c, l @@ -2205,7 +2205,7 @@ Function5645: .loop ldh [hMapObjectIndexBuffer], a call SetFacing_Standing - ld hl, OBJECT_STRUCT_LENGTH + ld hl, OBJECT_LENGTH add hl, bc ld b, h ld c, l @@ -2421,7 +2421,7 @@ HandleNPCStep:: jr z, .next call Function437b .next - ld hl, OBJECT_STRUCT_LENGTH + ld hl, OBJECT_LENGTH add hl, bc ld b, h ld c, l @@ -2466,7 +2466,7 @@ RefreshPlayerSprite: jr ContinueSpawnFacing SpawnInFacingDown: - ld a, 0 + ld a, DOWN ContinueSpawnFacing: ld bc, wPlayerStruct call SetSpriteDirection @@ -2582,7 +2582,7 @@ Function587a: add hl, bc set OBJ_FLAGS2_5, [hl] .next - ld hl, OBJECT_STRUCT_LENGTH + ld hl, OBJECT_LENGTH add hl, bc ld b, h ld c, l @@ -2625,7 +2625,7 @@ Function58b9:: add hl, bc res OBJ_FLAGS2_5, [hl] .next - ld hl, OBJECT_STRUCT_LENGTH + ld hl, OBJECT_LENGTH add hl, bc ld b, h ld c, l @@ -2750,7 +2750,7 @@ ApplyBGMapAnchorToObjects: add e ld [hl], a .skip - ld hl, OBJECT_STRUCT_LENGTH + ld hl, OBJECT_LENGTH add hl, bc ld b, h ld c, l @@ -2809,7 +2809,7 @@ InitSprites: jr .add .skip - ld hl, OBJECT_STRUCT_LENGTH + ld hl, OBJECT_LENGTH add hl, bc ld b, h ld c, l @@ -2817,7 +2817,7 @@ InitSprites: jr .next .add - ld hl, OBJECT_STRUCT_LENGTH + ld hl, OBJECT_LENGTH add hl, bc ld b, h ld c, l diff --git a/engine/overworld/map_objects_2.asm b/engine/overworld/map_objects_2.asm index f055e0fd9..d89d95fc0 100644 --- a/engine/overworld/map_objects_2.asm +++ b/engine/overworld/map_objects_2.asm @@ -19,7 +19,7 @@ LoadObjectMasks: ld [de], a inc de pop bc - ld hl, OBJECT_LENGTH + ld hl, MAPOBJECT_LENGTH add hl, bc ld b, h ld c, l diff --git a/engine/overworld/map_setup.asm b/engine/overworld/map_setup.asm index 98b2d90de..1c84f049a 100644 --- a/engine/overworld/map_setup.asm +++ b/engine/overworld/map_setup.asm @@ -18,7 +18,7 @@ INCLUDE "data/maps/setup_scripts.asm" ReadMapSetupScript: .loop ld a, [hli] - cp -1 + cp map_end ret z push hl @@ -62,52 +62,52 @@ MapSetupCommands: ; entries correspond to command indexes in constants/map_setup_constants.asm dba EnableLCD ; 00 dba DisableLCD ; 01 - dba MapSetup_Sound_Off ; 02 + dba InitSound ; 02 dba PlayMapMusic ; 03 dba RestartMapMusic ; 04 dba FadeToMapMusic ; 05 - dba RotatePalettesRightMapAndMusic ; 06 - dba EnterMapMusic ; 07 + dba FadeMapMusicAndPalettes ; 06 + dba PlayMapMusicBike ; 07 dba ForceMapMusic ; 08 dba FadeInMusic ; 09 dba LoadBlockData ; 0a (callback 1) - dba LoadNeighboringBlockData ; 0b + dba LoadConnectionBlockData ; 0b dba SaveScreen ; 0c dba BufferScreen ; 0d - dba LoadGraphics ; 0e - dba LoadTileset ; 0f + dba LoadMapGraphics ; 0e + dba LoadMapTileset ; 0f dba LoadMapTimeOfDay ; 10 dba LoadMapPalettes ; 11 dba LoadWildMonData ; 12 dba RefreshMapSprites ; 13 dba HandleNewMap ; 14 - dba InitCommandQueue ; 15 - dba LoadObjectsRunCallback_02 ; 16 - dba LoadSpawnPoint ; 17 + dba HandleContinueMap ; 15 + dba LoadMapObjects ; 16 + dba EnterMapSpawnPoint ; 17 dba EnterMapConnection ; 18 - dba LoadWarpData ; 19 + dba EnterMapWarp ; 19 dba LoadMapAttributes ; 1a - dba LoadMapAttributes_SkipPeople ; 1b + dba LoadMapAttributes_SkipObjects ; 1b dba ClearBGPalettes ; 1c dba FadeOutPalettes ; 1d dba FadeInPalettes ; 1e - dba GetCoordOfUpperLeftCorner ; 1f - dba RestoreFacingAfterWarp ; 20 + dba GetMapScreenCoords ; 1f + dba GetWarpDestCoords ; 20 dba SpawnInFacingDown ; 21 dba SpawnPlayer ; 22 dba RefreshPlayerCoords ; 23 - dba DelayClearingOldSprites ; 24 - dba DelayLoadingNewSprites ; 25 + dba ResetPlayerObjectAction ; 24 + dba SkipUpdateMapSprites ; 25 dba UpdateRoamMons ; 26 dba JumpRoamMons ; 27 - dba FadeOldMapMusic ; 28 + dba FadeOutMapMusic ; 28 dba ActivateMapAnims ; 29 dba SuspendMapAnims ; 2a - dba RetainOldPalettes ; 2b - dba DontScrollText ; 2c - dba ReturnFromMapSetupScript ; 2d + dba ApplyMapPalettes ; 2b + dba EnableTextAcceleration ; 2c + dba InitMapNameSign ; 2d -DontScrollText: +EnableTextAcceleration: xor a ld [wDisableTextAcceleration], a ret @@ -122,7 +122,7 @@ SuspendMapAnims: ldh [hMapAnims], a ret -LoadObjectsRunCallback_02: +LoadMapObjects: ld a, MAPCALLBACK_OBJECTS call RunMapCallback farcall LoadObjectMasks @@ -132,12 +132,12 @@ LoadObjectsRunCallback_02: ; unused ret -DelayClearingOldSprites: +ResetPlayerObjectAction: ld hl, wPlayerSpriteSetupFlags set PLAYERSPRITESETUP_RESET_ACTION_F, [hl] ret -DelayLoadingNewSprites: +SkipUpdateMapSprites: ld hl, wPlayerSpriteSetupFlags set PLAYERSPRITESETUP_SKIP_RELOAD_GFX_F, [hl] ret @@ -178,13 +178,13 @@ CheckReplaceKrisSprite: jr z, .surfing call GetMapEnvironment cp INDOOR - jr z, .checkbiking + jr z, .no_biking cp ENVIRONMENT_5 - jr z, .checkbiking + jr z, .no_biking cp DUNGEON - jr z, .checkbiking + jr z, .no_biking jr .nope -.checkbiking +.no_biking ld a, [wPlayerState] cp PLAYER_BIKE jr nz, .nope @@ -200,31 +200,32 @@ CheckReplaceKrisSprite: .CheckSurfing: call CheckOnWater - jr nz, .ret_nc + jr nz, .nope2 ld a, [wPlayerState] cp PLAYER_SURF - jr z, ._surfing + jr z, .is_surfing cp PLAYER_SURF_PIKA - jr z, ._surfing + jr z, .is_surfing ld a, PLAYER_SURF ld [wPlayerState], a -._surfing +.is_surfing scf ret -.ret_nc + +.nope2 and a ret -FadeOldMapMusic: +FadeOutMapMusic: ld a, 6 call SkipMusic ret -RetainOldPalettes: +ApplyMapPalettes: farcall _UpdateTimePals ret -RotatePalettesRightMapAndMusic: +FadeMapMusicAndPalettes: ld e, 0 ld a, [wMusicFadeID] ld d, 0 diff --git a/engine/overworld/npc_movement.asm b/engine/overworld/npc_movement.asm index d249d2fd4..f4c730247 100644 --- a/engine/overworld/npc_movement.asm +++ b/engine/overworld/npc_movement.asm @@ -369,7 +369,7 @@ IsNPCAtCoord: jr nz, .setcarry .next - ld hl, OBJECT_STRUCT_LENGTH + ld hl, OBJECT_LENGTH add hl, bc ld b, h ld c, l @@ -523,7 +523,7 @@ Unreferenced_Function7113: jr .yes .next - ld hl, OBJECT_STRUCT_LENGTH + ld hl, OBJECT_LENGTH add hl, bc ld b, h ld c, l diff --git a/engine/overworld/overworld.asm b/engine/overworld/overworld.asm index e47645f2c..814f608f7 100644 --- a/engine/overworld/overworld.asm +++ b/engine/overworld/overworld.asm @@ -109,7 +109,7 @@ AddIndoorSprites: push af ld a, [hl] call AddSpriteGFX - ld de, OBJECT_LENGTH + ld de, MAPOBJECT_LENGTH add hl, de pop af inc a diff --git a/engine/overworld/player_movement.asm b/engine/overworld/player_movement.asm index 09d6b47de..9f372640b 100644 --- a/engine/overworld/player_movement.asm +++ b/engine/overworld/player_movement.asm @@ -120,7 +120,7 @@ DoPlayerMovement:: ld c, a call CheckWhirlpoolTile jr c, .not_whirlpool - ld a, 3 + ld a, PLAYERMOVEMENT_FORCE_TURN scf ret @@ -222,7 +222,7 @@ DoPlayerMovement:: .continue_walk ld a, STEP_WALK call .DoStep - ld a, 5 + ld a, PLAYERMOVEMENT_CONTINUE scf ret @@ -247,7 +247,7 @@ DoPlayerMovement:: ld a, STEP_TURN call .DoStep - ld a, 2 + ld a, PLAYERMOVEMENT_TURN scf ret @@ -345,7 +345,7 @@ DoPlayerMovement:: call PlayMapMusic ld a, STEP_WALK call .DoStep - ld a, 6 + ld a, PLAYERMOVEMENT_EXIT_WATER scf ret @@ -374,7 +374,7 @@ DoPlayerMovement:: call PlaySFX ld a, STEP_LEDGE call .DoStep - ld a, 7 + ld a, PLAYERMOVEMENT_JUMP scf ret @@ -428,11 +428,11 @@ DoPlayerMovement:: call .StandInPlace scf - ld a, 1 + ld a, PLAYERMOVEMENT_WARP ret .not_warp - xor a + xor a ; PLAYERMOVEMENT_NORMAL ret .EdgeWarps: @@ -465,7 +465,7 @@ DoPlayerMovement:: ld a, [hl] ld [wPlayerTurningDirection], a - ld a, 4 + ld a, PLAYERMOVEMENT_FINISH ret .Steps: diff --git a/engine/overworld/player_object.asm b/engine/overworld/player_object.asm index 9f1b13dd9..478c8f6c6 100644 --- a/engine/overworld/player_object.asm +++ b/engine/overworld/player_object.asm @@ -132,9 +132,9 @@ CopyObjectStruct:: and a ret nz ; masked - ld hl, wObjectStructs + OBJECT_STRUCT_LENGTH * 1 + ld hl, wObjectStructs + OBJECT_LENGTH * 1 ld a, 1 - ld de, OBJECT_STRUCT_LENGTH + ld de, OBJECT_LENGTH .loop ldh [hObjectStructIndexBuffer], a ld a, [hl] @@ -224,7 +224,7 @@ CopyMapObjectToObjectStruct: ret InitializeVisibleSprites: - ld bc, wMapObjects + OBJECT_LENGTH + ld bc, wMapObjects + MAPOBJECT_LENGTH ld a, 1 .loop ldh [hMapObjectIndexBuffer], a @@ -271,7 +271,7 @@ InitializeVisibleSprites: jp c, .ret .next - ld hl, OBJECT_LENGTH + ld hl, MAPOBJECT_LENGTH add hl, bc ld b, h ld c, l @@ -311,7 +311,7 @@ CheckObjectEnteringVisibleRange:: ld d, a ld a, [wXCoord] ld e, a - ld bc, wMapObjects + OBJECT_LENGTH + ld bc, wMapObjects + MAPOBJECT_LENGTH ld a, 1 .loop_v ldh [hMapObjectIndexBuffer], a @@ -345,7 +345,7 @@ CheckObjectEnteringVisibleRange:: pop de .next_v - ld hl, OBJECT_LENGTH + ld hl, MAPOBJECT_LENGTH add hl, bc ld b, h ld c, l @@ -367,7 +367,7 @@ CheckObjectEnteringVisibleRange:: ld e, a ld a, [wYCoord] ld d, a - ld bc, wMapObjects + OBJECT_LENGTH + ld bc, wMapObjects + MAPOBJECT_LENGTH ld a, 1 .loop_h ldh [hMapObjectIndexBuffer], a @@ -401,7 +401,7 @@ CheckObjectEnteringVisibleRange:: pop de .next_h - ld hl, OBJECT_LENGTH + ld hl, MAPOBJECT_LENGTH add hl, bc ld b, h ld c, l diff --git a/engine/overworld/scripting.asm b/engine/overworld/scripting.asm index 7496b82bd..245d8e763 100644 --- a/engine/overworld/scripting.asm +++ b/engine/overworld/scripting.asm @@ -148,7 +148,7 @@ ScriptCommandTable: dw Script_farjumptext ; 52 dw Script_jumptext ; 53 dw Script_waitbutton ; 54 - dw Script_buttonsound ; 55 + dw Script_promptbutton ; 55 dw Script_pokepic ; 56 dw Script_closepokepic ; 57 dw Script__2dmenu ; 58 @@ -398,7 +398,7 @@ Script_waitbutton: jp WaitButton -Script_buttonsound: +Script_promptbutton: ; script command 0x55 ldh a, [hOAMUpdate] @@ -406,7 +406,7 @@ Script_buttonsound: ld a, $1 ldh [hOAMUpdate], a call WaitBGMap - call ButtonSound + call PromptButton pop af ldh [hOAMUpdate], a ret @@ -525,12 +525,12 @@ GiveItemScript: end .Full: - buttonsound + promptbutton pocketisfull end ReceivedItemText: - text_far UnknownText_0x1c4719 + text_far _ReceivedItemText text_end Script_verbosegiveitemvar: @@ -622,11 +622,11 @@ CurItemName: ret PutItemInPocketText: - text_far UnknownText_0x1c472c + text_far _PutItemInPocketText text_end PocketIsFullText: - text_far UnknownText_0x1c474b + text_far _PocketIsFullText text_end Script_pokemart: @@ -1952,7 +1952,7 @@ Script_getmoney: call ResetStringBuffer1 call GetMoneyAccount ld hl, wStringBuffer1 - lb bc, PRINTNUM_RIGHTALIGN | 3, 6 + lb bc, PRINTNUM_LEFTALIGN | 3, 6 call PrintNum ld de, wStringBuffer1 jp GetStringBuffer @@ -1964,7 +1964,7 @@ Script_getcoins: call ResetStringBuffer1 ld hl, wStringBuffer1 ld de, wCoins - lb bc, PRINTNUM_RIGHTALIGN | 2, 6 + lb bc, PRINTNUM_LEFTALIGN | 2, 6 call PrintNum ld de, wStringBuffer1 jp GetStringBuffer @@ -1976,7 +1976,7 @@ Script_getnum: call ResetStringBuffer1 ld de, wScriptVar ld hl, wStringBuffer1 - lb bc, PRINTNUM_RIGHTALIGN | 1, 3 + lb bc, PRINTNUM_LEFTALIGN | 1, 3 call PrintNum ld de, wStringBuffer1 jp GetStringBuffer diff --git a/engine/overworld/select_menu.asm b/engine/overworld/select_menu.asm index 9cc2ba149..18532edae 100644 --- a/engine/overworld/select_menu.asm +++ b/engine/overworld/select_menu.asm @@ -5,14 +5,14 @@ SelectMenu:: .NotRegistered: call OpenText - ld b, BANK(ItemMayBeRegisteredText) - ld hl, ItemMayBeRegisteredText + ld b, BANK(MayRegisterItemText) + ld hl, MayRegisterItemText call MapTextbox call WaitButton jp CloseText -ItemMayBeRegisteredText: - text_far UnknownText_0x1c1cf3 +MayRegisterItemText: + text_far _MayRegisterItemText text_end CheckRegisteredItem: diff --git a/engine/overworld/spawn_points.asm b/engine/overworld/spawn_points.asm index 6b4476f2b..33e4c96b3 100644 --- a/engine/overworld/spawn_points.asm +++ b/engine/overworld/spawn_points.asm @@ -1,6 +1,6 @@ INCLUDE "data/maps/spawn_points.asm" -LoadSpawnPoint: +EnterMapSpawnPoint: ; loads the spawn point in wDefaultSpawnpoint push hl push de diff --git a/engine/overworld/warp_connection.asm b/engine/overworld/warp_connection.asm index 2b36d1e42..ed3b26ef5 100644 --- a/engine/overworld/warp_connection.asm +++ b/engine/overworld/warp_connection.asm @@ -1,4 +1,3 @@ - HandleNewMap: call ClearUnusedMapBuffer call ResetMapBufferEventFlags @@ -7,7 +6,7 @@ HandleNewMap: call ResetBikeFlags ld a, MAPCALLBACK_NEWMAP call RunMapCallback -InitCommandQueue: +HandleContinueMap: farcall ClearCmdQueue ld a, MAPCALLBACK_CMDQUEUE call RunMapCallback @@ -150,7 +149,7 @@ EnterMapConnection: scf ret -LoadWarpData: +EnterMapWarp: call .SaveDigWarp call .SetSpawn ld a, [wNextWarp] @@ -296,8 +295,8 @@ LoadMapTimeOfDay: ldh [rVBK], a ret -LoadGraphics: - call LoadTileset +LoadMapGraphics: + call LoadMapTileset call LoadTilesetGFX xor a ldh [hMapAnims], a @@ -314,7 +313,7 @@ LoadMapPalettes: RefreshMapSprites: call ClearSprites - farcall ReturnFromMapSetupScript + farcall InitMapNameSign call GetMovementPermissions farcall RefreshPlayerSprite farcall CheckReplaceKrisSprite @@ -326,7 +325,7 @@ RefreshMapSprites: call SafeUpdateSprites .skip ld a, [wPlayerSpriteSetupFlags] - and %00011100 + and (1 << PLAYERSPRITESETUP_FEMALE_TO_MALE_F) | (1 << 3) | (1 << 4) ld [wPlayerSpriteSetupFlags], a ret @@ -387,7 +386,7 @@ CheckMovingOffEdgeOfMap:: scf ret -GetCoordOfUpperLeftCorner:: +GetMapScreenCoords:: ld hl, wOverworldMapBlocks ld a, [wXCoord] bit 0, a diff --git a/engine/overworld/wildmons.asm b/engine/overworld/wildmons.asm index a384915b6..61ef89b18 100644 --- a/engine/overworld/wildmons.asm +++ b/engine/overworld/wildmons.asm @@ -821,7 +821,7 @@ RandomUnseenWildMon: ld a, c ld [wNamedObjectIndexBuffer], a call GetPokemonName - ld hl, .SawRareMonText + ld hl, .JustSawSomeRareMonText call PrintText xor a ld [wScriptVar], a @@ -832,8 +832,7 @@ RandomUnseenWildMon: ld [wScriptVar], a ret -.SawRareMonText: - ; I just saw some rare @ in @ . I'll call you if I see another rare #MON, OK? +.JustSawSomeRareMonText: text_far _JustSawSomeRareMonText text_end |