Simulator::cEmpire class

An empire in Space Stage.

Base classes

class ISimulatorSerializableRefCounted
class cIdentityColorable
A Simulator class inherited by all those classes that can have an identity color, such as empires, tribes, etc.

Public static variables

static const uint32_t TYPE
static const uint32_t NOUN_ID

Public static functions

static auto CaptureSystem(cStarRecord* pStarRecord, uint32_t empireID) -> void
Captures a star system for a specific empire.

Public functions

auto GetEmpireID() const -> uint32_t
Returns the political ID of this empire.
auto GetHomeStarRecord() -> cStarRecord*
auto GetSpeciesProfile() -> cSpeciesProfile*
auto SetSpeciesProfile(cSpeciesProfile* pSpecies) -> void
auto UpdateAndGetColor() -> Math::ColorRGB
Calculates and returns the identity color of the empire, based on the mIDColorID field.
auto AddRef() -> int pure virtual
auto Release() -> int pure virtual
auto Cast(uint32_t typeID) const -> void* pure virtual

Public variables

eastl::string16 mEmpireName
int mCurrentGameMode
int mFlags
EmpireTrait mTrait
A member of EmpireTrait enum, EmpireTrait::kEmpireTraitNone.
Archetypes mArchetype
A member of Archetypes enum, Archetypes::kArchetypePlayerWanderer by default.
eastl::vector<cEmpirePtr> mEnemies
eastl::vector<cEmpirePtr> mAllies
int mPoliticalID
eastl::vector<cStarRecordPtr> mStars
eastl::vector<cStarRecordPtr> mNextStarTowardsHome
StarID mHomeStar
PlanetID mHomePlanet
ResourceKey mUFOKey
ResourceKey mCaptainKey
int mEmpireMoney
char mTravelDistance
int field_D8
float field_DC
float field_E0
float field_E4
float field_E8
float field_EC
eastl::vector<int> field_F0
ICityMusicPtr mpCityMusic
cCultureSet mCultureSet
cGonzagoTimer field_128
eastl::list<uint32_t> mAdventureList

Function documentation

static void Simulator::cEmpire::CaptureSystem(cStarRecord* pStarRecord, uint32_t empireID)

Captures a star system for a specific empire.

pStarRecord The star system to capture.
empireID Political ID of the empire that will become the owner.

Math::ColorRGB Simulator::cEmpire::UpdateAndGetColor()

Calculates and returns the identity color of the empire, based on the mIDColorID field.

ColorIDs equal or greater than 0x53DBCF1 are cached, and colorID - 0x53DBCF1 is an index to the real color stored in animations~!ui.prop in IdentityColors property. 0x53DBCF1 is special and uses the empire species identity color, instead of the color on the list. If the ID less than 0x53DBCF1, the color will be recalculated, cached, and the ID will be updated.