summaryrefslogtreecommitdiff
path: root/engine/menu/draw_start_menu.asm
diff options
context:
space:
mode:
authorxCrystal <rgr.crystal@gmail.com>2017-12-30 01:54:27 +0100
committerxCrystal <rgr.crystal@gmail.com>2017-12-30 01:54:27 +0100
commit237aeb8fbdb204948d611830565d4a00c6b0ab70 (patch)
tree94dea41b4af4a3374a1a1e2f56665cff2ea5baa9 /engine/menu/draw_start_menu.asm
parent94b9a86c8b9b6ea29653e98921205056790d6617 (diff)
Add space between arguments in assembly instructions and remove redundant a in instructions like add a, x
Diffstat (limited to 'engine/menu/draw_start_menu.asm')
-rw-r--r--engine/menu/draw_start_menu.asm72
1 files changed, 36 insertions, 36 deletions
diff --git a/engine/menu/draw_start_menu.asm b/engine/menu/draw_start_menu.asm
index 83a81aac..11777dc6 100644
--- a/engine/menu/draw_start_menu.asm
+++ b/engine/menu/draw_start_menu.asm
@@ -3,60 +3,60 @@ DrawStartMenu:
CheckEvent EVENT_GOT_POKEDEX
; menu with pokedex
coord hl, 10, 0
- ld b,$0e
- ld c,$08
- jr nz,.drawTextBoxBorder
+ ld b, $0e
+ ld c, $08
+ jr nz, .drawTextBoxBorder
; shorter menu if the player doesn't have the pokedex
coord hl, 10, 0
- ld b,$0c
- ld c,$08
+ ld b, $0c
+ ld c, $08
.drawTextBoxBorder
call TextBoxBorder
- ld a,D_DOWN | D_UP | START | B_BUTTON | A_BUTTON
- ld [wMenuWatchedKeys],a
- ld a,$02
- ld [wTopMenuItemY],a ; Y position of first menu choice
- ld a,$0b
- ld [wTopMenuItemX],a ; X position of first menu choice
- ld a,[wBattleAndStartSavedMenuItem] ; remembered menu selection from last time
- ld [wCurrentMenuItem],a
- ld [wLastMenuItem],a
+ ld a, D_DOWN | D_UP | START | B_BUTTON | A_BUTTON
+ ld [wMenuWatchedKeys], a
+ ld a, $02
+ ld [wTopMenuItemY], a ; Y position of first menu choice
+ ld a, $0b
+ ld [wTopMenuItemX], a ; X position of first menu choice
+ ld a, [wBattleAndStartSavedMenuItem] ; remembered menu selection from last time
+ ld [wCurrentMenuItem], a
+ ld [wLastMenuItem], a
xor a
- ld [wMenuWatchMovingOutOfBounds],a
- ld hl,wd730
- set 6,[hl] ; no pauses between printing each letter
+ ld [wMenuWatchMovingOutOfBounds], a
+ ld hl, wd730
+ set 6, [hl] ; no pauses between printing each letter
coord hl, 12, 2
CheckEvent EVENT_GOT_POKEDEX
; case for not having pokedex
- ld a,$06
- jr z,.storeMenuItemCount
+ ld a, $06
+ jr z, .storeMenuItemCount
; case for having pokedex
- ld de,StartMenuPokedexText
+ ld de, StartMenuPokedexText
call PrintStartMenuItem
- ld a,$07
+ ld a, $07
.storeMenuItemCount
- ld [wMaxMenuItem],a ; number of menu items
- ld de,StartMenuPokemonText
+ ld [wMaxMenuItem], a ; number of menu items
+ ld de, StartMenuPokemonText
call PrintStartMenuItem
- ld de,StartMenuItemText
+ ld de, StartMenuItemText
call PrintStartMenuItem
- ld de,wPlayerName ; player's name
+ ld de, wPlayerName ; player's name
call PrintStartMenuItem
- ld a,[wd72e]
- bit 6,a ; is the player using the link feature?
+ ld a, [wd72e]
+ bit 6, a ; is the player using the link feature?
; case for not using link feature
- ld de,StartMenuSaveText
- jr z,.printSaveOrResetText
+ ld de, StartMenuSaveText
+ jr z, .printSaveOrResetText
; case for using link feature
- ld de,StartMenuResetText
+ ld de, StartMenuResetText
.printSaveOrResetText
call PrintStartMenuItem
- ld de,StartMenuOptionText
+ ld de, StartMenuOptionText
call PrintStartMenuItem
- ld de,StartMenuExitText
+ ld de, StartMenuExitText
call PlaceString
- ld hl,wd730
- res 6,[hl] ; turn pauses between printing letters back on
+ ld hl, wd730
+ res 6, [hl] ; turn pauses between printing letters back on
ret
StartMenuPokedexText:
@@ -84,6 +84,6 @@ PrintStartMenuItem:
push hl
call PlaceString
pop hl
- ld de,SCREEN_WIDTH * 2
- add hl,de
+ ld de, SCREEN_WIDTH * 2
+ add hl, de
ret