unity新项目打开时按照指定平台打开

为了避免unity新项目打开然后再切平台浪费时间,在一开始加载的时候的时候就指定平台、

官方文档:

https://docs.unity3d.com/Manual/CommandLineArguments.html

windows命令行

cd C:gUnityEditor && unity -projectPath D:codeunityProject -buildTarget ios

windows批处理

@echo off  
"C:gUnityEditorUnity.exe" "-projectPath" "D:codeunityProject" "-buildTarget" "android"
exit
原文地址:https://www.cnblogs.com/wangle/p/14833055.html