From 96f8e06ec9aa117bb8dd7e8d671d93e3884cb98f Mon Sep 17 00:00:00 2001 From: Tremulous Test Server Date: Wed, 7 Jan 2015 22:59:50 +0000 Subject: Added G_admin_writeconfig and changed outside calls to use that. --- src/game/g_admin.c | 4 ++++ src/game/g_admin.h | 1 + src/game/g_team.c | 2 +- 3 files changed, 6 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/game/g_admin.c b/src/game/g_admin.c index 0677e6f..b6e115b 100644 --- a/src/game/g_admin.c +++ b/src/game/g_admin.c @@ -4539,3 +4539,7 @@ void G_admin_cleanup( void ) BG_DefragmentMemory( ); } +void G_admin_writeconfig( void ) +{ + if ( g_admin_levels ) admin_writeconfig( ); +} diff --git a/src/game/g_admin.h b/src/game/g_admin.h index 61b012c..8132607 100644 --- a/src/game/g_admin.h +++ b/src/game/g_admin.h @@ -220,5 +220,6 @@ void G_admin_buffer_begin( void ); void G_admin_buffer_end( gentity_t *ent ); void G_admin_duration( int secs, char *duration, int dursize ); void G_admin_cleanup( void ); +void G_admin_writeconfig( void ); #endif /* ifndef _G_ADMIN_H */ diff --git a/src/game/g_team.c b/src/game/g_team.c index cea0b25..246c072 100644 --- a/src/game/g_team.c +++ b/src/game/g_team.c @@ -224,7 +224,7 @@ void G_LeaveTeamReal( gentity_t *self, qboolean reset_score ) G_namelog_update_score( self->client ); - admin_writeconfig(); + G_admin_writeconfig(); } void G_LeaveTeam( gentity_t *self ) -- cgit