The first one is, in the example renpy.input function in the Text Input doc (https://www.renpy.org/doc/html/input.html), an argument 'with_none' is shown, but nowhere on that page does it describe what it is or does. Does anyone know?
Secondly, my main question is this, I was trying to have a typewriter sound effect play each time the player strikes a key to enter their name, and I was following this forum post: viewtopic.php?t=40217
I wrote this code:
Code: Select all
init python:
def typewriter():
renpy.music.play("sounds/typewriter.ogg", channel="audio")
...
python:
nameHero = renpy.input(_("What {i}is{/i} your name?"), length = 24, changed = typewriter)
Code: Select all
I'm sorry, but an uncaught exception occurred.
While running game code:
File "game/script_1_name.rpy", line 173, in script
python:
File "game/script_1_name.rpy", line 175, in <module>
nameHero = renpy.input(_("What {i}is{/i} your name?"), length = 24, changed = typewriter)
TypeError: input() got an unexpected keyword argument 'changed'
-- Full Traceback ------------------------------------------------------------
Full traceback:
File "game/script_1_name.rpy", line 173, in script
python:
File "C:\Users\Derp\Desktop\renpy-7.3.2-sdk\renpy\ast.py", line 912, in execute
renpy.python.py_exec_bytecode(self.code.bytecode, self.hide, store=self.store)
File "C:\Users\Derp\Desktop\renpy-7.3.2-sdk\renpy\python.py", line 2004, in py_exec_bytecode
exec bytecode in globals, locals
File "game/script_1_name.rpy", line 175, in <module>
nameHero = renpy.input(_("What {i}is{/i} your name?"), length = 24, changed = typewriter)
TypeError: input() got an unexpected keyword argument 'changed'
Windows-8-6.2.9200
Ren'Py 7.3.2.320
Derp 1.0
Wed Sep 25 11:59:37 2019