mirror of
https://github.com/rwengine/openrw.git
synced 2024-11-22 10:22:52 +01:00
rwviewer: load gamedata before passing it to gameworld
This commit is contained in:
parent
2670de509f
commit
3628faf72b
@ -144,12 +144,12 @@ void ViewerWindow::loadGame(const QString& path) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
gameData = std::make_unique<GameData>(&engineLog, gameDir.absolutePath().toStdString());
|
gameData = std::make_unique<GameData>(&engineLog, gameDir.absolutePath().toStdString());
|
||||||
|
gameData->load();
|
||||||
|
|
||||||
gameWorld = std::make_unique<GameWorld>(&engineLog, gameData.get());
|
gameWorld = std::make_unique<GameWorld>(&engineLog, gameData.get());
|
||||||
renderer = std::make_unique<GameRenderer>(&engineLog, gameData.get());
|
renderer = std::make_unique<GameRenderer>(&engineLog, gameData.get());
|
||||||
gameWorld->state = new GameState;
|
gameWorld->state = new GameState;
|
||||||
|
|
||||||
gameWorld->data->load();
|
|
||||||
|
|
||||||
renderer->text.setFontTexture(FONT_PAGER, "pager");
|
renderer->text.setFontTexture(FONT_PAGER, "pager");
|
||||||
renderer->text.setFontTexture(FONT_PRICEDOWN, "font1");
|
renderer->text.setFontTexture(FONT_PRICEDOWN, "font1");
|
||||||
renderer->text.setFontTexture(FONT_ARIAL, "font2");
|
renderer->text.setFontTexture(FONT_ARIAL, "font2");
|
||||||
|
Loading…
Reference in New Issue
Block a user