Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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 WinterboltGames · May 22, 2017 at 06:04 PM · fpslagframerate dropsframes per second

Frame Rate Issue

Hello everybody,

something weird is happening when I run my game (or even after building it), the game keeps giving little frame drops like this

alt text

it's like it's 60-60-60-11-60-60-60-1-60-60-60-11and soon

I don't know why or this happened since it has started to happen just right now today

if you have any answer please post it here I'm very experienced and smart don't worry

thanks in advance.

fps-drop-image.png (51.3 kB)
Comment
Add comment · Show 4
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 Bunny83 · May 22, 2017 at 06:59 PM 1
Share

Uhm, it's hard to interpret your "graph". What does it represent? The frame time for each frame? Your roman numerals also don't make much sense as they basically say 1,2,3,4,4,3,5,6,7,8,9,8,7,11,12. The usual order is I, II, III, IV, V, VI, VII, VIII, IX, X, XI, XII, XIII, XIV, XV, XVI, ...

Also if the graph shows the frame times in "ms" it would mean you get a frame rate of 40 fps and at the spikes only 20 fps.

If you get a cyclic framerate drop it has to be something "cyclic". A common case would be the physics system (FixedUpdate) since it usually runs at a lower rate than the normal Update. By default the physics rate is set to 50fps (0.02sec or 20 ms). Since your frame time is larger than the time required for one physics step, Unity will have to call FixedUpdate multiple times per frame.

With the information given we can only guess what you're doing in your game / application. You should edit your question and add more information. For example if you're using the physics system, how many objects you have in your scene, etc... Just presenting symptoms without any information on the possible causes makes it impossible to give an answer.

avatar image WinterboltGames Bunny83 · May 22, 2017 at 07:16 PM 0
Share

hi @Bunny83, first thank you for correcting my wrong roman numerals

what I meant in that question is that the games run at 60+ frames per second but It give little freezes and hangs during runtime for example ...

if you are walking down the street at your normal speed and suddenly stop for 1/10 of a second then continue moving at your normal speed.

if you know what I mean please reply

thanks in advance

avatar image WinterboltGames Bunny83 · May 22, 2017 at 08:08 PM 0
Share

here are some more screenshots from the profiler if this helps

2 screenshots showing all of what was happening

alt text

alt text

2017-05-22-22-05-18-unity-560f3-personal-64bit-lev.png (129.3 kB)
2017-05-22-22-05-46-unity-560f3-personal-64bit-lev.png (129.0 kB)
avatar image MrJamieMcC · May 22, 2017 at 07:30 PM 0
Share

Are you spawning any objetcs?

2 Replies

· Add your reply
  • Sort: 
avatar image
1
Best Answer

Answer by WinterboltGames · May 22, 2017 at 09:16 PM

No problem I have solved it myself

here's how to anyone having the same problem:

I had about 50-60 spawning scripts looping ray casts I have fixed this problem by making them all united under single caster that casts the Ray once

also thanks for @Bunny83 for this:-

If you get a cyclic framerate drop it has to be something "cyclic". A common case would be the physics system (FixedUpdate) since it usually runs at a lower rate than the normal Update. By default the physics rate is set to 50fps (0.02sec or 20 ms). Since your frame time is larger than the time required for one physics step, Unity will have to call FixedUpdate multiple times per frame.

With the information given we can only guess what you're doing in your game / application. You should edit your question and add more information. For example if you're using the physics system, how many objects you have in your scene, etc... Just presenting symptoms without any information on the possible causes makes it impossible to give an answer.

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
1

Answer by MrJamieMcC · May 23, 2017 at 06:47 AM

Are you spawning any objetcs?

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 WinterboltGames · May 23, 2017 at 07:03 AM 0
Share

yes, but the problem wasn't in the spawning but in the ray casting it self since i have pooled all the objects that are spawned.

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

85 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 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 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 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

Increasing Unity Frame Rate? 0 Answers

Why do newer versions of Unity have problems with framerate never exceeding refresh rate despite vsync settings being turned off? 0 Answers

[Android] Debug vs Release build FPS 0 Answers

Odd FPS in Editor & Built game. 0 Answers

Sudden Framerate drops at random times?? 2 Answers


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