*Solved* Error message when saving

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Post Reply
Message
Author
Grabb505
Newbie
Posts: 2
Joined: Sun Jan 21, 2018 6:24 am
Contact:

*Solved* Error message when saving

#1 Post by Grabb505 »

Hi!

I am trying to develop a new game and I've been working with Renpyper for the last few hours to implement a simple way to add moods and traits since I couldn't figure out how to do it in normal Ren'py.

Ever since I did this, I've been getting error messages when trying to save my game. I really don't understand what happened here.
Anyone able to help?

The only change I know that I have done to the Save page is that I increased the amount of save slots available from 3x2 to 5x3 (with smaller icons obviously to make it fit).

When I make a comment out of "call renpyper_init" then I can save.

Code: Select all

I'm sorry, but an uncaught exception occurred.

While running game code:
  File "renpy/common/00action_file.rpy", line 361, in __call__
    renpy.save(fn, extra_info=save_name)
Exception: Could not pickle <module 'math' (built-in)>. (perhaps store.math = <module 'math' (built-in)>)

-- Full Traceback ------------------------------------------------------------

Full traceback:
  File "renpy/common/_layout/screen_load_save.rpym", line 35, in script
    $ ui.interact()
  File "D:\renpy-6.99.14-sdk\renpy\ast.py", line 848, in execute
    renpy.python.py_exec_bytecode(self.code.bytecode, self.hide, store=self.store)
  File "D:\renpy-6.99.14-sdk\renpy\python.py", line 1804, in py_exec_bytecode
    exec bytecode in globals, locals
  File "renpy/common/_layout/screen_load_save.rpym", line 35, in <module>
    $ ui.interact()
  File "D:\renpy-6.99.14-sdk\renpy\ui.py", line 287, in interact
    rv = renpy.game.interface.interact(roll_forward=roll_forward, **kwargs)
  File "D:\renpy-6.99.14-sdk\renpy\display\core.py", line 2620, in interact
    repeat, rv = self.interact_core(preloads=preloads, trans_pause=trans_pause, **kwargs)
  File "D:\renpy-6.99.14-sdk\renpy\display\core.py", line 3375, in interact_core
    rv = root_widget.event(ev, x, y, 0)
  File "D:\renpy-6.99.14-sdk\renpy\display\layout.py", line 986, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "D:\renpy-6.99.14-sdk\renpy\display\layout.py", line 986, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "D:\renpy-6.99.14-sdk\renpy\display\layout.py", line 986, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "D:\renpy-6.99.14-sdk\renpy\display\screen.py", line 667, in event
    rv = self.child.event(ev, x, y, st)
  File "D:\renpy-6.99.14-sdk\renpy\display\layout.py", line 986, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "D:\renpy-6.99.14-sdk\renpy\display\layout.py", line 239, in event
    rv = d.event(ev, x - xo, y - yo, st)
  File "D:\renpy-6.99.14-sdk\renpy\display\layout.py", line 986, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "D:\renpy-6.99.14-sdk\renpy\display\layout.py", line 239, in event
    rv = d.event(ev, x - xo, y - yo, st)
  File "D:\renpy-6.99.14-sdk\renpy\display\layout.py", line 986, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "D:\renpy-6.99.14-sdk\renpy\display\layout.py", line 239, in event
    rv = d.event(ev, x - xo, y - yo, st)
  File "D:\renpy-6.99.14-sdk\renpy\display\behavior.py", line 897, in event
    return handle_click(self.clicked)
  File "D:\renpy-6.99.14-sdk\renpy\display\behavior.py", line 832, in handle_click
    rv = run(action)
  File "D:\renpy-6.99.14-sdk\renpy\display\behavior.py", line 306, in run
    return action(*args, **kwargs)
  File "renpy/common/00action_file.rpy", line 361, in __call__
    renpy.save(fn, extra_info=save_name)
  File "D:\renpy-6.99.14-sdk\renpy\loadsave.py", line 402, in save
    dump((roots, renpy.game.log), logf)
  File "D:\renpy-6.99.14-sdk\renpy\loadsave.py", line 46, in dump
    cPickle.dump(o, f, cPickle.HIGHEST_PROTOCOL)
  File "D:\renpy-6.99.14-sdk\renpy\python.py", line 1890, in module_pickle
    raise Exception("Could not pickle {!r}.".format(module))
Exception: Could not pickle <module 'math' (built-in)>. (perhaps store.math = <module 'math' (built-in)>)

Windows-8-6.2.9200
Ren'Py 6.99.14.3135
College Seduction 0.0.1
Any help would be greatly appreciated!
Regards,
Grabb505
Last edited by Grabb505 on Sun Jan 21, 2018 7:57 am, edited 2 times in total.

User avatar
Remix
Eileen-Class Veteran
Posts: 1628
Joined: Tue May 30, 2017 6:10 am
Completed: None... yet (as I'm still looking for an artist)
Projects: An un-named anime based trainer game
Contact:

Re: Error message when saving

#2 Post by Remix »

How are you importing the math module, where are you using it and can you alter the call?
(are you importing inside a saved function or class basically)
Frameworks & Scriptlets:

Grabb505
Newbie
Posts: 2
Joined: Sun Jan 21, 2018 6:24 am
Contact:

Re: Error message when saving

#3 Post by Grabb505 »

Remix wrote: Sun Jan 21, 2018 7:23 am How are you importing the math module, where are you using it and can you alter the call?
(are you importing inside a saved function or class basically)
I am not doing anything manually, it just appears when I use the renpyper thing.
I figured out how to do variables without Renpyper however, so this can be closed as its not longer an issue.

Thanks for the help!

Post Reply

Who is online

Users browsing this forum: IrisColt, solarisdreams