#include <Cost.h>
Public Member Functions | |
| Cost (const Cost &c) | |
| void | ReadCosts (const TiXmlNode *node) |
| TiXmlNode * | WriteCosts (TiXmlNode *node, const char *name) const |
| long | GetResources () const |
| long | GetCrew () const |
| void | SetResources (unsigned long r) |
| void | SetCrew (unsigned long c) |
| void | Zero () |
| long & | operator[] (long ct) |
| long | operator[] (long ct) const |
| Cost & | operator= (const Cost &c) |
| Cost & | operator *= (double factor) |
| Cost & | operator+= (const Cost &c) |
| Cost & | operator-= (const Cost &c) |
| void | Cleanup () |
Protected Attributes | |
| deque< long > | mMinerals |
| long | mResources |
| long | mCrew |
Friends | |
| bool | operator== (const Cost &a, const Cost &c) |
| Cost | operator * (const Cost &c, double factor) |
| Cost | operator+ (const Cost &a, const Cost &b) |
| Cost | operator- (const Cost &a, const Cost &b) |
This class defines the cost of items, in minerals, resources, and crew. Original Stars! didn't include a crew cost, so it will be 0 to begin with. Just cargo is done in Rules::WriteCargo and Rules::ReadCargo
Definition at line 39 of file Cost.h.
1.4.2-20050421