diff --git a/Assets/Scripts/Map/MapSignal.cs b/Assets/Scripts/Map/MapSignal.cs index ecbf25c0e..546551db3 100644 --- a/Assets/Scripts/Map/MapSignal.cs +++ b/Assets/Scripts/Map/MapSignal.cs @@ -9,6 +9,7 @@ using System.Collections; using System.Collections.Generic; using UnityEngine; +using UnityEditor; using System.Linq; using Simulator.Utilities; using Simulator.Controllable; @@ -37,7 +38,13 @@ public class MapSignal : MapData, IControllable, IMapType public string id { get { return _id; } - set { _id = value; } + set + { +#if UNITY_EDITOR + Undo.RecordObject(this, "Changed signal ID"); +#endif + _id = value; + } } public string Key => UID;