How to destroy rewarded video and is their another way to handle onadrewarded?

1,051 views
Skip to first unread message

Karuro Roke

unread,
Dec 2, 2017, 9:34:27 AM12/2/17
to Google Mobile Ads SDK Developers
I notice that both banner and interstitial ad have a Destroy() method but rewarded video don't have it. Also aside from using delegate is their another way to handle reward?

 public void Start()
   
{
       
this.rewardBasedVideo = RewardBasedVideoAd.Instance;

        rewardBasedVideo
.OnAdRewarded += HandleRewardBasedVideoRewarded;

       
this.RequestRewardedVideo();
   
}

public void HandleRewardBasedVideoRewarded(object sender, Reward args)
   
{
       
energy += 1;
   
}


Ivan Bautista (Mobile Ads SDK Team)

unread,
Dec 4, 2017, 1:24:37 AM12/4/17
to Google Mobile Ads SDK Developers
Hi Karuro,

As per the open source code for RewardedBasedVideoAd, there is no Destroy method available similar to BannerView or InterstitialAd objects. Please note that RewardedBasedVideoAds follows the singleton design so it references to a single instance unlike BannerView and InterstitialAd objects.

As for handling rewards, the onAdRewarded is the only event called when the user should be rewarded for watching a video. You may refer to these sample codes or this sample app on how to handle rewards via the official Google Mobile Ads Unity plugin.

Let me know if this helps or if you have any further technical concerns about the code implementation of the Mobile Ads SDK.

Regards,
Ivan Bautista
Mobile Ads SDK Team

Karuro Roke

unread,
Dec 4, 2017, 5:43:24 AM12/4/17
to Google Mobile Ads SDK Developers
Thank you.
Reply all
Reply to author
Forward
0 new messages