Revert "get rid of calling "NetUpdate" in the renderer"

This reverts commit 5ee3b41969.
This commit is contained in:
Alug committed 2026-01-15 21:20:17 +01:00
1 parent 39dc3a878c
commit 3ec9ddfb87
4 files changed
+35 -1

No files matched your search

+10
View File
@@ -7089,7 +7089,17 @@ void NetUpdate(void)
realtics = nowtime - gametime;
if (realtics <= 0) // nothing new to update
{
// dont do shit!
if (!resynch_local_inprogress)
{
//Local_Maketic(realtics); // make local tic, and call menu?
GetPackets(); // get packet from client or from server
CL_SendClientCmd(); // Send tic cmd
}
return;
}
if (realtics > 5)
{
+4
View File
@@ -593,6 +593,8 @@ static boolean D_Display(void)
//
if (wipe)
{
// note: moved up here because NetUpdate does input changes
// and input during wipe tends to mess things up
wipedefindex += WIPEFINALSHIFT;
if (rendermode != render_none)
@@ -603,6 +605,8 @@ static boolean D_Display(void)
}
}
NetUpdate(); // send out any new accumulation
// It's safe to end the game now.
if (G_GetExitGameFlag())
{
+9
View File
@@ -5680,6 +5680,9 @@ static void HWR_RenderViewpoint(gl_portal_t *rootportal, int stencil_level, bool
if (LIKELY(cv_glbatching.value))
HWR_RenderBatches(true);
// Check for new console commands.
NetUpdate();
if constexpr (Type == RenderViewpointType::kPortal)
{
if (skyWallVertexArraySize) // if there are skywalls to draw using the alternate method
@@ -5760,11 +5763,17 @@ static void HWR_RenderFrame(boolean skybox, boolean drawsky)
current_bsp_culling_distance = bsp_culling_distances[renderdist- 1];
}
// Check for new console commands.
NetUpdate();
portalclipline = NULL;
if (UNLIKELY(HWR_UsePortals()))
HWR_RenderViewpoint<RenderViewpointType::kPortal>(NULL, 0, !skybox);
else
HWR_RenderViewpoint<RenderViewpointType::kNormal>(NULL, 0, !skybox);
// Check for new console commands.
NetUpdate();
}
// ==========================================================================
+12 -1
View File
@@ -1378,6 +1378,12 @@ static void R_RenderViewpoint(maskcount_t* mask, boolean drawprecip)
Mask_Post(mask);
}
// FAB NOTE FOR WIN32 PORT !! I'm not finished already,
// but I suspect network may have problems with the video buffer being locked
// for all duration of rendering, and being released only once at the end..
// I mean, there is a win16lock() or something that lasts all the rendering,
// so maybe we should release screen lock before each netupdate below..?
static fixed_t viewfov[MAXSPLITSCREENPLAYERS];
void R_RenderPlayerView(player_t *player)
@@ -1444,11 +1450,13 @@ void R_RenderPlayerView(player_t *player)
portalclipend = viewwidth;
R_ClearClipSegs();
}
R_ClearDrawSegs();
R_ClearSegTables();
R_ClearSprites();
// check for new console commands.
NetUpdate();
R_SetColumnContext(COLUMNCONTEXT_FLUSH);
ps_numbspcalls.value.i = ps_numpolyobjects.value.i = ps_numdrawnodes.value.i = 0;
PS_START_TIMING(ps_bsptime);
@@ -1514,6 +1522,9 @@ void R_RenderPlayerView(player_t *player)
PS_STOP_TIMING(ps_sw_maskedtime);
free(masks);
// Check for new console commands.
NetUpdate();
// save value to skyVisiblePerPlayer
// this is so that P1 can't affect whether P2 can see a skybox or not, or vice versa
skyVisiblePerPlayer[viewssnum] = skyVisible;