我已经集成了Vungle视频广告在我的电晕游戏它是完美的工作,但几天前,它停止缓存视频广告完全,但几天后,它盯着它自己没有改变任何东西的代码。现在它再次停止缓存视频广告。我怀疑这个问题是从电晕或Vungle方面,但不确定。
local vungleInterstitial = "540e9681c7ec2b6d4400000e"
local videoCompletedCallback=nil
videoAddListener=function( event )
if (event.isError ) then
--Cached video ad not available for display
print("problem to show ad")
elseif event.type == "cachedAdAvailable" then
print("cachedAdAvailable")
elseif tostring(event.type) == "adView" then
print("called when add is viewed")
elseif event.type == "adStart" then
print("Corona ads started")
audio.pause()
elseif event.type == "adEnd" then
print("Corona ads ended")
videoCompletedCallback()
audio.resume()
end
end
showVideoAd = function(callbackFunc)
print("showVideoAd function called")
videoCompletedCallback=callbackFunc;
if ( vads.isAdAvailable() ) then
print(" if ( vads.isAdAvailable() ) then, is true")
print("vads.show")
vads.show( "interstitial", { isBackButtonEnabled = false } )
else
local alert = native.showAlert( "Video Ad", "The Video Ad is not available at the moment. Please Try after some time.", { "OK" } )
end
end
vads.init("vungle",vungleInterstitial,videoAddListener)
1条答案
按热度按时间0yg35tkg1#
这可能与地理或每日查看限制有关。尝试使用vungleTest作为您的AppID。