finally I figured it out , it is caused by the function BotFixIdealYaw()
The HPB_Bot template one is :
Code:
void BotFixIdealYaw(edict_t *pEdict)
{
// check for wrap around of angle...
if (pEdict->v.ideal_yaw >= 180)
pEdict->v.ideal_yaw -= 360 * ((int) (pEdict->v.ideal_yaw / 360) + 1);
if (pEdict->v.ideal_yaw < -180)
pEdict->v.ideal_yaw += 360 * ((int) (-pEdict->v.ideal_yaw / 360) + 1);
}
It should rather be :
Code:
void BotFixIdealYaw(edict_t *pEdict)
{
// check for wrap around of angle...
if (pEdict->v.ideal_yaw > 180)
pEdict->v.ideal_yaw -= 360;
if (pEdict->v.ideal_yaw < -180)
pEdict->v.ideal_yaw += 360;
}
Dont know wherever its the solution , havent test it out yet , but I think that is the solution since no other code are related to aiming and angle