Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Author
Message
Giku_
14
Years of Service
User Offline
Joined: 14th Jan 2012
Location: The World
Posted: 29th Feb 2012 18:01
It is possible tu rotate a sprite from a central point of it? Something like a wheel?
Millenium7
21
Years of Service
User Offline
Joined: 13th Dec 2004
Location:
Posted: 29th Feb 2012 19:10
the built in rotation always rotates from the point of it's position (which is top left by default)
you need to offset the sprite, this only affects the actual drawing of it. So if you



the sprite will still exist at it's original position as far as your game code is concerned, but the visual position of the sprite is shifted up and left by 50%. So if before you were doing something along the lines of...



in order to center the image on the screen, you need to change it to

Login to post a reply

Server time is: 2026-07-10 00:42:46
Your offset time is: 2026-07-10 00:42:46