微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

将特定的库从android SDK添加到unity项目

如何解决将特定的库从android SDK添加到unity项目

我正在尝试将Applovin广告添加到unity项目中,并且需要添加新的播放服务SDK

将Google Play服务添加到您的应用

由于Google的新要求,您需要集成Google 将Services SDK插入您的应用。

这是强制性的;没有Google Play服务,SDK无法 功能

当我联系applovin时,他们要求我将此库添加到我的项目中

@bot.event async def on_message(message): bad_words = ['badword1','badword2','badword3','badword4','badword5','badword6'] if message.author == bot.user: return for word in bad_words: if 0 < message.content.count(word) < 2: await message.channel.send("{},bitte achte auf Deine Wortwahl.".format(message.author.mention)) await message.delete() break else: await bot.process_commands(message)

我该怎么做?我没有使用android studio,而是直接从unity引擎导出。

解决方法

applovin的答案

如果尚未使用自定义mainTemplate.gradle,则可以在Android PlayerSettings下的Publishing>Custom Main Gradle Template.中启用它 将此行添加到您的mainTemplate.gradle文件中:

implementation 'com.google.android.gms:play-services-ads-identifier:16.0.0'

示例:

dependencies {
    implementation fileTree(dir: 'libs',include: ['*.jar'])
    implementation 'com.google.android.gms:play-services-ads-identifier:16.0.0'
**DEPS**}

这些步骤适用于任何SDK实现,请考虑自己在Gradle文件中。

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。