Debug.Log("Version of the runtime: " + Application.unityVersion);
注:这行代码必须写在主线程里,也就是继承自MonoBehaviour的脚本里
原文地址:http://blog.youkuaiyun.com/smilelance/article/details/7889253
Unity版本检查与Debug日志输出
本文介绍如何在Unity游戏中使用Debug.Log方法输出运行时版本信息,并强调必须在主线程中执行此操作的重要性。通过实例代码演示了如何获取并打印Unity版本号。
Debug.Log("Version of the runtime: " + Application.unityVersion);
注:这行代码必须写在主线程里,也就是继承自MonoBehaviour的脚本里
原文地址:http://blog.youkuaiyun.com/smilelance/article/details/7889253
725