public static void ShowVideoAdByZoneKey(string zoneIdKey, bool offerV4VCBeforePlay = false, bool showPopUpAfter = false)
{
ADCVideoZone videoZone = GetVideoZoneObjectByKey(zoneIdKey);
string zoneId = GetZoneIdByKey(zoneIdKey);
if (IsVideoAvailableByZoneKey(zoneIdKey))
{
if (videoZone.zoneType == ADCVideoZoneType.Interstitial)
{
AdColony.ShowVideoAd(zoneId);
}
else if (videoZone.zoneType == ADCVideoZoneType.V4VC)
{
if (offerV4VCBeforePlay)
{
AdColony.OfferV4VC(showPopUpAfter, zoneId);
}
else
{
AdColony.ShowV4VC(showPopUpAfter, zoneId);
}
}
else
{
//Check nothing, video zone type isn't correct
Debug.Log("An incorrect video zone type was requested to play. Please resolve this issue.");
}
Debug.Log("The zone '" + zoneId + "' was requested to play.");
}
else
{
Debug.Log("The zone '" + zoneId + "' was requested to play, but it is NOT ready to play yet.");
}
}