This repository has been archived on 2019-12-09. You can view files and clone it, but cannot push or open issues or pull requests.
pacman2/engine/components/sprite.py
2019-12-04 18:17:52 +01:00

17 lines
405 B
Python

from .component import Component
from ..servers.graphics import GraphicsServer
class Sprite(Component):
def __init__(self, surf, z):
super().__init__()
self.surf = surf
self.width = self.surf.get_width()
self.z = z
def register(self):
GraphicsServer().register_component(self)
def unregister(self):
GraphicsServer().register_component(self)