Created
December 14, 2017 08:24
-
-
Save afandiyusuf/b396241714df5cbcdaf3098a31260dc5 to your computer and use it in GitHub Desktop.
Quit On Back Button Unity3d
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
public class QuitOnBack : MonoBehaviour { | |
// Update is called once per frame | |
void Update () { | |
if (Input.GetKeyDown(KeyCode.Escape)) | |
Application.Quit(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment