I am trying to rotate a sprite in Monogame, but for some reason I can't get it right! I would be really grateful if someone explains the mystery of rotation!
This is the line of code that I am using to draw and rotate my sprite, just a note the variable rotation
is the angle I am incrementing it by 0.1 on every Update, this is just for testing purpose. How do I make the cannon rotate around an origin point that is inside the image? For example around its center point like a helicopter propeller? Check the video to see the result from this line of code.
spriteBatch.Draw(cannon.image, new Rectangle(300, 300, cannon.image.Width, cannon.image.Height), null, Color.White, rotation, new Vector2(0, 0), SpriteEffects.None, 0f);