diff options
Diffstat (limited to 'engines/wintermute/base/base_game_settings.cpp')
-rw-r--r-- | engines/wintermute/base/base_game_settings.cpp | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/engines/wintermute/base/base_game_settings.cpp b/engines/wintermute/base/base_game_settings.cpp index 1de8b31ca7..43809b5d1e 100644 --- a/engines/wintermute/base/base_game_settings.cpp +++ b/engines/wintermute/base/base_game_settings.cpp @@ -103,7 +103,7 @@ bool BaseGameSettings::loadSettings(const char *filename) { TOKEN_TABLE_END - byte *origBuffer = BaseFileManager::getEngineInstance()->readWholeFile(filename); + char *origBuffer = (char *)BaseFileManager::getEngineInstance()->readWholeFile(filename); if (origBuffer == nullptr) { BaseEngine::LOG(0, "BaseGame::LoadSettings failed for file '%s'", filename); return STATUS_FAILED; @@ -111,78 +111,78 @@ bool BaseGameSettings::loadSettings(const char *filename) { bool ret = STATUS_OK; - byte *buffer = origBuffer; - byte *params; + char *buffer = origBuffer; + char *params; int cmd; BaseParser parser; - if (parser.getCommand((char **)&buffer, commands, (char **)¶ms) != TOKEN_SETTINGS) { + if (parser.getCommand(&buffer, commands, ¶ms) != TOKEN_SETTINGS) { BaseEngine::LOG(0, "'SETTINGS' keyword expected in game settings file."); return STATUS_FAILED; } buffer = params; - while ((cmd = parser.getCommand((char **)&buffer, commands, (char **)¶ms)) > 0) { + while ((cmd = parser.getCommand(&buffer, commands, ¶ms)) > 0) { switch (cmd) { case TOKEN_GAME: delete[] _gameFile; - _gameFile = new char[strlen((char *)params) + 1]; + _gameFile = new char[strlen(params) + 1]; if (_gameFile) { - strcpy(_gameFile, (char *)params); + strcpy(_gameFile, params); } break; case TOKEN_STRING_TABLE: - if (DID_FAIL(_stringTable->loadFile((char *)params))) { + if (DID_FAIL(_stringTable->loadFile(params))) { cmd = PARSERR_GENERIC; } break; case TOKEN_RESOLUTION: - parser.scanStr((char *)params, "%d,%d", &_resWidth, &_resHeight); + parser.scanStr(params, "%d,%d", &_resWidth, &_resHeight); break; case TOKEN_REQUIRE_3D_ACCELERATION: - parser.scanStr((char *)params, "%b", &_requireAcceleration); + parser.scanStr(params, "%b", &_requireAcceleration); break; case TOKEN_REQUIRE_SOUND: - parser.scanStr((char *)params, "%b", &_requireSound); + parser.scanStr(params, "%b", &_requireSound); break; case TOKEN_HWTL_MODE: - parser.scanStr((char *)params, "%d", &_TLMode); + parser.scanStr(params, "%d", &_TLMode); break; case TOKEN_ALLOW_WINDOWED_MODE: - parser.scanStr((char *)params, "%b", &_allowWindowed); + parser.scanStr(params, "%b", &_allowWindowed); break; case TOKEN_ALLOW_DESKTOP_RES: - parser.scanStr((char *)params, "%b", &_allowDesktopRes); + parser.scanStr(params, "%b", &_allowDesktopRes); break; case TOKEN_ALLOW_ADVANCED: - parser.scanStr((char *)params, "%b", &_allowAdvanced); + parser.scanStr(params, "%b", &_allowAdvanced); break; case TOKEN_ALLOW_ACCESSIBILITY_TAB: - parser.scanStr((char *)params, "%b", &_allowAccessTab); + parser.scanStr(params, "%b", &_allowAccessTab); break; case TOKEN_ALLOW_ABOUT_TAB: - parser.scanStr((char *)params, "%b", &_allowAboutTab); + parser.scanStr(params, "%b", &_allowAboutTab); break; case TOKEN_REGISTRY_PATH: - //BaseEngine::instance().getRegistry()->setBasePath((char *)params); + //BaseEngine::instance().getRegistry()->setBasePath(params); break; case TOKEN_RICH_SAVED_GAMES: - parser.scanStr((char *)params, "%b", &_richSavedGames); + parser.scanStr(params, "%b", &_richSavedGames); break; case TOKEN_SAVED_GAME_EXT: - _savedGameExt = (char *)params; + _savedGameExt = params; break; case TOKEN_GUID: |