[nexuiz-commits] r6991 - in trunk/data: . qcsrc/server

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Thu Jun 11 18:56:10 EDT 2009


Author: mand1nga
Date: 2009-06-11 18:56:10 -0400 (Thu, 11 Jun 2009)
New Revision: 6991

Modified:
   trunk/data/defaultNexuiz.cfg
   trunk/data/qcsrc/server/havocbot.qc
Log:
New cvar bot_ai_enemydetectionradius for limiting bots visibility

Modified: trunk/data/defaultNexuiz.cfg
===================================================================
--- trunk/data/defaultNexuiz.cfg	2009-06-11 22:28:18 UTC (rev 6990)
+++ trunk/data/defaultNexuiz.cfg	2009-06-11 22:56:10 UTC (rev 6991)
@@ -353,6 +353,7 @@
 set bot_ai_thinkinterval 0.05
 set bot_ai_strategyinterval 3 "How often a new objective is chosen"
 set bot_ai_enemydetectioninterval 0.5 "How often bots pick a new target"
+set bot_ai_enemydetectionradius 10000 "How far bots can see enemies"
 set bot_ai_dodgeupdateinterval 0.1 "How often scan for items to dodge. Currently not in use."
 set bot_ai_chooseweaponinterval 0.3 "How often the best weapon according to the situation will be chosen"
 set bot_ai_dangerdetectioninterval 0.1 "How often scan for waypoints with dangers near"

Modified: trunk/data/qcsrc/server/havocbot.qc
===================================================================
--- trunk/data/qcsrc/server/havocbot.qc	2009-06-11 22:28:18 UTC (rev 6990)
+++ trunk/data/qcsrc/server/havocbot.qc	2009-06-11 22:56:10 UTC (rev 6991)
@@ -721,6 +721,7 @@
 	{
 		v = (head.absmin + head.absmax) * 0.5;
 		rating = vlen(v - eye);
+		if (rating<cvar("bot_ai_enemydetectionradius"))
 		if (bestrating > rating)
 		if (bot_shouldattack(head))
 		{



More information about the nexuiz-commits mailing list