public Timer Regist(Action<Timer> callback, float interval, int times, TimerStateType state = TimerStateType.Normal) { Timer timer = new Timer(callback, interval, times, state); _timers.Add(timer); return timer; }
//移除一个计时器 public void Remove(Timer timer) { if (_timers.Contains(timer)) _timers.Remove(timer); }
//注册一个计时器 public Timer Regist(Timer timer) { _timers.Add(timer); return timer; }