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
1
Question by Generalkidd · Jan 26, 2015 at 02:43 AM · rigidbody

Rigidbodies not working correctly

I have a simple game where there are several towers of stacked blocks. The main character is a simple ball that's supposed to crash into those blocks and knock everything over. It's basically a physics playground. I originally developed the game on a relatively low power computer and the collisions worked fine and the towers would topple. However, when I run the game on a modern, fast computer, the collisions are detected, but nothing happens when I collide into the tower of blocks. None of the settings have been changed. Why are the physics varying between computers of different speeds?

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 immersiveGamer · Jan 26, 2015 at 03:29 AM

You problem is probably that of moving the ball in Update instead of FixedUpdate. Since your new computer is more powerful it is calling Update more times. This can cause the ball to then slip through the colliders. FixedUpdate (as it's name implies) is updated at a fixed interval while Update is called as fast as it can (each frame) meaning if it is faster than fixed update some physics won't detect properly. Try putting your ball movement into that and see if it works. That or try moving your ball with physics (forces and such) instead of moving the ball directly.

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 Generalkidd · Jan 26, 2015 at 03:43 AM 0
Share

The balls collisions aren't calculated in Update() though. I'm purely relying on the rigidbodies and colliders to handle all of the physics. On faster computers, the ball doesn't appear to be clipping through other objects either. It just stops when it collides into an object. Switching to fixedUpdated makes the game very jittery too.

avatar image immersiveGamer · Jan 26, 2015 at 06:11 AM 0
Share

So you aren't using transform.Translate or transform.position to move the ball? I still feel like the problem is with moving that ball. If you don't $$anonymous$$d posting the code on which moves the ball. If it isn't that then two other options. $$anonymous$$ight be how the forces are being calculated. And two, is this an old project that you imported into a new version of unity? $$anonymous$$ight be some problems with that.

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

3 People are following this question.

avatar image avatar image avatar image

Related Questions

In what var can I know the size of velocity 3 Answers

How do I connect two objects together in the scene? 1 Answer

Understanding Space.World and Space.Self: Character changing movement direction 1 Answer

Particle System speed and Rigidbody Velocity. 0 Answers

NavMesh Collision Detection? 0 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