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 Team_26 · May 17, 2014 at 04:38 PM · optimizationlag

Game OPTIMIZATION methods

Hi! I know that there're a lot of questions about this on this page, but I can't find answer for MY game.

In my game there's a looot of small cubes which are using physics (rigidbodys with gravity switched on etc). It's because I shoot projectiles to cubes. Some of targets are windows, which are trashing and makes a lot of small cubes. I do only 1/3 of my level and already the game is lagging (Normally there's about 70 FPS, but when I shoot too much cubes and windows it decreases to about 1-6 FPS).

I tried to: - Disable scripts, when they do their job (there're a script for 90% of cubes, so I thought it can be very useful);

I know that games like this are hard to optimize, but I hope you can tell me some hints and reply me.

Sorry for my bad English. I hope you know what I mean. When you reply me, please use simple words and sentences.

[EDIT]: **I haven't got Pro Version of Unity and I can't use Profiler window to tell you some more important informations.**

[EDIT]: ***I see (in stats window) that value "Verts" varies between 6-40K. How can I reduce it and no delete my cubes (I see it's because my windows)?***

[EDIT]: *I forgot to tell you there's no difficult models in my game now.*

Comment
Add comment · Show 5
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 Jamora · May 17, 2014 at 04:42 PM 0
Share

Have you read Unity's Guide to Optimizing Graphics Performance and Unity - Practical Guide to Optimization for $$anonymous$$obiles?

avatar image Team_26 · May 17, 2014 at 04:47 PM 0
Share

I read some of these but there's suggestions but there're for much complication games - I don't use any difficult shaders, shadows, models, textures etc. $$anonymous$$y game is simple, but I see that the number of moving my gameObjects are making this job (are making that the game is lagging).

avatar image luminance · May 17, 2014 at 05:57 PM 4
Share

How many rigidbodies are we talking about? Do they all need to be rigidbodies? You might just be co$$anonymous$$g up against the fact that physics performance of lots (>100) of interacting objects can get real slow real fast.

If you're also creating a lot of cubes on the fly, you might want to look into reducing your calls to Instantiate with object pools.

avatar image Team_26 · May 21, 2014 at 04:41 PM 0
Share

Yes, they must have rigidbodies. But thanks for link to object pools. It can be useful. Are there any other methods to optimize my game?

avatar image NoseKills · May 21, 2014 at 05:17 PM 0
Share

I see (in stats window) that value "Verts" varies between 6-40$$anonymous$$. How can I reduce it and no delete my cubes

6k-40k verts, 24 verts per cube => means 250 - 1600 cubes ? If this is correct I don't think there's any amount of optimizing that will make you'r game run, unless you just cut the amount of rigidbodies.

Just like @lu$$anonymous$$ance said.

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by justin35f · May 21, 2014 at 05:31 PM

As some of the comments have stated, it sounds like you have too many game objects with rigidbodies attached. Both of these will affect performance. Each game object has scripts and components that need to be processed each frame. Each rigidbody is run through physics simulation as well. You need to consider cutting down the number of game objects that are active at any given time.

Try to keep the number of rigidbodies low. It depends on the hardware that the game is being run on (mobile, pc, web, etc...) so an exact number can't be given.

Comment
Add comment · Show 1 · 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 Team_26 · May 26, 2014 at 04:44 PM 0
Share

Thanks. Anymore?

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

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

Related Questions

Why does this simple follow script make my game lag? 2 Answers

Public, private and getting stuff efficiency question. 2 Answers

Alternative to SendMessage()? / Mobile Optimization 1 Answer

Can't Find Optimization Problem in My Scripts 4 Answers

How can I optimize my range tests? 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