title: Rotate Sprite around Pivot Point in Pygame
body: <p>I try to rotate my canon in pygame</p>
  <p><a href="https://i.stack.imgur.com/V0tQX.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/V0tQX.png" alt="enter image description here" /></a></p>
  <p>The problem ist that with</p>
  <pre><code>pygame.transform.rotate()
  </code></pre>
  <p>The rotation is about the center which obviously is not the correct rotation point for the gun.
  So how can i move the rotation point ~20px from the center down?</p>
  <p>This is my initialization of the gun:</p>
  <pre><code>self.image = pygame.image.load(&quot;./assets/Tower/MiniGun.png&quot;).convert_alpha()
  self.rect = self.image.get_rect()
  self.rect.center = (80, 250)
  </code></pre>