diff options
author | Rangi <remy.oukaour+rangi42@gmail.com> | 2020-10-05 20:09:52 -0400 |
---|---|---|
committer | Rangi <remy.oukaour+rangi42@gmail.com> | 2020-10-05 20:09:52 -0400 |
commit | 10151dd4ebce1a0d7c0c30c8a93f1988345d1c2e (patch) | |
tree | 8aa57b181063fe20d0415cbf037ca2063363aaa3 | |
parent | 8871f4b611ec2c8a7f65592bf0b990182db7ec99 (diff) |
Identify some more unnamed labels
-rw-r--r-- | engine/gfx/color.asm | 2 | ||||
-rw-r--r-- | engine/items/tmhm.asm | 3 | ||||
-rw-r--r-- | engine/overworld/load_map_part.asm | 12 | ||||
-rw-r--r-- | engine/overworld/npc_movement.asm | 39 | ||||
-rw-r--r-- | engine/overworld/overworld.asm | 11 | ||||
-rw-r--r-- | engine/pokemon/bills_pc_top.asm | 4 | ||||
-rw-r--r-- | engine/pokemon/mail_2.asm | 3 | ||||
-rw-r--r-- | engine/printer/printer.asm | 4 | ||||
-rw-r--r-- | engine/rtc/print_hours_mins.asm | 3 | ||||
-rw-r--r-- | engine/rtc/timeset.asm | 2 |
10 files changed, 47 insertions, 36 deletions
diff --git a/engine/gfx/color.asm b/engine/gfx/color.asm index c6ce55aa..d03724f8 100644 --- a/engine/gfx/color.asm +++ b/engine/gfx/color.asm @@ -669,7 +669,7 @@ CGBCopyBattleObjectPals: ; unreferenced BattleObjectPals: INCLUDE "gfx/battle_anims/battle_anims.pal" -Function9c39: ; unreferenced +CGBCopyTwoPredefObjectPals: ; unreferenced call CheckCGB ret z ld a, (1 << rOBPI_AUTO_INCREMENT) | $10 diff --git a/engine/items/tmhm.asm b/engine/items/tmhm.asm index bc6f94c6..e7c622d7 100644 --- a/engine/items/tmhm.asm +++ b/engine/items/tmhm.asm @@ -435,7 +435,8 @@ TMHMPocket_GetCurrentLineCoord: jr nz, .loop ret -Function2c89a: ; unreferenced +PlaceMoveNameAfterTMHMName: ; unreferenced +; Similar to a part of TMHM_DisplayPocketItems. pop hl ld bc, 3 add hl, bc diff --git a/engine/overworld/load_map_part.asm b/engine/overworld/load_map_part.asm index 32dc1226..4e8e228b 100644 --- a/engine/overworld/load_map_part.asm +++ b/engine/overworld/load_map_part.asm @@ -35,7 +35,8 @@ _LoadMapPart:: jr nz, .loop ret -Function153ba: ; unreferenced +ForceApplyFlashlight1: ; unreferenced +; See pokegold-spaceworld's ApplyFlashlight.force_1 in home/map.asm. decoord 2, 2 ld bc, (SURROUNDING_WIDTH + 1) * 2 add hl, bc @@ -66,7 +67,8 @@ Function153ba: ; unreferenced jr nz, .loop ret -Function153dd: ; unreferenced +ForceApplyFlashlight2: ; unreferenced +; See pokegold-spaceworld's ApplyFlashlight.force_2 in home/map.asm. decoord 4, 4 ld bc, (SURROUNDING_WIDTH + 1) * 4 add hl, bc @@ -97,7 +99,8 @@ Function153dd: ; unreferenced jr nz, .loop ret -Ureferenced_Function15400: +ForceApplyFlashlight3: ; unreferenced +; See pokegold-spaceworld's ApplyFlashlight.force_3 in home/map.asm. decoord 6, 6 ld bc, (SURROUNDING_WIDTH + 1) * 6 add hl, bc @@ -128,7 +131,8 @@ Ureferenced_Function15400: jr nz, .loop ret -Function15423: ; unreferenced +ForceApplyFlashlight4: ; unreferenced +; See pokegold-spaceworld's ApplyFlashlight.force_4 in home/map.asm. decoord 8, 8 ld bc, (SURROUNDING_WIDTH + 1) * 8 add hl, bc diff --git a/engine/overworld/npc_movement.asm b/engine/overworld/npc_movement.asm index bcc47a20..1fb8e63a 100644 --- a/engine/overworld/npc_movement.asm +++ b/engine/overworld/npc_movement.asm @@ -274,14 +274,14 @@ WillObjectBumpIntoSomeoneElse: ld e, [hl] jr IsNPCAtCoord -Function70f4: ; unreferenced +IsObjectFacingSomeoneElse: ; unreferenced ldh a, [hMapObjectIndexBuffer] call GetObjectStruct - call .CheckWillBeFacingNPC + call .GetFacingCoords call IsNPCAtCoord ret -.CheckWillBeFacingNPC: +.GetFacingCoords: ld hl, OBJECT_NEXT_MAP_X add hl, bc ld d, [hl] @@ -289,12 +289,13 @@ Function70f4: ; unreferenced add hl, bc ld e, [hl] call GetSpriteDirection - and a + and a ; OW_DOWN? jr z, .down cp OW_UP jr z, .up cp OW_LEFT jr z, .left + ; OW_RIGHT inc d ret @@ -326,32 +327,31 @@ IsNPCAtCoord: ld hl, OBJECT_PALETTE add hl, bc bit BIG_OBJECT_F, [hl] - jr z, .got - + jr z, .not_big call WillObjectIntersectBigObject - jr nc, .ok - jr .ok2 + jr nc, .check_current_coords + jr .continue -.got +.not_big ld hl, OBJECT_NEXT_MAP_X add hl, bc ld a, [hl] cp d - jr nz, .ok + jr nz, .check_current_coords ld hl, OBJECT_NEXT_MAP_Y add hl, bc ld a, [hl] cp e - jr nz, .ok + jr nz, .check_current_coords -.ok2 +.continue ldh a, [hMapObjectIndexBuffer] ld l, a ldh a, [hObjectStructIndexBuffer] cp l - jr nz, .setcarry + jr nz, .yes -.ok +.check_current_coords ld hl, OBJECT_MAP_X add hl, bc ld a, [hl] @@ -366,7 +366,7 @@ IsNPCAtCoord: ld l, a ldh a, [hObjectStructIndexBuffer] cp l - jr nz, .setcarry + jr nz, .yes .next ld hl, OBJECT_LENGTH @@ -380,7 +380,7 @@ IsNPCAtCoord: and a ret -.setcarry +.yes scf ret @@ -473,7 +473,7 @@ IsObjectMovingOffEdgeOfScreen: scf ret -Function71f2: ; unreferenced +IsNPCAtPlayerCoord: ; unreferenced ld a, [wPlayerStandingMapX] ld d, a ld a, [wPlayerStandingMapY] @@ -484,16 +484,17 @@ Function71f2: ; unreferenced ldh [hObjectStructIndexBuffer], a call DoesObjectHaveASprite jr z, .next + ld hl, OBJECT_MOVEMENTTYPE add hl, bc ld a, [hl] cp SPRITEMOVEDATA_BIGDOLLSYM - jr nz, .not_snorlax + jr nz, .not_big call WillObjectIntersectBigObject jr c, .yes jr .next -.not_snorlax +.not_big ld hl, OBJECT_NEXT_MAP_Y add hl, bc ld a, [hl] diff --git a/engine/overworld/overworld.asm b/engine/overworld/overworld.asm index 43465f73..0d285d2a 100644 --- a/engine/overworld/overworld.asm +++ b/engine/overworld/overworld.asm @@ -433,21 +433,22 @@ endr .done: ret -Function1438a: ; unreferenced +GetUsedSpriteTileB: ; unreferenced ld a, c jr GetUsedSprite -Function1438d: ; unreferenced +GetUsedSpriteFirst: ; unreferenced ld a, c - ld b, 0 + ld b, $00 jr GetUsedSprite -Function14392: ; unreferenced +GetUsedSpriteSecond: ; unreferenced ld a, c - ld b, SPRITE_GFX_LIST_CAPACITY + ld b, $0c jr GetUsedSprite GetUsedSprite: +; Input: b = tile id, c = index push bc ld a, c ldh [hUsedSpriteIndex], a diff --git a/engine/pokemon/bills_pc_top.asm b/engine/pokemon/bills_pc_top.asm index 3428d038..e4d82e41 100644 --- a/engine/pokemon/bills_pc_top.asm +++ b/engine/pokemon/bills_pc_top.asm @@ -139,7 +139,7 @@ BillsPC_DepositMenu: and a ret -Functione4ed: ; unreferenced +BillsPC_Deposit_CheckPartySize: ; unreferenced ld a, [wPartyCount] and a jr z, .no_mon @@ -206,7 +206,7 @@ BillsPC_WithdrawMenu: and a ret -Functione548: ; unreferenced +BillsPC_Withdraw_CheckPartySize: ; unreferenced ld a, [wPartyCount] cp PARTY_LENGTH jr nc, .party_full diff --git a/engine/pokemon/mail_2.asm b/engine/pokemon/mail_2.asm index 0ddf8242..c728b533 100644 --- a/engine/pokemon/mail_2.asm +++ b/engine/pokemon/mail_2.asm @@ -690,7 +690,8 @@ MailGFX_PlaceMessage: .place_author jp PlaceString -Functionbb4c5: ; unreferenced +InvertBytes: ; unreferenced +; invert bc bytes starting at hl .loop ld a, [hl] xor $ff diff --git a/engine/printer/printer.asm b/engine/printer/printer.asm index 648b0168..a6e0f956 100644 --- a/engine/printer/printer.asm +++ b/engine/printer/printer.asm @@ -571,7 +571,9 @@ PlacePrinterStatusString: ld [wPrinterStatus], a ret -Function847b9: ; unreferenced +PlacePrinterStatusStringBorderless: ; unreferenced +; Similar to PlacePrinterStatusString, but with different hlcoords +; and ClearBox instead of TextBox. ld a, [wPrinterStatus] and a ret z diff --git a/engine/rtc/print_hours_mins.asm b/engine/rtc/print_hours_mins.asm index 149e8cb1..83d23736 100644 --- a/engine/rtc/print_hours_mins.asm +++ b/engine/rtc/print_hours_mins.asm @@ -1,9 +1,10 @@ Function1c0a0d: ; unreferenced ; Debug function? +; Input: bc = value, de = destination ld a, b ld b, c ld c, a - push bc + push bc ; de points to this on the stack for PrintNum push de ld hl, sp+2 ld d, h diff --git a/engine/rtc/timeset.asm b/engine/rtc/timeset.asm index 4cdfc41b..bcf58bad 100644 --- a/engine/rtc/timeset.asm +++ b/engine/rtc/timeset.asm @@ -193,7 +193,7 @@ DisplayHourOClock: pop hl ret -Function907ba: ; unreferenced +DisplayHoursMinutesWithMinString: ; unreferenced ld h, d ld l, e push hl |