Type Function Return value none Revision 2017.3060 Keywords ads, advertising, Appodeal, load See also appodeal.init() appodeal.show() appodeal.isLoaded()
Pre-loads an Appodeal banner, static interstitial, video, or rewarded video ad for instant display upon a future call to appodeal.show().
By default, Appodeal automatically caches ads in the background, so there is normally no need to load ads in advance. To use this function, you must turn off automatic caching as described in the documentation for appodeal.init().
appodeal.load( adUnitType )
String. Valid values include "banner"
, "interstitial"
, "video"
, and "rewardedVideo"
.
local appodeal = require( "plugin.appodeal" ) local function adListener( event ) if ( event.phase == "init" ) then -- Successful initialization -- Pre-load a static interstitial ad appodeal.load( "interstitial" ) end end -- Initialize the Appodeal plugin appodeal.init( adListener, { appKey="YOUR_APP_KEY", autoCacheAds=false } )