Skip to content

Commit

Permalink
Fix 3D primitives disappearing (#3264)
Browse files Browse the repository at this point in the history
  • Loading branch information
tederis committed Dec 7, 2023
1 parent a1bef1a commit 04a1e2b
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions Client/core/CCore.cpp
Expand Up @@ -1994,16 +1994,12 @@ void CCore::OnDeviceRestore()
//
void CCore::OnPreFxRender()
{
// Don't do nothing if nothing won't be drawn

if (CGraphics::GetSingleton().HasPrimitive3DPreGUIQueueItems())
CGraphics::GetSingleton().DrawPrimitive3DPreGUIQueue();

if (!CGraphics::GetSingleton().HasLine3DPreGUIQueueItems())
return;
if (!CGraphics::GetSingleton().HasLine3DPreGUIQueueItems() && !CGraphics::GetSingleton().HasPrimitive3DPreGUIQueueItems())
return;

CGraphics::GetSingleton().EnteringMTARenderZone();

CGraphics::GetSingleton().DrawPrimitive3DPreGUIQueue();
CGraphics::GetSingleton().DrawLine3DPreGUIQueue();

CGraphics::GetSingleton().LeavingMTARenderZone();
Expand Down

0 comments on commit 04a1e2b

Please sign in to comment.