onRewardGranted function is not firing (solved)

7 posts (showing 1-7)
mottatta

Market Level 5Community Level 5
592 posts

I built an app using AIR 21. I tried to implement rewarded videos, but it seems onRewardGranted function is never fired, although onRewardUnavailable and onRewardDeclined functions work just fine.

Does anyone has same the issue?

posted 2016-10-05T10:17:57-07:00
FGL_Dave

FGL AdminCommunity Level 4
304 posts

Hi mottatta,

Please ensure you're using the latest Drag and Drop library - this was an old issue that was fixed in the most recent update (about 2 weeks ago). If the issue persists please let us know and we'll look into it further.

Thanks!

posted 2016-10-06T13:01:42-07:00
grado

Market Level 0Community Level 0
1255 posts

im having that problem on iOS at least. Will try android...

Works on android, but doesnt seem to on iOS...

posted 2016-10-06T14:14:55-07:00
grado

Market Level 0Community Level 0
1255 posts

im having that problem on iOS at least. Will try android...

Works on android, but doesnt seem to on iOS...

posted 2016-10-06T15:27:14-07:00
mottatta

Market Level 5Community Level 5
592 posts

I still can't get the onRewardGranted function firing. I press 'Download Drag and Drop library', it should download the latest version, right? Or is it possible some bug in my code, that for some reason wouldn't fire this function only? It will be really weird, if it works for djstatika and not for me.

posted 2016-10-06T20:15:05-07:00 | edited 2016-10-06T20:27:52-07:00
FGL_Dave

FGL AdminCommunity Level 4
304 posts

That is strange. We'll give it a bit of further testing and report back here if we find anything. You're correct that if you press that download button, you'll get the latest version.

Does the demo project included with the drag and drop library work for you? (you could just copy the code from the demo to a new class in your current project and test it that way if you don't want to mess about with setting the project up).

posted 2016-10-07T09:50:55-07:00
mottatta

Market Level 5Community Level 5
592 posts

Hey Dave,

Thanks a lot for your help! It turns out that it's a bug in my code. onRewardGranted receives 2 params, but since I didn't copied the function from the demo project I didn't expect those two parameters and it was throwing an error, which I couldn't see when testing on desktop. 

Sorry for bothering you and once again thanks for the help :-)

posted 2016-10-07T10:16:34-07:00