From 56ab05c70d6b59a465c8cd83c1c2767790426360 Mon Sep 17 00:00:00 2001 From: Marcus Huderle Date: Thu, 7 Sep 2017 20:48:31 -0700 Subject: Small label improvements --- engine/field_select_screen.asm | 6 +++--- engine/pinball_game/ball_init/ball_init.asm | 2 +- engine/pinball_game/flippers.asm | 4 ++-- wram.asm | 13 +++++++------ 4 files changed, 13 insertions(+), 12 deletions(-) diff --git a/engine/field_select_screen.asm b/engine/field_select_screen.asm index f785989..0941547 100644 --- a/engine/field_select_screen.asm +++ b/engine/field_select_screen.asm @@ -57,7 +57,7 @@ ChooseFieldToPlay: ; 0xd74e ld a, [hNewlyPressedButtons] and (A_BUTTON | B_BUTTON) ret z - ld [wd8f6], a + ld [wFieldSelectPressedButton], a ld a, $18 ; number of frames to blink the border after selecting the Field ld [wFieldSelectBlinkingBorderTimer], a ld a, $1 @@ -69,7 +69,7 @@ ChooseFieldToPlay: ; 0xd74e ret ExitFieldSelectScreen: ; 0xd774 - ld a, [wd8f6] ; this holds the button that was pressed (A or B) + ld a, [wFieldSelectPressedButton] ; this holds the button that was pressed (A or B) bit BIT_A_BUTTON, a jr z, .didntPressA ld hl, FieldSelectConfirmationAnimationData @@ -83,7 +83,7 @@ ExitFieldSelectScreen: ; 0xd774 push af call FadeOut call DisableLCD - ld a, [wd8f6] + ld a, [wFieldSelectPressedButton] bit BIT_A_BUTTON, a jr z, .pressedB ld a, [wSelectedFieldIndex] diff --git a/engine/pinball_game/ball_init/ball_init.asm b/engine/pinball_game/ball_init/ball_init.asm index e7a13c7..3d894da 100644 --- a/engine/pinball_game/ball_init/ball_init.asm +++ b/engine/pinball_game/ball_init/ball_init.asm @@ -19,7 +19,7 @@ InitBallForStage: ; 0x83ba ld [wd7b0], a ld [wd7b1], a ld [wd7b4], a - ld [wd7b5], a + ld [wd7b4 + 1], a ld [wBallSpin], a ld [wBallRotation], a inc a diff --git a/engine/pinball_game/flippers.asm b/engine/pinball_game/flippers.asm index c6bd5ab..d71419a 100644 --- a/engine/pinball_game/flippers.asm +++ b/engine/pinball_game/flippers.asm @@ -88,7 +88,7 @@ Func_e118: ; 0xe118 ld a, l ld [wd7b4], a ld a, h - ld [wd7b5], a + ld [wd7b4 + 1], a ld a, [wd7b2] ld c, a ld a, [wd7b3] @@ -195,7 +195,7 @@ CheckRightFlipperCollision: ; 0xe226 ; collision with flipper occurred ld a, [wd7b4] ld [$ffc0], a - ld a, [wd7b5] + ld a, [wd7b4 + 1] ld [$ffc1], a ret diff --git a/wram.asm b/wram.asm index 12e3f6a..5c96d11 100644 --- a/wram.asm +++ b/wram.asm @@ -1755,10 +1755,7 @@ wd7b3:: ; 0xd7b3 ds $1 wd7b4:: ; 0xd7b4 - ds $1 - -wd7b5:: ; 0xd7b5 - ds $1 + ds $2 wLeftFlipperAnimationState:: ; 0xd7b6 ds $1 @@ -2238,10 +2235,14 @@ wScreenState:: ; 0xd8f2 ds $3 -wd8f6:: ; 0xd8f6 - ds $12 +wFieldSelectPressedButton:: ; 0xd8f6 +; Holds which button was pressed on the field select screen. (A or B) + ds $1 + + ds $11 wd908:: ; 0xd908 +; unused ds $1 wTitleScreenCursorSelection:: ; 0xd909 -- cgit v1.2.3