AdGui reward events are incredibly hard to test as a developer, since you’re not guaranteed to get an ad yourself, and the terms around ads may mean that your advert view is treated differently to a normal players’. However, so far I have been unable to receive OnAdEvents whatsoever. Testing with real users, I’ve seen the same, I have debug prints for the event being fired at all, and I just don’t get any output.
Additionally, AdGuis can be created client side, but listening to the event on the client to prompt a reward would be entirely insecure. It would not be possible to listen to the event on a client-side AdGui from the server, even if the event did work.
Expected behavior
I would test this in a repro environment, but games must be approved for advertisements and have over 2k MAU, which a repro environment wouldn’t have.
Currently, it’s very difficult to test AdGuis, the first thing I would propose is that in Studio, regardless of your advertisement approval status, a test/ example advertisement runs that behaves the same as a real one for testing purposes to allow for development around that behaviour.
Secondly, I would propose an event that fires when an ad view is registered, but does not count as a rewarded ad view. This would help with debugging but also feeding back to users. The terms of service specifically say that ‘misleading’ rewards are not allowed, however when we don’t control whether or not we get that reward event, or have information on when it is fired, it’s impossible to ensure a user is properly rewarded.
Lastly, better documentation on what the usage of this method is intended to be. My assumption has been that it’s a server side event, as the event provides a player id, but - what are we supposed to do for client side ad units, and why does it not seem to fire at all, in my experience, when I or other players watch a video ad for 15 seconds? This may be down to user error, but a lack of debugging routes means it’s very difficult to figure out.
A better solution overall may be instead a single event listener for all adguis in the game on the server side. Instead of listening to an AdGui itself, a developer would listen to this single event which would return the specific AdGui as a parameter. This way, client-side advertisements could also be rewarded in a secure way, and the whole thing would be less prone to failure.
Edit:
It looks like this has been reported before: