mirror of
https://github.com/thegeneralist01/Scene-Manager-DevRepo
synced 2026-01-11 15:40:29 +01:00
Added VehicleManeuver.GoForwardWithCustomSteeringAngle after each driving task to stop AI from braking at each waypoint.
This commit is contained in:
parent
54c2bd8c12
commit
98f7efe647
1 changed files with 5 additions and 0 deletions
|
|
@ -57,6 +57,7 @@ namespace SceneManager
|
|||
if (waypoints.ElementAtOrDefault(nextWaypoint) != null && !collectedVehicle.StoppedAtWaypoint)
|
||||
{
|
||||
collectedVehicle.Vehicle.Driver.Tasks.DriveToPosition(waypoints[nextWaypoint].Position, waypoints[nextWaypoint].Speed, (VehicleDrivingFlags)263043, 2f).WaitForCompletion();
|
||||
collectedVehicle.Vehicle.Driver.Tasks.PerformDrivingManeuver(collectedVehicle.Vehicle, VehicleManeuver.GoForwardWithCustomSteeringAngle, 3);
|
||||
}
|
||||
|
||||
if (waypoints.ElementAtOrDefault(nextWaypoint) != null && waypoints[nextWaypoint].DrivingFlag == VehicleDrivingFlags.StopAtDestination)
|
||||
|
|
@ -95,6 +96,10 @@ namespace SceneManager
|
|||
cv.Vehicle.Driver.Dismiss();
|
||||
cv.Vehicle.Driver.Tasks.Clear();
|
||||
cv.Vehicle.Driver.BlockPermanentEvents = false;
|
||||
if (cv.Vehicle.Driver.GetAttachedBlip())
|
||||
{
|
||||
cv.Vehicle.Driver.GetAttachedBlip().Delete();
|
||||
}
|
||||
cv.Vehicle.Driver.IsPersistent = false;
|
||||
|
||||
cv.Vehicle.Dismiss();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue