Hi:
I'm learning how to build an android game. i used the App Unity remote 5 to connect my android phone to Unity editor. When i hit "play" button, i got a warning " Set-up Android SDK path to make Android remote work" . If I tried to build the project, what i got is asking me to update Android SDK
it popped up a instruction windows said"SDK Plamform Tools version 0.0.0<23.0.0"
if I continued click the update button, it showed another warning like this:
![alt text][1]
then i got three errors:
Error:Invalid command android
UnityEditor.HostView:OnGUI()
CommandInvokationFailure: Unable to update the SDK. Please run the SDK Manager manually to make sure you have the latest set of tools and the required platforms installed. See the Console for more details.
C:/Program Files/Java/jdk1.8.0_144\bin\java.exe -Xmx2048M -Dcom.android.sdkmanager.toolsdir="C:/Program Files/sdk-tools-Adroid\tools" -Dfile.encoding=UTF8 -jar "C:\Program Files\Unity\Editor\Data\PlaybackEngines\AndroidPlayer/Tools\sdktools.jar" android update sdk -a -u -t tool,platform-tool,build-tools-23.0.2
stderr[
Error:Invalid command android
]
stdout[
]
exit code: 64
UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
UnityEditor.Android.AndroidSDKTools.RunCommandInternal (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
UnityEditor.Android.AndroidSDKTools.RunCommandSafe (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
UnityEditor.HostView:OnGUI()
Error building Player: CommandInvokationFailure: Unable to update the SDK. Please run the SDK Manager manually to make sure you have the latest set of tools and the required platforms installed. See the Console for more details.
C:/Program Files/Java/jdk1.8.0_144\bin\java.exe -Xmx2048M -Dcom.android.sdkmanager.toolsdir="C:/Program Files/sdk-tools-Adroid\tools" -Dfile.encoding=UTF8 -jar "C:\Program Files\Unity\Editor\Data\PlaybackEngines\AndroidPlayer/Tools\sdktools.jar" android update sdk -a -u -t tool,platform-tool,build-tools-23.0.2
stderr[
Error:Invalid command android
]
stdout[
]
exit code: 64
i've installed jdk successfully. (i've set up "JAVA_HOME" variable, path and CLASSPATH at Environment Variable, and checked with cmd commend )
About the Android SDK, what I download is "the command line tools", sdk-tools-windows-3859397.zip
this zip only contains a folder name "tools", its content includes:
![alt text][2]
I store this "tools" folder at location *C:\Program Files\sdk-tools-Adroid* , at Environment Variable settings , i created:
ANDROID_HOME C:\Program Files\sdk-tools-Adroid
PATH C:\Program Files\sdk-tools-Adroid
both in user variable and system variable.
I tried everything i found, i don't know what to do to make this work, can anyone help me please?
[1]: /storage/temp/102426-02.jpg
[2]: /storage/temp/102425-03.jpg
↧