Update() public method

public Update ( ) : void
return void
Esempio n. 1
0
        static void Main()
        {
            DX.ChangeWindowMode( DX.TRUE );
            DX.SetGraphMode(1600, 900, 32);

            if ( DX.DxLib_Init() == -1 )
            {
                return;
            }

            DX.SetDrawScreen(DX.DX_SCREEN_BACK);

            Scene scene = new TestScene();

            SceneController sc = new SceneController(scene);

            while (DX.ProcessMessage() == 0 && DX.CheckHitKey(DX.KEY_INPUT_ESCAPE) == 0)
            {
                DX.ClearDrawScreen();

                sc.Update();

                DX.ScreenFlip();
            }

            DX.DxLib_End();

            return;
        }
Esempio n. 2
0
        static void Main(String[] args)
        {
            ChangeWindowMode(TRUE);
            DxLib_Init();
            SetDrawScreen(DX_SCREEN_BACK); //ウィンドウモード変更と初期化と裏画面設定
            SetMainWindowText("俺の冒険");     //タイトル文字変更
            SetGraphMode(1280, 720, 32);   //ウィンドウサイズ変更

            Scene           scene = new Start();
            SceneController sc    = new SceneController(scene);

            DXLibScene.source.Function fc = new Function();

            while (ScreenFlip() == 0 && ProcessMessage() == 0 && ClearDrawScreen() == 0 &&
                   CheckHitKey(KEY_INPUT_ESCAPE) == 0 && fc.getUpdateKey() == 0)
            {
                if (SceneController.copyScene != null)
                {
                    sc.CopySceneDraw();
                }
                sc.Draw();
                sc.Update();
            }
            DxLib_End();
            return;
        }
Esempio n. 3
0
        /// <summary>
        /// Allows the game to run logic such as updating the world,
        /// checking for collisions, gathering input, and playing audio.
        /// </summary>
        /// <param name="gameTime">Provides a snapshot of timing values.</param>
        protected override void Update(GameTime gameTime)
        {
            FMODManager.Update();
            UIController.Update();
            SceneController.Update();

            if (
                GamePad.GetState(PlayerIndex.One).Buttons.Back == ButtonState.Pressed ||
                GamePad.GetState(PlayerIndex.One).Buttons.Start == ButtonState.Pressed ||
                Keyboard.GetState().IsKeyDown(Keys.Escape)
                )
            {
                Exit();
            }

            base.Update(gameTime);
        }
 // Update is called once per frame
 public void Update()
 {
     sceneController.Update();
 }
Esempio n. 5
0
 void Update()
 {
     SceneController.Update();
 }