mirror of
https://github.com/libretro/scummvm.git
synced 2025-01-16 23:19:49 +00:00
DREAMWEB: Clearer API for enterCode
This commit is contained in:
parent
dadabd252a
commit
fb9b5d11ef
@ -72,10 +72,10 @@ void DreamGenContext::showKeypad() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void DreamGenContext::enterCode() {
|
void DreamGenContext::enterCode() {
|
||||||
enterCode(ax, cx);
|
enterCode(al, ah, cl, ch);
|
||||||
}
|
}
|
||||||
|
|
||||||
void DreamGenContext::enterCode(uint16 keypadAx, uint16 keypadCx) {
|
void DreamGenContext::enterCode(uint8 digit0, uint8 digit1, uint8 digit2, uint8 digit3) {
|
||||||
RectWithCallback keypadList[] = {
|
RectWithCallback keypadList[] = {
|
||||||
{ kKeypadx+9,kKeypadx+30,kKeypady+9,kKeypady+22,&DreamGenContext::buttonOne },
|
{ kKeypadx+9,kKeypadx+30,kKeypady+9,kKeypady+22,&DreamGenContext::buttonOne },
|
||||||
{ kKeypadx+31,kKeypadx+52,kKeypady+9,kKeypady+22,&DreamGenContext::buttonTwo },
|
{ kKeypadx+31,kKeypadx+52,kKeypady+9,kKeypady+22,&DreamGenContext::buttonTwo },
|
||||||
@ -93,8 +93,10 @@ void DreamGenContext::enterCode(uint16 keypadAx, uint16 keypadCx) {
|
|||||||
{ 0xFFFF,0,0,0,0 }
|
{ 0xFFFF,0,0,0,0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
data.word(kKeypadax) = keypadAx;
|
data.byte(kKeypadax+0) = digit0;
|
||||||
data.word(kKeypadcx) = keypadCx;
|
data.byte(kKeypadax+1) = digit1;
|
||||||
|
data.byte(kKeypadcx+0) = digit2;
|
||||||
|
data.byte(kKeypadcx+1) = digit3;
|
||||||
getRidOfReels();
|
getRidOfReels();
|
||||||
loadKeypad();
|
loadKeypad();
|
||||||
createPanel();
|
createPanel();
|
||||||
|
@ -396,6 +396,6 @@
|
|||||||
void buttonNought();
|
void buttonNought();
|
||||||
void buttonEnter();
|
void buttonEnter();
|
||||||
void buttonPress(uint8 buttonId);
|
void buttonPress(uint8 buttonId);
|
||||||
void enterCode(uint16 keypadAx, uint16 keypadCx);
|
void enterCode(uint8 digit0, uint8 digit1, uint8 digit2, uint8 digit3);
|
||||||
void enterCode();
|
void enterCode();
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user