public void GetExit()//退出运行
    {
#if UNITY_EDITOR
        UnityEditor.EditorApplication.isPlaying = false;//用于退出运行

#else
Application.Quit();
#endif

    }
GameObject go = new GameObject("Empty");//创建一个空物体

 

相关文章:

  • 2021-10-23
  • 2022-12-23
  • 2022-12-23
  • 2021-07-30
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-08-08
猜你喜欢
  • 2021-12-18
  • 2021-07-05
  • 2022-12-23
  • 2022-12-23
  • 2022-02-26
  • 2021-12-24
  • 2021-10-21
相关资源
相似解决方案