JavaScript Game: Obstacle Avoidance with Cars