private TimeModule() { AutoStart = true; m_instance = this; EngineCoreEvents.SystemEvents.SendTaskExecuteNextFrame += ExecuteOnNextFrame; }
public static void RemoveTimeactionInObject(this TimeModule tm_, GameObject obj_, Action fun) { var tc = obj_.GetComponent <TimerComponent>(); tc?.RemoveTimeaction(fun); }
public static void SetTimeoutLiveInObject(this TimeModule tm_, GameObject obj_, Action fun, float time, bool loop = false, bool canPause = true) { var tc = obj_.GetOrAddComponent <TimerComponent>(); tc.SetTimeout(fun, time, loop, canPause); }
private TimeModule() { AutoStart = true; m_instance = this; }