24 #include <csutil/csstring.h> 27 #define CIRCLES_VALUE_TRIAS 250 28 #define OCTAS_VALUE_TRIAS 50 29 #define HEXAS_VALUE_TRIAS 10 31 #define CIRCLES_VALUE_HEXAS (CIRCLES_VALUE_TRIAS / HEXAS_VALUE_TRIAS) 32 #define CIRCLES_VALUE_OCTAS (CIRCLES_VALUE_TRIAS / OCTAS_VALUE_TRIAS) 33 #define OCTAS_VALUE_HEXAS (OCTAS_VALUE_TRIAS / HEXAS_VALUE_TRIAS) 54 psMoney(
const char * moneyString);
57 void Set(
const char * moneyString);
58 void Set(
int type,
int value);
59 void Set(
int circles,
int octas,
int hexas,
int trias);
126 void Adjust(
int type,
int value );
127 int Get(
int type )
const;
psMoney operator+=(const psMoney &other)
bool EnsureTrias(int minValue)
bool operator>(const psMoney &other) const
bool EnsureHexas(int minValue)
csString ToString() const
Convert psMoney to a string.
csString ToUserString() const
Convert psMoney to user-friendly string.
void Set(const char *moneyString)
void SetCircles(int c)
Set the number of circles.
psMoney operator*(const int mult) const
bool EnsureCircles(int minValue)
void SetOctas(int o)
Set the number of octas.
int GetCircles() const
Get the number of circles.
void Adjust(int type, int value)
int GetHexas() const
Get the number of hexas.
bool EnsureOctas(int minValue)
psMoney Normalized() const
Normalize to have the total match the highest possible number of high value coins.
int GetOctas() const
Get the number of octas.
psMoney operator+(const psMoney &other) const
psMoney operator-(void) const
void AdjustCircles(int c)
void SetHexas(int h)
Set the number of hexas.
void SetTrias(int t)
Set the number of trias.
int GetTotal() const
Get the total in trias.
int GetTrias() const
Get the number of trias.