walfin

Cannot rotate sprite, help!

Recommended Posts

I am trying to rotate a Sprite. However, it rotates around the 0,0 of the world instead. I have tried translating it back to 0,0, rotating it, then translating it back to the original x,y again, but it still did not work.

How do I rotate a Sprite around its current position?

Share this post


Link to post
Share on other sites

How are you doing the rotation? Could you share the code for the sprite including the movement code for it? Also are you rotating it with radians instead of degrees?

Share this post


Link to post
Share on other sites

That’s weird, this should work, i use it all the time ... at least i think 🤪

(After checking all my examples) indeed all my usage are mainly when the sprite is a child of an entity or a container, i’ll setup a quick test tomorrow, maybe something broken somewhere 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

  • Recently Browsing   0 members

    No registered users viewing this page.