Hi.
I’m trying to use the AppLovin plug-in to display video ads in my tvOS app, but it doesn’t work.
It looks like plugin is initializing. In AppLovin Control Panel (Manage Apps) i see my app and can configure it. I have setted “Test Mode” On.
When i try to load and show ads nothing happens.
What can i do to solve this problem?
main.lua:
local applovin = require( "plugin.applovin" ) local function adListener( event ) if ( event.phase == "init" ) then -- Successful initialization print( event.isError ) -- Load an AppLovin ad applovin.load() elseif ( event.phase == "loaded" ) then -- The ad was successfully loaded print( event.type ) -- Show the ad applovin.show() elseif ( event.phase == "failed" ) then -- The ad failed to load print( event.type ) print( event.isError ) print( event.response ) elseif ( event.phase == "displayed" or event.phase == "playbackBegan" ) then -- The ad was displayed/played print( event.type ) elseif ( event.phase == "hidden" or event.phase == "playbackEnded" ) then -- The ad was closed/hidden print( event.type ) elseif ( event.phase == "clicked" ) then -- The ad was clicked/tapped print( event.type ) end end applovin.init( adListener, { sdkKey = "nz5riCWhaPKcn54BsZF\_t-6rRFeA4MZsJeg0sCiQc11O65ZzeqyWp3MEJ0OOMzEfbvgR6NtkPv6W\_fTeUQ9HUW" } )
build.settings:
settings = { orientation = { default = "landscapeLeft", supported = { "landscapeLeft", "landscapeRight" } }, plugins = { ["plugin.applovin"] = { publisherId = "com.coronalabs", supportedPlatforms = { appletvos=true } }, ["plugin.google.play.services"] = { publisherId = "com.coronalabs", supportedPlatforms = { android=true } }, }, }