Hi everyone, i am having problems with applovin’s rewarded videos.
I write the code as shown on the applovin documentation, and it works, the video is shown and it appears in applovin’s dashboard. The problems appears after the video, when it should give the reward, in fact it doesn’t at all.
Here is some code:
local adListener adListener = function( event ) if ( event.phase == "init" ) then -- Successful initialization print( event.isError ) -- Load an AppLovin ad applovin.load( "rewardedVideo" ) elseif ( event.phase == "loaded" ) then -- The ad was successfully loaded print( event.type ) 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 Toast.show("Video Played") applovin.load("rewardedVideo") 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="My Code", verboseLogging=false } )
the later on, in a button llistener:
if(applovin.isLoaded("rewardedVideo")) then applovin.show("rewardedVideo") end
So the video shows, but i don’t get the toast notification, or whatever else i put in the function.
Every help would be appreciated