void havocbot_goalrating_ball(entity this, float ratingscale, vector org)
{
- float t;
entity ball_owner;
ball_owner = ka_ball.owner;
if (ball_owner == this)
return;
- // If ball is carried by player then hunt them down.
if (ball_owner)
- {
- t = (GetResourceAmount(this, RESOURCE_HEALTH) + GetResourceAmount(this, RESOURCE_ARMOR)) / (GetResourceAmount(ball_owner, RESOURCE_HEALTH) + GetResourceAmount(ball_owner, RESOURCE_ARMOR));
- navigation_routerating(this, ball_owner, t * ratingscale, 2000);
- }
- else // Ball has been dropped so collect.
+ navigation_routerating(this, ball_owner, ratingscale, 2000);
+ else
navigation_routerating(this, ka_ball, ratingscale, 2000);
}
navigation_goalrating_start(this);
havocbot_goalrating_items(this, 10000, this.origin, 10000);
havocbot_goalrating_enemyplayers(this, 500, this.origin, 10000);
- havocbot_goalrating_ball(this, 20000, this.origin);
+ havocbot_goalrating_ball(this, 8000, this.origin);
navigation_goalrating_end(this);
navigation_goalrating_timeout_set(this);