OnDestroy() приватный Метод

private OnDestroy ( ) : void
Результат void
        void LateUpdate()
        {
            if (HighLogic.CurrentGame == null ||
                ClearInputLocks.focusFollowsclick) // ||
            //(!HighLogic.CurrentGame.Parameters.CustomParams<CTB>().focusFollowsclick && !HighLogic.LoadedSceneIsEditor))
            {
                return;
            }

            d = -1;
            ClickThruBlocker.CTBWin win = null;
            {
                foreach (var w in ClickThruBlocker.winList)
                {
                    //Log.Info("LateUpdate, w.Value.lastUpdated: " + w.Value.lastUpdated);
                    if (w.Value.lastUpdated + 4 < CBTGlobalMonitor.globalTimeTics) //+ 0.05 < Planetarium.GetUniversalTime())
                    {
                        d   = w.Key;
                        win = w.Value;
                        break;
                    }
                }
                if (d != -1)
                {
                    win.OnDestroy();
                }
            }
        }
Пример #2
0
        void LateUpdate()
        {
            if (HighLogic.CurrentGame.Parameters.CustomParams <CTB>().focusFollowsclick)
            {
                return;
            }

            d = 0;
            ClickThruBlocker.CTBWin win = null;
            //timeTics++;
            {
                foreach (var w in ClickThruBlocker.winList)
                {
                    if (w.Value.lastUpdated + 4 < CBTGlobalMonitor.globalTimeTics) //+ 0.05 < Planetarium.GetUniversalTime())
                    {
                        d   = w.Key;
                        win = w.Value;
                        break;
                    }
                }
                if (d != 0)
                {
                    win.OnDestroy();
                }
            }
        }
Пример #3
0
        void LateUpdate()
        {
            d = 0;
            ClickThruBlocker.CTBWin win = null;

            timeTics++;

            foreach (var w in  ClickThruBlocker.winList)
            {
                if (w.Value.lastUpdated + 4 < timeTics) //+ 0.05 < Planetarium.GetUniversalTime())
                {
                    d   = w.Key;
                    win = w.Value;
                    break;
                }
            }
            if (d != 0)
            {
                win.OnDestroy();
            }
        }