Spore ModAPI  2.4.0
API for creating C++ mods for Spore
Public Member Functions | Static Public Member Functions | Protected Attributes | List of all members
Simulator::cStarManager Class Reference

#include <StarManager.h>

Inheritance diagram for Simulator::cStarManager:
Simulator::cStrategy App::IMessageListener Simulator::ISimulatorStrategy IVirtual

Public Member Functions

cEmpireGetEmpire (uint32_t politicalID)
 Returns the empire that has the given political ID, or nullptr if no empire uses it. More...
 
cStarRecordGetStarRecord (StarIndex recordIndex)
 Returns the star record assigned to the specified id. More...
 
cPlanetRecordGetPlanetRecord (PlanetIndex recordIndex)
 
EmpiresMapGetEmpires ()
 
uint32_t GetGrobEmpireID ()
 
uint32_t NextPoliticalID (bool)
 Generates a new political ID. More...
 
cEmpireGetEmpireForStar (cStarRecord *starRecord)
 Returns the empire that controls this star record, creating it if necessary. More...
 
void RecordToPlanet (cPlanetRecord *record, intrusive_ptr< cPlanet > &dst)
 
cStarRecordGetSol () const
 
- Public Member Functions inherited from Simulator::ISimulatorStrategy
virtual int AddRef ()=0
 
virtual int Release ()=0
 
virtual void Initialize ()=0
 
virtual void Dispose ()=0
 
virtual const char * GetName ()=0
 
virtual void OnModeExited (uint32_t previousModeID, uint32_t newModeID)=0
 
virtual void OnModeEntered (uint32_t previousModeID, uint32_t newModeID)=0
 
virtual int func1Ch ()=0
 
virtual int func20h ()=0
 
virtual bool func24h ()=0
 
virtual bool Write (void *)=0
 
virtual bool Read (void *)=0
 
virtual void func30h (int)=0
 
virtual bool func34h (int)=0
 
virtual void Update (int deltaTime, int deltaGameTime)=0
 
virtual void PostUpdate (int deltaTime, int deltaGameTime)=0
 
virtual void func40h (int)=0
 
virtual void func44h (int)=0
 
virtual void func48h ()=0
 
virtual void func4Ch ()=0
 
- Public Member Functions inherited from IVirtual
virtual ~IVirtual ()
 
- Public Member Functions inherited from App::IMessageListener
virtual ~IMessageListener ()
 
virtual bool HandleMessage (uint32_t messageID, void *pMessage)=0
 Called every time a message is received. More...
 
virtual int AddRef ()=0
 
virtual int Release ()=0
 

Static Public Member Functions

static cStarManagerGet ()
 Returns the active Simulator star manager, used for most things in space stage. More...
 

Protected Attributes

map< int, int > field_20
 
vector< int > field_3C
 
vector< int > field_50
 
bool field_64
 
int field_68
 
string16 field_6C
 
char _padding_7C [0x24]
 
vector< int > field_A0
 
int field_B4
 
int field_B8
 
int field_BC
 
int field_C0
 
int field_C4
 
vector< vector< intrusive_ptr< cStarRecord > > > mStarRecords
 
vector< intrusive_ptr< Object > > field_DC
 
vector< intrusive_ptr< Object > > field_F0
 
vector< intrusive_ptr< Object > > field_104
 
vector< intrusive_ptr< Object > > field_118
 
map< uint32_t, intrusive_ptr< Object > > field_12C
 
intrusive_ptr< cStarRecordmpSol
 
intrusive_ptr< cStarRecordfield_14C
 
EmpiresMap mEmpiresMap
 
vector< int > field_16C
 
int field_180
 
map< int, int > field_184
 
intrusive_ptr< Objectfield_1A0
 
intrusive_ptr< Objectfield_1A4
 
int field_1A8
 
int field_1AC
 
int field_1B0
 
int field_1B4
 
int field_1B8
 
float field_1BC
 
float field_1C0
 
int field_1C4
 
int field_1C8
 
int field_1CC
 
int field_1D0
 
int field_1D4
 
uint32_t mGrobEmpireID
 
intrusive_ptr< cStarRecordfield_1DC
 
cSpaceTradeRouteManager mTradeRouteMgr
 
intrusive_ptr< cRelationshipManagermpRelationshipManager
 
vector< int > field_208
 
bool field_21C
 
intrusive_ptr< Objectfield_220
 
intrusive_ptr< Objectfield_224
 
intrusive_ptr< Objectfield_228
 
- Protected Attributes inherited from Simulator::cStrategy
int mnRefCount
 
int field_C
 
int field_10
 
int field_14
 
int field_18
 

Member Function Documentation

◆ Get()

static cStarManager* Simulator::cStarManager::Get ( )
static

Returns the active Simulator star manager, used for most things in space stage.

Same as StarManager().

◆ GetEmpire()

cEmpire* Simulator::cStarManager::GetEmpire ( uint32_t  politicalID)

Returns the empire that has the given political ID, or nullptr if no empire uses it.

Parameters
politicalID

◆ GetEmpireForStar()

cEmpire* Simulator::cStarManager::GetEmpireForStar ( cStarRecord starRecord)

Returns the empire that controls this star record, creating it if necessary.

If no empire controls this star record or the one that controls it does not yet exist, it will be created and added to the empire map.

Parameters
starRecord

◆ GetEmpires()

EmpiresMap& Simulator::cStarManager::GetEmpires ( )

◆ GetGrobEmpireID()

uint32_t Simulator::cStarManager::GetGrobEmpireID ( )
inline

◆ GetPlanetRecord()

cPlanetRecord* Simulator::cStarManager::GetPlanetRecord ( PlanetIndex  recordIndex)

◆ GetSol()

cStarRecord * Simulator::cStarManager::GetSol ( ) const
inline

◆ GetStarRecord()

cStarRecord* Simulator::cStarManager::GetStarRecord ( StarIndex  recordIndex)

Returns the star record assigned to the specified id.

There are three possibilities:

  • If id == 0, the galaxy center is returned ?
  • If id == -1, nullptr is returned.
  • Otherwise, the id is divided in sector index (& 0xFFFFF000) and star index (& 0x00000FFF) and the star record is returned.

◆ NextPoliticalID()

uint32_t Simulator::cStarManager::NextPoliticalID ( bool  )

Generates a new political ID.

◆ RecordToPlanet()

void Simulator::cStarManager::RecordToPlanet ( cPlanetRecord record,
intrusive_ptr< cPlanet > &  dst 
)

Member Data Documentation

◆ _padding_7C

char Simulator::cStarManager::_padding_7C[0x24]
protected

◆ field_104

vector<intrusive_ptr<Object> > Simulator::cStarManager::field_104
protected

◆ field_118

vector<intrusive_ptr<Object> > Simulator::cStarManager::field_118
protected

◆ field_12C

map<uint32_t, intrusive_ptr<Object> > Simulator::cStarManager::field_12C
protected

◆ field_14C

intrusive_ptr<cStarRecord> Simulator::cStarManager::field_14C
protected

◆ field_16C

vector<int> Simulator::cStarManager::field_16C
protected

◆ field_180

int Simulator::cStarManager::field_180
protected

◆ field_184

map<int, int> Simulator::cStarManager::field_184
protected

◆ field_1A0

intrusive_ptr<Object> Simulator::cStarManager::field_1A0
protected

◆ field_1A4

intrusive_ptr<Object> Simulator::cStarManager::field_1A4
protected

◆ field_1A8

int Simulator::cStarManager::field_1A8
protected

◆ field_1AC

int Simulator::cStarManager::field_1AC
protected

◆ field_1B0

int Simulator::cStarManager::field_1B0
protected

◆ field_1B4

int Simulator::cStarManager::field_1B4
protected

◆ field_1B8

int Simulator::cStarManager::field_1B8
protected

◆ field_1BC

float Simulator::cStarManager::field_1BC
protected

◆ field_1C0

float Simulator::cStarManager::field_1C0
protected

◆ field_1C4

int Simulator::cStarManager::field_1C4
protected

◆ field_1C8

int Simulator::cStarManager::field_1C8
protected

◆ field_1CC

int Simulator::cStarManager::field_1CC
protected

◆ field_1D0

int Simulator::cStarManager::field_1D0
protected

◆ field_1D4

int Simulator::cStarManager::field_1D4
protected

◆ field_1DC

intrusive_ptr<cStarRecord> Simulator::cStarManager::field_1DC
protected

◆ field_20

map<int, int> Simulator::cStarManager::field_20
protected

◆ field_208

vector<int> Simulator::cStarManager::field_208
protected

◆ field_21C

bool Simulator::cStarManager::field_21C
protected

◆ field_220

intrusive_ptr<Object> Simulator::cStarManager::field_220
protected

◆ field_224

intrusive_ptr<Object> Simulator::cStarManager::field_224
protected

◆ field_228

intrusive_ptr<Object> Simulator::cStarManager::field_228
protected

◆ field_3C

vector<int> Simulator::cStarManager::field_3C
protected

◆ field_50

vector<int> Simulator::cStarManager::field_50
protected

◆ field_64

bool Simulator::cStarManager::field_64
protected

◆ field_68

int Simulator::cStarManager::field_68
protected

◆ field_6C

string16 Simulator::cStarManager::field_6C
protected

◆ field_A0

vector<int> Simulator::cStarManager::field_A0
protected

◆ field_B4

int Simulator::cStarManager::field_B4
protected

◆ field_B8

int Simulator::cStarManager::field_B8
protected

◆ field_BC

int Simulator::cStarManager::field_BC
protected

◆ field_C0

int Simulator::cStarManager::field_C0
protected

◆ field_C4

int Simulator::cStarManager::field_C4
protected

◆ field_DC

vector<intrusive_ptr<Object> > Simulator::cStarManager::field_DC
protected

◆ field_F0

vector<intrusive_ptr<Object> > Simulator::cStarManager::field_F0
protected

◆ mEmpiresMap

EmpiresMap Simulator::cStarManager::mEmpiresMap
protected

◆ mGrobEmpireID

uint32_t Simulator::cStarManager::mGrobEmpireID
protected

◆ mpRelationshipManager

intrusive_ptr<cRelationshipManager> Simulator::cStarManager::mpRelationshipManager
protected

◆ mpSol

intrusive_ptr<cStarRecord> Simulator::cStarManager::mpSol
protected

◆ mStarRecords

vector<vector<intrusive_ptr<cStarRecord> > > Simulator::cStarManager::mStarRecords
protected

◆ mTradeRouteMgr

cSpaceTradeRouteManager Simulator::cStarManager::mTradeRouteMgr
protected

The documentation for this class was generated from the following file: