[quake3-commits] r2271 - in trunk/code: botlib cgame game q3_ui ui

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Mon Jun 18 12:39:58 EDT 2012


Author: ztm
Date: 2012-06-18 12:39:58 -0400 (Mon, 18 Jun 2012)
New Revision: 2271

Modified:
   trunk/code/botlib/be_aas_reach.c
   trunk/code/botlib/be_ai_move.c
   trunk/code/cgame/cg_players.c
   trunk/code/game/ai_dmnet.c
   trunk/code/game/ai_dmq3.c
   trunk/code/q3_ui/ui_gameinfo.c
   trunk/code/ui/ui_gameinfo.c
Log:
REFACTOR [anough to enough]

Modified: trunk/code/botlib/be_aas_reach.c
===================================================================
--- trunk/code/botlib/be_aas_reach.c	2012-06-18 16:36:21 UTC (rev 2270)
+++ trunk/code/botlib/be_aas_reach.c	2012-06-18 16:39:58 UTC (rev 2271)
@@ -848,7 +848,7 @@
 	area1 = &aasworld.areas[area1num];
 	area2 = &aasworld.areas[area2num];
 
-	//if the areas are not near anough
+	//if the areas are not near enough
 	for (i = 0; i < 3; i++)
 	{
 		if (area1->mins[i] > area2->maxs[i] + 10) return qfalse;
@@ -923,7 +923,7 @@
 
 	area1 = &aasworld.areas[area1num];
 	area2 = &aasworld.areas[area2num];
-	//if the areas are not near anough in the x-y direction
+	//if the areas are not near enough in the x-y direction
 	for (i = 0; i < 2; i++)
 	{
 		if (area1->mins[i] > area2->maxs[i] + 10) return qfalse;
@@ -1085,7 +1085,7 @@
 	area2 = &aasworld.areas[area2num];
 	//if the first area contains a liquid
 	area1swim = AAS_AreaSwim(area1num);
-	//if the areas are not near anough in the x-y direction
+	//if the areas are not near enough in the x-y direction
 	for (i = 0; i < 2; i++)
 	{
 		if (area1->mins[i] > area2->maxs[i] + 10) return qfalse;
@@ -2131,7 +2131,7 @@
 	//maximum height a player can jump with the given initial z velocity
 	maxjumpheight = AAS_MaxJumpHeight(phys_jumpvel);
 
-	//if the areas are not near anough in the x-y direction
+	//if the areas are not near enough in the x-y direction
 	for (i = 0; i < 2; i++)
 	{
 		if (area1->mins[i] > area2->maxs[i] + maxjumpdistance) return qfalse;

Modified: trunk/code/botlib/be_ai_move.c
===================================================================
--- trunk/code/botlib/be_ai_move.c	2012-06-18 16:36:21 UTC (rev 2270)
+++ trunk/code/botlib/be_ai_move.c	2012-06-18 16:39:58 UTC (rev 2271)
@@ -1988,7 +1988,7 @@
 	{
 		//botimport.Print(PRT_MESSAGE, "moving towards ladder\n");
 		VectorSubtract(reach->end, ms->origin, dir);
-		//make sure the horizontal movement is large anough
+		//make sure the horizontal movement is large enough
 		VectorCopy(dir, hordir);
 		hordir[2] = 0;
 		dist = VectorNormalize(hordir);

Modified: trunk/code/cgame/cg_players.c
===================================================================
--- trunk/code/cgame/cg_players.c	2012-06-18 16:36:21 UTC (rev 2270)
+++ trunk/code/cgame/cg_players.c	2012-06-18 16:39:58 UTC (rev 2271)
@@ -1696,7 +1696,7 @@
 		dir[2] += 100;
 		VectorNormalize( dir );
 		d = DotProduct(pole.axis[2], dir);
-		// if there is anough movement orthogonal to the flag pole
+		// if there is enough movement orthogonal to the flag pole
 		if (fabs(d) < 0.9) {
 			//
 			d = DotProduct(pole.axis[0], dir);

Modified: trunk/code/game/ai_dmnet.c
===================================================================
--- trunk/code/game/ai_dmnet.c	2012-06-18 16:36:21 UTC (rev 2270)
+++ trunk/code/game/ai_dmnet.c	2012-06-18 16:39:58 UTC (rev 2271)
@@ -2451,7 +2451,7 @@
 	else if (!(moveresult.flags & MOVERESULT_MOVEMENTVIEWSET)
 				&& !(bs->flags & BFL_IDEALVIEWSET) ) {
 		attack_skill = trap_Characteristic_BFloat(bs->character, CHARACTERISTIC_ATTACK_SKILL, 0, 1);
-		//if the bot is skilled anough
+		//if the bot is skilled enough
 		if (attack_skill > 0.3) {
 			BotAimAtEnemy(bs);
 		}
@@ -2597,7 +2597,7 @@
 	else if (!(moveresult.flags & MOVERESULT_MOVEMENTVIEWSET)
 				&& !(bs->flags & BFL_IDEALVIEWSET)) {
 		attack_skill = trap_Characteristic_BFloat(bs->character, CHARACTERISTIC_ATTACK_SKILL, 0, 1);
-		//if the bot is skilled anough and the enemy is visible
+		//if the bot is skilled enough and the enemy is visible
 		if (attack_skill > 0.3) {
 			//&& BotEntityVisible(bs->entitynum, bs->eye, bs->viewangles, 360, bs->enemy)
 			BotAimAtEnemy(bs);

Modified: trunk/code/game/ai_dmq3.c
===================================================================
--- trunk/code/game/ai_dmq3.c	2012-06-18 16:36:21 UTC (rev 2270)
+++ trunk/code/game/ai_dmq3.c	2012-06-18 16:39:58 UTC (rev 2271)
@@ -713,7 +713,7 @@
 	//if the bot is roaming
 	if (bs->ctfroam_time > FloatTime())
 		return;
-	//if the bot has anough aggression to decide what to do
+	//if the bot has enough aggression to decide what to do
 	if (BotAggression(bs) < 50)
 		return;
 	//set the time to send a message to the team mates
@@ -960,7 +960,7 @@
 	//if the bot is roaming
 	if (bs->ctfroam_time > FloatTime())
 		return;
-	//if the bot has anough aggression to decide what to do
+	//if the bot has enough aggression to decide what to do
 	if (BotAggression(bs) < 50)
 		return;
 	//set the time to send a message to the team mates
@@ -1074,7 +1074,7 @@
 	//if the bot is roaming
 	if (bs->ctfroam_time > FloatTime())
 		return;
-	//if the bot has anough aggression to decide what to do
+	//if the bot has enough aggression to decide what to do
 	if (BotAggression(bs) < 50)
 		return;
 	//set the time to send a message to the team mates
@@ -1219,7 +1219,7 @@
 	//if the bot is roaming
 	if (bs->ctfroam_time > FloatTime())
 		return;
-	//if the bot has anough aggression to decide what to do
+	//if the bot has enough aggression to decide what to do
 	if (BotAggression(bs) < 50)
 		return;
 	//set the time to send a message to the team mates
@@ -2515,7 +2515,7 @@
 		bs->camp_time = FloatTime();
 		return qfalse;
 	}
-	//if the bot isn't healthy anough
+	//if the bot isn't healthy enough
 	if (BotAggression(bs) < 50) return qfalse;
 	//the bot should have at least have the rocket launcher, the railgun or the bfg10k with some ammo
 	if ((bs->inventory[INVENTORY_ROCKETLAUNCHER] <= 0 || bs->inventory[INVENTORY_ROCKETS] < 10) &&
@@ -2607,7 +2607,7 @@
 		//direction and length towards the roam target
 		VectorSubtract(trace.endpos, bs->origin, dir);
 		len = VectorNormalize(dir);
-		//if the roam target is far away anough
+		//if the roam target is far away enough
 		if (len > 200) {
 			//the roam target is in the given direction before walls
 			VectorScale(dir, len * trace.fraction - 40, dir);
@@ -3398,7 +3398,7 @@
 			VectorSubtract(entinfo.origin, bs->enemyorigin, dir);
 			//if the enemy is NOT pretty far away and strafing just small steps left and right
 			if (!(dist > 100 && VectorLengthSquared(dir) < Square(32))) {
-				//if skilled anough do exact prediction
+				//if skilled enough do exact prediction
 				if (aim_skill > 0.8 &&
 						//if the weapon is ready to fire
 						bs->cur_ps.weaponstate == WEAPON_READY) {
@@ -3458,10 +3458,10 @@
 				//if hitpoint is not vertically too far from the ground target
 				if (fabs(trace.endpos[2] - groundtarget[2]) < 50) {
 					VectorSubtract(trace.endpos, groundtarget, dir);
-					//if the hitpoint is near anough the ground target
+					//if the hitpoint is near enough the ground target
 					if (VectorLengthSquared(dir) < Square(60)) {
 						VectorSubtract(trace.endpos, start, dir);
-						//if the hitpoint is far anough from the bot
+						//if the hitpoint is far enough from the bot
 						if (VectorLengthSquared(dir) > Square(100)) {
 							//check if the bot is visible from the ground target
 							trace.endpos[2] += 1;
@@ -3483,7 +3483,7 @@
 		//
 		VectorCopy(bs->lastenemyorigin, bestorigin);
 		bestorigin[2] += 8;
-		//if the bot is skilled anough
+		//if the bot is skilled enough
 		if (aim_skill > 0.5) {
 			//do prediction shots around corners
 			if (wi.number == WP_BFG ||

Modified: trunk/code/q3_ui/ui_gameinfo.c
===================================================================
--- trunk/code/q3_ui/ui_gameinfo.c	2012-06-18 16:36:21 UTC (rev 2270)
+++ trunk/code/q3_ui/ui_gameinfo.c	2012-06-18 16:39:58 UTC (rev 2271)
@@ -197,7 +197,7 @@
 		UI_LoadArenasFromFile(filename);
 	}
 	trap_Print( va( "%i arenas parsed\n", ui_numArenas ) );
-	if (outOfMemory) trap_Print(S_COLOR_YELLOW"WARNING: not anough memory in pool to load all arenas\n");
+	if (outOfMemory) trap_Print(S_COLOR_YELLOW"WARNING: not enough memory in pool to load all arenas\n");
 
 	// set initial numbers
 	for( n = 0; n < ui_numArenas; n++ ) {
@@ -347,7 +347,7 @@
 	trap_FS_FCloseFile( f );
 
 	ui_numBots += UI_ParseInfos( buf, MAX_BOTS - ui_numBots, &ui_botInfos[ui_numBots] );
-	if (outOfMemory) trap_Print(S_COLOR_YELLOW"WARNING: not anough memory in pool to load all bots\n");
+	if (outOfMemory) trap_Print(S_COLOR_YELLOW"WARNING: not enough memory in pool to load all bots\n");
 }
 
 /*

Modified: trunk/code/ui/ui_gameinfo.c
===================================================================
--- trunk/code/ui/ui_gameinfo.c	2012-06-18 16:36:21 UTC (rev 2270)
+++ trunk/code/ui/ui_gameinfo.c	2012-06-18 16:39:58 UTC (rev 2271)
@@ -164,7 +164,7 @@
 	}
 	trap_Print( va( "%i arenas parsed\n", ui_numArenas ) );
 	if (UI_OutOfMemory()) {
-		trap_Print(S_COLOR_YELLOW"WARNING: not anough memory in pool to load all arenas\n");
+		trap_Print(S_COLOR_YELLOW"WARNING: not enough memory in pool to load all arenas\n");
 	}
 
 	for( n = 0; n < ui_numArenas; n++ ) {



More information about the quake3-commits mailing list