Android 将Admob和Google Play Game服务添加到flash as3
我正在尝试将Google Play游戏服务ANE和Admob ANE添加到同一个项目中,但我不断收到错误:Android 将Admob和Google Play Game服务添加到flash as3,android,actionscript-3,flash,ane,Android,Actionscript 3,Flash,Ane,我正在尝试将Google Play游戏服务ANE和Admob ANE添加到同一个项目中,但我不断收到错误: ArgumentError: Error #3500: The extension context does not have a method with the name cacheInterstitial. at flash.external::ExtensionContext/_call() at flash.external::ExtensionContext/call() at
ArgumentError: Error #3500: The extension context does not have a method with the name cacheInterstitial.
at flash.external::ExtensionContext/_call()
at flash.external::ExtensionContext/call()
at com.pozirk.ads.admob::AdMob/cacheInterstitial()[D:\Pozirk\_projects\ANEAdMob\air\AdMob\com\pozirk\ads\admob\AdMob.as:83]
at runtime::ContentPlayer/loadInitialContent()
at runtime::ContentPlayer/playRawContent()
at runtime::ContentPlayer/playContent()
at runtime::AppRunner/run()
at ADLAppEntry/run()
at global/runtime::ADLEntry()
Cannot display source code at this location.
以下是我的代码,我不确定我做错了什么,如果有人能帮助我,我将非常感激:
import com.pozirk.ads.admob.*
import com.freshplanet.ane.AirGooglePlayGames.*
public class Main extends MovieClip
{
private var admob:AdMob = new AdMob();
private var googlePlayGames:AirGooglePlayGames = new AirGooglePlayGames()
public function Main()
{
googlePlayGames.startAtLaunch();
// Show Leaderboard
googlePlayGames.showLeaderboard("000000000000000000");
admob.init();
admob.cacheInterstitial("ca-app-pub-0000000000000000/0000000000");
admob.cacheInterstitial("ca-app-pub-0000000000000000/0000000000");
这是我的XML描述符文件:
<android>
<manifestAdditions>
<![CDATA[<manifest>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
<application>
<meta-data android:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version" />
<activity android:name="com.google.android.gms.ads.AdActivity" android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize" android:theme="@android:style/Theme.Translucent"/>
<!-- GooglePlay Games Services -->
<meta-data android:name="com.google.android.gms.games.APP_ID" android:value="\ 90007276375" />
<activity android:name="com.freshplanet.googleplaygames.SignInActivity" android:theme="@android:style/Theme.Translucent.NoTitleBar.Fullscreen" />
</application>
</manifest>]]>
</manifestAdditions>
</android>
]]>
首先,xml中的扩展标记在哪里?按照ane developer提供的所有必要步骤进行操作。对不起,我有扩展标签,我只是忘了在@sameerjain的帖子中包含它