跳转到主要内容

Documentation Index

Fetch the complete documentation index at: https://docs.cloudx.io/llms.txt

Use this file to discover all available pages before exploring further.

Google Waterfall 适配器支持 横幅 (320×50)MREC (300×250) 广告格式。该适配器不支持插屏和激励广告。 Assets/CloudXSdk/Editor/CloudXDependencies.xml 中取消注释 Google Waterfall 相关行:
<!-- Android -->
<androidPackage spec="io.cloudx:adapter-googlewaterfall:25.1.0.0"/>

<!-- iOS -->
<iosPod name="CloudXGoogleWaterfallAdapter" version="3.4.2" minTargetSdk="13.0"/>
修改文件后,前往 Assets > External Dependency Manager > Android Resolver > Force Resolve

AdMob 应用 ID(必需)

Google Mobile Ads SDK 需要您的 AdMob 应用 ID。缺少该 ID 会导致 iOS 应用启动时崩溃,并在 Android 上记录致命警告。请使用您 AdMob 控制台中的应用 ID。

Android

Assets/Plugins/Android/AndroidManifest.xml<application> 内添加 meta-data:
AndroidManifest.xml
<meta-data
    android:name="com.google.android.gms.ads.APPLICATION_ID"
    android:value="ca-app-pub-XXXXXXXXXXXXXXXX~YYYYYYYYYY" />

iOS

在生成的 Info.plist 中添加 GADApplicationIdentifier
Info.plist
<key>GADApplicationIdentifier</key>
<string>ca-app-pub-XXXXXXXXXXXXXXXX~YYYYYYYYYY</string>

iOS Info.plist 配置

SKAdNetwork IDs(iOS 14.5+ 必需)

添加 Google 的 SKAdNetwork 标识符,以便 Google 归因安装。Google 在其 Google Mobile Ads 文档 中发布了完整且最新的列表。请包含完整列表以最大化归因覆盖率。

应用追踪透明度(iOS 14+)

Info.plist
<key>NSUserTrackingUsageDescription</key>
<string>此标识符将用于向您投放个性化广告。</string>

iOS 项目配置

链接器标志: 在 Build Settings 的 Other Linker Flags 中添加 -ObjC

支持

如需支持,请联系 mobile@cloudx.io