Esempio n. 1
0
        protected override void OnUpdate(GameTime gameTime)
        {
            //timer -= Time.DeltaTime;
            //if (timer <= 0.0f && Network.IsServer) {
            //    for (int i = 0; i < 24; i++) {
            //        NetHelper.Instantiate("bouncy", "SERVER",
            //            new Vector2(128 + SE.Utility.Random.Next(0.0f, 1024.0f), 128 + SE.Utility.Random.Next(0.0f, 1024.0f)));
            //    }
            //    timer = 0.05f;
            //}

            if (IsEditor)
            {
                if (InputManager.KeyCodePressed(Keys.F3))
                {
                    SceneManager.SetCurrentScene("_DEMOS\\networktest");
                    Network.StartServer(919, 920);
                }
            }

            if (SceneManager.CurrentScene.LevelName != "menu" && !backToMenu.Enabled)
            {
                backToMenu.Enable();
            }
            else if (SceneManager.CurrentScene.LevelName == "menu")
            {
                backToMenu.Disable(true);
            }
        }
Esempio n. 2
0
 public override void OnEnter()
 {
     if (DebugMode.Value)
     {
         DDebug.Log("Playmaker - State Name [" + State.Name + "] - Disable Back Button");
     }
     BackButton.Disable();
     if (FinishImmediately.Value)
     {
         Finish();
     }
 }
Esempio n. 3
0
        private void ExecuteActions()
        {
            // ReSharper disable once SwitchStatementMissingSomeCases
            switch (BackButtonAction)
            {
            case BackButtonState.Disable:
                BackButton.Disable();
                break;

            case BackButtonState.Enable:
                BackButton.Enable();
                break;

            case BackButtonState.EnableByForce:
                BackButton.EnableByForce();
                break;
            }
        }