LoginSignup
2
0

More than 5 years have passed since last update.

Daydream開発入門 アプリを終了させる

Last updated at Posted at 2017-11-04

バックキーや画面内の×ボタンを押してもアプリが終了しなかったため、終了させる方法をメモしておきます

バックキーを有効にする

    void Start () {
        // バックキーを有効化
        Input.backButtonLeavesApp = true;
    }

×ボタンでアプリを終了させる

    void Update () {
        // ×ボタンタップでアプリを終了
        if (Input.GetKeyDown(KeyCode.Escape)) {
            Application.Quit();
        }
    }
2
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
0