summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
author/dev/humancontroller <devhc@example.com>2014-07-12 23:48:06 +0200
committer/dev/humancontroller <devhc@example.com>2017-03-09 13:51:07 +0100
commit5e0f74ed9df36ba5d58aeb13cce527047e572b90 (patch)
treec1c51b2a20063b0fadef62a952804873c06bb2a8 /src
parentef59d5034a993363c2750dcdceed35175d436621 (diff)
remove the abusable levelshot command and related hacks
Diffstat (limited to 'src')
-rw-r--r--src/cgame/cg_consolecmds.c1
-rw-r--r--src/cgame/cg_draw.c4
-rw-r--r--src/cgame/cg_local.h1
-rw-r--r--src/cgame/cg_servercmds.c11
-rw-r--r--src/client/cl_cgame.c19
-rw-r--r--src/game/g_cmds.c17
6 files changed, 0 insertions, 53 deletions
diff --git a/src/cgame/cg_consolecmds.c b/src/cgame/cg_consolecmds.c
index adae40a8..7876bc32 100644
--- a/src/cgame/cg_consolecmds.c
+++ b/src/cgame/cg_consolecmds.c
@@ -259,7 +259,6 @@ void CG_InitConsoleCommands( void )
trap_AddCommand( "noclip" );
trap_AddCommand( "team" );
trap_AddCommand( "follow" );
- trap_AddCommand( "levelshot" );
trap_AddCommand( "setviewpos" );
trap_AddCommand( "callvote" );
trap_AddCommand( "vote" );
diff --git a/src/cgame/cg_draw.c b/src/cgame/cg_draw.c
index ee604e76..f59c11aa 100644
--- a/src/cgame/cg_draw.c
+++ b/src/cgame/cg_draw.c
@@ -3407,10 +3407,6 @@ static void CG_Draw2D( void )
{
menuDef_t *menu = NULL;
- // if we are taking a levelshot for the menu, don't draw anything
- if( cg.levelShot )
- return;
-
// fading to black if stamina runs out
// (only 2D that can't be disabled)
CG_DrawLighting( );
diff --git a/src/cgame/cg_local.h b/src/cgame/cg_local.h
index cf1da82d..53841e45 100644
--- a/src/cgame/cg_local.h
+++ b/src/cgame/cg_local.h
@@ -920,7 +920,6 @@ typedef struct
int clientNum;
qboolean demoPlayback;
- qboolean levelShot; // taking a level menu screenshot
int deferredPlayerLoading;
qboolean loading; // don't defer players at initial startup
qboolean intermissionStarted; // don't play voice rewards, because game will end shortly
diff --git a/src/cgame/cg_servercmds.c b/src/cgame/cg_servercmds.c
index ae4a2619..ab071d42 100644
--- a/src/cgame/cg_servercmds.c
+++ b/src/cgame/cg_servercmds.c
@@ -1178,16 +1178,6 @@ static void CG_Chat_f( void )
/*
=================
-CG_ClientLevelShot_f
-=================
-*/
-static void CG_ClientLevelShot_f( void )
-{
- cg.levelShot = qtrue;
-}
-
-/*
-=================
CG_ServerMenu_f
=================
*/
@@ -1270,7 +1260,6 @@ void CG_UnregisterCommands( void )
static consoleCommand_t svcommands[ ] =
{
{ "chat", CG_Chat_f },
- { "clientLevelShot", CG_ClientLevelShot_f },
{ "cmds", CG_GameCmds_f },
{ "cp", CG_CenterPrint_f },
{ "cs", CG_ConfigStringModified },
diff --git a/src/client/cl_cgame.c b/src/client/cl_cgame.c
index 9ce67455..da15e4e6 100644
--- a/src/client/cl_cgame.c
+++ b/src/client/cl_cgame.c
@@ -336,25 +336,6 @@ rescan:
return qtrue;
}
- // the clientLevelShot command is used during development
- // to generate 128*128 screenshots from the intermission
- // point of levels for the menu system to use
- // we pass it along to the cgame to make apropriate adjustments,
- // but we also clear the console and notify lines here
- if ( !strcmp( cmd, "clientLevelShot" ) ) {
- // don't do it if we aren't running the server locally,
- // otherwise malicious remote servers could overwrite
- // the existing thumbnails
- if ( !com_sv_running->integer ) {
- return qfalse;
- }
- // close the console
- Con_Close();
- // take a special screenshot next frame
- Cbuf_AddText( "wait ; wait ; wait ; wait ; screenshot levelshot\n" );
- return qtrue;
- }
-
// we may want to put a "connect to other server" command here
// cgame can now act on the command
diff --git a/src/game/g_cmds.c b/src/game/g_cmds.c
index cf203560..6c903ce4 100644
--- a/src/game/g_cmds.c
+++ b/src/game/g_cmds.c
@@ -547,22 +547,6 @@ void Cmd_Noclip_f( gentity_t *ent )
/*
-==================
-Cmd_LevelShot_f
-
-This is just to help generate the level pictures
-for the menus. It goes to the intermission immediately
-and sends over a command to the client to resize the view,
-hide the scoreboard, and take a special screenshot
-==================
-*/
-void Cmd_LevelShot_f( gentity_t *ent )
-{
- BeginIntermission( );
- trap_SendServerCommand( ent - g_entities, "clientLevelShot" );
-}
-
-/*
=================
Cmd_Kill_f
=================
@@ -3101,7 +3085,6 @@ commands_t cmds[ ] = {
{ "itemdeact", CMD_HUMAN|CMD_LIVING, Cmd_DeActivateItem_f },
{ "itemtoggle", CMD_HUMAN|CMD_LIVING, Cmd_ToggleItem_f },
{ "kill", CMD_TEAM|CMD_LIVING, Cmd_Kill_f },
- { "levelshot", CMD_CHEAT, Cmd_LevelShot_f },
{ "listmaps", CMD_MESSAGE|CMD_INTERMISSION, Cmd_ListMaps_f },
{ "m", CMD_MESSAGE|CMD_INTERMISSION, Cmd_PrivateMessage_f },
{ "mt", CMD_MESSAGE|CMD_INTERMISSION, Cmd_PrivateMessage_f },