- Home /
joint angles after Application.LoadLevel()
I have an arm made up of a series of hinge joints. I'd like to reset the level, but maintain the current position of the arm, so I call DontDestroyOnLoad() on my arm object and use LoadLevel() to reload the level.
However, after reloading the level, the current orientation of the hinge joints becomes the "new zero" degrees. For instance, if the elbow was oriented at 45 degrees before LoadLevel(), that orientation is now considered 0 degrees. Is there any way to prevent this from happening?
Thanks.
Answer by efge · Mar 21, 2011 at 09:40 PM
I think not. From the reference for HingeJoint.angle:
The rest angle between the bodies is always zero at the beginning of the simulation.
Thanks for your response. I'm going to move the arm back to the pre-reset position, ins$$anonymous$$d.
Your answer
![](https://koobas.hobune.stream/wayback/20220613114045im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Hinge Joint Limits in C sharp 1 Answer
Spring Joint Worm set-up 0 Answers
How can i change HingeJoint's axis from code? 0 Answers
Hinge or Configurable Joint to rigidbody's certain coordinates 1 Answer
Weird behaviour with hinge joint 0 Answers