Esempio n. 1
0
    public static void DestroyTimer(TimerEvent timer, bool isCallBack = false)
    {
        if (m_timers.Contains(timer))
        {
            if (isCallBack)
            {
                timer.CallBackTimer();
            }

            m_timers.Remove(timer);
        }
        else
        {
            Debug.LogError("Timer DestroyTimer error: dont exist timer " + timer);
        }
    }
Esempio n. 2
0
    public static void DestroyTimer(TimerEvent l_timer, bool isCallBack = false)
    {
        if (s_instance.m_timers.Contains(l_timer))
        {
            if (isCallBack)
            {
                l_timer.CallBackTimer();
            }

            s_instance.m_timers.Remove(l_timer);
        }
        else
        {
            Debug.LogError("Timer DestroyTimer error: dont exist timer " + l_timer);
        }
    }
Esempio n. 3
0
    public static void DestroyTimer(TimerEvent timer, bool isCallBack = false)
    {
        //Debug.Log("DestroyTimer1  ----TIMER " + timer.m_timerName);
        if (m_timers.Contains(timer))
        {
            if (isCallBack)
            {
                timer.CallBackTimer();
            }

            m_timers.Remove(timer);
            HeapObjectPool <TimerEvent> .PutObject(timer);
        }
        else
        {
            Debug.LogError("Timer DestroyTimer error: dont exist timer " + timer);
        }
    }