FULLPIPE: CGameLoader -> GameLoader
This commit is contained in:
parent
918d2f175a
commit
4a6ede35e7
4 changed files with 20 additions and 20 deletions
|
@ -45,7 +45,7 @@ enum FullpipeGameFeatures {
|
|||
|
||||
class BehaviorManager;
|
||||
class BaseModalObject;
|
||||
class CGameLoader;
|
||||
class GameLoader;
|
||||
class GameVar;
|
||||
class InputController;
|
||||
class Inventory2;
|
||||
|
@ -98,7 +98,7 @@ public:
|
|||
|
||||
Graphics::Surface _backgroundSurface;
|
||||
|
||||
CGameLoader *_gameLoader;
|
||||
GameLoader *_gameLoader;
|
||||
GameProject *_gameProject;
|
||||
bool loadGam(const char *fname, int scene = 0);
|
||||
|
||||
|
|
|
@ -47,7 +47,7 @@ InteractionController *getGameLoaderInteractionController() {
|
|||
return g_fullpipe->_gameLoader->_interactionController;
|
||||
}
|
||||
|
||||
CGameLoader::CGameLoader() {
|
||||
GameLoader::GameLoader() {
|
||||
_interactionController = new InteractionController();
|
||||
_inputController = new InputController();
|
||||
|
||||
|
@ -74,15 +74,15 @@ CGameLoader::CGameLoader() {
|
|||
g_fullpipe->_msgId = 0;
|
||||
}
|
||||
|
||||
CGameLoader::~CGameLoader() {
|
||||
GameLoader::~GameLoader() {
|
||||
free(_gameName);
|
||||
delete _gameProject;
|
||||
delete _interactionController;
|
||||
delete _inputController;
|
||||
}
|
||||
|
||||
bool CGameLoader::load(MfcArchive &file) {
|
||||
debug(5, "CGameLoader::load()");
|
||||
bool GameLoader::load(MfcArchive &file) {
|
||||
debug(5, "GameLoader::load()");
|
||||
|
||||
_gameName = file.readPascalString();
|
||||
debug(6, "_gameName: %s", _gameName);
|
||||
|
@ -129,7 +129,7 @@ bool CGameLoader::load(MfcArchive &file) {
|
|||
return true;
|
||||
}
|
||||
|
||||
bool CGameLoader::loadScene(int sceneId) {
|
||||
bool GameLoader::loadScene(int sceneId) {
|
||||
SceneTag *st;
|
||||
|
||||
int idx = getSceneTagBySceneId(sceneId, &st);
|
||||
|
@ -155,7 +155,7 @@ bool CGameLoader::loadScene(int sceneId) {
|
|||
return false;
|
||||
}
|
||||
|
||||
bool CGameLoader::gotoScene(int sceneId, int entranceId) {
|
||||
bool GameLoader::gotoScene(int sceneId, int entranceId) {
|
||||
SceneTag *st;
|
||||
|
||||
int sc2idx = getSceneTagBySceneId(sceneId, &st);
|
||||
|
@ -234,7 +234,7 @@ bool preloadCallback(const PreloadItem &pre, int flag) {
|
|||
return true;
|
||||
}
|
||||
|
||||
bool CGameLoader::preloadScene(int sceneId, int entranceId) {
|
||||
bool GameLoader::preloadScene(int sceneId, int entranceId) {
|
||||
debug(0, "preloadScene(%d, %d), ", sceneId, entranceId);
|
||||
|
||||
if (_preloadSceneId != sceneId || _preloadEntranceId != entranceId) {
|
||||
|
@ -289,7 +289,7 @@ bool CGameLoader::preloadScene(int sceneId, int entranceId) {
|
|||
return true;
|
||||
}
|
||||
|
||||
bool CGameLoader::unloadScene(int sceneId) {
|
||||
bool GameLoader::unloadScene(int sceneId) {
|
||||
SceneTag *tag;
|
||||
int sceneTag = getSceneTagBySceneId(sceneId, &tag);
|
||||
|
||||
|
@ -310,7 +310,7 @@ bool CGameLoader::unloadScene(int sceneId) {
|
|||
return true;
|
||||
}
|
||||
|
||||
int CGameLoader::getSceneTagBySceneId(int sceneId, SceneTag **st) {
|
||||
int GameLoader::getSceneTagBySceneId(int sceneId, SceneTag **st) {
|
||||
if (_sc2array.size() > 0 && _gameProject->_sceneTagList->size() > 0) {
|
||||
for (uint i = 0; i < _sc2array.size(); i++) {
|
||||
if (_sc2array[i]._sceneId == sceneId) {
|
||||
|
@ -329,11 +329,11 @@ int CGameLoader::getSceneTagBySceneId(int sceneId, SceneTag **st) {
|
|||
return -1;
|
||||
}
|
||||
|
||||
void CGameLoader::applyPicAniInfos(Scene *sc, PicAniInfo **picAniInfo, int picAniInfoCount) {
|
||||
void GameLoader::applyPicAniInfos(Scene *sc, PicAniInfo **picAniInfo, int picAniInfoCount) {
|
||||
if (picAniInfoCount <= 0)
|
||||
return;
|
||||
|
||||
debug(0, "CGameLoader::applyPicAniInfos(sc, ptr, %d)", picAniInfoCount);
|
||||
debug(0, "GameLoader::applyPicAniInfos(sc, ptr, %d)", picAniInfoCount);
|
||||
|
||||
PictureObject *pict;
|
||||
StaticANIObject *ani;
|
||||
|
@ -381,11 +381,11 @@ void CGameLoader::applyPicAniInfos(Scene *sc, PicAniInfo **picAniInfo, int picAn
|
|||
}
|
||||
}
|
||||
|
||||
void CGameLoader::saveScenePicAniInfos(int sceneId) {
|
||||
warning("STUB: CGameLoader::saveScenePicAniInfos(%d)", sceneId);
|
||||
void GameLoader::saveScenePicAniInfos(int sceneId) {
|
||||
warning("STUB: GameLoader::saveScenePicAniInfos(%d)", sceneId);
|
||||
}
|
||||
|
||||
void CGameLoader::updateSystems(int counterdiff) {
|
||||
void GameLoader::updateSystems(int counterdiff) {
|
||||
if (g_fullpipe->_currentScene) {
|
||||
g_fullpipe->_currentScene->update(counterdiff);
|
||||
|
||||
|
|
|
@ -72,10 +72,10 @@ class PreloadItems : public Common::Array<PreloadItem *>, public CObject {
|
|||
virtual bool load(MfcArchive &file);
|
||||
};
|
||||
|
||||
class CGameLoader : public CObject {
|
||||
class GameLoader : public CObject {
|
||||
public:
|
||||
CGameLoader();
|
||||
virtual ~CGameLoader();
|
||||
GameLoader();
|
||||
virtual ~GameLoader();
|
||||
|
||||
virtual bool load(MfcArchive &file);
|
||||
bool loadScene(int sceneId);
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
namespace Fullpipe {
|
||||
|
||||
bool FullpipeEngine::loadGam(const char *fname, int scene) {
|
||||
_gameLoader = new CGameLoader();
|
||||
_gameLoader = new GameLoader();
|
||||
|
||||
if (!_gameLoader->loadFile(fname))
|
||||
return false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue