Search Unity

Admob error when clicking on ads (Unity 3.4f1)

Discussion in 'Android' started by fractivSammy, Jun 28, 2011.

  1. fractivSammy

    fractivSammy

    Joined:
    May 26, 2011
    Posts:
    10
    Wasn't sure whether to post this in the beta discussion group because I'm not sure it's a beta only issue, so I'm trying here first. Has anyone experienced the following error when clicking on an ad with admob?

    E/Ads (30327): Tried to launch a new AdActivity with a different AdManager.

    I click the ad and nothing happens except for this error popping up in adb. It doesn't happen all the time, sometimes I can click on the ad and it works no problem.

    The code I'm using for generating the ads is almost identical to the code in the example plugin in the forum stickies.

    Anyone know what's going on?

    Thanks,
    Sam
     
    Last edited: Jun 28, 2011
  2. zine92

    zine92

    Joined:
    Nov 13, 2010
    Posts:
    1,347
    Unity 3.4f1!?!?! o_O I don't think you will get any answers here alot of us are using Unity 3.3 so. Can't really help but you might wanna try emailing Unity instead or file a bug report. Thank you.
     
  3. fractivSammy

    fractivSammy

    Joined:
    May 26, 2011
    Posts:
    10
    I downgraded to Unity 3.3 and have the same problem.
     
  4. fractivSammy

    fractivSammy

    Joined:
    May 26, 2011
    Posts:
    10
    Scratch that, I hadn't reverted everything properly. It does seem to work correctly in 3.3.
     
  5. zine92

    zine92

    Joined:
    Nov 13, 2010
    Posts:
    1,347
    Icic. Hmm. Might be some bugs that they are gonna fixed before the offical release, i guess.
     
  6. fractivSammy

    fractivSammy

    Joined:
    May 26, 2011
    Posts:
    10
    Scratch that again. :) I tested it some more in 3.3 and I do get the same error. I really have no idea what's going on. Seems like a problem with the Admob SDK itself, but I don't see anyone else reporting the issue.

    For a sanity check, here's the code I'm using (pretty much copied directly from the example):

    Code (csharp):
    1.  
    2.     @Override
    3.     protected void onCreate (Bundle savedInstanceState)
    4.     {
    5.         super.onCreate(savedInstanceState);
    6.        
    7.         LinearLayout layout = new LinearLayout( this );
    8.         addContentView( layout, new ViewGroup.LayoutParams(LayoutParams.FILL_PARENT,LayoutParams.FILL_PARENT) );
    9.         layout.setOrientation( LinearLayout.VERTICAL );
    10.          // Create the adView
    11.         AdView adView = new AdView(this, AdSize.BANNER, "a14e03efdf7a2f1" );
    12.         // Add the adView to the layer
    13.         layout.addView(adView, new LayoutParams(LayoutParams.FILL_PARENT,LayoutParams.WRAP_CONTENT));
    14.         // Initiate a generic request to load it with an ad
    15.         adView.loadAd( new AdRequest() );
    16.     }
    17.  
    Sam
     
    Last edited: Jun 29, 2011