diff options
| author | Rangi <remy.oukaour+rangi42@gmail.com> | 2020-07-07 11:30:10 -0400 | 
|---|---|---|
| committer | Rangi <remy.oukaour+rangi42@gmail.com> | 2020-07-07 11:30:10 -0400 | 
| commit | 13129459f11e73df8c556f0c02cd4fca7266a346 (patch) | |
| tree | f0157c5ba3e66a48eba01fef6ce7283f1dece57a /engine | |
| parent | 45ed05decf330faab4503fe8fecadc54698c9724 (diff) | |
Sync coordinate macros with pokecrystal
Diffstat (limited to 'engine')
59 files changed, 532 insertions, 532 deletions
| diff --git a/engine/battle/animations.asm b/engine/battle/animations.asm index f19f1f4f..9f7b728a 100755 --- a/engine/battle/animations.asm +++ b/engine/battle/animations.asm @@ -682,7 +682,7 @@ DoBallTossSpecialEffects:  	cp 1  	ret nz  .moveGhostMarowakLeft -	coord hl, 17, 0 +	hlcoord 17, 0  	ld de, 20  	lb bc, 7, 7  .loop @@ -781,7 +781,7 @@ DoExplodeSpecialEffects:  	cp 1 ; is it the end of the subanimation?  	jr nz, FlashScreenEveryFourFrameBlocks  ; if it's the end of the subanimation, make the attacking pokemon disappear -	coord hl, 1, 5 +	hlcoord 1, 5  	jp AnimationHideMonPic ; make pokemon disappear  ; flashes the screen when subanimation counter is 1 modulo 4 @@ -1135,12 +1135,12 @@ AnimationSlideMonUp:  	ld c, 7  	ldh a, [hWhoseTurn]  	and a -	coord hl, 1, 6 -	coord de, 1, 5 +	hlcoord 1, 6 +	decoord 1, 5  	ld a, $30  	jr z, .next -	coord hl, 12, 1 -	coord de, 12, 0 +	hlcoord 12, 1 +	decoord 12, 0  	ld a, $ff  .next  	ld [wSlideMonUpBottomRowLeftTile], a @@ -1203,9 +1203,9 @@ _AnimationSlideMonUp:  ; Fill in the bottom row of the mon pic with the next row's tile IDs.  	ldh a, [hWhoseTurn]  	and a -	coord hl, 1, 11 +	hlcoord 1, 11  	jr z, .next -	coord hl, 12, 6 +	hlcoord 12, 6  .next  	ld a, [wSlideMonUpBottomRowLeftTile]  	inc a @@ -1372,11 +1372,11 @@ AnimationShakeBackAndForth:  ; The mon's sprite disappears after this animation.  	ldh a, [hWhoseTurn]  	and a -	coord hl, 0, 5 -	coord de, 2, 5 +	hlcoord 0, 5 +	decoord 2, 5  	jr z, .next -	coord hl, 11, 0 -	coord de, 13, 0 +	hlcoord 11, 0 +	decoord 13, 0  .next  	xor a @@ -1420,9 +1420,9 @@ AnimationMoveMonHorizontally:  	call AnimationHideMonPic  	ldh a, [hWhoseTurn]  	and a -	coord hl, 2, 5 +	hlcoord 2, 5  	jr z, .next -	coord hl, 11, 0 +	hlcoord 11, 0  .next  	xor a  	push hl @@ -1533,12 +1533,12 @@ AnimationSquishMonPic:  	ldh a, [hWhoseTurn]  	and a  	jr z, .playerTurn -	coord hl, 16, 0 -	coord de, 14, 0 +	hlcoord 16, 0 +	decoord 14, 0  	jr .next  .playerTurn -	coord hl, 5, 5 -	coord de, 3, 5 +	hlcoord 5, 5 +	decoord 3, 5  .next  	push de  	xor a ; left @@ -1746,10 +1746,10 @@ _AnimationSlideMonOff:  	ldh a, [hWhoseTurn]  	and a  	jr z, .playerTurn -	coord hl, 12, 0 +	hlcoord 12, 0  	jr .next  .playerTurn -	coord hl, 0, 5 +	hlcoord 0, 5  .next  	ld d, 8 ; d's value is unused  .slideLoop ; iterates once for each time the pic slides by one tile @@ -1996,7 +1996,7 @@ ChangeMonPic:  	xor a  	ld [wSpriteFlipped], a  	call GetMonHeader -	coord hl, 12, 0 +	hlcoord 12, 0  	call LoadFrontSpriteByMonIndex  	jr .done  .playerTurn @@ -2064,7 +2064,7 @@ ClearMonPicFromTileMap:  	push bc  	ld e, a  	ld d, 0 -	coord hl, 0, 0 +	hlcoord 0, 0  	add hl, de  	lb bc, 7, 7  	call ClearScreenArea @@ -2086,7 +2086,7 @@ GetMonSpriteTileMapPointerFromRowCount:  .enemyTurn  	ld a, 12  .next -	coord hl, 0, 0 +	hlcoord 0, 0  	ld e, a  	ld d, 0  	add hl, de diff --git a/engine/battle/battle_transitions.asm b/engine/battle/battle_transitions.asm index 8a22e70f..e563855d 100644 --- a/engine/battle/battle_transitions.asm +++ b/engine/battle/battle_transitions.asm @@ -181,7 +181,7 @@ BattleTransition_Spiral:  	call BattleTransition_InwardSpiral  	jr .done  .outwardSpiral -	coord hl, 10, 10 +	hlcoord 10, 10  	ld a, $3  	ld [wOutwardSpiralCurrentDirection], a  	ld a, l @@ -210,7 +210,7 @@ BattleTransition_Spiral:  BattleTransition_InwardSpiral:  	ld a, 7  	ld [wInwardSpiralUpdateScreenCounter], a -	coord hl, 0, 0 +	hlcoord 0, 0  	ld c, SCREEN_HEIGHT - 1  	ld de, SCREEN_WIDTH  	call BattleTransition_InwardSpiral_ @@ -350,20 +350,20 @@ BattleTransition_Shrink:  	push bc  	xor a  	ldh [hAutoBGTransferEnabled], a -	coord hl, 0, 7 -	coord de, 0, 8 +	hlcoord 0, 7 +	decoord 0, 8  	ld bc, -SCREEN_WIDTH * 2  	call BattleTransition_CopyTiles1 -	coord hl, 0, 10 -	coord de, 0, 9 +	hlcoord 0, 10 +	decoord 0, 9  	ld bc, SCREEN_WIDTH * 2  	call BattleTransition_CopyTiles1 -	coord hl, 8, 0 -	coord de, 9, 0 +	hlcoord 8, 0 +	decoord 9, 0  	ld bc, -2  	call BattleTransition_CopyTiles2 -	coord hl, 11, 0 -	coord de, 10, 0 +	hlcoord 11, 0 +	decoord 10, 0  	ld bc, 2  	call BattleTransition_CopyTiles2  	ld a, $1 @@ -384,20 +384,20 @@ BattleTransition_Split:  	ldh [hAutoBGTransferEnabled], a  .loop  	push bc -	coord hl, 0, 16 -	coord de, 0, 17 +	hlcoord 0, 16 +	decoord 0, 17  	ld bc, -SCREEN_WIDTH * 2  	call BattleTransition_CopyTiles1 -	coord hl, 0, 1 -	coord de, 0, 0 +	hlcoord 0, 1 +	decoord 0, 0  	ld bc, SCREEN_WIDTH * 2  	call BattleTransition_CopyTiles1 -	coord hl, 18, 0 -	coord de, 19, 0 +	hlcoord 18, 0 +	decoord 19, 0  	ld bc, -2  	call BattleTransition_CopyTiles2 -	coord hl, 1, 0 -	coord de, 0, 0 +	hlcoord 1, 0 +	decoord 0, 0  	ld bc, 2  	call BattleTransition_CopyTiles2  	call BattleTransition_TransferDelay3 @@ -493,8 +493,8 @@ BattleTransition_CopyTiles2:  ; used for high level wild dungeon battles  BattleTransition_VerticalStripes:  	ld c, SCREEN_HEIGHT -	coord hl, 0, 0 -	coord de, 1, 17 +	hlcoord 0, 0 +	decoord 1, 17  	xor a  	ldh [hAutoBGTransferEnabled], a  .loop @@ -532,8 +532,8 @@ BattleTransition_VerticalStripes_:  ; used for low level wild dungeon battles  BattleTransition_HorizontalStripes:  	ld c, SCREEN_WIDTH -	coord hl, 0, 0 -	coord de, 19, 1 +	hlcoord 0, 0 +	decoord 19, 1  	xor a  	ldh [hAutoBGTransferEnabled], a  .loop @@ -654,84 +654,84 @@ BattleTransition_Circle_Sub2:  BattleTransition_HalfCircle1:  	db $01  	dw BattleTransition_CircleData1 -	dwCoord 18, 6 +	dwcoord 18, 6  	db $01  	dw BattleTransition_CircleData2 -	dwCoord 19, 3 +	dwcoord 19, 3  	db $01  	dw BattleTransition_CircleData3 -	dwCoord 18, 0 +	dwcoord 18, 0  	db $01  	dw BattleTransition_CircleData4 -	dwCoord 14, 0 +	dwcoord 14, 0  	db $01  	dw BattleTransition_CircleData5 -	dwCoord 10, 0 +	dwcoord 10, 0  	db $00  	dw BattleTransition_CircleData5 -	dwCoord 9, 0 +	dwcoord 9, 0  	db $00  	dw BattleTransition_CircleData4 -	dwCoord 5, 0 +	dwcoord 5, 0  	db $00  	dw BattleTransition_CircleData3 -	dwCoord 1, 0 +	dwcoord 1, 0  	db $00  	dw BattleTransition_CircleData2 -	dwCoord 0, 3 +	dwcoord 0, 3  	db $00  	dw BattleTransition_CircleData1 -	dwCoord 1, 6 +	dwcoord 1, 6  BattleTransition_HalfCircle2:  	db $00  	dw BattleTransition_CircleData1 -	dwCoord 1, 11 +	dwcoord 1, 11  	db $00  	dw BattleTransition_CircleData2 -	dwCoord 0, 14 +	dwcoord 0, 14  	db $00  	dw BattleTransition_CircleData3 -	dwCoord 1, 17 +	dwcoord 1, 17  	db $00  	dw BattleTransition_CircleData4 -	dwCoord 5, 17 +	dwcoord 5, 17  	db $00  	dw BattleTransition_CircleData5 -	dwCoord 9, 17 +	dwcoord 9, 17  	db $01  	dw BattleTransition_CircleData5 -	dwCoord 10, 17 +	dwcoord 10, 17  	db $01  	dw BattleTransition_CircleData4 -	dwCoord 14, 17 +	dwcoord 14, 17  	db $01  	dw BattleTransition_CircleData3 -	dwCoord 18, 17 +	dwcoord 18, 17  	db $01  	dw BattleTransition_CircleData2 -	dwCoord 19, 14 +	dwcoord 19, 14  	db $01  	dw BattleTransition_CircleData1 -	dwCoord 18, 11 +	dwcoord 18, 11  BattleTransition_Circle_Sub3:  	push hl diff --git a/engine/battle/core.asm b/engine/battle/core.asm index 9a66265c..859f30d5 100755 --- a/engine/battle/core.asm +++ b/engine/battle/core.asm @@ -11,7 +11,7 @@ SlidePlayerAndEnemySilhouettesOnScreen:  	ld a, MESSAGE_BOX ; the usual text box at the bottom of the screen  	ld [wTextBoxID], a  	call DisplayTextBoxID -	coord hl, 1, 5 +	hlcoord 1, 5  	lb bc, 3, 7  	call ClearScreenArea  	call DisableLCD @@ -27,7 +27,7 @@ SlidePlayerAndEnemySilhouettesOnScreen:  	or c  	jr nz, .clearBackgroundLoop  ; copy the work RAM tile map to VRAM -	coord hl, 0, 0 +	hlcoord 0, 0  	ld de, vBGMap0  	ld b, 18 ; number of rows  .copyRowLoop @@ -86,7 +86,7 @@ SlidePlayerAndEnemySilhouettesOnScreen:  	ldh [hAutoBGTransferEnabled], a  	ld a, $31  	ldh [hStartTileID], a -	coord hl, 1, 5 +	hlcoord 1, 5  	predef CopyUncompressedPicToTilemap  	xor a  	ldh [hWY], a @@ -232,7 +232,7 @@ StartBattle:  	ld [wcf91], a  	ld [wBattleMonSpecies2], a  	call LoadScreenTilesFromBuffer1 -	coord hl, 1, 5 +	hlcoord 1, 5  	ld a, $9  	call SlideTrainerPicOffScreen  	call SaveScreenTilesToBuffer1 @@ -666,12 +666,12 @@ HandlePoisonBurnLeechSeed_IncreaseEnemyHP:  	ret  UpdateCurMonHPBar: -	coord hl, 10, 9    ; tile pointer to player HP bar +	hlcoord 10, 9    ; tile pointer to player HP bar  	ldh a, [hWhoseTurn]  	and a  	ld a, $1  	jr z, .playersTurn -	coord hl, 2, 2    ; tile pointer to enemy HP bar +	hlcoord 2, 2    ; tile pointer to enemy HP bar  	xor a  .playersTurn  	push bc @@ -767,10 +767,10 @@ FaintEnemyPokemon:  	ld hl, wPlayerUsedMove  	ld [hli], a  	ld [hl], a -	coord hl, 12, 5 -	coord de, 12, 6 +	hlcoord 12, 5 +	decoord 12, 6  	call SlideDownFaintedMonPic -	coord hl, 0, 0 +	hlcoord 0, 0  	lb bc, 4, 11  	call ClearScreenArea  	ld a, [wIsInBattle] @@ -1021,11 +1021,11 @@ RemoveFaintedPlayerMon:  	ld [hl], a  	ld [wBattleMonStatus], a  	call ReadPlayerMonCurHPAndStatus -	coord hl, 9, 7 +	hlcoord 9, 7  	lb bc, 5, 11  	call ClearScreenArea -	coord hl, 1, 10 -	coord de, 1, 11 +	hlcoord 1, 10 +	decoord 1, 11  	call SlideDownFaintedMonPic  	ld a, $1  	ld [wBattleResult], a @@ -1059,7 +1059,7 @@ DoUseNextMonDialogue:  	ld hl, UseNextMonText  	call PrintText  .displayYesNoBox -	coord hl, 13, 9 +	hlcoord 13, 9  	lb bc, 10, 14  	ld a, TWO_OPTION_MENU  	ld [wTextBoxID], a @@ -1136,7 +1136,7 @@ HandlePlayerBlackOut:  	ld a, [wCurOpponent]  	cp OPP_SONY1  	jr nz, .notSony1Battle -	coord hl, 0, 0  ; sony 1 battle +	hlcoord 0, 0  ; sony 1 battle  	lb bc, 8, 21  	call ClearScreenArea  	call ScrollTrainerPicAfterBattle @@ -1306,7 +1306,7 @@ EnemySendOutFirstMon:  	ld [wAICount], a  	ld hl, wPlayerBattleStatus1  	res 5, [hl] -	coord hl, 18, 0 +	hlcoord 18, 0  	ld a, 8  	call SlideTrainerPicOffScreen  	call PrintEmptyString @@ -1376,7 +1376,7 @@ EnemySendOutFirstMon:  	jr nz, .next4  	ld hl, TrainerAboutToUseText  	call PrintText -	coord hl, 0, 7 +	hlcoord 0, 7  	lb bc, 8, 1  	ld a, TWO_OPTION_MENU  	ld [wTextBoxID], a @@ -1411,7 +1411,7 @@ EnemySendOutFirstMon:  	call LoadScreenTilesFromBuffer1  .next4  	call ClearSprites -	coord hl, 0, 0 +	hlcoord 0, 0  	lb bc, 4, 11  	call ClearScreenArea  	ld b, SET_PAL_BATTLE @@ -1427,7 +1427,7 @@ EnemySendOutFirstMon:  	call LoadMonFrontSprite  	ld a, -$31  	ldh [hStartTileID], a -	coord hl, 15, 6 +	hlcoord 15, 6  	predef AnimateSendingOutMon  	ld a, [wEnemyMonSpecies2]  	call PlayCry @@ -1757,7 +1757,7 @@ SendOutMon:  	ldh [hWhoseTurn], a  	ld a, POOF_ANIM  	call PlayMoveAnimation -	coord hl, 4, 11 +	hlcoord 4, 11  	predef AnimateSendingOutMon  	ld a, [wcf91]  	call PlayCry @@ -1766,10 +1766,10 @@ SendOutMon:  ; show 2 stages of the player mon getting smaller before disappearing  AnimateRetreatingPlayerMon: -	coord hl, 1, 5 +	hlcoord 1, 5  	lb bc, 7, 7  	call ClearScreenArea -	coord hl, 3, 7 +	hlcoord 3, 7  	lb bc, 5, 5  	xor a  	ld [wDownscaledMonSize], a @@ -1778,7 +1778,7 @@ AnimateRetreatingPlayerMon:  	ld c, 4  	call DelayFrames  	call .clearScreenArea -	coord hl, 4, 9 +	hlcoord 4, 9  	lb bc, 3, 3  	ld a, 1  	ld [wDownscaledMonSize], a @@ -1788,9 +1788,9 @@ AnimateRetreatingPlayerMon:  	call Delay3  	call .clearScreenArea  	ld a, $4c -	Coorda 5, 11 +	ldcoord_a 5, 11  .clearScreenArea -	coord hl, 1, 5 +	hlcoord 1, 5  	lb bc, 7, 7  	jp ClearScreenArea @@ -1813,14 +1813,14 @@ DrawHUDsAndHPBars:  DrawPlayerHUDAndHPBar:  	xor a  	ldh [hAutoBGTransferEnabled], a -	coord hl, 9, 7 +	hlcoord 9, 7  	lb bc, 5, 11  	call ClearScreenArea  	callfar PlacePlayerHUDTiles -	coord hl, 18, 9 +	hlcoord 18, 9  	ld [hl], $73  	ld de, wBattleMonNick -	coord hl, 10, 7 +	hlcoord 10, 7  	call CenterMonName  	call PlaceString  	ld hl, wBattleMonSpecies @@ -1831,7 +1831,7 @@ DrawPlayerHUDAndHPBar:  	ld de, wLoadedMonLevel  	ld bc, wBattleMonPP - wBattleMonLevel  	call CopyData -	coord hl, 14, 8 +	hlcoord 14, 8  	push hl  	inc hl  	ld de, wLoadedMonStatus @@ -1842,7 +1842,7 @@ DrawPlayerHUDAndHPBar:  .doNotPrintLevel  	ld a, [wLoadedMonSpecies]  	ld [wcf91], a -	coord hl, 10, 9 +	hlcoord 10, 9  	predef DrawHP  	ld a, $1  	ldh [hAutoBGTransferEnabled], a @@ -1874,15 +1874,15 @@ DrawPlayerHUDAndHPBar:  DrawEnemyHUDAndHPBar:  	xor a  	ldh [hAutoBGTransferEnabled], a -	coord hl, 0, 0 +	hlcoord 0, 0  	lb bc, 4, 12  	call ClearScreenArea  	callfar PlaceEnemyHUDTiles  	ld de, wEnemyMonNick -	coord hl, 1, 0 +	hlcoord 1, 0  	call CenterMonName  	call PlaceString -	coord hl, 4, 1 +	hlcoord 4, 1  	push hl  	inc hl  	ld de, wEnemyMonStatus @@ -1955,7 +1955,7 @@ DrawEnemyHUDAndHPBar:  .drawHPBar  	xor a  	ld [wHPBarType], a -	coord hl, 2, 2 +	hlcoord 2, 2  	call DrawHPBar  	ld a, $1  	ldh [hAutoBGTransferEnabled], a @@ -2030,12 +2030,12 @@ DisplayBattleMenu::  	ld bc, NAME_LENGTH  	call CopyData  ; the following simulates the keystrokes by drawing menus on screen -	coord hl, 9, 14 +	hlcoord 9, 14  	ld [hl], "▶"  	ld c, 80  	call DelayFrames  	ld [hl], " " -	coord hl, 9, 16 +	hlcoord 9, 16  	ld [hl], "▶"  	ld c, 50  	call DelayFrames @@ -2060,14 +2060,14 @@ DisplayBattleMenu::  	ld a, " "  	jr z, .safariLeftColumn  ; put cursor in left column for normal battle menu (i.e. when it's not a Safari battle) -	Coorda 15, 14 ; clear upper cursor position in right column -	Coorda 15, 16 ; clear lower cursor position in right column +	ldcoord_a 15, 14 ; clear upper cursor position in right column +	ldcoord_a 15, 16 ; clear lower cursor position in right column  	ld b, $9 ; top menu item X  	jr .leftColumn_WaitForInput  .safariLeftColumn -	Coorda 13, 14 -	Coorda 13, 16 -	coord hl, 7, 14 +	ldcoord_a 13, 14 +	ldcoord_a 13, 16 +	hlcoord 7, 14  	ld de, wNumSafariBalls  	lb bc, 1, 2  	call PrintNumber @@ -2093,14 +2093,14 @@ DisplayBattleMenu::  	ld a, " "  	jr z, .safariRightColumn  ; put cursor in right column for normal battle menu (i.e. when it's not a Safari battle) -	Coorda 9, 14 ; clear upper cursor position in left column -	Coorda 9, 16 ; clear lower cursor position in left column +	ldcoord_a 9, 14 ; clear upper cursor position in left column +	ldcoord_a 9, 16 ; clear lower cursor position in left column  	ld b, $f ; top menu item X  	jr .rightColumn_WaitForInput  .safariRightColumn -	Coorda 1, 14 ; clear upper cursor position in left column -	Coorda 1, 16 ; clear lower cursor position in left column -	coord hl, 7, 14 +	ldcoord_a 1, 14 ; clear upper cursor position in left column +	ldcoord_a 1, 16 ; clear lower cursor position in left column +	hlcoord 7, 14  	ld de, wNumSafariBalls  	lb bc, 1, 2  	call PrintNumber @@ -2321,7 +2321,7 @@ PartyMenuOrRockOrRun:  	call GBPalNormal  	jp DisplayBattleMenu  .partyMonDeselected -	coord hl, 11, 11 +	hlcoord 11, 11  	ld bc, 6 * SCREEN_WIDTH + 9  	ld a, " "  	call FillMemory @@ -2483,18 +2483,18 @@ MoveSelectionMenu:  	ret z  	ld hl, wBattleMonMoves  	call .loadmoves -	coord hl, 4, 12 +	hlcoord 4, 12  	ld b, 4  	ld c, 14  	di ; out of pure coincidence, it is possible for vblank to occur between the di and ei  	   ; so it is necessary to put the di ei block to not cause tearing  	call TextBoxBorder -	coord hl, 4, 12 +	hlcoord 4, 12  	ld [hl], $7a -	coord hl, 10, 12 +	hlcoord 10, 12  	ld [hl], $7e  	ei -	coord hl, 6, 13 +	hlcoord 6, 13  	call .writemoves  	ld b, $5  	ld a, $c @@ -2502,11 +2502,11 @@ MoveSelectionMenu:  .mimicmenu  	ld hl, wEnemyMonMoves  	call .loadmoves -	coord hl, 0, 7 +	hlcoord 0, 7  	ld b, 4  	ld c, 14  	call TextBoxBorder -	coord hl, 2, 8 +	hlcoord 2, 8  	call .writemoves  	ld b, $1  	ld a, $7 @@ -2517,11 +2517,11 @@ MoveSelectionMenu:  	ld bc, wPartyMon2 - wPartyMon1  	call AddNTimes  	call .loadmoves -	coord hl, 4, 7 +	hlcoord 4, 7  	ld b, 4  	ld c, 14  	call TextBoxBorder -	coord hl, 6, 8 +	hlcoord 6, 8  	call .writemoves  	ld b, $5  	ld a, $7 @@ -2577,7 +2577,7 @@ SelectMenuItem:  	jr z, .battleselect  	dec a  	jr nz, .select -	coord hl, 1, 14 +	hlcoord 1, 14  	ld de, WhichTechniqueString  	call PlaceString  	jr .select @@ -2589,7 +2589,7 @@ SelectMenuItem:  	ld a, [wMenuItemToSwap]  	and a  	jr z, .select -	coord hl, 5, 13 +	hlcoord 5, 13  	dec a  	ld bc, SCREEN_WIDTH  	call AddNTimes @@ -2826,7 +2826,7 @@ SwapMovesInMenu:  PrintMenuItem:  	xor a  	ldh [hAutoBGTransferEnabled], a -	coord hl, 0, 8 +	hlcoord 0, 8  	ld b, 3  	ld c, 9  	call TextBoxBorder @@ -2839,7 +2839,7 @@ PrintMenuItem:  	ld a, [wCurrentMenuItem]  	cp b  	jr nz, .notDisabled -	coord hl, 1, 10 +	hlcoord 1, 10  	ld de, DisabledText  	call PlaceString  	jr .moveDisabled @@ -2871,23 +2871,23 @@ PrintMenuItem:  	and $3f  	ld [wcd6d], a  ; print TYPE/<type> and <curPP>/<maxPP> -	coord hl, 1, 9 +	hlcoord 1, 9  	ld de, TypeText  	call PlaceString -	coord hl, 7, 11 +	hlcoord 7, 11  	ld [hl], "/" -	coord hl, 5, 9 +	hlcoord 5, 9  	ld [hl], "/" -	coord hl, 5, 11 +	hlcoord 5, 11  	ld de, wcd6d  	lb bc, 1, 2  	call PrintNumber -	coord hl, 8, 11 +	hlcoord 8, 11  	ld de, wMaxPP  	lb bc, 1, 2  	call PrintNumber  	call GetCurrentMove -	coord hl, 2, 10 +	hlcoord 2, 10  	predef PrintMoveType  .moveDisabled  	ld a, $1 @@ -4822,7 +4822,7 @@ ApplyDamageToEnemyPokemon:  	ld [wHPBarNewHP+1], a  	ld a, [hl]  	ld [wHPBarNewHP], a -	coord hl, 2, 2 +	hlcoord 2, 2  	xor a  	ld [wHPBarType], a  	predef UpdateHPBar2 ; animate the HP bar shortening @@ -4940,7 +4940,7 @@ ApplyDamageToPlayerPokemon:  	ld [wHPBarMaxHP+1], a  	ld a, [hl]  	ld [wHPBarMaxHP], a -	coord hl, 10, 9 +	hlcoord 10, 9  	ld a, $01  	ld [wHPBarType], a  	predef UpdateHPBar2 ; animate the HP bar shortening @@ -6354,7 +6354,7 @@ LoadPlayerBackPic:  	ld [MBC1SRamEnable], a  	ld a, $31  	ldh [hStartTileID], a -	coord hl, 1, 5 +	hlcoord 1, 5  	predef_jump CopyUncompressedPicToTilemap  ; does nothing since no stats are ever selected (barring glitches) @@ -6770,7 +6770,7 @@ InitBattleCommon:  	ldh [hStartTileID], a  	dec a  	ld [wAICount], a -	coord hl, 12, 0 +	hlcoord 12, 0  	predef CopyUncompressedPicToTilemap  	ld a, $ff  	ld [wEnemyMonPartyPos], a @@ -6824,7 +6824,7 @@ InitWildBattle:  	xor a  	ld [wTrainerClass], a  	ldh [hStartTileID], a -	coord hl, 12, 0 +	hlcoord 12, 0  	predef CopyUncompressedPicToTilemap  ; common code that executes after init battle code specific to trainer or wild battles @@ -6846,10 +6846,10 @@ _InitBattleCommon:  	ld a, $9c  	ldh [hAutoBGTransferDest + 1], a  	call LoadScreenTilesFromBuffer1 -	coord hl, 9, 7 +	hlcoord 9, 7  	lb bc, 5, 10  	call ClearScreenArea -	coord hl, 1, 0 +	hlcoord 1, 0  	lb bc, 4, 10  	call ClearScreenArea  	call ClearSprites @@ -6993,7 +6993,7 @@ LoadMonBackPic:  ; been loaded with GetMonHeader.  	ld a, [wBattleMonSpecies2]  	ld [wcf91], a -	coord hl, 1, 5 +	hlcoord 1, 5  	ld b, 7  	ld c, 8  	call ClearScreenArea diff --git a/engine/battle/draw_hud_pokeball_gfx.asm b/engine/battle/draw_hud_pokeball_gfx.asm index c0a91949..8cd9528d 100644 --- a/engine/battle/draw_hud_pokeball_gfx.asm +++ b/engine/battle/draw_hud_pokeball_gfx.asm @@ -121,7 +121,7 @@ PlacePlayerHUDTiles:  	ld de, wHUDGraphicsTiles  	ld bc, $3  	call CopyData -	coord hl, 18, 10 +	hlcoord 18, 10  	ld de, -1  	jr PlaceHUDTiles @@ -136,7 +136,7 @@ PlaceEnemyHUDTiles:  	ld de, wHUDGraphicsTiles  	ld bc, $3  	call CopyData -	coord hl, 1, 2 +	hlcoord 1, 2  	ld de, $1  	jr PlaceHUDTiles diff --git a/engine/battle/end_of_battle.asm b/engine/battle/end_of_battle.asm index aa96f31d..bd4a1901 100755 --- a/engine/battle/end_of_battle.asm +++ b/engine/battle/end_of_battle.asm @@ -19,7 +19,7 @@ EndOfBattle:  	jr z, .placeWinOrLoseString  	ld de, DrawText  .placeWinOrLoseString -	coord hl, 6, 8 +	hlcoord 6, 8  	call PlaceString  	ld c, 200  	call DelayFrames diff --git a/engine/battle/ghost_marowak_anim.asm b/engine/battle/ghost_marowak_anim.asm index 9c47fd53..7405c40b 100644 --- a/engine/battle/ghost_marowak_anim.asm +++ b/engine/battle/ghost_marowak_anim.asm @@ -4,7 +4,7 @@ MarowakAnim:  	ldh [rOBP1], a  	call CopyMonPicFromBGToSpriteVRAM ; cover the BG ghost pic with a sprite ghost pic that looks the same  ; now that the ghost pic is being displayed using sprites, clear the ghost pic from the BG tilemap -	coord hl, 12, 0 +	hlcoord 12, 0  	lb bc, 7, 7  	call ClearScreenArea  	call Delay3 diff --git a/engine/battle/link_battle_versus_text.asm b/engine/battle/link_battle_versus_text.asm index 22fec0f3..29c11356 100644 --- a/engine/battle/link_battle_versus_text.asm +++ b/engine/battle/link_battle_versus_text.asm @@ -1,18 +1,18 @@  ; display "[player] VS [enemy]" text box with pokeballs representing their parties next to the names  DisplayLinkBattleVersusTextBox:  	call LoadTextBoxTilePatterns -	coord hl, 3, 4 +	hlcoord 3, 4  	ld b, 7  	ld c, 12  	call TextBoxBorder -	coord hl, 4, 5 +	hlcoord 4, 5  	ld de, wPlayerName  	call PlaceString -	coord hl, 4, 10 +	hlcoord 4, 10  	ld de, wLinkEnemyTrainerName  	call PlaceString  ; place bold "VS" tiles between the names -	coord hl, 9, 8 +	hlcoord 9, 8  	ld a, $69  	ld [hli], a  	ld [hl], $6a diff --git a/engine/battle/move_effects/drain_hp.asm b/engine/battle/move_effects/drain_hp.asm index e7b241f6..04a585cc 100644 --- a/engine/battle/move_effects/drain_hp.asm +++ b/engine/battle/move_effects/drain_hp.asm @@ -71,10 +71,10 @@ DrainHPEffect_:  .next  	ldh a, [hWhoseTurn]  	and a -	coord hl, 10, 9 +	hlcoord 10, 9  	ld a, $1  	jr z, .next2 -	coord hl, 2, 2 +	hlcoord 2, 2  	xor a  .next2  	ld [wHPBarType], a diff --git a/engine/battle/move_effects/heal.asm b/engine/battle/move_effects/heal.asm index d12b1ea4..e9fb62a7 100644 --- a/engine/battle/move_effects/heal.asm +++ b/engine/battle/move_effects/heal.asm @@ -89,10 +89,10 @@ HealEffect_:  	call BankswitchEtoF  	ldh a, [hWhoseTurn]  	and a -	coord hl, 10, 9 +	hlcoord 10, 9  	ld a, $1  	jr z, .updateHPBar -	coord hl, 2, 2 +	hlcoord 2, 2  	xor a  .updateHPBar  	ld [wHPBarType], a diff --git a/engine/battle/move_effects/recoil.asm b/engine/battle/move_effects/recoil.asm index aa2a3fed..85110d50 100644 --- a/engine/battle/move_effects/recoil.asm +++ b/engine/battle/move_effects/recoil.asm @@ -53,12 +53,12 @@ RecoilEffect_:  	ld [hli], a  	ld [hl], a  .getHPBarCoords -	coord hl, 10, 9 +	hlcoord 10, 9  	ldh a, [hWhoseTurn]  	and a  	ld a, $1  	jr z, .updateHPBar -	coord hl, 2, 2 +	hlcoord 2, 2  	xor a  .updateHPBar  	ld [wHPBarType], a diff --git a/engine/battle/scroll_draw_trainer_pic.asm b/engine/battle/scroll_draw_trainer_pic.asm index 978fb71a..e19d681a 100644 --- a/engine/battle/scroll_draw_trainer_pic.asm +++ b/engine/battle/scroll_draw_trainer_pic.asm @@ -6,7 +6,7 @@ _ScrollTrainerPicAfterBattle:  	ld b, SET_PAL_BATTLE  	call RunPaletteCommand  	callfar _LoadTrainerPic -	coord hl, 19, 0 +	hlcoord 19, 0  	ld c, $0  .scrollLoop  	inc c diff --git a/engine/battle/trainer_ai.asm b/engine/battle/trainer_ai.asm index ea476538..87bec842 100644 --- a/engine/battle/trainer_ai.asm +++ b/engine/battle/trainer_ai.asm @@ -542,7 +542,7 @@ AIRecoverHP:  AIPrintItemUseAndUpdateHPBar:  	call AIPrintItemUse_ -	coord hl, 2, 2 +	hlcoord 2, 2  	xor a  	ld [wHPBarType], a  	predef UpdateHPBar2 diff --git a/engine/battle/wild_encounters.asm b/engine/battle/wild_encounters.asm index 3d0eb556..e24f9632 100644 --- a/engine/battle/wild_encounters.asm +++ b/engine/battle/wild_encounters.asm @@ -25,7 +25,7 @@ TryDoWildEncounter:  .next  ; determine if wild pokemon can appear in the half-block we're standing in  ; is the bottom right tile (9,9) of the half-block we're standing in a grass/water tile? -	coord hl, 9, 9 +	hlcoord 9, 9  	ld c, [hl]  	ld a, [wGrassTile]  	cp c @@ -64,7 +64,7 @@ TryDoWildEncounter:  ; determine which wild pokemon (grass or water) can appear in the half-block we're standing in  	ld c, [hl]  	ld hl, wGrassMons -	aCoord 8, 9 +	lda_coord 8, 9  	cp $14 ; is the bottom left tile (8,9) of the half-block we're standing in a water tile?  	jr nz, .gotWildEncounterType ; else, it's treated as a grass tile by default  	ld hl, wWaterMons diff --git a/engine/events/cinnabar_lab.asm b/engine/events/cinnabar_lab.asm index aaa0428e..bccc95d1 100755 --- a/engine/events/cinnabar_lab.asm +++ b/engine/events/cinnabar_lab.asm @@ -20,7 +20,7 @@ GiveFossilToCinnabarLab::  	dec l  	ld b, l  	ld c, $d -	coord hl, 0, 0 +	hlcoord 0, 0  	call TextBoxBorder  	call UpdateSprites  	call PrintFossilsInBag @@ -100,7 +100,7 @@ PrintFossilsInBag:  	push hl  	ld [wd11e], a  	call GetItemName -	coord hl, 2, 2 +	hlcoord 2, 2  	ldh a, [hItemCounter]  	ld bc, SCREEN_WIDTH * 2  	call AddNTimes diff --git a/engine/events/diploma.asm b/engine/events/diploma.asm index 95dabab3..3248e152 100755 --- a/engine/events/diploma.asm +++ b/engine/events/diploma.asm @@ -14,7 +14,7 @@ DisplayDiploma::  	ld bc, $10  	ld a, BANK(CircleTile)  	call FarCopyData2 -	coord hl, 0, 0 +	hlcoord 0, 0  	lb bc, 16, 18  	predef Diploma_TextBoxBorder  	ld hl, DiplomaTextPointersAndCoords @@ -35,7 +35,7 @@ DisplayDiploma::  	pop bc  	dec c  	jr nz, .asm_56715 -	coord hl, 10, 4 +	hlcoord 10, 4  	ld de, wPlayerName  	call PlaceString  	farcall DrawPlayerCharacter @@ -85,15 +85,15 @@ UnusedPlayerNameLengthFunc:  DiplomaTextPointersAndCoords:  	dw DiplomaText -	dwCoord 5, 2 +	dwcoord 5, 2  	dw DiplomaPlayer -	dwCoord 3, 4 +	dwcoord 3, 4  	dw DiplomaEmptyText -	dwCoord 15, 4 +	dwcoord 15, 4  	dw DiplomaCongrats -	dwCoord 2, 6 +	dwcoord 2, 6  	dw DiplomaGameFreak -	dwCoord 9, 16 +	dwcoord 9, 16  DiplomaText:  	db CIRCLE_TILE_ID, "Diploma", CIRCLE_TILE_ID, "@" diff --git a/engine/events/hidden_objects/bills_house_pc.asm b/engine/events/hidden_objects/bills_house_pc.asm index 92679d66..a73596b4 100644 --- a/engine/events/hidden_objects/bills_house_pc.asm +++ b/engine/events/hidden_objects/bills_house_pc.asm @@ -84,11 +84,11 @@ BillsHousePokemonList::  .billsPokemonLoop  	ld hl, wd730  	set 6, [hl] -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, 10  	ld c, 9  	call TextBoxBorder -	coord hl, 2, 2 +	hlcoord 2, 2  	ld de, BillsMonListText  	call PlaceString  	ld hl, BillsHousePokemonListText2 diff --git a/engine/events/hidden_objects/book_or_sculpture.asm b/engine/events/hidden_objects/book_or_sculpture.asm index 2f3334b8..e04f4047 100644 --- a/engine/events/hidden_objects/book_or_sculpture.asm +++ b/engine/events/hidden_objects/book_or_sculpture.asm @@ -4,7 +4,7 @@ BookOrSculptureText::  	ld a, [wCurMapTileset]  	cp MANSION ; Celadon Mansion tileset  	jr nz, .ok -	aCoord 8, 6 +	lda_coord 8, 6  	cp $38  	jr nz, .ok  	ld hl, DiglettSculptureText diff --git a/engine/events/hidden_objects/bookshelves.asm b/engine/events/hidden_objects/bookshelves.asm index 23c087cc..b58444af 100644 --- a/engine/events/hidden_objects/bookshelves.asm +++ b/engine/events/hidden_objects/bookshelves.asm @@ -6,7 +6,7 @@ PrintBookshelfText::  ; facing up  	ld a, [wCurMapTileset]  	ld b, a -	aCoord 8, 7 +	lda_coord 8, 7  	ld c, a  	ld hl, BookshelfTileIDs  .loop diff --git a/engine/events/hidden_objects/museum_fossils.asm b/engine/events/hidden_objects/museum_fossils.asm index ef53ed89..5d7e08fd 100644 --- a/engine/events/hidden_objects/museum_fossils.asm +++ b/engine/events/hidden_objects/museum_fossils.asm @@ -42,7 +42,7 @@ DisplayMonFrontSpriteInBox:  	call LoadMonFrontSprite  	ld a, $80  	ldh [hStartTileID], a -	coord hl, 10, 11 +	hlcoord 10, 11  	predef AnimateSendingOutMon  	call WaitForTextScrollButtonPress  	call LoadScreenTilesFromBuffer1 diff --git a/engine/events/hidden_objects/school_blackboard.asm b/engine/events/hidden_objects/school_blackboard.asm index 48b97d73..de4700d4 100644 --- a/engine/events/hidden_objects/school_blackboard.asm +++ b/engine/events/hidden_objects/school_blackboard.asm @@ -26,11 +26,11 @@ LinkCableHelp::  .linkHelpLoop  	ld hl, wd730  	set 6, [hl] -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, 8  	ld c, 13  	call TextBoxBorder -	coord hl, 2, 2 +	hlcoord 2, 2  	ld de, HowToLinkText  	call PlaceString  	ld hl, LinkCableHelpText2 @@ -110,13 +110,13 @@ ViridianSchoolBlackboard::  .blackboardLoop  	ld hl, wd730  	set 6, [hl] -	coord hl, 0, 0 +	hlcoord 0, 0  	lb bc, 6, 10  	call TextBoxBorder -	coord hl, 1, 2 +	hlcoord 1, 2  	ld de, StatusAilmentText1  	call PlaceString -	coord hl, 6, 2 +	hlcoord 6, 2  	ld de, StatusAilmentText2  	call PlaceString  	ld hl, ViridianSchoolBlackboardText2 diff --git a/engine/events/pokemart.asm b/engine/events/pokemart.asm index 3345f540..c7cb8115 100755 --- a/engine/events/pokemart.asm +++ b/engine/events/pokemart.asm @@ -84,7 +84,7 @@ DisplayPokemartDialogue_::  	ld hl, PokemartTellSellPriceText  	lb bc, 14, 1 ; location that PrintText always prints to, this is useless  	call PrintText -	coord hl, 14, 7 +	hlcoord 14, 7  	lb bc, 8, 15  	ld a, TWO_OPTION_MENU  	ld [wTextBoxID], a @@ -162,7 +162,7 @@ DisplayPokemartDialogue_::  	call CopyStringToCF4B ; copy name to wcf4b  	ld hl, PokemartTellBuyPriceText  	call PrintText -	coord hl, 14, 7 +	hlcoord 14, 7  	lb bc, 8, 15  	ld a, TWO_OPTION_MENU  	ld [wTextBoxID], a diff --git a/engine/events/prize_menu.asm b/engine/events/prize_menu.asm index 2d8bde90..d9320fe7 100755 --- a/engine/events/prize_menu.asm +++ b/engine/events/prize_menu.asm @@ -22,7 +22,7 @@ CeladonPrizeMenu::  	ld a, $01  	ld [wTopMenuItemX], a  	call PrintPrizePrice -	coord hl, 0, 2 +	hlcoord 0, 2  	ld b, 8  	ld c, 16  	call TextBoxBorder @@ -93,71 +93,71 @@ GetPrizeMenuId:  	ld a, [wPrize1]  	ld [wd11e], a  	call GetItemName -	coord hl, 2, 4 +	hlcoord 2, 4  	call PlaceString  	ld a, [wPrize2]  	ld [wd11e], a  	call GetItemName -	coord hl, 2, 6 +	hlcoord 2, 6  	call PlaceString  	ld a, [wPrize3]  	ld [wd11e], a  	call GetItemName -	coord hl, 2, 8 +	hlcoord 2, 8  	call PlaceString  	jr .putNoThanksText  .putMonName  	ld a, [wPrize1]  	ld [wd11e], a  	call GetMonName -	coord hl, 2, 4 +	hlcoord 2, 4  	call PlaceString  	ld a, [wPrize2]  	ld [wd11e], a  	call GetMonName -	coord hl, 2, 6 +	hlcoord 2, 6  	call PlaceString  	ld a, [wPrize3]  	ld [wd11e], a  	call GetMonName -	coord hl, 2, 8 +	hlcoord 2, 8  	call PlaceString  .putNoThanksText -	coord hl, 2, 10 +	hlcoord 2, 10  	ld de, NoThanksText  	call PlaceString  ; put prices on the right side of the textbox  	ld de, wPrize1Price -	coord hl, 13, 5 +	hlcoord 13, 5  ; reg. c:  ; [low nybble] number of bytes  ; [bits 765 = %100] space-padding (not zero-padding)  	ld c, (1 << 7 | 2)  	call PrintBCDNumber  	ld de, wPrize2Price -	coord hl, 13, 7 +	hlcoord 13, 7  	ld c, (1 << 7 | 2)  	call PrintBCDNumber  	ld de, wPrize3Price -	coord hl, 13, 9 +	hlcoord 13, 9  	ld c, (1 << 7 | 2)  	jp PrintBCDNumber  INCLUDE "data/events/prizes.asm"  PrintPrizePrice: -	coord hl, 11, 0 +	hlcoord 11, 0  	ld b, 1  	ld c, 7  	call TextBoxBorder  	call UpdateSprites -	coord hl, 12, 0 +	hlcoord 12, 0  	ld de, .CoinString  	call PlaceString -	coord hl, 13, 1 +	hlcoord 13, 1  	ld de, .SixSpacesString  	call PlaceString -	coord hl, 13, 1 +	hlcoord 13, 1  	ld de, wPlayerCoins  	ld c, %10000010  	call PrintBCDNumber diff --git a/engine/events/vending_machine.asm b/engine/events/vending_machine.asm index 7bda91b0..a67f1c07 100755 --- a/engine/events/vending_machine.asm +++ b/engine/events/vending_machine.asm @@ -17,15 +17,15 @@ VendingMachineMenu::  	ld [wTopMenuItemX], a  	ld hl, wd730  	set 6, [hl] -	coord hl, 0, 3 +	hlcoord 0, 3  	ld b, 8  	ld c, 12  	call TextBoxBorder  	call UpdateSprites -	coord hl, 2, 5 +	hlcoord 2, 5  	ld de, DrinkText  	call PlaceString -	coord hl, 9, 6 +	hlcoord 9, 6  	ld de, DrinkPriceText  	call PlaceString  	ld hl, wd730 diff --git a/engine/items/item_effects.asm b/engine/items/item_effects.asm index b2901615..b04f11fb 100755 --- a/engine/items/item_effects.asm +++ b/engine/items/item_effects.asm @@ -1044,7 +1044,7 @@ ItemUseMedicine:  	sbc b  	ld [hl], a  	ld [wHPBarNewHP+1], a -	coord hl, 4, 1 +	hlcoord 4, 1  	ld a, [wWhichPokemon]  	ld bc, 2 * SCREEN_WIDTH  	call AddNTimes ; calculate coordinates of HP bar of pokemon that used Softboiled @@ -2221,7 +2221,7 @@ ItemUseTMHM:  	call PrintText  	ld hl, TeachMachineMoveText  	call PrintText -	coord hl, 14, 7 +	hlcoord 14, 7  	lb bc, 8, 15  	ld a, TWO_OPTION_MENU  	ld [wTextBoxID], a @@ -2607,7 +2607,7 @@ TossItem_::  	call CopyStringToCF4B ; copy name to wcf4b  	ld hl, IsItOKToTossItemText  	call PrintText -	coord hl, 14, 7 +	hlcoord 14, 7  	lb bc, 8, 15  	ld a, TWO_OPTION_MENU  	ld [wTextBoxID], a diff --git a/engine/items/town_map.asm b/engine/items/town_map.asm index 3cff630b..db066268 100755 --- a/engine/items/town_map.asm +++ b/engine/items/town_map.asm @@ -11,7 +11,7 @@ DisplayTownMap:  	push af  	ld b, $0  	call DrawPlayerOrBirdSprite ; player sprite -	coord hl, 1, 0 +	hlcoord 1, 0  	ld de, wcd6d  	call PlaceString  	ld hl, wOAMBuffer @@ -28,7 +28,7 @@ DisplayTownMap:  	jr .enterLoop  .townMapLoop -	coord hl, 0, 0 +	hlcoord 0, 0  	lb bc, 1, 20  	call ClearScreenArea  	ld hl, TownMapOrder @@ -55,7 +55,7 @@ DisplayTownMap:  	inc de  	cp $50  	jr nz, .copyMapName -	coord hl, 1, 0 +	hlcoord 1, 0  	ld de, wcd6d  	call PlaceString  	ld hl, wOAMBuffer + $10 @@ -118,7 +118,7 @@ LoadTownMap_Nest:  	push hl  	call DisplayWildLocations  	call GetMonName -	coord hl, 1, 0 +	hlcoord 1, 0  	call PlaceString  	ld h, b  	ld l, c @@ -153,34 +153,34 @@ LoadTownMap_Fly::  	push af  	ld [hl], $ff  	push hl -	coord hl, 0, 0 +	hlcoord 0, 0  	ld de, ToText  	call PlaceString  	ld a, [wCurMap]  	ld b, $0  	call DrawPlayerOrBirdSprite  	ld hl, wFlyLocationsList -	coord de, 18, 0 +	decoord 18, 0  .townMapFlyLoop  	ld a, " "  	ld [de], a  	push hl  	push hl -	coord hl, 3, 0 +	hlcoord 3, 0  	lb bc, 1, 15  	call ClearScreenArea  	pop hl  	ld a, [hl]  	ld b, $4  	call DrawPlayerOrBirdSprite ; draw bird sprite -	coord hl, 3, 0 +	hlcoord 3, 0  	ld de, wcd6d  	call PlaceString  	ld c, 15  	call DelayFrames -	coord hl, 18, 0 +	hlcoord 18, 0  	ld [hl], "▲" -	coord hl, 19, 0 +	hlcoord 19, 0  	ld [hl], "▼"  	pop hl  .inputLoop @@ -219,7 +219,7 @@ LoadTownMap_Fly::  	ld [hl], a  	ret  .pressedUp -	coord de, 18, 0 +	decoord 18, 0  	inc hl  	ld a, [hl]  	cp $ff @@ -231,7 +231,7 @@ LoadTownMap_Fly::  	ld hl, wFlyLocationsList  	jp .townMapFlyLoop  .pressedDown -	coord de, 19, 0 +	decoord 19, 0  	dec hl  	ld a, [hl]  	cp $ff @@ -278,7 +278,7 @@ LoadTownMap:  	call GBPalWhiteOutWithDelay3  	call ClearScreen  	call UpdateSprites -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, $12  	ld c, $12  	call TextBoxBorder @@ -293,7 +293,7 @@ LoadTownMap:  	ld bc, MonNestIconEnd - MonNestIcon  	ld a, BANK(MonNestIcon)  	call FarCopyDataDouble -	coord hl, 0, 0 +	hlcoord 0, 0  	ld de, CompressedMap  .nextTile  	ld a, [de] @@ -395,11 +395,11 @@ DisplayWildLocations:  	and a ; were any OAM entries written?  	jr nz, .drawPlayerSprite  ; if no OAM entries were written, print area unknown text -	coord hl, 1, 7 +	hlcoord 1, 7  	ld b, 2  	ld c, 15  	call TextBoxBorder -	coord hl, 2, 9 +	hlcoord 2, 9  	ld de, AreaUnknownText  	call PlaceString  	jr .done diff --git a/engine/link/cable_club.asm b/engine/link/cable_club.asm index dd93ebba..42d06846 100755 --- a/engine/link/cable_club.asm +++ b/engine/link/cable_club.asm @@ -9,11 +9,11 @@ CableClub_DoBattleOrTrade:  	call LoadFontTilePatterns  	call LoadHpBarAndStatusTilePatterns  	call LoadTrainerInfoTextBoxTiles -	coord hl, 3, 8 +	hlcoord 3, 8  	ld b, 2  	ld c, 12  	call CableClub_TextBoxBorder -	coord hl, 4, 10 +	hlcoord 4, 10  	ld de, PleaseWaitString  	call PlaceString  	ld hl, wPlayerNumHits @@ -399,7 +399,7 @@ TradeCenter_SelectMon:  	ld [wTopMenuItemY], a  	ld a, 1  	ld [wTopMenuItemX], a -	coord hl, 1, 1 +	hlcoord 1, 1  	lb bc, 6, 1  	call ClearScreenArea  .playerMonMenu_HandleInput @@ -464,11 +464,11 @@ TradeCenter_SelectMon:  	dec a  .displayStatsTradeMenu  	push af -	coord hl, 0, 14 +	hlcoord 0, 14  	ld b, 2  	ld c, 18  	call CableClub_TextBoxBorder -	coord hl, 2, 16 +	hlcoord 2, 16  	ld de, .statsTrade  	call PlaceString  	xor a @@ -480,7 +480,7 @@ TradeCenter_SelectMon:  	ld [wTopMenuItemY], a  .selectStatsMenuItem  	ld a, " " -	Coorda 11, 16 +	ldcoord_a 11, 16  	ld a, D_RIGHT | B_BUTTON | A_BUTTON  	ld [wMenuWatchedKeys], a  	ld a, 1 @@ -497,7 +497,7 @@ TradeCenter_SelectMon:  	jp .playerMonMenu  .selectTradeMenuItem  	ld a, " " -	Coorda 1, 16 +	ldcoord_a 1, 16  	ld a, D_LEFT | B_BUTTON | A_BUTTON  	ld [wMenuWatchedKeys], a  	ld a, 11 @@ -548,7 +548,7 @@ TradeCenter_SelectMon:  	ld [hl], a  .cancelMenuItem_Loop  	ld a, "▶" ; filled arrow cursor -	Coorda 1, 16 +	ldcoord_a 1, 16  .cancelMenuItem_JoypadLoop  	call JoypadLowSensitivity  	ldh a, [hJoy5] @@ -560,14 +560,14 @@ TradeCenter_SelectMon:  	jr z, .cancelMenuItem_JoypadLoop  ; if Up pressed  	ld a, " " -	Coorda 1, 16 +	ldcoord_a 1, 16  	ld a, [wPartyCount]  	dec a  	ld [wCurrentMenuItem], a  	jp .playerMonMenu  .cancelMenuItem_APressed  	ld a, "▷" ; unfilled arrow cursor -	Coorda 1, 16 +	ldcoord_a 1, 16  	ld a, $f  	ld [wSerialExchangeNybbleSendData], a  	call Serial_PrintWaitingTextAndSyncAndExchangeNybble @@ -596,15 +596,15 @@ ReturnToCableClubRoom:  	ret  TradeCenter_DrawCancelBox: -	coord hl, 11, 15 +	hlcoord 11, 15  	ld a, $7e  	ld bc, 2 * SCREEN_WIDTH + 9  	call FillMemory -	coord hl, 0, 15 +	hlcoord 0, 15  	ld b, 1  	ld c, 9  	call CableClub_TextBoxBorder -	coord hl, 2, 16 +	hlcoord 2, 16  	ld de, CancelTextString  	jp PlaceString @@ -613,7 +613,7 @@ CancelTextString:  TradeCenter_PlaceSelectedEnemyMonMenuCursor:  	ld a, [wSerialSyncAndExchangeNybbleReceiveData] -	coord hl, 1, 9 +	hlcoord 1, 9  	ld bc, SCREEN_WIDTH  	call AddNTimes  	ld [hl], "▷" ; cursor @@ -630,24 +630,24 @@ TradeCenter_DisplayStats:  	jp TradeCenter_DrawCancelBox  TradeCenter_DrawPartyLists: -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, 6  	ld c, 18  	call CableClub_TextBoxBorder -	coord hl, 0, 8 +	hlcoord 0, 8  	ld b, 6  	ld c, 18  	call CableClub_TextBoxBorder -	coord hl, 5, 0 +	hlcoord 5, 0  	ld de, wPlayerName  	call PlaceString -	coord hl, 5, 8 +	hlcoord 5, 8  	ld de, wLinkEnemyTrainerName  	call PlaceString -	coord hl, 2, 1 +	hlcoord 2, 1  	ld de, wPartySpecies  	call TradeCenter_PrintPartyListNames -	coord hl, 2, 9 +	hlcoord 2, 9  	ld de, wEnemyPartyMons  	; fall through @@ -684,7 +684,7 @@ TradeCenter_Trade:  	ld [wSerialExchangeNybbleReceiveData], a  	ld [wMenuWatchMovingOutOfBounds], a  	ld [wMenuJoypadPollCount], a -	coord hl, 0, 12 +	hlcoord 0, 12  	ld b, 4  	ld c, 18  	call CableClub_TextBoxBorder @@ -709,10 +709,10 @@ TradeCenter_Trade:  	ld [wd11e], a  	call GetMonName  	ld hl, WillBeTradedText -	coord bc, 1, 14 +	bccoord 1, 14  	call TextCommandProcessor  	call SaveScreenTilesToBuffer1 -	coord hl, 10, 7 +	hlcoord 10, 7  	lb bc, 8, 11  	ld a, TRADE_CANCEL_MENU  	ld [wTwoOptionMenuID], a @@ -726,11 +726,11 @@ TradeCenter_Trade:  ; if trade cancelled  	ld a, $1  	ld [wSerialExchangeNybbleSendData], a -	coord hl, 0, 12 +	hlcoord 0, 12  	ld b, 4  	ld c, 18  	call CableClub_TextBoxBorder -	coord hl, 1, 14 +	hlcoord 1, 14  	ld de, TradeCanceled  	call PlaceString  	call Serial_PrintWaitingTextAndSyncAndExchangeNybble @@ -743,11 +743,11 @@ TradeCenter_Trade:  	dec a ; did the other person cancel?  	jr nz, .doTrade  ; if the other person cancelled -	coord hl, 0, 12 +	hlcoord 0, 12  	ld b, 4  	ld c, 18  	call CableClub_TextBoxBorder -	coord hl, 1, 14 +	hlcoord 1, 14  	ld de, TradeCanceled  	call PlaceString  	jp .tradeCancelled @@ -851,11 +851,11 @@ TradeCenter_Trade:  	call Serial_PrintWaitingTextAndSyncAndExchangeNybble  	ld c, 40  	call DelayFrames -	coord hl, 0, 12 +	hlcoord 0, 12  	ld b, 4  	ld c, 18  	call CableClub_TextBoxBorder -	coord hl, 1, 14 +	hlcoord 1, 14  	ld de, TradeCompleted  	call PlaceString  	predef SaveSAVtoSRAM2 diff --git a/engine/link/print_waiting_text.asm b/engine/link/print_waiting_text.asm index c48459d3..d74d635f 100644 --- a/engine/link/print_waiting_text.asm +++ b/engine/link/print_waiting_text.asm @@ -1,5 +1,5 @@  PrintWaitingText:: -	coord hl, 3, 10 +	hlcoord 3, 10  	ld b, $1  	ld c, $b  	ld a, [wIsInBattle] @@ -10,7 +10,7 @@ PrintWaitingText::  .asm_4c17  	call CableClub_TextBoxBorder  .asm_4c1a -	coord hl, 4, 11 +	hlcoord 4, 11  	ld de, WaitingText  	call PlaceString  	ld c, 50 diff --git a/engine/menus/display_text_id_init.asm b/engine/menus/display_text_id_init.asm index fd1d3960..c030e7c9 100644 --- a/engine/menus/display_text_id_init.asm +++ b/engine/menus/display_text_id_init.asm @@ -13,18 +13,18 @@ DisplayTextIDInit::  ; below this, so this seems unnecessary.  	CheckEvent EVENT_GOT_POKEDEX  ; start menu with pokedex -	coord hl, 10, 0 +	hlcoord 10, 0  	ld b, $0e  	ld c, $08  	jr nz, .drawTextBoxBorder  ; start menu without pokedex -	coord hl, 10, 0 +	hlcoord 10, 0  	ld b, $0c  	ld c, $08  	jr .drawTextBoxBorder  ; if text ID is not 0 (i.e. not the start menu) then do a standard dialogue text box  .notStartMenu -	coord hl, 0, 12 +	hlcoord 0, 12  	ld b, $04  	ld c, $12  .drawTextBoxBorder diff --git a/engine/menus/draw_badges.asm b/engine/menus/draw_badges.asm index 1888e32f..a74497c1 100644 --- a/engine/menus/draw_badges.asm +++ b/engine/menus/draw_badges.asm @@ -43,11 +43,11 @@ DrawBadges:  	ld [hli], a  	ld [hl], $60 ; First name -	coord hl, 2, 11 +	hlcoord 2, 11  	ld de, wTempObtainedBadgesBooleans  	call .DrawBadgeRow -	coord hl, 2, 14 +	hlcoord 2, 14  	ld de, wTempObtainedBadgesBooleans + 4  ;	call .DrawBadgeRow  ;	ret diff --git a/engine/menus/draw_start_menu.asm b/engine/menus/draw_start_menu.asm index 21e444e9..00d385bc 100644 --- a/engine/menus/draw_start_menu.asm +++ b/engine/menus/draw_start_menu.asm @@ -2,12 +2,12 @@  DrawStartMenu::  	CheckEvent EVENT_GOT_POKEDEX  ; menu with pokedex -	coord hl, 10, 0 +	hlcoord 10, 0  	ld b, $0e  	ld c, $08  	jr nz, .drawTextBoxBorder  ; shorter menu if the player doesn't have the pokedex -	coord hl, 10, 0 +	hlcoord 10, 0  	ld b, $0c  	ld c, $08  .drawTextBoxBorder @@ -25,7 +25,7 @@ DrawStartMenu::  	ld [wMenuWatchMovingOutOfBounds], a  	ld hl, wd730  	set 6, [hl] ; no pauses between printing each letter -	coord hl, 12, 2 +	hlcoord 12, 2  	CheckEvent EVENT_GOT_POKEDEX  ; case for not having pokedex  	ld a, $06 diff --git a/engine/menus/league_pc.asm b/engine/menus/league_pc.asm index d930e42f..f2107c49 100755 --- a/engine/menus/league_pc.asm +++ b/engine/menus/league_pc.asm @@ -95,18 +95,18 @@ LeaguePCShowMon:  	ld b, SET_PAL_POKEMON_WHOLE_SCREEN  	ld c, 0  	call RunPaletteCommand -	coord hl, 12, 5 +	hlcoord 12, 5  	call GetMonHeader  	call LoadFrontSpriteByMonIndex  	call GBPalNormal -	coord hl, 0, 13 +	hlcoord 0, 13  	ld b, 2  	ld c, $12  	call TextBoxBorder -	coord hl, 1, 15 +	hlcoord 1, 15  	ld de, HallOfFameNoText  	call PlaceString -	coord hl, 16, 15 +	hlcoord 16, 15  	ld de, wHoFTeamNo  	lb bc, 1, 3  	call PrintNumber diff --git a/engine/menus/main_menu.asm b/engine/menus/main_menu.asm index 44aeccca..d2776240 100755 --- a/engine/menus/main_menu.asm +++ b/engine/menus/main_menu.asm @@ -33,20 +33,20 @@ MainMenu:  	cp 1  	jr z, .noSaveFile  ; there's a save file -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, 6  	ld c, 13  	call TextBoxBorder -	coord hl, 2, 2 +	hlcoord 2, 2  	ld de, ContinueText  	call PlaceString  	jr .next2  .noSaveFile -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, 4  	ld c, 13  	call TextBoxBorder -	coord hl, 2, 2 +	hlcoord 2, 2  	ld de, NewGameText  	call PlaceString  .next2 @@ -141,12 +141,12 @@ LinkMenu:  	call SaveScreenTilesToBuffer1  	ld hl, WhereWouldYouLikeText  	call PrintText -	coord hl, 5, 5 +	hlcoord 5, 5  	ld b, $6  	ld c, $d  	call TextBoxBorder  	call UpdateSprites -	coord hl, 7, 7 +	hlcoord 7, 7  	ld de, CableClubOptionsText  	call PlaceString  	xor a @@ -240,11 +240,11 @@ LinkMenu:  	ld c, d  .updateCursorPosition  	ld a, b -	Coorda 6, 7 +	ldcoord_a 6, 7  	ld a, c -	Coorda 6, 9 +	ldcoord_a 6, 9  	ld a, d -	Coorda 6, 11 +	ldcoord_a 6, 11  	ld c, 40  	call DelayFrames  	call LoadScreenTilesFromBuffer1 @@ -345,21 +345,21 @@ CableClubOptionsText:  DisplayContinueGameInfo:  	xor a  	ldh [hAutoBGTransferEnabled], a -	coord hl, 4, 7 +	hlcoord 4, 7  	ld b, 8  	ld c, 14  	call TextBoxBorder -	coord hl, 5, 9 +	hlcoord 5, 9  	ld de, SaveScreenInfoText  	call PlaceString -	coord hl, 12, 9 +	hlcoord 12, 9  	ld de, wPlayerName  	call PlaceString -	coord hl, 17, 11 +	hlcoord 17, 11  	call PrintNumBadges -	coord hl, 16, 13 +	hlcoord 16, 13  	call PrintNumOwnedMons -	coord hl, 13, 15 +	hlcoord 13, 15  	call PrintPlayTime  	ld a, 1  	ldh [hAutoBGTransferEnabled], a @@ -369,23 +369,23 @@ DisplayContinueGameInfo:  PrintSaveScreenText:  	xor a  	ldh [hAutoBGTransferEnabled], a -	coord hl, 4, 0 +	hlcoord 4, 0  	ld b, $8  	ld c, $e  	call TextBoxBorder  	call LoadTextBoxTilePatterns  	call UpdateSprites -	coord hl, 5, 2 +	hlcoord 5, 2  	ld de, SaveScreenInfoText  	call PlaceString -	coord hl, 12, 2 +	hlcoord 12, 2  	ld de, wPlayerName  	call PlaceString -	coord hl, 17, 4 +	hlcoord 17, 4  	call PrintNumBadges -	coord hl, 16, 6 +	hlcoord 16, 6  	call PrintNumOwnedMons -	coord hl, 13, 8 +	hlcoord 13, 8  	call PrintPlayTime  	ld a, $1  	ldh [hAutoBGTransferEnabled], a @@ -429,28 +429,28 @@ SaveScreenInfoText:  	next "TIME@"  DisplayOptionMenu: -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, 3  	ld c, 18  	call TextBoxBorder -	coord hl, 0, 5 +	hlcoord 0, 5  	ld b, 3  	ld c, 18  	call TextBoxBorder -	coord hl, 0, 10 +	hlcoord 0, 10  	ld b, 3  	ld c, 18  	call TextBoxBorder -	coord hl, 1, 1 +	hlcoord 1, 1  	ld de, TextSpeedOptionText  	call PlaceString -	coord hl, 1, 6 +	hlcoord 1, 6  	ld de, BattleAnimationOptionText  	call PlaceString -	coord hl, 1, 11 +	hlcoord 1, 11  	ld de, BattleStyleOptionText  	call PlaceString -	coord hl, 2, 16 +	hlcoord 2, 16  	ld de, OptionMenuCancelText  	call PlaceString  	xor a @@ -644,7 +644,7 @@ SetCursorPositionsFromOptions:  	dec hl  	ld a, [hl]  	ld [wOptionsTextSpeedCursorX], a ; text speed cursor X coordinate -	coord hl, 0, 3 +	hlcoord 0, 3  	call .placeUnfilledRightArrow  	sla c  	ld a, 1 ; On @@ -652,7 +652,7 @@ SetCursorPositionsFromOptions:  	ld a, 10 ; Off  .storeBattleAnimationCursorX  	ld [wOptionsBattleAnimCursorX], a ; battle animation cursor X coordinate -	coord hl, 0, 8 +	hlcoord 0, 8  	call .placeUnfilledRightArrow  	sla c  	ld a, 1 @@ -660,10 +660,10 @@ SetCursorPositionsFromOptions:  	ld a, 10  .storeBattleStyleCursorX  	ld [wOptionsBattleStyleCursorX], a ; battle style cursor X coordinate -	coord hl, 0, 13 +	hlcoord 0, 13  	call .placeUnfilledRightArrow  ; cursor in front of Cancel -	coord hl, 0, 16 +	hlcoord 0, 16  	ld a, 1  .placeUnfilledRightArrow  	ld e, a diff --git a/engine/menus/naming_screen.asm b/engine/menus/naming_screen.asm index e6886c98..a16c9501 100755 --- a/engine/menus/naming_screen.asm +++ b/engine/menus/naming_screen.asm @@ -4,7 +4,7 @@ AskName:  	push hl  	ld a, [wIsInBattle]  	dec a -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, 4  	ld c, 11  	call z, ClearScreenArea ; only if in wild battle @@ -13,7 +13,7 @@ AskName:  	call GetMonName  	ld hl, DoYouWantToNicknameText  	call PrintText -	coord hl, 14, 7 +	hlcoord 14, 7  	lb bc, 8, 15  	ld a, TWO_OPTION_MENU  	ld [wTextBoxID], a @@ -93,7 +93,7 @@ DisplayNamingScreen:  	call LoadHpBarAndStatusTilePatterns  	call LoadEDTile  	farcall LoadMonPartySpriteGfx -	coord hl, 0, 4 +	hlcoord 0, 4  	ld b, 9  	ld c, 18  	call TextBoxBorder @@ -344,7 +344,7 @@ PrintAlphabet:  	jr nz, .lowercase  	ld de, UpperCaseAlphabet  .lowercase -	coord hl, 2, 5 +	hlcoord 2, 5  	lb bc, 5, 9 ; 5 rows, 9 columns  .outerLoop  	push bc @@ -371,13 +371,13 @@ PrintNicknameAndUnderscores:  	call CalcStringLength  	ld a, c  	ld [wNamingScreenNameLength], a -	coord hl, 10, 2 +	hlcoord 10, 2  	lb bc, 1, 10  	call ClearScreenArea -	coord hl, 10, 2 +	hlcoord 10, 2  	ld de, wcf4b  	call PlaceString -	coord hl, 10, 3 +	hlcoord 10, 3  	ld a, [wNamingScreenType]  	cp NAME_MON_SCREEN  	jr nc, .pokemon1 @@ -416,7 +416,7 @@ PrintNicknameAndUnderscores:  .emptySpacesRemaining  	ld c, a  	ld b, $0 -	coord hl, 10, 3 +	hlcoord 10, 3  	add hl, bc  	ld [hl], $77 ; raised underscore tile id  	ret @@ -450,7 +450,7 @@ CalcStringLength:  	jr .loop  PrintNamingText: -	coord hl, 0, 1 +	hlcoord 0, 1  	ld a, [wNamingScreenType]  	ld de, YourTextString  	and a @@ -465,12 +465,12 @@ PrintNamingText:  	pop af  	ld [wd11e], a  	call GetMonName -	coord hl, 4, 1 +	hlcoord 4, 1  	call PlaceString  	ld hl, $1  	add hl, bc  	ld [hl], $c9 -	coord hl, 1, 3 +	hlcoord 1, 3  	ld de, NicknameTextString  	jr .placeString  .notNickname diff --git a/engine/menus/party_menu.asm b/engine/menus/party_menu.asm index 4eeb0ed8..14216b64 100755 --- a/engine/menus/party_menu.asm +++ b/engine/menus/party_menu.asm @@ -30,7 +30,7 @@ RedrawPartyMenu_::  	jp z, .printMessage  	call ErasePartyMenuCursors  	farcall InitPartyMenuBlkPacket -	coord hl, 3, 0 +	hlcoord 3, 0  	ld de, wPartySpecies  	xor a  	ld c, a diff --git a/engine/menus/players_pc.asm b/engine/menus/players_pc.asm index ebaacd52..5461be51 100755 --- a/engine/menus/players_pc.asm +++ b/engine/menus/players_pc.asm @@ -22,12 +22,12 @@ PlayerPCMenu:  	ld hl, wFlags_0xcd60  	set 5, [hl]  	call LoadScreenTilesFromBuffer2 -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, $8  	ld c, $e  	call TextBoxBorder  	call UpdateSprites -	coord hl, 2, 2 +	hlcoord 2, 2  	ld de, PlayersPCMenuEntries  	call PlaceString  	ld hl, wTopMenuItemY diff --git a/engine/menus/pokedex.asm b/engine/menus/pokedex.asm index a2a55bfd..53719712 100755 --- a/engine/menus/pokedex.asm +++ b/engine/menus/pokedex.asm @@ -119,7 +119,7 @@ HandlePokedexSideMenu:  	pop af  	ld [wCurrentMenuItem], a  	push bc -	coord hl, 0, 3 +	hlcoord 0, 3  	ld de, 20  	lb bc, " ", 13  	call DrawTileLine ; cover up the menu cursor in the pokemon list @@ -128,7 +128,7 @@ HandlePokedexSideMenu:  .buttonBPressed  	push bc -	coord hl, 15, 10 +	hlcoord 15, 10  	ld de, 20  	lb bc, " ", 7  	call DrawTileLine ; cover up the menu cursor in the side menu @@ -158,43 +158,43 @@ HandlePokedexListMenu:  	xor a  	ldh [hAutoBGTransferEnabled], a  ; draw the horizontal line separating the seen and owned amounts from the menu -	coord hl, 15, 8 +	hlcoord 15, 8  	ld a, "─"  	ld [hli], a  	ld [hli], a  	ld [hli], a  	ld [hli], a  	ld [hli], a -	coord hl, 14, 0 +	hlcoord 14, 0  	ld [hl], $71 ; vertical line tile -	coord hl, 14, 1 +	hlcoord 14, 1  	call DrawPokedexVerticalLine -	coord hl, 14, 9 +	hlcoord 14, 9  	call DrawPokedexVerticalLine  	ld hl, wPokedexSeen  	ld b, wPokedexSeenEnd - wPokedexSeen  	call CountSetBits  	ld de, wNumSetBits -	coord hl, 16, 3 +	hlcoord 16, 3  	lb bc, 1, 3  	call PrintNumber ; print number of seen pokemon  	ld hl, wPokedexOwned  	ld b, wPokedexOwnedEnd - wPokedexOwned  	call CountSetBits  	ld de, wNumSetBits -	coord hl, 16, 6 +	hlcoord 16, 6  	lb bc, 1, 3  	call PrintNumber ; print number of owned pokemon -	coord hl, 16, 2 +	hlcoord 16, 2  	ld de, PokedexSeenText  	call PlaceString -	coord hl, 16, 5 +	hlcoord 16, 5  	ld de, PokedexOwnText  	call PlaceString -	coord hl, 1, 1 +	hlcoord 1, 1  	ld de, PokedexContentsText  	call PlaceString -	coord hl, 16, 10 +	hlcoord 16, 10  	ld de, PokedexMenuItemsText  	call PlaceString  ; find the highest pokedex number among the pokemon the player has seen @@ -217,10 +217,10 @@ HandlePokedexListMenu:  .loop  	xor a  	ldh [hAutoBGTransferEnabled], a -	coord hl, 4, 2 +	hlcoord 4, 2  	lb bc, 14, 10  	call ClearScreenArea -	coord hl, 1, 3 +	hlcoord 1, 3  	ld a, [wListScrollOffset]  	ld [wd11e], a  	ld d, 7 @@ -415,43 +415,43 @@ ShowPokedexDataInternal:  	xor a  	ldh [hTilesetType], a -	coord hl, 0, 0 +	hlcoord 0, 0  	ld de, 1  	lb bc, $64, SCREEN_WIDTH  	call DrawTileLine ; draw top border -	coord hl, 0, 17 +	hlcoord 0, 17  	ld b, $6f  	call DrawTileLine ; draw bottom border -	coord hl, 0, 1 +	hlcoord 0, 1  	ld de, 20  	lb bc, $66, $10  	call DrawTileLine ; draw left border -	coord hl, 19, 1 +	hlcoord 19, 1  	ld b, $67  	call DrawTileLine ; draw right border  	ld a, $63 ; upper left corner tile -	Coorda 0, 0 +	ldcoord_a 0, 0  	ld a, $65 ; upper right corner tile -	Coorda 19, 0 +	ldcoord_a 19, 0  	ld a, $6c ; lower left corner tile -	Coorda 0, 17 +	ldcoord_a 0, 17  	ld a, $6e ; lower right corner tile -	Coorda 19, 17 +	ldcoord_a 19, 17 -	coord hl, 0, 9 +	hlcoord 0, 9  	ld de, PokedexDataDividerLine  	call PlaceString ; draw horizontal divider line -	coord hl, 9, 6 +	hlcoord 9, 6  	ld de, HeightWeightText  	call PlaceString  	call GetMonName -	coord hl, 9, 2 +	hlcoord 9, 2  	call PlaceString  	ld hl, PokedexEntryPointers @@ -465,7 +465,7 @@ ShowPokedexDataInternal:  	ld e, a  	ld d, [hl] ; de = address of pokedex entry -	coord hl, 9, 4 +	hlcoord 9, 4  	call PlaceString ; print species name  	ld h, b @@ -475,7 +475,7 @@ ShowPokedexDataInternal:  	push af  	call IndexToPokedex -	coord hl, 2, 8 +	hlcoord 2, 8  	ld a, "№"  	ld [hli], a  	ld a, "<DOT>" @@ -500,7 +500,7 @@ ShowPokedexDataInternal:  	call Delay3  	call GBPalNormal  	call GetMonHeader ; load pokemon picture location -	coord hl, 1, 1 +	hlcoord 1, 1  	call LoadFlippedFrontSpriteByMonIndex ; draw pokemon picture  	ld a, [wcf91]  	call PlayCry ; play pokemon cry @@ -515,14 +515,14 @@ ShowPokedexDataInternal:  	jp z, .waitForButtonPress ; if the pokemon has not been owned, don't print the height, weight, or description  	inc de ; de = address of feet (height)  	ld a, [de] ; reads feet, but a is overwritten without being used -	coord hl, 12, 6 +	hlcoord 12, 6  	lb bc, 1, 2  	call PrintNumber ; print feet (height)  	ld a, "′"  	ld [hl], a  	inc de  	inc de ; de = address of inches (height) -	coord hl, 15, 6 +	hlcoord 15, 6  	lb bc, LEADING_ZEROES | 1, 2  	call PrintNumber ; print inches (height)  	ld a, "″" @@ -544,10 +544,10 @@ ShowPokedexDataInternal:  	ld a, [de] ; a = lower byte of weight  	ld [hl], a ; store lower byte of weight in [hDexWeight + 1]  	ld de, hDexWeight -	coord hl, 11, 8 +	hlcoord 11, 8  	lb bc, 2, 5 ; 2 bytes, 5 digits  	call PrintNumber ; print weight -	coord hl, 14, 8 +	hlcoord 14, 8  	ldh a, [hDexWeight + 1]  	sub 10  	ldh a, [hDexWeight] @@ -565,7 +565,7 @@ ShowPokedexDataInternal:  	ldh [hDexWeight], a ; restore original value of [hDexWeight]  	pop hl  	inc hl ; hl = address of pokedex description text -	coord bc, 1, 11 +	bccoord 1, 11  	ld a, %10  	ldh [hClearLetterPrintingDelayFlags], a  	call TextCommandProcessor ; print pokedex description text diff --git a/engine/menus/save.asm b/engine/menus/save.asm index 2941a07e..45fed8a6 100755 --- a/engine/menus/save.asm +++ b/engine/menus/save.asm @@ -154,10 +154,10 @@ SaveSAV:  	ret nz  .save  	call SaveSAVtoSRAM -	coord hl, 1, 13 +	hlcoord 1, 13  	lb bc, 4, 18  	call ClearScreenArea -	coord hl, 1, 14 +	hlcoord 1, 14  	ld de, NowSavingString  	call PlaceString  	ld c, 120 @@ -175,7 +175,7 @@ NowSavingString:  SaveSAVConfirm:  	call PrintText -	coord hl, 0, 7 +	hlcoord 0, 7  	lb bc, 8, 1  	ld a, TWO_OPTION_MENU  	ld [wTextBoxID], a @@ -435,20 +435,20 @@ DisplayChangeBoxMenu:  	and $7f  	ld [wCurrentMenuItem], a  	ld [wLastMenuItem], a -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, 2  	ld c, 9  	call TextBoxBorder  	ld hl, ChooseABoxText  	call PrintText -	coord hl, 11, 0 +	hlcoord 11, 0  	ld b, 12  	ld c, 7  	call TextBoxBorder  	ld hl, hFlagsFFF6  	set 2, [hl]  	ld de, BoxNames -	coord hl, 13, 1 +	hlcoord 13, 1  	call PlaceString  	ld hl, hFlagsFFF6  	res 2, [hl] @@ -457,19 +457,19 @@ DisplayChangeBoxMenu:  	cp 9  	jr c, .singleDigitBoxNum  	sub 9 -	coord hl, 8, 2 +	hlcoord 8, 2  	ld [hl], "1"  	add "0"  	jr .next  .singleDigitBoxNum  	add "1"  .next -	Coorda 9, 2 -	coord hl, 1, 2 +	ldcoord_a 9, 2 +	hlcoord 1, 2  	ld de, BoxNoText  	call PlaceString  	call GetMonCountsForAllBoxes -	coord hl, 18, 1 +	hlcoord 18, 1  	ld de, wBoxMonCounts  	ld bc, SCREEN_WIDTH  	ld a, $c diff --git a/engine/menus/start_sub_menus.asm b/engine/menus/start_sub_menus.asm index 33d504b8..8f1a2d61 100755 --- a/engine/menus/start_sub_menus.asm +++ b/engine/menus/start_sub_menus.asm @@ -285,7 +285,7 @@ StartMenu_Pokemon::  ; writes a blank tile to all possible menu cursor positions on the party menu  ErasePartyMenuCursors:: -	coord hl, 0, 1 +	hlcoord 0, 1  	ld bc, 2 * 20 ; menu cursor positions are 2 rows apart  	ld a, 6 ; 6 menu cursor positions  .loop @@ -330,10 +330,10 @@ StartMenu_Item::  .choseItem  ; erase menu cursor (blank each tile in front of an item name)  	ld a, " " -	Coorda 5, 4 -	Coorda 5, 6 -	Coorda 5, 8 -	Coorda 5, 10 +	ldcoord_a 5, 4 +	ldcoord_a 5, 6 +	ldcoord_a 5, 8 +	ldcoord_a 5, 10  	call PlaceUnfilledArrowMenuCursor  	xor a  	ld [wMenuItemToSwap], a @@ -480,10 +480,10 @@ DrawTrainerInfo:  	lb bc, BANK(RedPicFront), $01  	predef DisplayPicCenteredOrUpperRight  	call DisableLCD -	coord hl, 0, 2 +	hlcoord 0, 2  	ld a, " "  	call TrainerInfo_DrawVerticalLine -	coord hl, 1, 2 +	hlcoord 1, 2  	call TrainerInfo_DrawVerticalLine  	ld hl, vChars2 + $70  	ld de, vChars2 @@ -526,7 +526,7 @@ DrawTrainerInfo:  	dec a  	ld [hli], a  	ld [hl], 1 -	coord hl, 0, 0 +	hlcoord 0, 0  	call TrainerInfo_DrawTextBox  	ld hl, wTrainerInfoTextBoxWidthPlus1  	ld a, 16 + 1 @@ -534,27 +534,27 @@ DrawTrainerInfo:  	dec a  	ld [hli], a  	ld [hl], 3 -	coord hl, 1, 10 +	hlcoord 1, 10  	call TrainerInfo_DrawTextBox -	coord hl, 0, 10 +	hlcoord 0, 10  	ld a, $d7  	call TrainerInfo_DrawVerticalLine -	coord hl, 19, 10 +	hlcoord 19, 10  	call TrainerInfo_DrawVerticalLine -	coord hl, 6, 9 +	hlcoord 6, 9  	ld de, TrainerInfo_BadgesText  	call PlaceString -	coord hl, 2, 2 +	hlcoord 2, 2  	ld de, TrainerInfo_NameMoneyTimeText  	call PlaceString -	coord hl, 7, 2 +	hlcoord 7, 2  	ld de, wPlayerName  	call PlaceString -	coord hl, 8, 4 +	hlcoord 8, 4  	ld de, wPlayerMoney  	ld c, $e3  	call PrintBCDNumber -	coord hl, 9, 6 +	hlcoord 9, 6  	ld de, wPlayTimeHours ; hours  	lb bc, LEFT_ALIGN | 1, 3  	call PrintNumber @@ -667,7 +667,7 @@ SwitchPartyMon::  SwitchPartyMon_ClearGfx:  	push af -	coord hl, 0, 0 +	hlcoord 0, 0  	ld bc, SCREEN_WIDTH * 2  	call AddNTimes  	ld c, SCREEN_WIDTH * 2 diff --git a/engine/menus/text_box.asm b/engine/menus/text_box.asm index 51339ec2..2e69c5a4 100644 --- a/engine/menus/text_box.asm +++ b/engine/menus/text_box.asm @@ -111,7 +111,7 @@ GetTextBoxIDText:  ; hl = address of upper left corner of text box  GetAddressOfScreenCoords:  	push bc -	coord hl, 0, 0 +	hlcoord 0, 0  	ld bc, 20  .loop ; loop to add d rows to the base address  	ld a, d @@ -274,11 +274,11 @@ DisplayMoneyBox:  	ld a, MONEY_BOX_TEMPLATE  	ld [wTextBoxID], a  	call DisplayTextBoxID -	coord hl, 13, 1 +	hlcoord 13, 1  	ld b, 1  	ld c, 6  	call ClearScreenArea -	coord hl, 12, 1 +	hlcoord 12, 1  	ld de, wPlayerMoney  	ld c, $a3  	call PrintBCDNumber @@ -578,14 +578,14 @@ DisplayFieldMoveMonMenu:  	jr nz, .fieldMovesExist  ; no field moves -	coord hl, 11, 11 +	hlcoord 11, 11  	ld b, 5  	ld c, 7  	call TextBoxBorder  	call UpdateSprites  	ld a, 12  	ldh [hFieldMoveMonMenuTopMenuItemX], a -	coord hl, 13, 12 +	hlcoord 13, 12  	ld de, PokemonMenuEntries  	jp PlaceString @@ -594,7 +594,7 @@ DisplayFieldMoveMonMenu:  ; Calculate the text box position and dimensions based on the leftmost X coord  ; of the field move names before adjusting for the number of field moves. -	coord hl, 0, 11 +	hlcoord 0, 11  	ld a, [wFieldMovesLeftmostXCoord]  	dec a  	ld e, a @@ -625,7 +625,7 @@ DisplayFieldMoveMonMenu:  	call UpdateSprites  ; Calculate the position of the first field move name to print. -	coord hl, 0, 12 +	hlcoord 0, 12  	ld a, [wFieldMovesLeftmostXCoord]  	inc a  	ld e, a @@ -674,7 +674,7 @@ DisplayFieldMoveMonMenu:  	pop hl  	ld a, [wFieldMovesLeftmostXCoord]  	ldh [hFieldMoveMonMenuTopMenuItemX], a -	coord hl, 0, 12 +	hlcoord 0, 12  	ld a, [wFieldMovesLeftmostXCoord]  	inc a  	ld e, a diff --git a/engine/movie/credits.asm b/engine/movie/credits.asm index 42b8e0cc..ae35a2b7 100755 --- a/engine/movie/credits.asm +++ b/engine/movie/credits.asm @@ -14,9 +14,9 @@ HallOfFamePC:  	ld bc, $10  	ld a, $ff  	call FillMemory -	coord hl, 0, 0 +	hlcoord 0, 0  	call FillFourRowsWithBlack -	coord hl, 0, 14 +	hlcoord 0, 14  	call FillFourRowsWithBlack  	ld a, %11000000  	ldh [rBGP], a @@ -61,7 +61,7 @@ DisplayCreditsMon:  	ld a, [hl]  	ld [wcf91], a  	ld [wd0b5], a -	coord hl, 8, 6 +	hlcoord 8, 6  	call GetMonHeader  	call LoadFrontSpriteByMonIndex  	ld hl, vBGMap0 + $c @@ -162,7 +162,7 @@ FillFourRowsWithBlack:  	jp FillMemory  FillMiddleOfScreenWithWhite: -	coord hl, 0, 4 +	hlcoord 0, 4  	ld bc, SCREEN_WIDTH * 10  	ld a, " "  	jp FillMemory @@ -172,7 +172,7 @@ Credits:  	push de  .nextCreditsScreen  	pop de -	coord hl, 9, 6 +	hlcoord 9, 6  	push hl  	call FillMiddleOfScreenWithWhite  	pop hl @@ -248,10 +248,10 @@ Credits:  	ld hl, vChars2 + $600  	lb bc, BANK(TheEndGfx), (TheEndGfxEnd - TheEndGfx) / $10  	call CopyVideoData -	coord hl, 4, 8 +	hlcoord 4, 8  	ld de, TheEndTextString  	call PlaceString -	coord hl, 4, 9 +	hlcoord 4, 9  	inc de  	call PlaceString  	jp FadeInCreditsText diff --git a/engine/movie/evolution.asm b/engine/movie/evolution.asm index b006dea6..cabe7254 100755 --- a/engine/movie/evolution.asm +++ b/engine/movie/evolution.asm @@ -99,7 +99,7 @@ EvolutionSetWholeScreenPalette:  Evolution_LoadPic:  	call GetMonHeader -	coord hl, 7, 2 +	hlcoord 7, 2  	jp LoadFlippedFrontSpriteByMonIndex  Evolution_BackAndForthAnim: @@ -118,7 +118,7 @@ Evolution_ChangeMonPic:  	push bc  	xor a  	ldh [hAutoBGTransferEnabled], a -	coord hl, 7, 2 +	hlcoord 7, 2  	lb bc, 7, 7  	ld de, SCREEN_WIDTH - 7  .loop diff --git a/engine/movie/hall_of_fame.asm b/engine/movie/hall_of_fame.asm index 355a3f4f..071e7ca1 100755 --- a/engine/movie/hall_of_fame.asm +++ b/engine/movie/hall_of_fame.asm @@ -57,11 +57,11 @@ AnimateHallOfFame:  	call HoFDisplayAndRecordMonInfo  	ld c, 80  	call DelayFrames -	coord hl, 2, 13 +	hlcoord 2, 13  	ld b, 3  	ld c, 14  	call TextBoxBorder -	coord hl, 4, 15 +	hlcoord 4, 15  	ld de, HallOfFameText  	call PlaceString  	ld c, 180 @@ -112,7 +112,7 @@ HoFShowMonOrPlayer:  	call HoFLoadPlayerPics  	jr .next1  .showMon -	coord hl, 12, 5 +	hlcoord 12, 5  	call GetMonHeader  	call LoadFrontSpriteByMonIndex  	predef LoadMonBackPic @@ -157,22 +157,22 @@ HoFDisplayAndRecordMonInfo:  	jp HoFRecordMonInfo  HoFDisplayMonInfo: -	coord hl, 0, 2 +	hlcoord 0, 2  	ld b, 9  	ld c, 10  	call TextBoxBorder -	coord hl, 2, 6 +	hlcoord 2, 6  	ld de, HoFMonInfoText  	call PlaceString -	coord hl, 1, 4 +	hlcoord 1, 4  	ld de, wcd6d  	call PlaceString  	ld a, [wHoFMonLevel] -	coord hl, 8, 7 +	hlcoord 8, 7  	call PrintLevelCommon  	ld a, [wHoFMonSpecies]  	ld [wd0b5], a -	coord hl, 3, 9 +	hlcoord 3, 9  	predef PrintMonType  	ld a, [wHoFMonSpecies]  	jp PlayCry @@ -203,27 +203,27 @@ HoFLoadPlayerPics:  HoFLoadMonPlayerPicTileIDs:  ; c = base tile ID  	ld b, 0 -	coord hl, 12, 5 +	hlcoord 12, 5  	predef_jump CopyTileIDsFromList  HoFDisplayPlayerStats:  	SetEvent EVENT_HALL_OF_FAME_DEX_RATING  	predef DisplayDexRating -	coord hl, 0, 4 +	hlcoord 0, 4  	ld b, 6  	ld c, 10  	call TextBoxBorder -	coord hl, 5, 0 +	hlcoord 5, 0  	ld b, 2  	ld c, 9  	call TextBoxBorder -	coord hl, 7, 2 +	hlcoord 7, 2  	ld de, wPlayerName  	call PlaceString -	coord hl, 1, 6 +	hlcoord 1, 6  	ld de, HoFPlayTimeText  	call PlaceString -	coord hl, 5, 7 +	hlcoord 5, 7  	ld de, wPlayTimeHours  	lb bc, 1, 3  	call PrintNumber @@ -232,10 +232,10 @@ HoFDisplayPlayerStats:  	ld de, wPlayTimeMinutes  	lb bc, LEADING_ZEROES | 1, 2  	call PrintNumber -	coord hl, 1, 9 +	hlcoord 1, 9  	ld de, HoFMoneyText  	call PlaceString -	coord hl, 4, 10 +	hlcoord 4, 10  	ld de, wPlayerMoney  	ld c, $a3  	call PrintBCDNumber diff --git a/engine/movie/intro.asm b/engine/movie/intro.asm index 08b6ed8b..fc404b82 100755 --- a/engine/movie/intro.asm +++ b/engine/movie/intro.asm @@ -217,7 +217,7 @@ IntroClearScreen:  IntroClearMiddleOfScreen:  ; clear the area of the tile map between the black bars on the top and bottom -	coord hl, 0, 4 +	hlcoord 0, 4  	ld bc, SCREEN_WIDTH * 10  IntroClearCommon: @@ -274,7 +274,7 @@ IntroMoveMon:  	ret  IntroCopyTiles: -	coord hl, 13, 7 +	hlcoord 13, 7  CopyTileIDsFromList_ZeroBaseTileID:  	ld c, 0 @@ -348,16 +348,16 @@ PlayShootingStar:  IntroDrawBlackBars:  ; clear the screen and draw black bars on the top and bottom  	call IntroClearScreen -	coord hl, 0, 0 +	hlcoord 0, 0  	ld c, SCREEN_WIDTH * 4  	call IntroPlaceBlackTiles -	coord hl, 0, 14 +	hlcoord 0, 14  	ld c, SCREEN_WIDTH * 4  	call IntroPlaceBlackTiles  	ld hl, vBGMap1  	ld c,  BG_MAP_WIDTH * 4  	call IntroPlaceBlackTiles -	ld hl, vBGMap1 + BG_MAP_WIDTH * 14 +	hlbgcoord 0, 14, vBGMap1  	ld c,  BG_MAP_WIDTH * 4  	jp IntroPlaceBlackTiles diff --git a/engine/movie/oak_speech/clear_save.asm b/engine/movie/oak_speech/clear_save.asm index c423fb0b..d5c04e6e 100755 --- a/engine/movie/oak_speech/clear_save.asm +++ b/engine/movie/oak_speech/clear_save.asm @@ -5,7 +5,7 @@ DoClearSaveDialogue:  	call LoadTextBoxTilePatterns  	ld hl, ClearSaveDataText  	call PrintText -	coord hl, 14, 7 +	hlcoord 14, 7  	lb bc, 8, 15  	ld a, NO_YES_MENU  	ld [wTwoOptionMenuID], a diff --git a/engine/movie/oak_speech/oak_speech.asm b/engine/movie/oak_speech/oak_speech.asm index 2328e3ab..4b64f20d 100755 --- a/engine/movie/oak_speech/oak_speech.asm +++ b/engine/movie/oak_speech/oak_speech.asm @@ -68,7 +68,7 @@ OakSpeech:  	ld [wd0b5], a  	ld [wcf91], a  	call GetMonHeader -	coord hl, 6, 4 +	hlcoord 6, 4  	call LoadFlippedFrontSpriteByMonIndex  	call MovePicLeft  	ld hl, OakSpeechText2 @@ -141,7 +141,7 @@ OakSpeech:  	ld [MBC1RomBank], a  	ld c, 20  	call DelayFrames -	coord hl, 6, 5 +	hlcoord 6, 5  	ld b, 7  	ld c, 7  	call ClearScreenArea @@ -224,9 +224,9 @@ IntroDisplayPicCenteredOrUpperRight:  	pop bc  	ld a, c  	and a -	coord hl, 15, 1 +	hlcoord 15, 1  	jr nz, .next -	coord hl, 6, 4 +	hlcoord 6, 4  .next  	xor a  	ldh [hStartTileID], a diff --git a/engine/movie/oak_speech/oak_speech2.asm b/engine/movie/oak_speech/oak_speech2.asm index 5ee0a871..28208ddc 100755 --- a/engine/movie/oak_speech/oak_speech2.asm +++ b/engine/movie/oak_speech/oak_speech2.asm @@ -66,7 +66,7 @@ HisNameIsText:  OakSpeechSlidePicLeft:  	push de -	coord hl, 0, 0 +	hlcoord 0, 0  	lb bc, 12, 11  	call ClearScreenArea ; clear the name list text box  	ld c, 10 @@ -76,13 +76,13 @@ OakSpeechSlidePicLeft:  	ld bc, NAME_LENGTH  	call CopyData  	call Delay3 -	coord hl, 12, 4 +	hlcoord 12, 4  	lb de, 6, 6 * SCREEN_WIDTH + 5  	ld a, $ff  	jr OakSpeechSlidePicCommon  OakSpeechSlidePicRight: -	coord hl, 5, 4 +	hlcoord 5, 4  	lb de, 6, 6 * SCREEN_WIDTH + 5  	xor a @@ -161,15 +161,15 @@ OakSpeechSlidePicCommon:  DisplayIntroNameTextBox:  	push de -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, $a  	ld c, $9  	call TextBoxBorder -	coord hl, 3, 0 +	hlcoord 3, 0  	ld de, .namestring  	call PlaceString  	pop de -	coord hl, 2, 2 +	hlcoord 2, 2  	call PlaceString  	call UpdateSprites  	xor a diff --git a/engine/movie/title.asm b/engine/movie/title.asm index 00e639ae..69838afb 100755 --- a/engine/movie/title.asm +++ b/engine/movie/title.asm @@ -63,7 +63,7 @@ DisplayTitleScreen:  	call ClearBothBGMaps  ; place tiles for pokemon logo (except for the last row) -	coord hl, 2, 1 +	hlcoord 2, 1  	ld a, $80  	ld de, SCREEN_WIDTH  	ld c, 6 @@ -81,7 +81,7 @@ DisplayTitleScreen:  	jr nz, .pokemonLogoTileLoop  ; place tiles for the last row of the pokemon logo -	coord hl, 2, 7 +	hlcoord 2, 7  	ld a, $31  	ld b, $10  .pokemonLogoLastTileRowLoop @@ -98,7 +98,7 @@ DisplayTitleScreen:  	ld [hl], a  ; place tiles for title screen copyright -	coord hl, 2, 17 +	hlcoord 2, 17  	ld de, .tileScreenCopyrightTiles  	ld b, $10  .tileScreenCopyrightTilesLoop @@ -353,7 +353,7 @@ ClearBothBGMaps:  LoadTitleMonSprite:  	ld [wcf91], a  	ld [wd0b5], a -	coord hl, 5, 10 +	hlcoord 5, 10  	call GetMonHeader  	jp LoadFrontSpriteByMonIndex @@ -372,7 +372,7 @@ LoadCopyrightTiles:  	ld hl, vChars2 + $600  	lb bc, BANK(NintendoCopyrightLogoGraphics), (GamefreakLogoGraphicsEnd - NintendoCopyrightLogoGraphics) / $10  	call CopyVideoData -	coord hl, 2, 7 +	hlcoord 2, 7  	ld de, CopyrightTextString  	jp PlaceString @@ -386,7 +386,7 @@ INCLUDE "data/pokemon/title_mons.asm"  ; prints version text (red, blue)  PrintGameVersionOnTitleScreen: -	coord hl, 7, 8 +	hlcoord 7, 8  	ld de, VersionOnTitleScreenText  	jp PlaceString diff --git a/engine/movie/trade.asm b/engine/movie/trade.asm index 6aac7e23..3883c362 100755 --- a/engine/movie/trade.asm +++ b/engine/movie/trade.asm @@ -148,7 +148,7 @@ Trade_Delay80:  	jp DelayFrames  Trade_ClearTileMap: -	coord hl, 0, 0 +	hlcoord 0, 0  	ld bc, SCREEN_WIDTH * SCREEN_HEIGHT  	ld a, " "  	jp FillMemory @@ -232,7 +232,7 @@ Trade_ShowPlayerMon:  	ldh [hSCX], a  	xor a  	ldh [hAutoBGTransferEnabled], a -	coord hl, 4, 0 +	hlcoord 4, 0  	ld b, 6  	ld c, 10  	call TextBoxBorder @@ -281,7 +281,7 @@ Trade_DrawOpenEndOfLinkCable:  	call DelayFrame  	ld a, %10001011  	ldh [rLCDC], a -	coord hl, 6, 2 +	hlcoord 6, 2  	ld b, $7 ; open end of link cable tile ID list index  	call CopyTileIDsFromList_ZeroBaseTileID  	call Trade_CopyTileMapToVRAM @@ -353,7 +353,7 @@ Trade_ShowEnemyMon:  	ld a, TRADE_BALL_TILT_ANIM  	call Trade_ShowAnimation  	call Trade_ShowClearedWindow -	coord hl, 4, 10 +	hlcoord 4, 10  	ld b, 6  	ld c, 10  	call TextBoxBorder @@ -370,7 +370,7 @@ Trade_ShowEnemyMon:  	ld a, [wTradedEnemyMonSpecies]  	call PlayCry  	call Trade_Delay100 -	coord hl, 4, 10 +	hlcoord 4, 10  	lb bc, 8, 12  	call ClearScreenArea  	jp PrintTradeTakeCareText @@ -462,7 +462,7 @@ Trade_DrawLeftGameboy:  	call Trade_ClearTileMap  ; draw link cable -	coord hl, 11, 4 +	hlcoord 11, 4  	ld a, $5d  	ld [hli], a  	ld a, $5e @@ -473,16 +473,16 @@ Trade_DrawLeftGameboy:  	jr nz, .loop  ; draw gameboy pic -	coord hl, 5, 3 +	hlcoord 5, 3  	ld b, $6  	call CopyTileIDsFromList_ZeroBaseTileID  ; draw text box with player name below gameboy pic -	coord hl, 4, 12 +	hlcoord 4, 12  	ld b, 2  	ld c, 7  	call TextBoxBorder -	coord hl, 5, 14 +	hlcoord 5, 14  	ld de, wPlayerName  	call PlaceString @@ -492,7 +492,7 @@ Trade_DrawRightGameboy:  	call Trade_ClearTileMap  ; draw horizontal segment of link cable -	coord hl, 0, 4 +	hlcoord 0, 4  	ld a, $5e  	ld c, $e  .loop @@ -520,16 +520,16 @@ Trade_DrawRightGameboy:  	ld [hl], a  ; draw gameboy pic -	coord hl, 7, 8 +	hlcoord 7, 8  	ld b, $6  	call CopyTileIDsFromList_ZeroBaseTileID  ; draw text box with enemy name above link cable -	coord hl, 6, 0 +	hlcoord 6, 0  	ld b, 2  	ld c, 7  	call TextBoxBorder -	coord hl, 7, 2 +	hlcoord 7, 2  	ld de, wLinkEnemyTrainerName  	call PlaceString @@ -538,7 +538,7 @@ Trade_DrawRightGameboy:  Trade_DrawCableAcrossScreen:  ; Draws the link cable across the screen.  	call Trade_ClearTileMap -	coord hl, 0, 4 +	hlcoord 0, 4  	ld a, $5e  	ld c, SCREEN_WIDTH  .loop @@ -551,7 +551,7 @@ Trade_CopyCableTilesOffScreen:  ; This is used to copy the link cable tiles off screen so that the cable  ; continues when the screen is scrolled.  	push hl -	coord hl, 0, 4 +	hlcoord 0, 4  	call CopyToRedrawRowOrColumnSrcTiles  	pop hl  	ld a, h @@ -735,7 +735,7 @@ Trade_LoadMonSprite:  	xor $1  	ldh [hAutoBGTransferEnabled], a  	call GetMonHeader -	coord hl, 7, 2 +	hlcoord 7, 2  	call LoadFlippedFrontSpriteByMonIndex  	ld c, 10  	jp DelayFrames diff --git a/engine/movie/trade2.asm b/engine/movie/trade2.asm index 6b744fd8..f0d91846 100755 --- a/engine/movie/trade2.asm +++ b/engine/movie/trade2.asm @@ -1,43 +1,43 @@  Trade_PrintPlayerMonInfoText: -	coord hl, 5, 0 +	hlcoord 5, 0  	ld de, Trade_MonInfoText  	call PlaceString  	ld a, [wTradedPlayerMonSpecies]  	ld [wd11e], a  	predef IndexToPokedex -	coord hl, 9, 0 +	hlcoord 9, 0  	ld de, wd11e  	lb bc, LEADING_ZEROES | 1, 3  	call PrintNumber -	coord hl, 5, 2 +	hlcoord 5, 2  	ld de, wcf4b  	call PlaceString -	coord hl, 8, 4 +	hlcoord 8, 4  	ld de, wTradedPlayerMonOT  	call PlaceString -	coord hl, 8, 6 +	hlcoord 8, 6  	ld de, wTradedPlayerMonOTID  	lb bc, LEADING_ZEROES | 2, 5  	jp PrintNumber  Trade_PrintEnemyMonInfoText: -	coord hl, 5, 10 +	hlcoord 5, 10  	ld de, Trade_MonInfoText  	call PlaceString  	ld a, [wTradedEnemyMonSpecies]  	ld [wd11e], a  	predef IndexToPokedex -	coord hl, 9, 10 +	hlcoord 9, 10  	ld de, wd11e  	lb bc, LEADING_ZEROES | 1, 3  	call PrintNumber -	coord hl, 5, 12 +	hlcoord 5, 12  	ld de, wcd6d  	call PlaceString -	coord hl, 8, 14 +	hlcoord 8, 14  	ld de, wTradedEnemyMonOT  	call PlaceString -	coord hl, 8, 16 +	hlcoord 8, 16  	ld de, wTradedEnemyMonOTID  	lb bc, LEADING_ZEROES | 2, 5  	jp PrintNumber diff --git a/engine/overworld/doors.asm b/engine/overworld/doors.asm index ed893773..d38818fa 100755 --- a/engine/overworld/doors.asm +++ b/engine/overworld/doors.asm @@ -11,7 +11,7 @@ IsPlayerStandingOnDoorTile:  	ld a, [hli]  	ld h, [hl]  	ld l, a -	aCoord 8, 9 ; a = lower left background tile under player's sprite +	lda_coord 8, 9 ; a = lower left background tile under player's sprite  	ld b, a  .loop  	ld a, [hli] diff --git a/engine/overworld/ledges.asm b/engine/overworld/ledges.asm index cba544f6..254680a5 100755 --- a/engine/overworld/ledges.asm +++ b/engine/overworld/ledges.asm @@ -8,7 +8,7 @@ HandleLedges::  	predef GetTileAndCoordsInFrontOfPlayer  	ld a, [wSpritePlayerStateData1FacingDirection]  	ld b, a -	aCoord 8, 9 +	lda_coord 8, 9  	ld c, a  	ld a, [wTileInFrontOfPlayer]  	ld d, a diff --git a/engine/overworld/movement.asm b/engine/overworld/movement.asm index a20b3174..a2930993 100644 --- a/engine/overworld/movement.asm +++ b/engine/overworld/movement.asm @@ -13,7 +13,7 @@ UpdatePlayerSprite:  ; background tile the sprite is standing on is greater than $5F, which is  ; the maximum number for map tiles  .checkIfTextBoxInFrontOfSprite -	aCoord 8, 9 +	lda_coord 8, 9  	ldh [hTilePlayerStandingOn], a  	cp MAP_TILESET_SIZE  	jr c, .lowerLeftTileIsMapTile @@ -709,7 +709,7 @@ GetTileSpriteStandsOn:  	add SCREEN_WIDTH ; screen X tile + 20  	ld d, $0  	ld e, a -	coord hl, 0, 0 +	hlcoord 0, 0  	add hl, bc  	add hl, bc  	add hl, bc diff --git a/engine/overworld/player_animations.asm b/engine/overworld/player_animations.asm index fec10daf..69c1eefc 100755 --- a/engine/overworld/player_animations.asm +++ b/engine/overworld/player_animations.asm @@ -358,7 +358,7 @@ IsPlayerStandingOnWarpPadOrHole::  	jr z, .done  	cp c  	jr nz, .nextEntry -	aCoord 8, 9 +	lda_coord 8, 9  	cp [hl]  	jr z, .foundMatch  .nextEntry diff --git a/engine/overworld/player_state.asm b/engine/overworld/player_state.asm index 39c8f756..70326754 100644 --- a/engine/overworld/player_state.asm +++ b/engine/overworld/player_state.asm @@ -204,7 +204,7 @@ IsPlayerStandingOnDoorTileOrWarpTile::  	ld h, [hl]  	ld l, a  	ld de, $1 -	aCoord 8, 9 +	lda_coord 8, 9  	call IsInArray  	jr nc, .done  	ld hl, wd736 @@ -223,28 +223,28 @@ PrintSafariZoneSteps::  	ret c  	cp CERULEAN_CAVE_2F  	ret nc -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, 3  	ld c, 7  	call TextBoxBorder -	coord hl, 1, 1 +	hlcoord 1, 1  	ld de, wSafariSteps  	lb bc, 2, 3  	call PrintNumber -	coord hl, 4, 1 +	hlcoord 4, 1  	ld de, SafariSteps  	call PlaceString -	coord hl, 1, 3 +	hlcoord 1, 3  	ld de, SafariBallText  	call PlaceString  	ld a, [wNumSafariBalls]  	cp 10  	jr nc, .asm_c56d -	coord hl, 5, 3 +	hlcoord 5, 3  	ld a, " "  	ld [hl], a  .asm_c56d -	coord hl, 6, 3 +	hlcoord 6, 3  	ld de, wNumSafariBalls  	lb bc, 1, 2  	jp PrintNumber @@ -267,28 +267,28 @@ _GetTileAndCoordsInFrontOfPlayer:  	and a ; cp SPRITE_FACING_DOWN  	jr nz, .notFacingDown  ; facing down -	aCoord 8, 11 +	lda_coord 8, 11  	inc d  	jr .storeTile  .notFacingDown  	cp SPRITE_FACING_UP  	jr nz, .notFacingUp  ; facing up -	aCoord 8, 7 +	lda_coord 8, 7  	dec d  	jr .storeTile  .notFacingUp  	cp SPRITE_FACING_LEFT  	jr nz, .notFacingLeft  ; facing left -	aCoord 6, 9 +	lda_coord 6, 9  	dec e  	jr .storeTile  .notFacingLeft  	cp SPRITE_FACING_RIGHT  	jr nz, .storeTile  ; facing right -	aCoord 10, 9 +	lda_coord 10, 9  	inc e  .storeTile  	ld c, a @@ -308,7 +308,7 @@ GetTileTwoStepsInFrontOfPlayer:  ; facing down  	ld hl, hPlayerFacing  	set 0, [hl] -	aCoord 8, 13 +	lda_coord 8, 13  	inc d  	jr .storeTile  .notFacingDown @@ -317,7 +317,7 @@ GetTileTwoStepsInFrontOfPlayer:  ; facing up  	ld hl, hPlayerFacing  	set 1, [hl] -	aCoord 8, 5 +	lda_coord 8, 5  	dec d  	jr .storeTile  .notFacingUp @@ -326,7 +326,7 @@ GetTileTwoStepsInFrontOfPlayer:  ; facing left  	ld hl, hPlayerFacing  	set 2, [hl] -	aCoord 4, 9 +	lda_coord 4, 9  	dec e  	jr .storeTile  .notFacingLeft @@ -335,7 +335,7 @@ GetTileTwoStepsInFrontOfPlayer:  ; facing right  	ld hl, hPlayerFacing  	set 3, [hl] -	aCoord 12, 9 +	lda_coord 12, 9  	inc e  .storeTile  	ld c, a diff --git a/engine/pokemon/bills_pc.asm b/engine/pokemon/bills_pc.asm index 0a760a27..0b514111 100644 --- a/engine/pokemon/bills_pc.asm +++ b/engine/pokemon/bills_pc.asm @@ -10,17 +10,17 @@ DisplayPCMainMenu::  	ld a, [wNumHoFTeams]  	and a  	jr nz, .leaguePCAvailable -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, 8  	ld c, 14  	jr .next  .noOaksPC -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, 6  	ld c, 14  	jr .next  .leaguePCAvailable -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, 10  	ld c, 14  .next @@ -30,15 +30,15 @@ DisplayPCMainMenu::  	ld [wMaxMenuItem], a  	CheckEvent EVENT_MET_BILL  	jr nz, .metBill -	coord hl, 2, 2 +	hlcoord 2, 2  	ld de, SomeonesPCText  	jr .next2  .metBill -	coord hl, 2, 2 +	hlcoord 2, 2  	ld de, BillsPCText  .next2  	call PlaceString -	coord hl, 2, 4 +	hlcoord 2, 4  	ld de, wPlayerName  	call PlaceString  	ld l, c @@ -47,7 +47,7 @@ DisplayPCMainMenu::  	call PlaceString  	CheckEvent EVENT_GOT_POKEDEX  	jr z, .noOaksPC2 -	coord hl, 2, 6 +	hlcoord 2, 6  	ld de, OaksPCText  	call PlaceString  	ld a, [wNumHoFTeams] @@ -55,20 +55,20 @@ DisplayPCMainMenu::  	jr z, .noLeaguePC  	ld a, 4  	ld [wMaxMenuItem], a -	coord hl, 2, 8 +	hlcoord 2, 8  	ld de, PKMNLeaguePCText  	call PlaceString -	coord hl, 2, 10 +	hlcoord 2, 10  	ld de, LogOffPCText  	jr .next3  .noLeaguePC -	coord hl, 2, 8 +	hlcoord 2, 8  	ld de, LogOffPCText  	jr .next3  .noOaksPC2  	ld a, $2  	ld [wMaxMenuItem], a -	coord hl, 2, 6 +	hlcoord 2, 6  	ld de, LogOffPCText  .next3  	call PlaceString @@ -119,11 +119,11 @@ BillsPCMenu:  	lb bc, BANK(PokeballTileGraphics), $01  	call CopyVideoData  	call LoadScreenTilesFromBuffer2DisableBGTransfer -	coord hl, 0, 0 +	hlcoord 0, 0  	ld b, 10  	ld c, 12  	call TextBoxBorder -	coord hl, 2, 2 +	hlcoord 2, 2  	ld de, BillsPCMenuText  	call PlaceString  	ld hl, wTopMenuItemY @@ -146,7 +146,7 @@ BillsPCMenu:  	ld [wPlayerMonNumber], a  	ld hl, WhatText  	call PrintText -	coord hl, 9, 14 +	hlcoord 9, 14  	ld b, 2  	ld c, 9  	call TextBoxBorder @@ -156,15 +156,15 @@ BillsPCMenu:  	jr c, .singleDigitBoxNum  ; two digit box num  	sub 9 -	coord hl, 17, 16 +	hlcoord 17, 16  	ld [hl], "1"  	add "0"  	jr .next  .singleDigitBoxNum  	add "1"  .next -	Coorda 18, 16 -	coord hl, 10, 16 +	ldcoord_a 18, 16 +	hlcoord 10, 16  	ld de, BoxNoPCText  	call PlaceString  	ld a, 1 @@ -380,7 +380,7 @@ HMMoveArray:  INCLUDE "data/moves/hm_moves.asm"  DisplayDepositWithdrawMenu: -	coord hl, 9, 10 +	hlcoord 9, 10  	ld b, 6  	ld c, 9  	call TextBoxBorder @@ -390,9 +390,9 @@ DisplayDepositWithdrawMenu:  	jr nz, .next  	ld de, WithdrawPCText  .next -	coord hl, 11, 12 +	hlcoord 11, 12  	call PlaceString -	coord hl, 11, 14 +	hlcoord 11, 14  	ld de, StatsCancelPCText  	call PlaceString  	ld hl, wTopMenuItemY diff --git a/engine/pokemon/evos_moves.asm b/engine/pokemon/evos_moves.asm index 564a8557..ed44f9a6 100755 --- a/engine/pokemon/evos_moves.asm +++ b/engine/pokemon/evos_moves.asm @@ -121,7 +121,7 @@ Evolution_PartyMonLoop: ; loop over party mons  	call DelayFrames  	xor a  	ldh [hAutoBGTransferEnabled], a -	coord hl, 0, 0 +	hlcoord 0, 0  	lb bc, 12, 20  	call ClearScreenArea  	ld a, $1 diff --git a/engine/pokemon/learn_move.asm b/engine/pokemon/learn_move.asm index e7b907d5..8e852fd4 100755 --- a/engine/pokemon/learn_move.asm +++ b/engine/pokemon/learn_move.asm @@ -76,7 +76,7 @@ DontAbandonLearning:  AbandonLearning:  	ld hl, AbandonLearningText  	call PrintText -	coord hl, 14, 7 +	hlcoord 14, 7  	lb bc, 8, 15  	ld a, TWO_OPTION_MENU  	ld [wTextBoxID], a @@ -99,7 +99,7 @@ TryingToLearn:  	push hl  	ld hl, TryingToLearnText  	call PrintText -	coord hl, 14, 7 +	hlcoord 14, 7  	lb bc, 8, 15  	ld a, TWO_OPTION_MENU  	ld [wTextBoxID], a @@ -120,11 +120,11 @@ TryingToLearn:  	push hl  	ld hl, WhichMoveToForgetText  	call PrintText -	coord hl, 4, 7 +	hlcoord 4, 7  	ld b, 4  	ld c, 14  	call TextBoxBorder -	coord hl, 6, 8 +	hlcoord 6, 8  	ld de, wMovesString  	ldh a, [hFlagsFFF6]  	set 2, a diff --git a/engine/pokemon/status_screen.asm b/engine/pokemon/status_screen.asm index c2abeedd..83d33fe5 100755 --- a/engine/pokemon/status_screen.asm +++ b/engine/pokemon/status_screen.asm @@ -105,7 +105,7 @@ StatusScreen:  	push af  	xor a  	ldh [hTilesetType], a -	coord hl, 19, 1 +	hlcoord 19, 1  	lb bc, 6, 10  	call DrawLineBox ; Draws the box around name, HP and status  	ld de, -6 @@ -113,54 +113,54 @@ StatusScreen:  	ld [hl], "<DOT>"  	dec hl  	ld [hl], "№" -	coord hl, 19, 9 +	hlcoord 19, 9  	lb bc, 8, 6  	call DrawLineBox ; Draws the box around types, ID No. and OT -	coord hl, 10, 9 +	hlcoord 10, 9  	ld de, Type1Text  	call PlaceString ; "TYPE1/" -	coord hl, 11, 3 +	hlcoord 11, 3  	predef DrawHP  	ld hl, wStatusScreenHPBarColor  	call GetHealthBarColor  	ld b, SET_PAL_STATUS_SCREEN  	call RunPaletteCommand -	coord hl, 16, 6 +	hlcoord 16, 6  	ld de, wLoadedMonStatus  	call PrintStatusCondition  	jr nz, .StatusWritten -	coord hl, 16, 6 +	hlcoord 16, 6  	ld de, OKText  	call PlaceString ; "OK"  .StatusWritten -	coord hl, 9, 6 +	hlcoord 9, 6  	ld de, StatusText  	call PlaceString ; "STATUS/" -	coord hl, 14, 2 +	hlcoord 14, 2  	call PrintLevel ; Pokémon level  	ld a, [wMonHIndex]  	ld [wd11e], a  	ld [wd0b5], a  	predef IndexToPokedex -	coord hl, 3, 7 +	hlcoord 3, 7  	ld de, wd11e  	lb bc, LEADING_ZEROES | 1, 3  	call PrintNumber ; Pokémon no. -	coord hl, 11, 10 +	hlcoord 11, 10  	predef PrintMonType  	ld hl, NamePointers2  	call .GetStringPointer  	ld d, h  	ld e, l -	coord hl, 9, 1 +	hlcoord 9, 1  	call PlaceString ; Pokémon name  	ld hl, OTPointers  	call .GetStringPointer  	ld d, h  	ld e, l -	coord hl, 12, 16 +	hlcoord 12, 16  	call PlaceString ; OT -	coord hl, 12, 14 +	hlcoord 12, 14  	ld de, wLoadedMonOTID  	lb bc, LEADING_ZEROES | 2, 5  	call PrintNumber ; ID Number @@ -168,7 +168,7 @@ StatusScreen:  	call PrintStatsBox  	call Delay3  	call GBPalNormal -	coord hl, 1, 0 +	hlcoord 1, 0  	call LoadFlippedFrontSpriteByMonIndex ; draw Pokémon picture  	ld a, [wcf91]  	call PlayCry ; play Pokémon cry @@ -252,19 +252,19 @@ PrintStatsBox:  	ld a, d  	and a ; a is 0 from the status screen  	jr nz, .DifferentBox -	coord hl, 0, 8 +	hlcoord 0, 8  	ld b, 8  	ld c, 8  	call TextBoxBorder ; Draws the box -	coord hl, 1, 9 ; Start printing stats from here +	hlcoord 1, 9 ; Start printing stats from here  	ld bc, $19 ; Number offset  	jr .PrintStats  .DifferentBox -	coord hl, 9, 2 +	hlcoord 9, 2  	ld b, 8  	ld c, 9  	call TextBoxBorder -	coord hl, 11, 3 +	hlcoord 11, 3  	ld bc, $18  .PrintStats  	push bc @@ -311,16 +311,16 @@ StatusScreen2:  	ld bc, NUM_MOVES  	call CopyData  	callfar FormatMovesString -	coord hl, 9, 2 +	hlcoord 9, 2  	lb bc, 5, 10  	call ClearScreenArea ; Clear under name -	coord hl, 19, 3 +	hlcoord 19, 3  	ld [hl], $78 -	coord hl, 0, 8 +	hlcoord 0, 8  	ld b, 8  	ld c, 18  	call TextBoxBorder ; Draw move container -	coord hl, 2, 9 +	hlcoord 2, 9  	ld de, wMovesString  	call PlaceString ; Print moves  	ld a, [wNumMovesMinusOne] @@ -329,7 +329,7 @@ StatusScreen2:  	ld a, $4  	sub c  	ld b, a ; Number of moves ? -	coord hl, 11, 10 +	hlcoord 11, 10  	ld de, SCREEN_WIDTH * 2  	ld a, "<BOLD_P>"  	call StatusScreen_PrintPP ; Print "PP" @@ -341,7 +341,7 @@ StatusScreen2:  	call StatusScreen_PrintPP ; Fill the rest with --  .InitPP  	ld hl, wLoadedMonMoves -	coord de, 14, 10 +	decoord 14, 10  	ld b, 0  .PrintPP  	ld a, [hli] @@ -391,7 +391,7 @@ StatusScreen2:  	cp $4  	jr nz, .PrintPP  .PPDone -	coord hl, 9, 3 +	hlcoord 9, 3  	ld de, StatusScreenExpText  	call PlaceString  	ld a, [wLoadedMonLevel] @@ -401,7 +401,7 @@ StatusScreen2:  	inc a  	ld [wLoadedMonLevel], a ; Increase temporarily if not 100  .Level100 -	coord hl, 14, 6 +	hlcoord 14, 6  	ld [hl], "<to>"  	inc hl  	inc hl @@ -409,22 +409,22 @@ StatusScreen2:  	pop af  	ld [wLoadedMonLevel], a  	ld de, wLoadedMonExp -	coord hl, 12, 4 +	hlcoord 12, 4  	lb bc, 3, 7  	call PrintNumber ; exp  	call CalcExpToLevelUp  	ld de, wLoadedMonExp -	coord hl, 7, 6 +	hlcoord 7, 6  	lb bc, 3, 7  	call PrintNumber ; exp needed to level up -	coord hl, 9, 0 +	hlcoord 9, 0  	call StatusScreen_ClearName -	coord hl, 9, 1 +	hlcoord 9, 1  	call StatusScreen_ClearName  	ld a, [wMonHIndex]  	ld [wd11e], a  	call GetMonName -	coord hl, 9, 1 +	hlcoord 9, 1  	call PlaceString  	ld a, $1  	ldh [hAutoBGTransferEnabled], a diff --git a/engine/slots/slot_machine.asm b/engine/slots/slot_machine.asm index 64c14997..a1326240 100755 --- a/engine/slots/slot_machine.asm +++ b/engine/slots/slot_machine.asm @@ -79,11 +79,11 @@ MainSlotMachineLoop:  	ld [wCurrentMenuItem], a  	ld [wLastMenuItem], a  	ld [wMenuWatchMovingOutOfBounds], a -	coord hl, 14, 11 +	hlcoord 14, 11  	ld b, 5  	ld c, 4  	call TextBoxBorder -	coord hl, 16, 12 +	hlcoord 16, 12  	ld de, CoinMultiplierSlotMachineText  	call PlaceString  	call HandleMenuInput @@ -133,7 +133,7 @@ MainSlotMachineLoop:  .skip2  	ld hl, OneMoreGoSlotMachineText  	call PrintText -	coord hl, 14, 12 +	hlcoord 14, 12  	lb bc, 13, 15  	xor a ; YES_NO_MENU  	ld [wTwoOptionMenuID], a @@ -615,7 +615,7 @@ YeahText:  SlotMachine_PrintWinningSymbol:  ; prints winning symbol and down arrow in text box -	coord hl, 2, 14 +	hlcoord 2, 14  	ld a, [wSlotMachineWinningSymbol]  	add $25  	ld [hli], a @@ -627,7 +627,7 @@ SlotMachine_PrintWinningSymbol:  	ld [hli], a  	inc a  	ld [hl], a -	coord hl, 18, 16 +	hlcoord 18, 16  	ld [hl], "▼"  	ret @@ -642,13 +642,13 @@ SlotMachine_SubtractBetFromPlayerCoins:  	predef SubBCDPredef  SlotMachine_PrintCreditCoins: -	coord hl, 5, 1 +	hlcoord 5, 1  	ld de, wPlayerCoins  	ld c, $2  	jp PrintBCDNumber  SlotMachine_PrintPayoutCoins: -	coord hl, 11, 1 +	hlcoord 11, 1  	ld de, wPayoutCoins  	lb bc, LEADING_ZEROES | 2, 4 ; 2 bytes, 4 digits  	jp PrintNumber @@ -725,19 +725,19 @@ SlotMachine_LightBalls:  	jr z, SlotMachine_UpdateTwoCoinBallTiles  SlotMachine_UpdateThreeCoinBallTiles: -	coord hl, 3, 2 +	hlcoord 3, 2  	call SlotMachine_UpdateBallTiles -	coord hl, 3, 10 +	hlcoord 3, 10  	call SlotMachine_UpdateBallTiles  SlotMachine_UpdateTwoCoinBallTiles: -	coord hl, 3, 4 +	hlcoord 3, 4  	call SlotMachine_UpdateBallTiles -	coord hl, 3, 8 +	hlcoord 3, 8  	call SlotMachine_UpdateBallTiles  SlotMachine_UpdateOneCoinBallTiles: -	coord hl, 3, 6 +	hlcoord 3, 6  SlotMachine_UpdateBallTiles:  	ld a, [wNewSlotMachineBallTile] @@ -864,7 +864,7 @@ LoadSlotMachineTiles:  	ld a, BANK(SlotMachineTiles2)  	call FarCopyData2  	ld hl, SlotMachineMap -	coord de, 0, 0 +	decoord 0, 0  	ld bc, SlotMachineMapEnd - SlotMachineMap  	call CopyData  	call EnableLCD | 
