Hi, i have opened the example from github
https://github.com/sdkbox/sdkbox-sample-admob/blob/master/cpp/Classes/HelloWorldScene.cpp
I dont know how to implement the Reward function. i think, this function will be called when the video is being watched until finish. But, i dont know how
virtual void reward(const std::string &name, const std::string ¤cy, double amount) {
if (showText) {
totalCoins += amount;
showText(StringUtils::format("%s name=%s currency=%s amount=%lf total=%d",
__FUNCTION__, name.c_str(), currency.c_str(), amount, totalCoins));
}
}
then, how to the game know that user watch the ads until finish or not? in the Listener, there are method name “adViewDidDismissScreen”. it will call when user close the ads even thought the user cancel the ads, right?
Can SDKBOX use listener like this?
https://developers.google.com/android/reference/com/google/android/gms/ads/reward/RewardedVideoAdListener
ok, I’ll add the callbacks.
OK, thank you very much. I will wait :
test, but it seems there are a bug with AdMob iOS SDK:
- (void)rewardBasedVideoAdDidCompletePlaying:(GADRewardBasedVideoAd *)rewardBasedVideoAd {
never called.
the other delegate works.
Oh, sorry its my mistake. I am not fully understand the use of the listener before. Actually, the “reward” listener automatically be called when user watch the ads until finish. i thought that “reward” just function in class listener.
Sorry for my poor Programming skill .
and thank you for response my problem
=== Sugestion ===
please add void reward in the SDKBOX Docs