class MySprite(pygame.sprite.Sprite):Refers to MySprite.image , as variable common to all instances, I guess, somewhat a static member in C++, Am I right?
image = None
def __init__(self):
pygame.sprite.Sprite.__init__(self)
if MySprite.image is None:
# This is the first time this class has been instantiated.
# So, load the image for this and all subsequence instances.
MySprite.image = pygame.image.load("image.png")
self.image = MySprite.image