Several codes that used to work perfectly now randomly generate errors.
I need to get the value of mixer volumes.
I use the variable _preferences.volumes['music'] and _preferences.volumes['sfx'], and later pass them to a screen.
This worked like a charm, and suddenly generates errors when I build distributions.
Code: Select all
I'm sorry, but an uncaught exception occurred.
While running game code:
File "game/script.rpy", line 97, in script
define quick_boutons = [
File "game/script.rpy", line 101, in <module>
"action":Show("ecran_pause",music=_preferences.volumes['music'],son=_preferences.volumes['sfx']),
KeyError: 'music'
-- Full Traceback ------------------------------------------------------------
Full traceback:
File "C:\Documents and Settings\Korova\Bureau\Clair_Obscur-0.1-win\Clair_Obscur-0.1-win\renpy\bootstrap.py", line 288, in bootstrap
renpy.main.main()
File "C:\Documents and Settings\Korova\Bureau\Clair_Obscur-0.1-win\Clair_Obscur-0.1-win\renpy\main.py", line 360, in main
game.context().run(node)
File "game/script.rpy", line 97, in script
define quick_boutons = [
File "C:\Documents and Settings\Korova\Bureau\Clair_Obscur-0.1-win\Clair_Obscur-0.1-win\renpy\ast.py", line 1716, in execute
value = renpy.python.py_eval_bytecode(self.code.bytecode)
File "C:\Documents and Settings\Korova\Bureau\Clair_Obscur-0.1-win\Clair_Obscur-0.1-win\renpy\python.py", line 1472, in py_eval_bytecode
return eval(bytecode, globals, locals)
File "game/script.rpy", line 101, in <module>
"action":Show("ecran_pause",music=_preferences.volumes['music'],son=_preferences.volumes['sfx']),
KeyError: 'music'
Windows-XP-5.1.2600-SP2
Ren'Py 6.99.4.467
clairobscur 0.1
I had the error once under linux, and now under windows (XP), no problem on Mac OS (I develop either on linux or Mac)
I don't understand the problem, can someone help me ?