Rewarded Ads
In order to integrate the Rewarded Video ads, you need to use the Yodo1MasRewardAdDelegate delegate.
1. Set Up Rewarded Video Ad Delegate Methods
[Yodo1Mas sharedInstance].rewardAdDelegate = self; #pragma mark - Yodo1MasAdDelegate - (void)onAdOpened:(Yodo1MasAdEvent *)event { } - (void)onAdClosed:(Yodo1MasAdEvent *)event { } - (void)onAdError:(Yodo1MasAdEvent *)event error:(Yodo1MasError *)error { } #pragma mark - Ad Rewarded - (void)onAdRewardEarned:(Yodo1MasAdEvent *)event { }
Yodo1Mas.sharedInstance().rewardAdDelegate = self func onAdOpened(_ event: Yodo1MasAdEvent) { } func onAdClosed(_ event: Yodo1MasAdEvent) { } func onAdError(_ event: Yodo1MasAdEvent, _ error: Yodo1MasError) { } func onAdRewardEarned(_ event: Yodo1MasAdEvent) { }
2. Check the Loading Status of Rewarded Video Ads
BOOL isLoaded = [[Yodo1Mas sharedInstance] isRewardAdLoaded];
let isLoaded = Yodo1Mas.sharedInstance().isRewardAdLoaded()
3. Show Rewarded Video Ads
[[Yodo1Mas sharedInstance] showRewardAd]
Yodo1Mas.sharedInstance().showRewardAd()