tag:blogger.com,1999:blog-948384407338209758.post2206938126130651722..comments2022-03-17T14:07:12.473-07:00Comments on BrainWorks: The Rambo ProblemTed Vesseneshttp://www.blogger.com/profile/17711708636792771116noreply@blogger.comBlogger4125tag:blogger.com,1999:blog-948384407338209758.post-38556685259395022992008-01-09T03:47:00.000-08:002008-01-09T03:47:00.000-08:00Whoops, found itWhoops, found itAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-948384407338209758.post-21091401961567180062008-01-09T01:59:00.000-08:002008-01-09T01:59:00.000-08:00Amazing Ted. Keep up the great work. BTW what's th...Amazing Ted. Keep up the great work. BTW what's the latest link for the current bot version download.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-948384407338209758.post-26321573461774841892008-01-08T19:03:00.000-08:002008-01-08T19:03:00.000-08:00Technically that's correct. If you look at the so...Technically that's correct. If you look at the source code for BotEnemeyHealth() in <A HREF="http://quake3-brainworks.googlecode.com/svn/trunk/code/game/ai_self.c" REL="nofollow">ai_self.c</A>, the code estimates health differently based on the skill of the bot. Unskilled bots always assume their targets have 125 health, for example, and average skilled bots use the estimate as defined by BotEnemyHealthSet(). (This function is called by the scanning code in <A HREF="http://quake3-brainworks.googlecode.com/svn/trunk/code/game/ai_scan.c" REL="nofollow">ai_scan.c</A> when the bot hears a pain sound, since pain sounds change as the target gets more hurt.)<BR/><BR/>But yes, the high skill bots really do use the exact health totals of their targets, because good players know their target's health to better granularity than +/-25. It requires some concentration to count the damage ticks from each hit of plasma or lightning, multiply by damage per shot, and subtract from your last known value of the target's health, but it's not THAT hard for players to get an estimate within 5 health points. While it's technically not correct to look up the health values correctly, it produces more realistic bots, so I decided it was the right thing for the code.Ted Vesseneshttps://www.blogger.com/profile/17711708636792771116noreply@blogger.comtag:blogger.com,1999:blog-948384407338209758.post-58995409341948841692008-01-08T11:47:00.000-08:002008-01-08T11:47:00.000-08:00the all important: * H = Target's current healthSu...the all important:<BR/> * H = Target's current health<BR/><BR/>Sure it's nice to know enemy's health (your source):<BR/>ai_weapon.c<BR/>BotTargetWeapon()<BR/>health = BotEnemyHealth(bs); // Estimate the enemy target's health<BR/><BR/>But I think this info is not available to players (q3 source):<BR/>cg_local.h<BR/>clientInfo_t <BR/>int health; // you only get this info about your teammatesAnonymousnoreply@blogger.com