Ejemplo n.º 1
0
    // Creates a banner of the given type placed based on the position parameter
    public static void createBanner( AdMobAndroidAd type, AdMobAdPlacement placement )
    {
        if( Application.platform != RuntimePlatform.Android )
            return;

        _admobPlugin.Call( "createBanner", (int)type, (int)placement );
    }
Ejemplo n.º 2
0
    // Creates a banner of the given type placed based on the position parameter
    public static void createBanner(AdMobAndroidAd type, AdMobAdPlacement placement)
    {
        if (Application.platform != RuntimePlatform.Android)
        {
            return;
        }

        _admobPlugin.Call("createBanner", (int)type, (int)placement);
    }
Ejemplo n.º 3
0
    // Creates a banner of the given type at the given position. This method requires an adUnitId and you must be updated to the new AdMob system.
    public static void createBanner(string adUnitId, AdMobAndroidAd type, AdMobAdPlacement placement)
    {
        if (Application.platform != RuntimePlatform.Android)
        {
            return;
        }

        createBanner(adUnitId, (int)type, (int)placement);
    }
Ejemplo n.º 4
0
	public AdvertisementAdMob(string key_android, string inters_id): base(key_android, null)
	{	
		try
		{
			if (Info.IsEditor())
				return;
			
			#if UNITY_ANDROID
				this.inters_id = inters_id;
				
				placement = AdMobAdPlacement.BottomCenter;
			#endif
		}
		catch
		{
			Error(API, ERROR_STARTUP_CONSTRUCTOR);
		}
	}
Ejemplo n.º 5
0
    public AdvertisementAdMob(string key_android, string inters_id) : base(key_android, null)
    {
        try
        {
            if (Info.IsEditor())
            {
                return;
            }

                        #if UNITY_ANDROID
            this.inters_id = inters_id;

            placement = AdMobAdPlacement.BottomCenter;
                        #endif
        }
        catch
        {
            Error(API, ERROR_STARTUP_CONSTRUCTOR);
        }
    }
Ejemplo n.º 6
0
    public override void fetchBanner(AdvertisementManager.Positions pos)
    {
        try
        {
            base.fetchBanner(pos);

            if (Info.IsEditor() || (firstTime && !Setup()))
            {
                return;
            }

                        #if UNITY_ANDROID
            placement = (pos == AdvertisementManager.Positions.BOTTOM)
                                        ? AdMobAdPlacement.BottomCenter
                                        : AdMobAdPlacement.TopCenter;
                        #endif
        }
        catch
        {
            Error(API, ERROR_LOADING_BANNER);
        }
    }
Ejemplo n.º 7
0
	public override void fetchBanner(AdvertisementManager.Positions pos)
	{
		try
		{
			base.fetchBanner(pos);
			
			if (Info.IsEditor() || (firstTime && !Setup()))
				return;
			
			#if UNITY_ANDROID
				placement = (pos == AdvertisementManager.Positions.BOTTOM)
					? AdMobAdPlacement.BottomCenter
					: AdMobAdPlacement.TopCenter;
			#endif
		}
		catch
		{
			Error(API, ERROR_LOADING_BANNER);
		}
	}
Ejemplo n.º 8
0
 // Creates a banner of the given type at the given position. This method requires an adUnitId and you must be updated to the new AdMob system.
 public static void createBanner(string adUnitId, AdMobAndroidAd type, AdMobAdPlacement placement)
 {
     createBanner(adUnitId, (int)type, (int)placement);
 }
Ejemplo n.º 9
0
 // Creates a banner of the given type at the given position. This method does not take an adUnitId and will work with legacy AdMob accounts.
 public static void createBanner(AdMobAndroidAd type, AdMobAdPlacement placement)
 {
     createBanner("", type, placement);
 }
Ejemplo n.º 10
0
 // Creates a banner of the given type at the given position. This method requires an adUnitId and you must be updated to the new AdMob system.
 public static void createBanner( string adUnitId, AdMobAndroidAd type, AdMobAdPlacement placement )
 {
     createBanner( adUnitId, (int)type, (int)placement );
 }
Ejemplo n.º 11
0
 // Creates a banner of the given type at the given position. This method does not take an adUnitId and will work with legacy AdMob accounts.
 public static void createBanner( AdMobAndroidAd type, AdMobAdPlacement placement )
 {
     createBanner( "", type, placement );
 }