ref: 847843d866aa79727f7d1dd98c2b212e8b5053ef
parent: 9f53825ce2701f94470a98b3decd8013fbeba91a
author: yenatch <[email protected]>
date: Sat Sep 7 19:49:20 EDT 2013
rename BUTTON_A and BUTTON_B constants to A_BUTTON and B_BUTTON
--- a/common/joypad.asm
+++ b/common/joypad.asm
@@ -101,8 +101,8 @@
; Now that we have the input, we can do stuff with it.
; For example, soft reset:
- and BUTTON_A | BUTTON_B | SELECT | START
- cp BUTTON_A | BUTTON_B | SELECT | START
+ and A_BUTTON | B_BUTTON | SELECT | START
+ cp A_BUTTON | B_BUTTON | SELECT | START
jp z, Reset
ret
@@ -283,11 +283,11 @@
pop bc
ld a, [hJoyDown]
- cp D_UP | SELECT | BUTTON_B
+ cp D_UP | SELECT | B_BUTTON
jr z, .asm_a34
ld a, [$ffa9]
- and START | BUTTON_A
+ and START | A_BUTTON
jr nz, .asm_a34
dec c
@@ -306,7 +306,7 @@
call DelayFrame
call GetJoypadPublic
ld a, [hJoyPressed]
- and BUTTON_A | BUTTON_B
+ and A_BUTTON | B_BUTTON
ret nz
call RTC
jr Functiona36
@@ -382,7 +382,7 @@
Functionaa5: ; aa5
call Functiona57
ld a, [$ffa9]
- and BUTTON_A | BUTTON_B
+ and A_BUTTON | B_BUTTON
jr z, Functionaa5
ret
; aaf
--- a/common/text.asm
+++ b/common/text.asm
@@ -1054,7 +1054,7 @@
push bc
call GetJoypadPublic
ld a, [hJoyDown]
- and BUTTON_A | BUTTON_B
+ and A_BUTTON | B_BUTTON
jr nz, .asm_14fd
ld c, 30
call DelayFrames
@@ -1136,7 +1136,7 @@
ld [hli], a
call GetJoypadPublic
ld a, [hJoyDown]
- and BUTTON_A | BUTTON_B
+ and A_BUTTON | B_BUTTON
jr nz, .asm_155a
ld c, 10
call DelayFrames
--- a/constants.asm
+++ b/constants.asm
@@ -170,8 +170,8 @@
D_PAD EQU %00100000
NO_INPUT EQU %00000000
-BUTTON_A EQU %00000001
-BUTTON_B EQU %00000010
+A_BUTTON EQU %00000001
+B_BUTTON EQU %00000010
SELECT EQU %00000100
START EQU %00001000
D_RIGHT EQU %00010000
--- a/main.asm
+++ b/main.asm
@@ -23902,9 +23902,9 @@
call .PrintMenuAccount
call Function1f1a
ld a, [$cf73]
- cp BUTTON_B
+ cp B_BUTTON
jr z, .b
- cp BUTTON_A
+ cp A_BUTTON
jr z, .a
jr .loop
.a
@@ -31482,11 +31482,11 @@
call Functiona57
ld a, [hJoyPressed]
- and BUTTON_B
+ and B_BUTTON
jr nz, .asm_16c95
ld a, [hJoyPressed]
- and BUTTON_A
+ and A_BUTTON
jr nz, .asm_16c82
call Function16ca0
@@ -61158,7 +61158,7 @@
ld hl, .data_802e8
add hl, de
ld a, [CurInput]
- and BUTTON_A | BUTTON_B | SELECT | START
+ and A_BUTTON | B_BUTTON | SELECT | START
or [hl]
ld [CurInput], a
ret
@@ -70599,7 +70599,7 @@
CheckAPressOW: ; 96999
ld a, [hJoyPressed]
- and BUTTON_A
+ and A_BUTTON
ret z
call TryObjectEvent
ret c
@@ -75887,7 +75887,7 @@
Options_Cancel: ; e4520
ld a, [hJoyPressed]
- and BUTTON_A
+ and A_BUTTON
jr nz, .asm_e4528
and a
ret
@@ -90228,7 +90228,7 @@
DudeAutoInput_A: ; 1de29f
db NO_INPUT, $50
- db BUTTON_A, $00
+ db A_BUTTON, $00
db NO_INPUT, $ff ; end
; 1de2a5
@@ -90236,7 +90236,7 @@
db NO_INPUT, $08
db D_RIGHT, $00
db NO_INPUT, $08
- db BUTTON_A, $00
+ db A_BUTTON, $00
db NO_INPUT, $ff ; end
; 1de2af
@@ -90250,7 +90250,7 @@
db NO_INPUT, $fe
db NO_INPUT, $fe
db NO_INPUT, $fe
- db BUTTON_A, $00
+ db A_BUTTON, $00
db NO_INPUT, $ff ; end
; 1de2c5