团结和Admob整合

时间:2017-08-02 11:53:30

标签: c# android unity3d admob ads

我已将admob Package添加到我的项目中但是当我尝试构建apk文件时出现此错误:

enter image description here

CommandInvokationFailure: Unable to convert classes into dex format.
C:/Program Files/Java/jdk1.8.0_25\bin\java.exe -Xmx2048M -Dcom.android.sdkmanager.toolsdir="C:/Users/PC-Boulot/AppData/Local/Android/sdk\tools" -Dfile.encoding=UTF8 -jar "C:\PROGRAM FILES\UNITY\EDITOR\Data\PlaybackEngines\AndroidPlayer/Tools\sdktools.jar" -

stderr[
Error:Invalid command dx
]
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.BuildPlayerWindow:BuildPlayerAndRun()

1 个答案:

答案 0 :(得分:0)

您使用的Unity版本是什么?这种情况曾经发生过,因为从那时起就已经解决了Unity漏洞。

尝试将项目迁移到Unity 2017.1以查看是否有帮助。