I'd integrated the HeyZap and build it for android, and then when I try to show a incentivized video, doesn't happen anything.
In the editor doesn't show any error, its says:
Call received to fetch an HZIncentivizedAd, but the SDK does not function in the editor. You must use a device/emulator to fetch/show ads.
and I think that is normal...
but in the App it doesn't show or display anything....
this is how I want it to start it:
#if UNITY_ANDROID
string tag = this.adTag();
HZIncentivizedAd.Fetch(tag);
HZShowOptions showOptions = new HZShowOptions();
showOptions.Tag = tag;
HZIncentivizedShowOptions incentivizedOptions = new HZIncentivizedShowOptions();
incentivizedOptions.Tag = tag;
incentivizedOptions.IncentivizedInfo = "test app incentivized info!";
HZIncentivizedAd.ShowWithOptions(incentivizedOptions);
#endif
HZIncentivizedAd.AdDisplayListener listener = delegate (string adState, string adTag)
{
if (adState.Equals("available"))
{
HZIncentivizedAd.Show();
Debug.Log("Available");
// Sent when an ad has been loaded and is ready to be displayed,
// either because we autofetched an ad or because you called
// `Fetch`.
}
if (adState.Equals("fetch_failed"))
{
// Sent when an ad has failed to load.
// This is sent with when we try to autofetch an ad and fail, and also
// as a response to calls you make to `Fetch` that fail.
// Some of the possible reasons for fetch failures:
// - Incentivized ad rate limiting (see your app's Publisher
// Settings dashboard)
// - None of the available ad networks had any fill
// - Network connectivity
// - The given ad tag is disabled (see your app's Publisher
// Settings dashboard)
// - One or more of the segments the user falls into are
// preventing an ad from being fetched (see your
// Segmentation Settings dashboard)
}
if (adState.Equals("incentivized_result_complete"))
{
// The user has watched the entire video and should be given a reward.
}
if (adState.Equals("incentivized_result_incomplete"))
{
// The user did not watch the entire video and should not be given a reward.
}
if (adState.Equals("audio_starting"))
{
// The ad about to be shown will need audio.
// Mute any background music.
}
if (adState.Equals("audio_finished"))
{
// The ad being shown no longer needs audio.
// Any background music can be resumed.
}
if (adState.Equals("show"))
{
// Sent when an ad has been displayed.
// This is a good place to pause your app, if applicable.
}
if (adState.Equals("hide"))
{
// Sent when an ad has been removed from view.
// This is a good place to unpause your app, if applicable.
}
if (adState.Equals("click"))
{
// Sent when an ad has been clicked by the user.
}
};
HZIncentivizedAd.SetDisplayListener(listener);
So please, anyone knows what is the problem?
↧