aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorx2048 <codeforsmile@gmail.com>2023-03-20 11:42:16 +0100
committerGitHub <noreply@github.com>2023-03-20 11:42:16 +0100
commit9af587c54ebacd6708cc57902278c30556b6aaa0 (patch)
treecb86f3bd9c69c4876a1079b03eae7fc79952609c /src
parent6cd2eea48781dd7318b6ea78c5cdea4a3ee5db02 (diff)
downloadminetest-9af587c54ebacd6708cc57902278c30556b6aaa0.tar.xz
Move rendering engine reset after deletion of game objects
Diffstat (limited to 'src')
-rw-r--r--src/client/game.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/game.cpp b/src/client/game.cpp
index 43249e05b..e42e6d338 100644
--- a/src/client/game.cpp
+++ b/src/client/game.cpp
@@ -1113,6 +1113,8 @@ Game::~Game()
&settingChangedCallback, this);
g_settings->deregisterChangedCallback("camera_smoothing",
&settingChangedCallback, this);
+ if (m_rendering_engine)
+ m_rendering_engine->finalize();
}
bool Game::startup(bool *kill,
@@ -1289,8 +1291,6 @@ void Game::run()
void Game::shutdown()
{
- m_rendering_engine->finalize();
-
auto formspec = m_game_ui->getFormspecGUI();
if (formspec)
formspec->quitMenu();