TWiki Home Tharsis . Design . SaveAbility Tharsis webs:
Design | Guilds | Combat | Website
Design . { Home | Changes | Index | Search | Go }
The ability to do a complete save of anything, possibly extending to the main-method of saving/editing rooms.

Overview of methods:


-- PumaN - 18 Jul 2003

To address the limitation of being unable to save blueprint objects:

An alternative would be to save inventory objects to a filename pattern of [base] + '.' + [position-in-inventory]

Base of course might include several other .[position] parts when you start to get containers in containers.

This addresses the issue of handling blueprint objects as well as cloned objects in inventories.

-- FantoM - 18 Jul 2003

Presume that every savable object has a method with prototype save(string filename)

When an object is saved this method is first called with a parameter of basedir + canonical_form(file_name(the_object))

This object then saves itself and calls the save method for each object in it's inventory, passing filename + "." + index_in_inventory

Presume now that objects not in the inventory but which should be saved with the object register themselves with the object.

They can be saved now by passing filename + "." + (size_of_inventory + index_in_externalobjects)

This addresses the issue of external objects.

-- FantoM - 18 Jul 2003

Topic SaveAbility . { Edit | Attach | Ref-By | Printable | Diffs | r1.2 | > | r1.1 | More }
Revision r1.2 - 18 Jul 2003 - 12:17 GMT - FantoM
Parents: WebHome > MudLib
Copyright © 2001 by the contributing authors. All material on this collaboration tool is the property of the contributing authors.
Ideas, requests, problems regarding Tharsis? Send feedback.