Changeset View
Changeset View
Standalone View
Standalone View
source/graphics/MapReader.h
Show First 20 Lines • Show All 57 Lines • ▼ Show 20 Lines | CCinemaManager*, CTriggerManager*, CPostprocManager* pPostproc, CSimulation2*, const CSimContext*, | ||||
int playerID, bool skipEntities); | int playerID, bool skipEntities); | ||||
void LoadRandomMap(const CStrW& scriptFile, const ScriptContext& cx, JS::HandleValue settings, CTerrain*, WaterManager*, SkyManager*, CLightEnv*, CGameView*, CCinemaManager*, CTriggerManager*, CPostprocManager* pPostproc_, CSimulation2*, int playerID); | void LoadRandomMap(const CStrW& scriptFile, const ScriptContext& cx, JS::HandleValue settings, CTerrain*, WaterManager*, SkyManager*, CLightEnv*, CGameView*, CCinemaManager*, CTriggerManager*, CPostprocManager* pPostproc_, CSimulation2*, int playerID); | ||||
private: | private: | ||||
// Load script settings for use by scripts | // Load script settings for use by scripts | ||||
int LoadScriptSettings(); | int LoadScriptSettings(); | ||||
// load player settings only | int ParsePlayerSettings(); | ||||
int LoadPlayerSettings(); | int ParseMapSettings(); | ||||
// load map settings only | |||||
int LoadMapSettings(); | |||||
// UnpackTerrain: unpack the terrain from the input stream | // UnpackTerrain: unpack the terrain from the input stream | ||||
int UnpackTerrain(); | int UnpackTerrain(); | ||||
// UnpackCinema: unpack the cinematic tracks from the input stream | // UnpackCinema: unpack the cinematic tracks from the input stream | ||||
int UnpackCinema(); | int UnpackCinema(); | ||||
// UnpackMap: unpack the given data from the raw data stream into local variables | // UnpackMap: unpack the given data from the raw data stream into local variables | ||||
int UnpackMap(); | int UnpackMap(); | ||||
// ApplyData: take all the input data, and rebuild the scene from it | // ApplyData: take all the input data, and rebuild the scene from it | ||||
int ApplyData(); | int ApplyData(); | ||||
int ApplyTerrainData(); | int ApplyTerrainData(); | ||||
// read some misc data from the XML file | // read some misc data from the XML file | ||||
int ReadXML(); | int ReadXML(); | ||||
// read entity data from the XML file | // read entity data from the XML file | ||||
int ReadXMLEntities(); | int ReadXMLEntities(); | ||||
// Copy random map settings over to sim | |||||
int LoadRMSettings(); | |||||
// Generate random map | // Generate random map | ||||
int GenerateMap(); | int GenerateMap(); | ||||
// Parse script data into terrain | // Parse script data into terrain | ||||
int ParseTerrain(); | int ParseTerrain(); | ||||
// Parse script data into entities | // Parse script data into entities | ||||
int ParseEntities(); | int ParseEntities(); | ||||
Show All 13 Lines | private: | ||||
std::vector<CTerrainTextureEntry*> m_TerrainTextures; | std::vector<CTerrainTextureEntry*> m_TerrainTextures; | ||||
// tile descriptions for each tile | // tile descriptions for each tile | ||||
std::vector<STileDesc> m_Tiles; | std::vector<STileDesc> m_Tiles; | ||||
// lightenv stored in file | // lightenv stored in file | ||||
CLightEnv m_LightEnv; | CLightEnv m_LightEnv; | ||||
// startup script | // startup script | ||||
CStrW m_Script; | CStrW m_Script; | ||||
// Map settings - this is the 'settings' property of the game InitAttributes. | |||||
JS::PersistentRootedValue m_MapSettings; | |||||
// random map data | // random map data | ||||
CStrW m_ScriptFile; | CStrW m_ScriptFile; | ||||
JS::PersistentRootedValue m_ScriptSettings; | |||||
JS::PersistentRootedValue m_MapData; | JS::PersistentRootedValue m_MapData; | ||||
CMapGenerator* m_MapGen; | CMapGenerator* m_MapGen; | ||||
CFileUnpacker unpacker; | CFileUnpacker unpacker; | ||||
CTerrain* pTerrain; | CTerrain* pTerrain; | ||||
WaterManager* pWaterMan; | WaterManager* pWaterMan; | ||||
SkyManager* pSkyMan; | SkyManager* pSkyMan; | ||||
▲ Show 20 Lines • Show All 50 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator