コード例 #1
0
 public static void AddLateUpdate(UnityEngine.Object obj, Action action, string DebugName)
 {
     TickComponent.Init();
     Tick.Entry.List late  = Tick.Late;
     Tick.Entry      entry = new Tick.Entry()
     {
         TargetObject = obj,
         Function     = action,
         DebugName    = string.Format("{0} - {1}", DebugName, obj.name)
     };
     late.Add(entry);
 }
コード例 #2
0
 public static void AddTimed(UnityEngine.Object obj, float minDelay, float maxDelay, Action action, string DebugName)
 {
     TickComponent.Init();
     Tick.Entry.List timed = Tick.Timed;
     Tick.Entry      entry = new Tick.Entry()
     {
         TargetObject = obj,
         MinDelay     = minDelay,
         RandDelay    = maxDelay - minDelay,
         Function     = action,
         DebugName    = string.Format("{0} - {1}", DebugName, obj.name)
     };
     timed.Add(entry);
 }
コード例 #3
0
 private void OnEnable()
 {
     UnityEngine.Object.DontDestroyOnLoad(base.gameObject);
     TickComponent.Instance = this;
 }