Skip to content

Commit

Permalink
Restore global time on Save/Restore.
Browse files Browse the repository at this point in the history
  • Loading branch information
nekonomicon committed Apr 4, 2021
1 parent 4ba54bd commit a07acb3
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions dlls/cbase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,8 @@ void DispatchSave( edict_t *pent, SAVERESTOREDATA *pSaveData )
{
ENTITYTABLE *pTable = &pSaveData->pTable[pSaveData->currentIndex];

gpGlobals->time = pSaveData->time;

if( pTable->pent != pent )
ALERT( at_error, "ENTITY TABLE OR INDEX IS WRONG!!!!\n" );

Expand Down Expand Up @@ -307,6 +309,9 @@ int DispatchRestore( edict_t *pent, SAVERESTOREDATA *pSaveData, int globalEntity
Vector oldOffset;

CRestore restoreHelper( pSaveData );

gpGlobals->time = pSaveData->time;

if( globalEntity )
{
CRestore tmpRestore( pSaveData );
Expand Down

0 comments on commit a07acb3

Please sign in to comment.