【问题标题】:How to add Chartboost dependency to my LibGDX project?如何将 Chartboost 依赖项添加到我的 LibGDX 项目?
【发布时间】:2023-03-19 20:09:01
【问题描述】:

我想将 Chartboost 添加到我的 LibGDX 游戏中,但我不知道如何将它作为依赖项添加到 Gradle。另外,Chartboost 使用 Google Play 游戏服务,所以我需要将它们都添加到 Gradle。我该怎么做?

【问题讨论】:

    标签: java gradle libgdx chartboost


    【解决方案1】:

    chartboost jar 似乎没有发布到公共 maven 存储库,因此您需要通过文件引用它:

    dependency {
        // references a file relative to the project folder
        files('libs/chartboost.jar')
    }
    

    要添加谷歌播放服务,您可以像这样引用它:

    dependencies {
        // Google Play Services
        compile 'com.google.android.gms:play-services:5.0.77'
    
        // Note: these libraries require the "Google Repository" and "Android Repository"
        //       to be installed via the SDK manager.
    }
    

    【讨论】:

    • 我需要把这个放在哪个依赖上?
    猜你喜欢
    • 1970-01-01
    • 2015-07-27
    • 2017-03-27
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-02-18
    • 1970-01-01
    相关资源
    最近更新 更多