Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by tenlinstudios · Mar 14, 2014 at 03:42 AM · iphoneframerateiadhiccup

iOS iAd causing hiccups on load

Hi!

I'm using the standard code (converted to JS) from Unity for putting up iAd. It worked on the first try no problem, but now my game hiccups each time a new banner is either loaded, or if there is an error loading an ad (seen through xcode output window when debugging, although it happens with a release build not run through xcode too). When I don't run the supplied code my game is pegged at 60fps, even with adbannervew it is 60fps until a new ad pops up. The hiccups are VERY noticable, it probably drops to 5fps during these times. Tested device is a 4th gen iPod touch 32gb.

The ads run fine on my iPad 2 and iPhone 5c, so I'm contemplating to not allow ipod 4g, but would rather allow this device.

Here is the code I am running (again, supplied by Unity website, converted to JS):

         private var banner : ADBannerView = null;
          
         ////////////////////////////////////////////////////////////////
         function Start() {
             banner = new ADBannerView(ADBannerView.Type.Banner, ADBannerView.Layout.Top);
             ADBannerView.onBannerWasClicked += OnBannerClicked;
             ADBannerView.onBannerWasLoaded  += OnBannerLoaded;
          
         }
         ////////////////////////////////////////////////////////////////
         function OnBannerClicked()
         {
             Debug.Log("Clicked!\n");
         }
          
         ////////////////////////////////////////////////////////////////
         function OnBannerLoaded()
         {
             Debug.Log("Loaded!\n");
             banner.visible = true;
         }
 
 

I'm not doing anything else iAd related, there is one gameobject that runs this script and does a DontDestroyOnLoad, that's it. I'm not sure if attaching any other game code would help, so let me know if you think something I am doing in my game could be causing something like this.

Thanks a million in advance!

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by MRCty · Apr 17, 2014 at 09:49 AM

Hello, I have the same issue. I also tried with Prime31 iAD plug-in but I get the same problem. I think I get the problem when iAD load new banner. I'm looking for a solution but I've not one until now...

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

21 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Stuttering / performance issue with certain JS scripts 0 Answers

Game stuttering only in iPhoneX and above. Not a performance issue. 0 Answers

Different calculations/math results between Unity editor and iPhone ? 1 Answer

Performance and testflight in an iphone app 0 Answers

How do I get high smooth FPS in Unity??(Improve Fillrate) 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges