View Single Post
Re: Bot running speed
Old
  (#2)
The Storm
Council Member / E[POD]bot developer
 
The Storm's Avatar
 
Status: Offline
Posts: 1,618
Join Date: Jul 2004
Location: Bulgaria
Default Re: Bot running speed - 31-07-2015

You should always get the maximum speed value from the engine and not set hardcoded numbers. How actually you get it?

Always use pEdict->v.maxspeed of the bot for the RunPlayerMove() function.
Also you need to use the SetClientMaxspeed callback and write this code inside:
Code:
void pfnSetClientMaxspeed(const edict_t * pEdict, float fNewMaxspeed)
{
    ((edict_t *) pEdict)->v.maxspeed = fNewMaxspeed;
    RETURN_META(MRES_IGNORED);
}
This should fix your speed issues. Also beware that the code I pasted is from E[POD]bot and it might have minor difference from the one in HPB_bot but you get the idea.
  
Reply With Quote