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 Hoffa25 · Apr 20, 2015 at 03:12 PM · fpslagframerate

Why so low fps on my simple 2d game? (8 fps on android device)

Im building my very first game and my guess is that I have done some beginner mistakes here... The game is a board game with very little animations (but the few I have is extremly laggy). Even when Im in the lobby I have 8 fps! I then made a grey UI panel covering the entire lobby. It gave me the exact same fps..? My android device is a new sony experia 8" tablet with 1920*1200 resolution.

When I run the game with grey panel background in the unity editor I get 22 fps (I have a ok computer). And if I lover the resolution to 1136*640 i get 37.

Heres what I think might have to do with the low fps (before I start messing around with this I felt like asking here):

  1. My game has alot of UI panels/text/buttons.

  2. I have added the shadow script to just about everything for nicer look.

  3. The game is in one scene only. Meaning when you go from menu/lobby to play wiew I just make the lobby disapear with .alpha, .interactable and .blocksraycasts. ..and vice versa.

  4. Its made in unity 4.6.4 and not in unity 5.

Comment
Add comment · Show 2
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
avatar image chourizo · Apr 20, 2015 at 06:55 PM 0
Share

Have you tried running the profiler?

avatar image tanoshimi · Apr 20, 2015 at 07:15 PM 0
Share

At that resolution you're having to push 2.3 million pixels every frame, which is a hell of a lot for a processor designed for a mobile phone...

4 Replies

· Add your reply
  • Sort: 
avatar image
3

Answer by lordlycastle · Apr 20, 2015 at 03:16 PM

There can many reasons, and no-one can really help without knowing what is exactly happening in the game. However, in Unity 5 Personal version Profiler is included now. So that can really help you where the resources, are getting used. Here is the manual, read it. It’ll really help you optimise the game, and get a better understanding as to what’s causing this issue.

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
avatar image
0

Answer by DoTA_KAMIKADzE · Apr 20, 2015 at 03:16 PM

Do you use pixel perfect in your canvas? That might be a bottleneck when you have lots of animated UI.

Also do you keep all your objects that can appear in game live? If so you should consider instantiating and destroying them instead.

Also check your quality settings (Edit => Project settings => Quality). Something like removing AA might help (make it an option in your game).

Check the sizes of your Textures (e.g. if you have Texture with 4kx4k but you need only 256x256 then you know what to do).

P.S. Also you should try to reduce draw calls if you have tons of them, and many more. As lordlycastle wrote - it is really broad subject, and it will be hard to guess where is your bottleneck and if it is only 1.

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
avatar image
0

Answer by screenname_taken · Apr 20, 2015 at 07:46 PM

There are many things that could be at fault without looking at the project. Is your UI using a lot of canvases? What do you have in your Update loops? Also, do you have empty update loops? What's the resolution of the textures?

Comment
Add comment · Show 2 · 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
avatar image Hoffa25 · Apr 21, 2015 at 05:57 AM 0
Share

I have very few update() and they dont do much. $$anonymous$$y UI and my game play is using tons of UI. The entire game is made with the new UI system. ...I only have one canvas but i guess i have 200 canvasgroups to be able to make buttons, panels etc disapear and come back.

avatar image screenname_taken · Apr 21, 2015 at 09:57 AM 0
Share

Are you doing a lot of getcomponent functions in your Update loops? or have a lot of Debug.log messages?

avatar image
0

Answer by Hoffa25 · Apr 21, 2015 at 02:39 PM

Thanks everybody! I guess the answer was that I had to many canvasgroups (UI panels) in my scene covering everything. The more i remove the higher fps i get. I have also implemented alot of Destroy(IntroUIpanels) so that after your intro they are gone and that also helped the fps. It has now gone up to about 13-19 wich i think is ok for the game im making.

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

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

I have performance lag after my game has been compiled. 1 Answer

Can I change the cap of framerate at web player? 1 Answer

Reduce Poly Count Within Unity? Higher FPS? 1 Answer

Extremely low fps in editor!!! 0 Answers

Game runs smoothly in landscape mode but lags/stutters in portrait! 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