2016-02-12 55 views
1

我更新谷歌的谷歌玩游戏服务如下所述:unity plugin,但我有以下错误:团结,依赖错误导入谷歌Play游戏服务

Google.JarResolver.ResolutionException: Cannot find candidate artifact for com.google.android.gms:play-services-games:8.4+ at Google.JarResolver.PlayServicesSupport.DependOn (System.String group, System.String artifact, System.String version) [0x00000] in :0 at GooglePlayGames.Editor.GPGSDependencies..cctor() [0x00024] in /Users/gabriele/Documents/number777pro/number/Number777/Assets/GooglePlayGames/Editor/GPGSDependencies.cs:46 UnityEditor.EditorAssemblies:SetLoadedEditorAssemblies(Assembly[])

我试图找到一个解决方案,但没有成功,谁知道如何解决?

+1

您需要通过Android SDK Manager更新Google Repository和Android Support Repository组件。 –

+0

我做到了,我也尝试重新下载android sdk,但它没有解决错误 –

+0

hi @GabrielePicco,你真的应该在下面给出答案! – Fattie

回答

11

它是由更新以下内Android SDK中的经理来解决:1。 支持Android库 2.谷歌播放服务 3.谷歌库


FYI 在Mac上...

转到您的Android工具目录这很可能是在这里..

cd /Users/ ... /Library/Android/android-sdk-macosx/tools

并运行此

./android update sdk --no-ui

它会安装一个非常大的数字下载(30分钟),包括它看起来像你需要解决此问题的一切。

... 
    Downloading Local Maven repository for Support Libraries, revision 28 
    Installing Local Maven repository for Support Libraries, revision 28 
    Installed Local Maven repository for Support Libraries, revision 2899%) 
    Downloading Google Play services, revision 29 
    Installing Google Play services, revision 29 
    Installed Google Play services, revision 2996%) 
    Downloading Google Repository, revision 25 
    Installing Google Repository, revision 25 
    Installed Google Repository, revision 2599%) 
... 
    Done. 34 packages installed. 

如果您是Unity-Mac用户,可能是您没有安装Android Studio,而只是安装了各种SDK。通过这种方式,您可以轻松地进行更新,而无需像Studio那样烦恼。反之,如果你只是运行

./android

它会打开不断得心应手AndroidSDKManager(即你的Mac上运行的实际GUI应用程序)。然后,您可以这样做,如果您确切知道要安装Play Services的内容,可能需要保存一些下载内容。请注意,幸运的是,SDKManager可以独立运行(没有你的Mac上的java),无需启动Studio。

希望它可以帮助别人。

+0

感谢它的工作。 – atifali