Exemple #1
0
        public override bool Trigger(object sender, object arg)
        {
            if (!this.CanTrigger)
            {
                return(false);
            }

            GameLoopEntry.QuitApplication();
            return(GameLoopEntry.QuitState > QuitState.None);
        }
Exemple #2
0
        public SirenToken BeginSignalSiren()
        {
            if (_currentToken != null)
            {
                return(_currentToken);
            }
            if (_activeSensors == null)
            {
                _activeSensors = new HashSet <AudibleSensor>();
            }

            _currentToken = new SirenToken(this);
            (this as IUpdateable).Update();
            GameLoopEntry.RegisterNextUpdate(this);
            return(_currentToken);
        }
 public static void CreateGameLoopEntry()
 {
     GameLoopEntry.Init();
 }