赞
踩
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class QuitScene : MonoBehaviour {
void Update () {
if (Input.GetKeyDown(KeyCode.Escape)){//按下ESC键则退出游戏
#if UNITY_EDITOR
UnityEditor.EditorApplication.isPlaying = false;
#else
Application.Quit();
#endif
}
}
}
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。