- Home /
Unity Rotation Not Working Properly?
Hey guys, I'm having an extremely weird issue. When rotating any objects within the inspector/editor they seem to rotate at first with the transform arrows moving and the inspector numbers also moving accordingly. Except the problem comes when I click off and back onto the object, the object seems to stay rotated and the inspector numbers stay at the position as if it were rotated but the transform arrows move back to the default position causing nothing to be moved correctly.
I made a new scene and tested the theory and everything seemed to work fine until I placed my prefabs into the scene, the folders were still the same but there was nothing in the scene view like before. Could it be some script on an object in the scene that directly affects the performance of the inspector or editor? None of my scripts were meant to be editor scripts and I have none placed in the folder.
Does this issue occour when you change the rotation through the editor tools and does it happen in play mode or not?
This happens when I select the rotate tool within the editor/inspector and change the values through the number slider or simply pulling the rotate transform angles that appear on screen. The odd rotation does effect the in game play. When I start the game with the "rotated" object it appears to have the rotation applied but when I click the object the transform arrows are in the default position and not matching with the rotated objects "should be" position. The error even persists through script too, for example. I have a gun point gameObject parented to the $$anonymous$$ain Camera, when the $$anonymous$$ain Camera is moved through the mouse look script the gun point does not follow as it is supposed to. It seems to stay in one spot the entire time as if it is static.
I may be able to upload a video if me typing everything out is not as understandable as you would like.
@HashinBrownsR - I have converted your answer to a comment , as that`s what it really is.
please be careful not to respond to comments by helpers in the Answer slot (this is reserved, well, for Answers!)
Take care dude, either way, your comment is now up Gruffy
Answer by Owen-Reynolds · Mar 25, 2014 at 12:46 AM
Think you're just misunderstanding the controls, and there is no problem.
On the top bar, look at local/global (next to Pivot.) Pick a rotated object, toggle the button a few times and the "problem" should go away.
Once you get used to it, being able to switch the arrows between those two settings is a spiffy feature (it's copied from 3D modeling programs.)
So when Global is toggled the problem seems to persist, at least in the inspector. However when I toggle on local the problem seems to go away. Both of these only work in the inspector though, when I go ingame the problem is still there.
It's not a problem. Global is supposed to ignore the object's rotation.
Suppose you have a slanted wall and need to move it due East. Using local, you have diagonal arrows, making it super hard. So ins$$anonymous$$d, you switch to Global, pull due East, and done.
How do you have the problem in game? There aren't any arrows in a build? Do you means when you have the Play button press in the editor?
By in game I mean that I have my game view and my scene view split. When I rotate my character in game while looking at the scene view panel the transform arrows stay put and don't follow my actual in game rotation.
To put it in short. I rotate my character and the transform arrows that tell me where I am actually facing don't follow.
Sounds like the same Global/Local confusion. If global is checked, you're telling Unity: "don't use the arrows to show rotation -- just keep them locked so I can drag them easier." It's a feature.
If you want to see the rotation, check it to Local. But the setting doesn't affect the game in any way. It just an option to make using the arrows easier sometimes.
Your answer
![](https://koobas.hobune.stream/wayback/20220613141100im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
A node in a childnode? 1 Answer
RotateAround Limitations 2 Answers
unity and drop box problem 1 Answer
What is this error and how can I fix it? 2 Answers
Rotating sprite through touch (storing current rotation) 0 Answers