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 stevensu1838 · Sep 15, 2020 at 08:04 AM · updatefixedupdateupdate problemratefrequency

Cannot change the framerate in script by using the official example code and my fixed update rate goes up to 90

Hi all,

I've been following this official example code to test the update rate and Fixedupdate rate of my unity project.

[Update rate VS Fixedupdate rate][1]

However, by uncommenting the following line: Application.targetFrameRate = 10 in the code, the framerate doesn't drop at all(the GUI displays Update around 50 and Fixedupdate 51![alt text][2]). Could you please do my a favour? Why is it like this?

     // Uncommenting this will cause framerate to drop to 10 frames per second.
     // This will mean that FixedUpdate is called more often than Update.
     Application.targetFrameRate = 10;

Another issue is when I test this code on a high performance machine. The the GUI displays Update around 90 and Fixedupdate 90. Why the Fixedupdate rate can be 90? Shouldn't it be 50HZ ? Thanks a lot [1]: https://docs.unity3d.com/ScriptReference/MonoBehaviour.FixedUpdate.html#:~:text=FixedUpdate%20executes%2050%20times%20per,using%20System. [2]: /storage/temp/167553-capture.png

capture.png (7.7 kB)
Comment
Add comment · Show 1
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 stevensu1838 · Sep 15, 2020 at 10:30 AM 0
Share

Thank you so much for your great help. $$anonymous$$y target is to fix the update rate of my Unity project at 120 fps or 150 fps. When using fixed update, the rate is 60 FPS only. However, When it come to using Application.targetFrameRate, it says Setting targetFrameRate only set the target frame rate but does not guarantee that frame rate will be achieved. related post Is there a way for me to fix the update rate at 120 HZ or 150HZ?

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by sevdigim1451 · Sep 15, 2020 at 09:03 AM

Actually I don't know so this topic than professionals but I tested that whenever if I write the code in update, update is slow from fixed update and if I want to put slow an normal time line I use Time.deltatime. So fixed update already use for all computers shall work same frequency.(My english not so good)May be you can see , if you test game in fixed update in different computers.Already Time.deltatime use for this. I hope help to you.

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

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

New Update Text Issue 0 Answers

2D Animated tile synchronization 0 Answers

GetKeyDown Space doesn't work correctly with FixedUpdate 2 Answers

Could Update and FixedUpdate happen at the same time? 1 Answer

Should we check animation condition in Update or FixedUpdatE? 3 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