Skip to content

Commit

Permalink
Overtake frequency fix
Browse files Browse the repository at this point in the history
  • Loading branch information
NomarCub committed Dec 12, 2019
1 parent c84fa9d commit c4f144e
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Assets/Scripts/Cars/CarController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,10 @@ internal bool TryOvertake(CarController otherCar)
|| cantGo()
|| overtakeInfo.state != OvertakeInfo.State.None
|| overtakeInfo.lastTried + 0.5f > Time.fixedTime)
{
overtakeInfo.lastTried = Time.fixedTime;
return false;
}

Node currentNode = shortestPath[currentNodeIndex];
Node previousNode = shortestPath[currentNodeIndex - 1];
Expand Down

0 comments on commit c4f144e

Please sign in to comment.