View Single Post
Re: Bugs to be fixed
Old
  (#24)
Josh_Borke
Member
 
Status: Offline
Posts: 152
Join Date: Jun 2004
Default Re: Bugs to be fixed - 26-07-2004

--last edit, i swear--
util.cpp line 653
Code:
weapon_id == CS_WEAPON_UMP45 ||
is there a reason a UMP45 is listed as a secondary weapon? seems to me to be a primary...
btw, pistol mode is trivial to include, here are the changes:
(+ = new code, - = removed code, everything else is already there)

game.h: line 118
Code:
   bool bEngineDebug;   // Print engine debug messages
 +  bool bPistols;
game.cpp: line 99
Code:
    bEngineDebug = false;		// ... prints engine debug messages (for figuring out engine interceptions)
  +  bPistols = false;	 // pistols only mode
bot.cpp: line 177
Code:
-  buy_primary = true;
 -  buy_secondary = false;
 +  buy_primary = (Game.bPistols ? false : true);
 +  buy_secondary = (Game.bPistols ? true : false);
line 101
Code:
-  if (RANDOM_LONG (0, 100) < 15)
 +  if (RANDOM_LONG (0, 100) < 15 || Game.bPistols)
line 338
Code:
-  buy_primary = true;
 +  buy_primary = (Game.bPistols ? false : true);
    buy_grenade = false;
    buy_flashbang = 0;
 -  buy_secondary = false;
 +  buy_secondary = (Game.bPistols ? true : false);
    buy_armor = false;
and of course teh requisite command in dll.cpp, but i'll let you decide what it should be.
I think that is all the changes, if you'd like me to, I can send you all the files I've changed.
the only problem i've found so far is that the T's buy ump45's but I think that is because the UTIL_giveweapontype returns SECONDARY for those.

should shields be classified as primary weapon?
currently if a bot is carrying a shield, the shield is not put into pBot->iPrimaryWeapon, should it be?

As always, HTH

Last edited by Josh_Borke; 26-07-2004 at 08:22..
  
Reply With Quote