[quake3-commits] r2265 - in trunk/code: cgame game ui

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Mon Jun 18 12:27:00 EDT 2012


Author: ztm
Date: 2012-06-18 12:27:00 -0400 (Mon, 18 Jun 2012)
New Revision: 2265

Modified:
   trunk/code/cgame/cg_event.c
   trunk/code/game/ai_dmq3.c
   trunk/code/game/g_spawn.c
   trunk/code/game/g_syscalls.c
   trunk/code/ui/ui_main.c
   trunk/code/ui/ui_syscalls.c
Log:
REFACTOR

>From /dev/humancontroller.

Modified: trunk/code/cgame/cg_event.c
===================================================================
--- trunk/code/cgame/cg_event.c	2012-06-18 16:25:13 UTC (rev 2264)
+++ trunk/code/cgame/cg_event.c	2012-06-18 16:27:00 UTC (rev 2265)
@@ -1066,13 +1066,13 @@
 					if (cg.snap->ps.powerups[PW_BLUEFLAG] || cg.snap->ps.powerups[PW_NEUTRALFLAG]) {
 					}
 					else {
-					if (cgs.clientinfo[cg.clientNum].team == TEAM_BLUE) {
+						if (cgs.clientinfo[cg.clientNum].team == TEAM_BLUE) {
 #ifdef MISSIONPACK
 							if (cgs.gametype == GT_1FCTF) 
 								CG_AddBufferedSound( cgs.media.yourTeamTookTheFlagSound );
 							else
 #endif
-						 	CG_AddBufferedSound( cgs.media.enemyTookYourFlagSound );
+							CG_AddBufferedSound( cgs.media.enemyTookYourFlagSound );
 						}
 						else if (cgs.clientinfo[cg.clientNum].team == TEAM_RED) {
 #ifdef MISSIONPACK

Modified: trunk/code/game/ai_dmq3.c
===================================================================
--- trunk/code/game/ai_dmq3.c	2012-06-18 16:25:13 UTC (rev 2264)
+++ trunk/code/game/ai_dmq3.c	2012-06-18 16:27:00 UTC (rev 2265)
@@ -2301,7 +2301,6 @@
 #endif
 	//
 	if (bs->enemy >= 0) {
-		//if the enemy is carrying a flag
 		BotEntityInfo(bs->enemy, &entinfo);
 		// if the enemy is carrying a flag
 		if (EntityCarriesFlag(&entinfo)) return qfalse;

Modified: trunk/code/game/g_spawn.c
===================================================================
--- trunk/code/game/g_spawn.c	2012-06-18 16:25:13 UTC (rev 2264)
+++ trunk/code/game/g_spawn.c	2012-06-18 16:27:00 UTC (rev 2265)
@@ -485,7 +485,7 @@
 
 	l = strlen( string );
 	if ( level.numSpawnVarChars + l + 1 > MAX_SPAWN_VARS_CHARS ) {
-		G_Error( "G_AddSpawnVarToken: MAX_SPAWN_VARS" );
+		G_Error( "G_AddSpawnVarToken: MAX_SPAWN_VARS_CHARS" );
 	}
 
 	dest = level.spawnVarChars + level.numSpawnVarChars;

Modified: trunk/code/game/g_syscalls.c
===================================================================
--- trunk/code/game/g_syscalls.c	2012-06-18 16:25:13 UTC (rev 2264)
+++ trunk/code/game/g_syscalls.c	2012-06-18 16:27:00 UTC (rev 2265)
@@ -48,6 +48,7 @@
 void trap_Error(const char *fmt)
 {
 	syscall(G_ERROR, fmt);
+	// shut up GCC warning about returning functions, because we know better
 	exit(1);
 }
 
@@ -227,7 +228,6 @@
 
 void trap_SnapVector( float *v ) {
 	syscall( G_SNAPVECTOR, v );
-	return;
 }
 
 // BotLib traps start here

Modified: trunk/code/ui/ui_main.c
===================================================================
--- trunk/code/ui/ui_main.c	2012-06-18 16:25:13 UTC (rev 2264)
+++ trunk/code/ui/ui_main.c	2012-06-18 16:27:00 UTC (rev 2265)
@@ -5108,7 +5108,6 @@
 	uiInfo.uiDC.drawSides = &_UI_DrawSides;
 	uiInfo.uiDC.drawTopBottom = &_UI_DrawTopBottom;
 	uiInfo.uiDC.clearScene = &trap_R_ClearScene;
-	uiInfo.uiDC.drawSides = &_UI_DrawSides;
 	uiInfo.uiDC.addRefEntityToScene = &trap_R_AddRefEntityToScene;
 	uiInfo.uiDC.renderScene = &trap_R_RenderScene;
 	uiInfo.uiDC.registerFont = &trap_R_RegisterFont;

Modified: trunk/code/ui/ui_syscalls.c
===================================================================
--- trunk/code/ui/ui_syscalls.c	2012-06-18 16:25:13 UTC (rev 2264)
+++ trunk/code/ui/ui_syscalls.c	2012-06-18 16:27:00 UTC (rev 2265)
@@ -47,6 +47,7 @@
 void trap_Error(const char *string)
 {
 	syscall(UI_ERROR, string);
+	// shut up GCC warning about returning functions, because we know better
 	exit(1);
 }
 



More information about the quake3-commits mailing list