mirror of
https://github.com/libretro/scummvm.git
synced 2025-03-06 18:27:26 +00:00
DREAMWEB: Move 'readKey' from dreamgen
This commit is contained in:
parent
98d3a6cc88
commit
d4646c335a
@ -98,6 +98,7 @@ p = parser(skip_binary_data = [
|
||||
'monitorfile22',
|
||||
'monitorfile23',
|
||||
'monitorfile24',
|
||||
'introtextfile',
|
||||
])
|
||||
p.strip_path = 3
|
||||
context = p.parse('dreamweb/dreamweb.asm')
|
||||
@ -475,6 +476,7 @@ generator = cpp(context, "DreamGen", blacklist = [
|
||||
], skip_output = [
|
||||
# These functions are processed but not output
|
||||
'dreamweb',
|
||||
'readkey',
|
||||
], skip_dispatch_call = True, skip_addr_constants = True,
|
||||
header_omit_blacklisted = True,
|
||||
function_name_remapping = {
|
||||
|
@ -11096,24 +11096,6 @@ _tmp1:
|
||||
multiGet();
|
||||
}
|
||||
|
||||
void DreamGenContext::readKey() {
|
||||
STACK_CHECK;
|
||||
bx = data.word(kBufferout);
|
||||
_cmp(bx, data.word(kBufferin));
|
||||
if (flags.z())
|
||||
goto nokey;
|
||||
_inc(bx);
|
||||
_and(bx, 15);
|
||||
data.word(kBufferout) = bx;
|
||||
di = offset_keybuffer;
|
||||
_add(di, bx);
|
||||
al = cs.byte(di);
|
||||
data.byte(kCurrentkey) = al;
|
||||
return;
|
||||
nokey:
|
||||
data.byte(kCurrentkey) = 0;
|
||||
}
|
||||
|
||||
void DreamGenContext::getRidOfReels() {
|
||||
STACK_CHECK;
|
||||
_cmp(data.byte(kRoomloaded), 0);
|
||||
|
@ -3056,6 +3056,23 @@ void DreamGenContext::atmospheres() {
|
||||
cancelCh0();
|
||||
}
|
||||
|
||||
void DreamGenContext::readKey() {
|
||||
STACK_CHECK;
|
||||
bx = data.word(kBufferout);
|
||||
_cmp(bx, data.word(kBufferin));
|
||||
if (flags.z())
|
||||
goto nokey;
|
||||
_inc(bx);
|
||||
_and(bx, 15);
|
||||
data.word(kBufferout) = bx;
|
||||
di = offset_keybuffer;
|
||||
_add(di, bx);
|
||||
al = cs.byte(di);
|
||||
data.byte(kCurrentkey) = al;
|
||||
return;
|
||||
nokey:
|
||||
data.byte(kCurrentkey) = 0;
|
||||
}
|
||||
|
||||
|
||||
} /*namespace dreamgen */
|
||||
|
Loading…
x
Reference in New Issue
Block a user