[quake3-commits] r1607 - trunk/code/botlib

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Mon Sep 14 21:44:58 EDT 2009


Author: icculus
Date: 2009-09-14 21:44:58 -0400 (Mon, 14 Sep 2009)
New Revision: 1607

Modified:
   trunk/code/botlib/be_aas_main.c
   trunk/code/botlib/be_aas_route.c
   trunk/code/botlib/be_aas_sample.c
   trunk/code/botlib/be_ai_char.c
   trunk/code/botlib/be_ai_chat.c
   trunk/code/botlib/be_ai_goal.c
   trunk/code/botlib/be_ai_move.c
   trunk/code/botlib/be_ai_weight.c
   trunk/code/botlib/be_interface.c
   trunk/code/botlib/be_interface.h
   trunk/code/botlib/botlib.h
Log:
Renamed bot_developer to botDeveloper to prevent symbol clash.

qagame*.so has a variable named this too, and this confuses the Linux
 dynamic loader since we're not using -fvisibility=hidden.

 Fixes Bugzilla #3944.


Modified: trunk/code/botlib/be_aas_main.c
===================================================================
--- trunk/code/botlib/be_aas_main.c	2009-09-15 01:36:17 UTC (rev 1606)
+++ trunk/code/botlib/be_aas_main.c	2009-09-15 01:44:58 UTC (rev 1607)
@@ -247,7 +247,7 @@
 	//
 	aasworld.frameroutingupdates = 0;
 	//
-	if (bot_developer)
+	if (botDeveloper)
 	{
 		if (LibVarGetValue("showcacheupdates"))
 		{

Modified: trunk/code/botlib/be_aas_route.c
===================================================================
--- trunk/code/botlib/be_aas_route.c	2009-09-15 01:36:17 UTC (rev 1606)
+++ trunk/code/botlib/be_aas_route.c	2009-09-15 01:44:58 UTC (rev 1607)
@@ -311,7 +311,7 @@
 
 	if (areanum <= 0 || areanum >= aasworld.numareas)
 	{
-		if (bot_developer)
+		if (botDeveloper)
 		{
 			botimport.Print(PRT_ERROR, "AAS_EnableRoutingArea: areanum %d out of range\n", areanum);
 		} //end if
@@ -1603,7 +1603,7 @@
 	//
 	if (areanum <= 0 || areanum >= aasworld.numareas)
 	{
-		if (bot_developer)
+		if (botDeveloper)
 		{
 			botimport.Print(PRT_ERROR, "AAS_AreaTravelTimeToGoalArea: areanum %d out of range\n", areanum);
 		} //end if
@@ -1611,7 +1611,7 @@
 	} //end if
 	if (goalareanum <= 0 || goalareanum >= aasworld.numareas)
 	{
-		if (bot_developer)
+		if (botDeveloper)
 		{
 			botimport.Print(PRT_ERROR, "AAS_AreaTravelTimeToGoalArea: goalareanum %d out of range\n", goalareanum);
 		} //end if

Modified: trunk/code/botlib/be_aas_sample.c
===================================================================
--- trunk/code/botlib/be_aas_sample.c	2009-09-15 01:36:17 UTC (rev 1606)
+++ trunk/code/botlib/be_aas_sample.c	2009-09-15 01:44:58 UTC (rev 1607)
@@ -150,7 +150,7 @@
 	if (!link)
 	{
 #ifndef BSPC
-		if (bot_developer)
+		if (botDeveloper)
 #endif
 		{
 			botimport.Print(PRT_FATAL, "empty aas link heap\n");

Modified: trunk/code/botlib/be_ai_char.c
===================================================================
--- trunk/code/botlib/be_ai_char.c	2009-09-15 01:36:17 UTC (rev 1606)
+++ trunk/code/botlib/be_ai_char.c	2009-09-15 01:44:58 UTC (rev 1607)
@@ -416,7 +416,7 @@
 		//
 		botimport.Print(PRT_MESSAGE, "loaded skill %d from %s\n", intskill, charfile);
 #ifdef DEBUG
-		if (bot_developer)
+		if (botDeveloper)
 		{
 			botimport.Print(PRT_MESSAGE, "skill %d loaded in %d msec from %s\n", intskill, Sys_MilliSeconds() - starttime, charfile);
 		} //end if

Modified: trunk/code/botlib/be_ai_chat.c
===================================================================
--- trunk/code/botlib/be_ai_chat.c	2009-09-15 01:36:17 UTC (rev 1606)
+++ trunk/code/botlib/be_ai_chat.c	2009-09-15 01:44:58 UTC (rev 1607)
@@ -1992,7 +1992,7 @@
 	botimport.Print(PRT_MESSAGE, "loaded %s\n", filename);
 	//
 	//BotDumpReplyChat(replychatlist);
-	if (bot_developer)
+	if (botDeveloper)
 	{
 		BotCheckReplyChatIntegrety(replychatlist);
 	} //end if
@@ -2191,7 +2191,7 @@
 	botimport.Print(PRT_MESSAGE, "loaded %s from %s\n", chatname, chatfile);
 	//
 	//BotDumpInitialChat(chat);
-	if (bot_developer)
+	if (botDeveloper)
 	{
 		BotCheckInitialChatIntegrety(chat);
 	} //end if

Modified: trunk/code/botlib/be_ai_goal.c
===================================================================
--- trunk/code/botlib/be_ai_goal.c	2009-09-15 01:36:17 UTC (rev 1606)
+++ trunk/code/botlib/be_ai_goal.c	2009-09-15 01:44:58 UTC (rev 1607)
@@ -522,7 +522,7 @@
 			numcampspots++;
 		} //end else if
 	} //end for
-	if (bot_developer)
+	if (botDeveloper)
 	{
 		botimport.Print(PRT_MESSAGE, "%d map locations\n", numlocations);
 		botimport.Print(PRT_MESSAGE, "%d camp spots\n", numcampspots);

Modified: trunk/code/botlib/be_ai_move.c
===================================================================
--- trunk/code/botlib/be_ai_move.c	2009-09-15 01:36:17 UTC (rev 1606)
+++ trunk/code/botlib/be_ai_move.c	2009-09-15 01:44:58 UTC (rev 1607)
@@ -772,7 +772,7 @@
 		if (i != MAX_AVOIDREACH && avoidreachtries[i] > AVOIDREACH_TRIES)
 		{
 #ifdef DEBUG
-			if (bot_developer)
+			if (botDeveloper)
 			{
 				botimport.Print(PRT_MESSAGE, "avoiding reachability %d\n", avoidreach[i]);
 			} //end if
@@ -3076,7 +3076,7 @@
 						} //end if
 						else
 						{
-							if (bot_developer)
+							if (botDeveloper)
 							{
 								botimport.Print(PRT_MESSAGE, "client %d: on func_plat without reachability\n", ms->client);
 							} //end if
@@ -3106,7 +3106,7 @@
 						} //end if
 						else
 						{
-							if (bot_developer)
+							if (botDeveloper)
 							{
 								botimport.Print(PRT_MESSAGE, "client %d: on func_bobbing without reachability\n", ms->client);
 							} //end if
@@ -3208,7 +3208,7 @@
 			else
 			{
 #ifdef DEBUG
-				if (bot_developer)
+				if (botDeveloper)
 				{
 					if (ms->reachability_time < AAS_Time())
 					{
@@ -3242,7 +3242,7 @@
 			if (!AAS_AreaReachability(ms->areanum))
 			{
 #ifdef DEBUG
-				if (bot_developer)
+				if (botDeveloper)
 				{
 					botimport.Print(PRT_MESSAGE, "area %d no reachability\n", ms->areanum);
 				} //end if
@@ -3273,12 +3273,12 @@
 			} //end if
 #ifdef DEBUG
 			
-			else if (bot_developer)
+			else if (botDeveloper)
 			{
 				botimport.Print(PRT_MESSAGE, "goal not reachable\n");
 				Com_Memset(&reach, 0, sizeof(aas_reachability_t)); //make compiler happy
 			} //end else
-			if (bot_developer)
+			if (botDeveloper)
 			{
 				//if still going for the same goal
 				if (ms->lastgoalareanum == goal->areanum)
@@ -3346,7 +3346,7 @@
 			Com_Memset(&reach, 0, sizeof(aas_reachability_t));
 		} //end else
 #ifdef DEBUG
-		if (bot_developer)
+		if (botDeveloper)
 		{
 			if (result->failure)
 			{
@@ -3402,7 +3402,7 @@
 				} //end else
 			} //end if
 		} //end for
-		if (bot_developer)
+		if (botDeveloper)
 		{
 			//if a jumppad is found with the trace but no reachability is found
 			if (foundjumppad && !ms->lastreachnum)
@@ -3447,7 +3447,7 @@
 			} //end switch
 			result->traveltype = reach.traveltype;
 #ifdef DEBUG
-			if (bot_developer)
+			if (botDeveloper)
 			{
 				if (result->failure)
 				{

Modified: trunk/code/botlib/be_ai_weight.c
===================================================================
--- trunk/code/botlib/be_ai_weight.c	2009-09-15 01:36:17 UTC (rev 1606)
+++ trunk/code/botlib/be_ai_weight.c	2009-09-15 01:44:58 UTC (rev 1607)
@@ -422,7 +422,7 @@
 	//if the file was located in a pak file
 	botimport.Print(PRT_MESSAGE, "loaded %s\n", filename);
 #ifdef DEBUG
-	if (bot_developer)
+	if (botDeveloper)
 	{
 		botimport.Print(PRT_MESSAGE, "weights loaded in %d msec\n", Sys_MilliSeconds() - starttime);
 	} //end if

Modified: trunk/code/botlib/be_interface.c
===================================================================
--- trunk/code/botlib/be_interface.c	2009-09-15 01:36:17 UTC (rev 1606)
+++ trunk/code/botlib/be_interface.c	2009-09-15 01:44:58 UTC (rev 1607)
@@ -58,7 +58,7 @@
 botlib_export_t be_botlib_export;
 botlib_import_t botimport;
 //
-int bot_developer;
+int botDeveloper;
 //qtrue if the library is setup
 int botlibsetup = qfalse;
 
@@ -139,7 +139,7 @@
 	char		logfilename[MAX_OSPATH];
 	char		*homedir, *gamedir;
 	
-	bot_developer = LibVarGetValue("bot_developer");
+	botDeveloper = LibVarGetValue("bot_developer");
  	memset( &botlibglobals, 0, sizeof(botlibglobals) );
 	//initialize byte swapping (litte endian etc.)
 //	Swap_Init();

Modified: trunk/code/botlib/be_interface.h
===================================================================
--- trunk/code/botlib/be_interface.h	2009-09-15 01:36:17 UTC (rev 1606)
+++ trunk/code/botlib/be_interface.h	2009-09-15 01:44:58 UTC (rev 1607)
@@ -50,7 +50,7 @@
 
 extern botlib_globals_t botlibglobals;
 extern botlib_import_t botimport;
-extern int bot_developer;					//true if developer is on
+extern int botDeveloper;					//true if developer is on
 
 //
 int Sys_MilliSeconds(void);

Modified: trunk/code/botlib/botlib.h
===================================================================
--- trunk/code/botlib/botlib.h	2009-09-15 01:36:17 UTC (rev 1606)
+++ trunk/code/botlib/botlib.h	2009-09-15 01:44:58 UTC (rev 1607)
@@ -443,7 +443,7 @@
 "log"						"0"					l_log.c				enable/disable creating a log file
 "maxclients"				"4"					be_interface.c		maximum number of clients
 "maxentities"				"1024"				be_interface.c		maximum number of entities
-"bot_developer"				"0"					be_interface.c		bot developer mode
+"bot_developer"				"0"					be_interface.c		bot developer mode (it's "botDeveloper" in C to prevent symbol clash).
 
 "phys_friction"				"6"					be_aas_move.c		ground friction
 "phys_stopspeed"			"100"				be_aas_move.c		stop speed



More information about the quake3-commits mailing list