summaryrefslogtreecommitdiff
path: root/src/game/g_admin.c
diff options
context:
space:
mode:
author/dev/humancontroller <devhc@example.com>2017-04-13 11:30:00 +0000
committer/dev/humancontroller <devhc@example.com>2017-04-15 17:24:16 +0200
commitc596670999d843b430df0c4fe0eeabd148614638 (patch)
tree6290cc624bbbeaa50e2a3c3d7bc705721867e971 /src/game/g_admin.c
parenta989cd97673eb20dbd9a2fed5723832d5cd39512 (diff)
remove a bunch of unused variables and some no-op code
Diffstat (limited to 'src/game/g_admin.c')
-rw-r--r--src/game/g_admin.c11
1 files changed, 2 insertions, 9 deletions
diff --git a/src/game/g_admin.c b/src/game/g_admin.c
index 90e33c4..481f957 100644
--- a/src/game/g_admin.c
+++ b/src/game/g_admin.c
@@ -646,7 +646,6 @@ static void admin_writeconfig( void )
fileHandle_t f;
int len, i;
int t;
- char levels[ MAX_STRING_CHARS ] = {""};
if( !g_admin.string[ 0 ] )
{
@@ -724,7 +723,6 @@ static void admin_writeconfig( void )
}
for( i = 0; i < MAX_ADMIN_COMMANDS && g_admin_commands[ i ]; i++ )
{
- levels[ 0 ] = '\0';
trap_FS_Write( "[command]\n", 10, f );
trap_FS_Write( "command = ", 10, f );
admin_writeconfig_string( g_admin_commands[ i ]->command, f );
@@ -2108,9 +2106,8 @@ qboolean G_admin_readconfig( gentity_t *ent, int skiparg )
qboolean G_admin_time( gentity_t *ent, int skiparg )
{
qtime_t qt;
- int t;
- t = trap_RealTime( &qt );
+ trap_RealTime( &qt );
ADMP( va( "^3!time: ^7local time is %02i:%02i:%02i\n",
qt.tm_hour, qt.tm_min, qt.tm_sec ) );
return qtrue;
@@ -4422,7 +4419,6 @@ qboolean G_admin_mute( gentity_t *ent, int skiparg )
char command[ MAX_ADMIN_CMD_LEN ], *cmd;
gentity_t *vic;
char secs[ 7 ];
- qboolean usageDuration = qfalse;
int seconds = 0;
G_SayArgv( skiparg, command, sizeof( command ) );
@@ -4493,7 +4489,6 @@ qboolean G_admin_mute( gentity_t *ent, int skiparg )
qboolean G_admin_cp( gentity_t *ent, int skiparg )
{
int minargc;
- char *s;
minargc = 2 + skiparg;
@@ -4503,7 +4498,6 @@ qboolean G_admin_cp( gentity_t *ent, int skiparg )
return qfalse;
}
- s = G_SayConcatArgs( 1 + skiparg );
G_CP(ent);
return qtrue;
}
@@ -8110,7 +8104,7 @@ qboolean G_admin_L0(gentity_t *ent, int skiparg ){
qboolean G_admin_L1(gentity_t *ent, int skiparg ){
int pids[ MAX_CLIENTS ];
- char name[ MAX_NAME_LENGTH ], *reason, err[ MAX_STRING_CHARS ];
+ char name[ MAX_NAME_LENGTH ], err[ MAX_STRING_CHARS ];
int minargc;
minargc = 2 + skiparg;
@@ -8121,7 +8115,6 @@ qboolean G_admin_L1(gentity_t *ent, int skiparg ){
return qfalse;
}
G_SayArgv( 1 + skiparg, name, sizeof( name ) );
- reason = G_SayConcatArgs( 2 + skiparg );
if( G_ClientNumbersFromString( name, pids ) != 1 )
{
G_MatchOnePlayer( pids, err, sizeof( err ) );