View Single Post
Re: Hi, thanks and help!
Old
  (#3)
mfrx
Member
 
Status: Offline
Posts: 13
Join Date: Jun 2005
Default Re: Hi, thanks and help! - 30-06-2005

Sorry, I should have been clearer.

First; the reason I need this is because I am trying to make the bots rocket jump (look down, jump and fire a rocket).

The problem is that a player may only fire a rocket once every 0.8 seconds (approx) so if I need to call the rocket jump function just before it is possible to fire again otherwise the bot may end up looking at the ground for 0.79 seconds

So I need to store the time that they last fired a weapon.

I have tried:
Code:
 
int GetWeaponData( struct edict_s *player, struct weapon_data_s *info )
{
char msg[200];
sprintf(msg, "ID: %d, Idle: %.2f, State: %d, Clip: %d", info->m_iId, info->m_flTimeWeaponIdle, info->m_iWeaponState, info->m_iClip);
clsUtil.WriteToConsole(msg);
}
and assigned that function to gFunctionTable.pfnGetWeaponData but all of the members are 0.

I hope that makes sense

1 of the game modes (Rocket Arena) has infinite ammo so the amount does not go down

Thanks again
  
Reply With Quote