BASICS
  Autoloading


LAST UPDATE
  Mateese, 21-February-1995


DESCRIPTION
  Autoloading is the name for the mechanism that enables players to keep
  equipment over logouts and reboots. It is implemented by a standardized
  way of storing vital data in the players savefile.

  The technical problem of autoloading is to retrieve enough information from
  the object to be able to fully re-initialize a completely different
  instatiation of this object later.
  As micro implements with the properties an own variable management, it is
  not problem save the important information simply by storing all property
  values in the players safefile, and later setting all these values back into
  the new object instatiation.

  Therefore all objects of micro can be and indeed are autoloading by default.

  It is task of the mud's management to keep the balance of the game, e.g. by
  limiting the possible load of players, by making equipment degradable and of
  overall low quality.

  To be autoloadable, an object has to return a non-zero value when queried
  for its P_Autodata property. This value returned is stored in the players
  safefile, and later used to reinitialize the new instatiation by setting
  the new objects P_Autodata to exactly this value.
  Default behaviour is to return P_Props for P_Autodata and vice versa
  setting value given as P_Autodata as new P_Props, thus making every object
  an autoloader.
  However, every object has to check its P_NoAutoload property: if this props
  value is non-zero, the object must not autoload.

  The special P_Autodata query is used instead of P_Props for two reasons:
   - objects may return just the necessary subset of their properties,
     reducing disk usage.
   - objects may deny autoloading, like the Nuclear Chainsaw XS-1138 which is
     to exist just once in the whole game.

  Container objects have to save/restore their contents in a likewise manner:
  they have to take care that their P_Autodata value carries enough
  information to recreate their former contents.


SEE ALSO
  properties(basics)
