mirror of https://github.com/zeldaret/oot.git
Use `CHECK_BTN_ANY` more
This commit is contained in:
parent
fffd300be3
commit
f93eee8320
|
|
@ -574,7 +574,7 @@ void EnTorch2_Update(Actor* thisx, GlobalContext* globalCtx2) {
|
|||
|
||||
pad54 = input->prev.button ^ input->cur.button;
|
||||
input->press.button = input->cur.button & pad54;
|
||||
if (input->cur.button & BTN_R) {
|
||||
if (CHECK_BTN_ANY(input->cur.button, BTN_R)) {
|
||||
input->cur.button = ((sCounterState == 0) && (this->swordState == 0)) ? BTN_R : input->cur.button ^ BTN_R;
|
||||
}
|
||||
input->rel.button = input->prev.button & pad54;
|
||||
|
|
|
|||
|
|
@ -319,21 +319,21 @@ void KaleidoScope_DrawDebugEditor(GlobalContext* globalCtx) {
|
|||
heldDBtnTimer = 16;
|
||||
}
|
||||
|
||||
if (dBtnInput & BTN_DDOWN) {
|
||||
if (CHECK_BTN_ANY(dBtnInput, BTN_DDOWN)) {
|
||||
if ((u32)++curRow > 10) {
|
||||
curRow = 0;
|
||||
}
|
||||
curSection = sRowFirstSections[curRow];
|
||||
} else if (dBtnInput & BTN_DUP) {
|
||||
} else if (CHECK_BTN_ANY(dBtnInput, BTN_DUP)) {
|
||||
if (--curRow < 0) {
|
||||
curRow = 22;
|
||||
}
|
||||
curSection = sRowFirstSections[curRow];
|
||||
} else if (dBtnInput & BTN_DLEFT) {
|
||||
} else if (CHECK_BTN_ANY(dBtnInput, BTN_DLEFT)) {
|
||||
if (--curSection < 0) {
|
||||
curSection = 0x5C;
|
||||
}
|
||||
} else if (dBtnInput & BTN_DRIGHT) {
|
||||
} else if (CHECK_BTN_ANY(dBtnInput, BTN_DRIGHT)) {
|
||||
if (++curSection > 0x5C) {
|
||||
curSection = 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue