mirror of
https://github.com/Mauler125/r5sdk.git
synced 2025-02-09 19:15:03 +01:00
Only run ImGui code if we aren't quitting
Should fix a very rare crash where this still gets called while imgui has already been destroyed.
This commit is contained in:
parent
8774baecd7
commit
506134fffb
@ -10,6 +10,7 @@
|
||||
#include "gameui/IConsole.h"
|
||||
#include "gameui/IBrowser.h"
|
||||
#include "engine/framelimit.h"
|
||||
#include "engine/sys_engine.h"
|
||||
#include "engine/sys_mainwind.h"
|
||||
#include "inputsystem/inputsystem.h"
|
||||
#include "public/bitmap/stb_image.h"
|
||||
@ -142,7 +143,9 @@ HRESULT __stdcall Present(IDXGISwapChain* pSwapChain, UINT nSyncInterval, UINT n
|
||||
}
|
||||
|
||||
g_FrameLimiter.Run();
|
||||
DrawImGui();
|
||||
|
||||
if (g_pEngine->GetQuitting() == IEngine::QUIT_NOTQUITTING)
|
||||
DrawImGui();
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
HRESULT result = s_fnSwapChainPresent(pSwapChain, nSyncInterval, nFlags);
|
||||
|
Loading…
x
Reference in New Issue
Block a user