I have a simple tack in front of me. I need to rotate sprite around its center, not top/left corner. I was experimenting and search for suggestions, but best i could get is sprite rotating properly, but jumping around canvas. I was trying to ajast coordinates right after rotation, but didnt manage it.
Can anyone point me in the right direction or simply tell me how to do it?
OriginX
Horizontal unit coordinate of the origin with respect to left edge. Permitted values in [0, 1]. A value of 0.0 means the origin lies on the left edge, 0.5 means the origin lies in the middle and 1.0 means the origin is on the right edge. OriginY
Vertical unit coordinate of the origin with respect to top edge. Permitted values in [0, 1]. A value of 0.0 means the origin lies on the top edge, 0.5 means the origin lies in the middle and 1.0 means the origin is on the bottom edge.
Just tryed and it works. Now, have to figure out how to move my sprite back to center of canvas. After ajusting Origins, my sprite jamped to top right corner...