Replace non-ASCII characters in comments with ASCII equivalents
Em dashes (---) replaced with --, arrows replaced with ->. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
6e00a47416
commit
643c1d0294
7 changed files with 6643 additions and 6643 deletions
|
|
@ -185,12 +185,12 @@ static void CG_TransitionSnapshot( void ) {
|
||||||
CG_TransitionPlayerState( ps, ops );
|
CG_TransitionPlayerState( ps, ops );
|
||||||
}
|
}
|
||||||
|
|
||||||
// server demo: detect follow→free camera transition
|
// server demo: detect follow->free camera transition
|
||||||
if ( cg.svDemoPlayback ) {
|
if ( cg.svDemoPlayback ) {
|
||||||
qboolean wasFollowing = ( ops->pm_flags & PMF_FOLLOW ) != 0;
|
qboolean wasFollowing = ( ops->pm_flags & PMF_FOLLOW ) != 0;
|
||||||
qboolean isFollowing = ( ps->pm_flags & PMF_FOLLOW ) != 0;
|
qboolean isFollowing = ( ps->pm_flags & PMF_FOLLOW ) != 0;
|
||||||
if ( wasFollowing && !isFollowing ) {
|
if ( wasFollowing && !isFollowing ) {
|
||||||
// exiting follow mode — init camera from last known position
|
// exiting follow mode -- init camera from last known position
|
||||||
cg.svDemoFreeCamera = qtrue;
|
cg.svDemoFreeCamera = qtrue;
|
||||||
cg.svDemoCameraTime = trap_Milliseconds();
|
cg.svDemoCameraTime = trap_Milliseconds();
|
||||||
VectorCopy( ops->origin, cg.svDemoCameraPs.origin );
|
VectorCopy( ops->origin, cg.svDemoCameraPs.origin );
|
||||||
|
|
@ -405,7 +405,7 @@ void CG_ProcessSnapshots( void ) {
|
||||||
// if time went backwards, we have a level restart or demo seek
|
// if time went backwards, we have a level restart or demo seek
|
||||||
if ( cg.nextSnap->serverTime < cg.snap->serverTime ) {
|
if ( cg.nextSnap->serverTime < cg.snap->serverTime ) {
|
||||||
if ( cg.svDemoPlayback ) {
|
if ( cg.svDemoPlayback ) {
|
||||||
// demo seek — discard old snap, use nextSnap as current,
|
// demo seek -- discard old snap, use nextSnap as current,
|
||||||
// and wait for another snapshot before rendering
|
// and wait for another snapshot before rendering
|
||||||
cg.snap = cg.nextSnap;
|
cg.snap = cg.nextSnap;
|
||||||
cg.nextSnap = NULL;
|
cg.nextSnap = NULL;
|
||||||
|
|
|
||||||
|
|
@ -1034,7 +1034,7 @@ void ClientThink( int clientNum ) {
|
||||||
// phone jack if they don't get any for a while
|
// phone jack if they don't get any for a while
|
||||||
ent->client->lastCmdTime = level.time;
|
ent->client->lastCmdTime = level.time;
|
||||||
|
|
||||||
// demo playback: don't run ClientThink_real — cgame owns
|
// demo playback: don't run ClientThink_real -- cgame owns
|
||||||
// the camera movement, G_RunFrame handles buttons and PVS origin
|
// the camera movement, G_RunFrame handles buttons and PVS origin
|
||||||
if ( g_svDemoPlaying.integer ) {
|
if ( g_svDemoPlaying.integer ) {
|
||||||
return;
|
return;
|
||||||
|
|
|
||||||
|
|
@ -1751,7 +1751,7 @@ int start, end;
|
||||||
gclient_t *cl = &level.clients[i];
|
gclient_t *cl = &level.clients[i];
|
||||||
gentity_t *e = &g_entities[i];
|
gentity_t *e = &g_entities[i];
|
||||||
|
|
||||||
// find the spectator — use client-owned origin for PVS
|
// find the spectator -- use client-owned origin for PVS
|
||||||
if ( e->client && cl->pers.connected == CON_CONNECTED
|
if ( e->client && cl->pers.connected == CON_CONNECTED
|
||||||
&& cl->sess.sessionTeam == TEAM_SPECTATOR ) {
|
&& cl->sess.sessionTeam == TEAM_SPECTATOR ) {
|
||||||
// copy client-owned origin from usercmd for PVS culling.
|
// copy client-owned origin from usercmd for PVS culling.
|
||||||
|
|
@ -1786,7 +1786,7 @@ int start, end;
|
||||||
e->s.number = i;
|
e->s.number = i;
|
||||||
} else if ( cl->pers.connected == CON_CONNECTED
|
} else if ( cl->pers.connected == CON_CONNECTED
|
||||||
&& cl->sess.sessionTeam != TEAM_SPECTATOR ) {
|
&& cl->sess.sessionTeam != TEAM_SPECTATOR ) {
|
||||||
// player left — mark disconnected
|
// player left -- mark disconnected
|
||||||
cl->pers.connected = CON_DISCONNECTED;
|
cl->pers.connected = CON_DISCONNECTED;
|
||||||
e->inuse = qfalse;
|
e->inuse = qfalse;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -183,7 +183,7 @@ G_WriteSessionData
|
||||||
void G_WriteSessionData( void ) {
|
void G_WriteSessionData( void ) {
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
// don't persist demo spectator sessions — the forced TEAM_SPECTATOR
|
// don't persist demo spectator sessions -- the forced TEAM_SPECTATOR
|
||||||
// would carry over to the next normal game
|
// would carry over to the next normal game
|
||||||
if ( g_svDemoPlaying.integer ) {
|
if ( g_svDemoPlaying.integer ) {
|
||||||
return;
|
return;
|
||||||
|
|
|
||||||
|
|
@ -353,13 +353,13 @@ void SV_SpawnServer( char *server, qboolean killBots ) {
|
||||||
|
|
||||||
// stop any active demo recording/playback (one demo = one map).
|
// stop any active demo recording/playback (one demo = one map).
|
||||||
// SVD_IsStarting() returns true when SVD_Play_f is calling devmap
|
// SVD_IsStarting() returns true when SVD_Play_f is calling devmap
|
||||||
// internally — don't stop our own playback.
|
// internally -- don't stop our own playback.
|
||||||
if ( SVD_IsRecording() ) {
|
if ( SVD_IsRecording() ) {
|
||||||
Com_Printf( "Map change — stopping demo recording.\n" );
|
Com_Printf( "Map change -- stopping demo recording.\n" );
|
||||||
SVD_StopRecord_f();
|
SVD_StopRecord_f();
|
||||||
}
|
}
|
||||||
if ( SVD_IsPlaying() && !SVD_IsStarting() ) {
|
if ( SVD_IsPlaying() && !SVD_IsStarting() ) {
|
||||||
Com_Printf( "Map change — stopping demo playback.\n" );
|
Com_Printf( "Map change -- stopping demo playback.\n" );
|
||||||
SVD_CleanupPlayback();
|
SVD_CleanupPlayback();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -859,7 +859,7 @@ void SV_Frame( int msec ) {
|
||||||
time_game = Sys_Milliseconds () - startTime;
|
time_game = Sys_Milliseconds () - startTime;
|
||||||
}
|
}
|
||||||
|
|
||||||
// check timeouts (skip during demo playback — zombie slots would be freed)
|
// check timeouts (skip during demo playback -- zombie slots would be freed)
|
||||||
if ( !SVD_IsPlaying() ) {
|
if ( !SVD_IsPlaying() ) {
|
||||||
SV_CheckTimeouts();
|
SV_CheckTimeouts();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -246,11 +246,11 @@ static void SVD_WriteFrame( fileHandle_t f ) {
|
||||||
demo.prevEntities[i].svFlags = ent->r.svFlags;
|
demo.prevEntities[i].svFlags = ent->r.svFlags;
|
||||||
demo.prevEntities[i].active = qtrue;
|
demo.prevEntities[i].active = qtrue;
|
||||||
} else if ( demo.prevEntities[i].active ) {
|
} else if ( demo.prevEntities[i].active ) {
|
||||||
// entity was removed — write a remove marker
|
// entity was removed -- write a remove marker
|
||||||
MSG_WriteDeltaEntity( &msg, &demo.prevEntities[i].es, NULL, qtrue );
|
MSG_WriteDeltaEntity( &msg, &demo.prevEntities[i].es, NULL, qtrue );
|
||||||
demo.prevEntities[i].active = qfalse;
|
demo.prevEntities[i].active = qfalse;
|
||||||
}
|
}
|
||||||
// else: entity was inactive and still inactive — write nothing
|
// else: entity was inactive and still inactive -- write nothing
|
||||||
}
|
}
|
||||||
|
|
||||||
// end of entities marker
|
// end of entities marker
|
||||||
|
|
@ -600,7 +600,7 @@ static qboolean SVD_ReadHeader( fileHandle_t f ) {
|
||||||
FS_Read( demo.playMapName, SVDEMO_MAX_MAPNAME, f );
|
FS_Read( demo.playMapName, SVDEMO_MAX_MAPNAME, f );
|
||||||
demo.playMapName[SVDEMO_MAX_MAPNAME - 1] = '\0';
|
demo.playMapName[SVDEMO_MAX_MAPNAME - 1] = '\0';
|
||||||
|
|
||||||
// read configstrings — store for re-application after map load
|
// read configstrings -- store for re-application after map load
|
||||||
{
|
{
|
||||||
short idx;
|
short idx;
|
||||||
while (1) {
|
while (1) {
|
||||||
|
|
@ -633,7 +633,7 @@ Called after devmap finishes in SVD_Play_f.
|
||||||
static void SVD_ApplyConfigstrings( void ) {
|
static void SVD_ApplyConfigstrings( void ) {
|
||||||
int i;
|
int i;
|
||||||
for ( i = 0; i < MAX_CONFIGSTRINGS; i++ ) {
|
for ( i = 0; i < MAX_CONFIGSTRINGS; i++ ) {
|
||||||
// skip CS_SERVERINFO and CS_SYSTEMINFO — they contain latched cvars
|
// skip CS_SERVERINFO and CS_SYSTEMINFO -- they contain latched cvars
|
||||||
// (sv_maxclients, sv_pure, etc.) that would trigger a map restart
|
// (sv_maxclients, sv_pure, etc.) that would trigger a map restart
|
||||||
if ( i == CS_SERVERINFO || i == CS_SYSTEMINFO ) {
|
if ( i == CS_SERVERINFO || i == CS_SYSTEMINFO ) {
|
||||||
continue;
|
continue;
|
||||||
|
|
@ -744,7 +744,7 @@ static qboolean SVD_ReadFrame( fileHandle_t f ) {
|
||||||
demo.playPrevEntities[entNum].active = qtrue;
|
demo.playPrevEntities[entNum].active = qtrue;
|
||||||
|
|
||||||
// apply to server entity and link for PVS.
|
// apply to server entity and link for PVS.
|
||||||
// use trBase as initial origin — G_RunFrame will refine with
|
// use trBase as initial origin -- G_RunFrame will refine with
|
||||||
// BG_EvaluateTrajectory for moving entities (rockets etc).
|
// BG_EvaluateTrajectory for moving entities (rockets etc).
|
||||||
ent = SV_GentityNum( entNum );
|
ent = SV_GentityNum( entNum );
|
||||||
ent->s = newEs;
|
ent->s = newEs;
|
||||||
|
|
@ -839,7 +839,7 @@ static qboolean SVD_ReadFrame( fileHandle_t f ) {
|
||||||
if ( len > 0 && len < (short)sizeof(buf) ) {
|
if ( len > 0 && len < (short)sizeof(buf) ) {
|
||||||
FS_Read( buf, len, f );
|
FS_Read( buf, len, f );
|
||||||
buf[len - 1] = '\0';
|
buf[len - 1] = '\0';
|
||||||
// broadcast — only the spectator is CS_ACTIVE, zombies are skipped
|
// broadcast -- only the spectator is CS_ACTIVE, zombies are skipped
|
||||||
SV_SendServerCommand( NULL, "%s", buf );
|
SV_SendServerCommand( NULL, "%s", buf );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -1025,7 +1025,7 @@ void SVD_Pause_f( void ) {
|
||||||
}
|
}
|
||||||
demo.paused = !demo.paused;
|
demo.paused = !demo.paused;
|
||||||
if ( !demo.paused ) {
|
if ( !demo.paused ) {
|
||||||
// resuming — toggle SERVERCOUNT to reset client snapshot timing
|
// resuming -- toggle SERVERCOUNT to reset client snapshot timing
|
||||||
// (drifted during pause from identical serverTimes).
|
// (drifted during pause from identical serverTimes).
|
||||||
svs.snapFlagServerBit ^= SNAPFLAG_SERVERCOUNT;
|
svs.snapFlagServerBit ^= SNAPFLAG_SERVERCOUNT;
|
||||||
}
|
}
|
||||||
|
|
@ -1047,7 +1047,7 @@ void SVD_Seek_f( void ) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( demo.numKeyframes <= 0 ) {
|
if ( demo.numKeyframes <= 0 ) {
|
||||||
Com_Printf( "No keyframes in this demo — seeking not available.\n" );
|
Com_Printf( "No keyframes in this demo -- seeking not available.\n" );
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1065,7 +1065,7 @@ void SVD_Seek_f( void ) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( bestKf < 0 ) {
|
if ( bestKf < 0 ) {
|
||||||
// target is before the first keyframe — seek to first
|
// target is before the first keyframe -- seek to first
|
||||||
bestKf = 0;
|
bestKf = 0;
|
||||||
targetTime = demo.keyframeTimes[0];
|
targetTime = demo.keyframeTimes[0];
|
||||||
}
|
}
|
||||||
|
|
@ -1189,7 +1189,7 @@ qboolean SVD_PlaybackFrame( void ) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// manual pause — don't consume demo data
|
// manual pause -- don't consume demo data
|
||||||
if ( demo.paused ) {
|
if ( demo.paused ) {
|
||||||
return qfalse;
|
return qfalse;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue