mirror of
https://github.com/thegeneralist01/Scene-Manager-DevRepo
synced 2026-01-11 15:40:29 +01:00
Moved waypoint removal code to the Waypoint class
This commit is contained in:
parent
4d305aea15
commit
87e1b591f4
1 changed files with 2 additions and 6 deletions
|
|
@ -185,7 +185,7 @@ namespace SceneManager
|
||||||
editWaypoint.Index = editWaypoint.OptionCount - 1;
|
editWaypoint.Index = editWaypoint.OptionCount - 1;
|
||||||
editWaypointMenu.RefreshIndex();
|
editWaypointMenu.RefreshIndex();
|
||||||
updateWaypointPosition.Checked = false;
|
updateWaypointPosition.Checked = false;
|
||||||
Logger.Log($"New waypoint (#{currentWaypoint.Number + 1}) added.");
|
Logger.Log($"New waypoint (#{currentPath.Waypoints.Last().Number}) added.");
|
||||||
|
|
||||||
Blip CreateNewWaypointBlip()
|
Blip CreateNewWaypointBlip()
|
||||||
{
|
{
|
||||||
|
|
@ -230,11 +230,7 @@ namespace SceneManager
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
currentWaypoint.Blip.Delete();
|
currentWaypoint.Remove();
|
||||||
if (currentWaypoint.CollectorRadiusBlip)
|
|
||||||
{
|
|
||||||
currentWaypoint.CollectorRadiusBlip.Delete();
|
|
||||||
}
|
|
||||||
currentPath.Waypoints.Remove(currentWaypoint);
|
currentPath.Waypoints.Remove(currentWaypoint);
|
||||||
Logger.Log($"[Path {currentPath.Number}] Waypoint {currentWaypoint.Number} ({currentWaypoint.DrivingFlag}) removed");
|
Logger.Log($"[Path {currentPath.Number}] Waypoint {currentWaypoint.Number} ({currentWaypoint.DrivingFlag}) removed");
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue