Hello, I have been botherd by a problem lately wich I could not find a solution to.
Ive modelled my character with 3ds max… Boned it (RIGGED) and got it to move with some animations. In unity ive got the upper part of the body seperated from the left and right legs. The upper part is called “Hands” and I have used it to aim at the mouse position at all time…
Now, the game is a side scroller shooter and the rifle should be aimin at the mouse.
For some reason it makes a twist and THEN aims at the mouse position…
The whole upper body is turned to the left and then aims at the mouse position… but from a very silly twist and by a wrong axis… How do I fix my transform.LookAt?
sounds like you might need to provide your LookAt with an up vector to stop the twisting long the look direction?
however if thats no it then sorry for repeating what you’ve tried
Im working on a top down my self and had to toy around with rotation the post here might have some information for you it talks about zeroing a rotation i.e. to level out but also has rotation code in in it as well as a link to another post on a similar topic
http://answers.unity3d.com/questions/312019/set-certain-axis-of-rotation-to-0.html