View Full Version : Export/Save state of level

12-11-2012, 07:51 AM
I want to import the level, change some of the loaded objects and save the level again.
Is there some kind of best practise?

If there isn't i would save all objects in some kind of XML file or (if there is some kind of "masterarray with all objects") serialise them with pickle (http://docs.python.org/2/library/pickle.html)for python.
Any suggestions regarding these ideas?

The Question is somewhat related to this question (http://forum.worldviz.com/showthread.php?t=4418), except that i don't really care about the exported format, as long as i can import it again.

12-11-2012, 10:36 AM
Can you explain how the objects are changing? Perhaps you can just save information to a text file about how they changed.

12-11-2012, 02:57 PM
You can export the scene to the osg format and load it later. See the last post in this (http://forum.worldviz.com/showthread.php?t=4418) thread.

12-18-2012, 02:25 AM
Thanks that will work perfect.
Load Scene (including objects) interact with them and safe the Scene again. I could use a txt file or XML, but if I can directly save as osg, it's much easier.