App developers currently have two ad unit options for adding high-paying interstitial ads to their apps:
- Full screen ‘canvases’ that are presented modally to a user and created by an ad SDK
- 300×250 IAB medium rectangle ads that are added to a UIViewController that is then presented via presentModalViewController
We’ve designed the Burstly SDK to allow developers to use both of these interstitial monetization options that yield higher eCPMs than banner ads. If you’re interested in adding interstitial ads to your app using the Burstly SDK, here’s a quick tutorial.
Create an OAIAdManager instance.
Implement the required OAIAdManager delegates:
- (NSString *)publisherId; – return your Burstly publisher ID as a string
- (NSString*)getZone; – return your Burstly zone ID as a string
- (UIViewController*)viewControllerForModalPresentation; – return the topmost UIViewController subclass in your view controller hierarchy
Add logic to send the requestRefreshAd message to your OAIAdManager instance. This would be a good place to pause your game if necessary.
Implement three optional OAIAdManager delegates:
- (void)adManager:(OAIAdManager*)manager didLoad:(NSString*)aNetwork isInterstitial:(BOOL)isInterstitial; – This delegate is called when an ad is received. If isInterstitial == YES, the ad network presents its own modal ad canvas. If isInterstitial == NO, the ad network does not present its own modal ad canvas (this is the case when the ad network returns a medium rectangle ad). In this case, you should add the OAIAdManager.view to a UIViewController instance and then presentModalViewController with the UIViewController instance containing the OAIAdManager.view to show the ad.
- (void)adManager:(OAIAdManager*)manager adNetworkControllerDismissFullScreen:(NSString*)aNetwork; – This delegate is called when an ad network which presented a modal canvas dismisses the modal canvas. If the ad presented to the user is an interstitial canvas launched by the ad network SDK (that is, if didLoad: isInterstitial is called with isInterstitial == YES), this means that the interstitial canvas has been dismissed and your app can resume.
- (void)adManager:(OAIAdManager*)manager failedToLoad:(NSString*)aNetwork; – If you paused your game, you should unpause your game if aNetwork is equal to “adserve”. This means that the Burstly SDK was unable to retrieve an ad.
That’s it! If you have any questions or comments just let us know at email@example.com.