I've looked everywhere, but I can't find how to correctly allow a player to input an answer, let alone a numerical answer. Renpy gives me an error with this code, stating that
Code: Select all
I'm sorry, but an uncaught exception occurred.
While running game code:
File "game/script.rpy", line 180, in script
$ number = renpy.input(allow="0123456789")
File "game/script.rpy", line 180, in <module>
$ number = renpy.input(allow="0123456789")
TypeError: input() takes at least 1 argument (1 given)
-- Full Traceback ------------------------------------------------------------
Full traceback:
File "game/script.rpy", line 180, in script
$ number = renpy.input(allow="0123456789")
File "C:\Users\14076\Downloads\renpy-7.3.5-sdk\renpy\ast.py", line 914, in execute
renpy.python.py_exec_bytecode(self.code.bytecode, self.hide, store=self.store)
File "C:\Users\14076\Downloads\renpy-7.3.5-sdk\renpy\python.py", line 2028, in py_exec_bytecode
exec bytecode in globals, locals
File "game/script.rpy", line 180, in <module>
$ number = renpy.input(allow="0123456789")
TypeError: input() takes at least 1 argument (1 given)
Windows-8-6.2.9200
Ren'Py 7.3.5.606
And the 1.0
Tue Apr 27 18:40:02 2021
Code: Select all
$ number = renpy.input(allow="0123456789")
if number = 65:
jump puzzlecorrect
else:
jump puzzlewrong
What am I doing wrong? I generally only use multiple choice questions, hence my confusion. Thank you!