#include <property.h>
Inheritance diagram for TProperty:
Public Methods | |
TProperty (TRace *Creator=0, TRace *Owner=0) | |
TRace * | getCreator () const |
TRace * | getOwner () const |
virtual bool | load (TDataPackageList *in) |
virtual bool | save (TDataPackageList *out) const |
void | setCreator (TRace *creator) |
void | setOwner (TRace *owner) |
Private Attributes | |
TLink< TRace > | fCreator |
TLink< TRace > | fOwner |
Basically the TProperty class provides two links to TRace called creator and owner. The creator link points to the race which created the object, while the owner link points to the race which owns the stellar object. The owner of a stellar object is the only one which may give orders to the object. The creator is responsible for modificators such as cheap engines. Having an owner and creator allows for example giving a fleet to another race while all properties of the fleet are determined by the creator.
|
Initializes Creator and Owner. |
|
|
|
|
|
Loads a TProperty object. Note that classes that are derived from this class must call TProperty::Load explicitly to load the data correctly.
Reimplemented from TLinkable. Reimplemented in TActionObject, TFleet, TStellarObject, TSubFleet, TSystem, and TSubFleetBasic. |
|
Saves TProperty by adding the data packages to the list. Note that classes that are derived from this class must call TProperty::Save explicitly to save the data correctly.
Reimplemented from TLinkable. Reimplemented in TActionObject, TFleet, TStellarObject, TSubFleet, TSystem, and TSubFleetBasic. |
|
Sets the creator of the object. (Note that the creator of a object normaly never changes during game play.)
|
|
Sets the owner of the object.
|
|
The creator of the object. |
|
The owner of the object. |