Fix op_read_char to accept optional timing arguments

Lost Pig calls read_char with only the required first operand.
The Z-machine spec says time and input_routine are optional.
This commit is contained in:
Jared Miller 2026-02-10 14:48:57 -05:00
parent 4313941334
commit 802c72819c
Signed by: shmup
GPG key ID: 22B5C6D66A38B06C

View file

@ -906,7 +906,7 @@ class ZCpu:
"""Play sound effect (no-op - sound not supported in text MUD)."""
pass
def op_read_char(self, unused, time, input_routine):
def op_read_char(self, unused, time=0, input_routine=0):
"""Read a single character from input stream 0 (keyboard).
Optionally, call a routine periodically to decide whether or