Ejemplo n.º 1
0
 void SetupBannerAdCallbacks()
 {
     // Create callbacks for banner ads
     _ShowBannerCallbacks                    = new ShowAdRequest();
     _ShowBannerCallbacks.OnDisplayed       += adUnitID => LionDebug.Log("Displayed Banner Ad :: Ad Unit ID = " + adUnitID);
     _ShowBannerCallbacks.OnClicked         += adUnitID => LionDebug.Log("Clicked Banner Ad :: Ad Unit ID = " + adUnitID);
     _ShowBannerCallbacks.OnHidden          += adUnitID => LionDebug.Log("Closed Banner Ad :: Ad Unit ID = " + adUnitID);
     _ShowBannerCallbacks.OnFailedToDisplay += (adUnitID, error) => LionDebug.LogError("Failed To Display Banner Ad :: Error = " + error + " :: Ad Unit ID = " + adUnitID);
 }
Ejemplo n.º 2
0
 void SetupInterstitialCallbacks()
 {
     // Create callbacks for interstitial ads
     _ShowInterstitialRequest = new ShowAdRequest();
     _ShowInterstitialRequest.SetPlacement("between_levels");
     _ShowInterstitialRequest.SetLevel(_Level);
     _ShowInterstitialRequest.OnDisplayed       += adUnitID => LionDebug.Log("Displayed Interstitial Ad :: Ad Unit ID = " + adUnitID);
     _ShowInterstitialRequest.OnClicked         += adUnitID => LionDebug.Log("Clicked Interstitial Ad :: Ad Unit ID = " + adUnitID);
     _ShowInterstitialRequest.OnHidden          += adUnitID => LionDebug.Log("Closed Interstitial Ad :: Ad Unit ID = " + adUnitID);
     _ShowInterstitialRequest.OnFailedToDisplay += (adUnitID, error) => LionDebug.LogError("Failed To Display Interstitial Video :: Error = " + error + " :: Ad Unit ID = " + adUnitID);
 }