When I rotate 3d object in unity manually it changes it's z rotation and x,y position so it stays in the same location (doesn't move only rotate), but when I rotate it in script it doesn't change position, only changes rotation and moves. How to rotate around z axis and change x,y position, so it stays in same place and only rotates?
Oki, I made it I made a empty object at center of this object and made that object a child of it and rotate empty object at center.