The class Card¶
The class Card inherits from the class pygame.Sprite. It represents a card of a specific category.
- class card.Card(center, width, height, color)¶
Class methods:
Attributes:
- category¶
the category of the card
- pos¶
the position of center of the card
Methods:
- bounding_box()¶
Returns the bounding box of the rectangle (
Box)
- rasterization(tr)¶
Returns two
intlists (rr, cc) made of the pixels’ coordinates of the rectangle’s rasterization with the given window-to -viewport transformations tr = (sx, sy, tx, ty)
The class supports the method
str.