Base
The Base class is a superclass.
It provides a base for all drawable objects, so it can't be used directly.
x: float
The x position of the object.
y: float
The y position of the object.
pos, position: float, float
The position of the object.
x: floatThe object x position
y: floatThe object y position
scale: float, float
The scale of the object.
x: floatThe object x scale
y: floatThe object y scale
anchor: float, float
The offset applied when rotating the object.
x: floatThe object x anchor
y: floatThe object y anchor
angle: float
The rotation of the object in degrees.
red: float
The red colour of the object.
green: float
The green colour of the object.
blue: float
The blue colour of the object.
alpha: float
The transparency of the object.
color: float, float, float, float
The colour of the object.
r: floatThe red colour of the object
g: floatThe green colour of the object
b: floatThe blue colour of the object
a: floatThe transparency of the object
top: float
The top position of the object's bounding box.
bottom: float
The bottom position of the object's bounding box.
left: float
The left position of the object's bounding box.
right: float
The right position of the object's bounding box.
draw() -> None
Display the object, call this from the game loop.
blit(screen: Screen) -> None
Render the object to an offscreen surface.
screen: ScreenThe destination surface
collide(target: object) -> bool
Detect collision with another object.
target: objectThe object to detect collision against, can be a drawable or the mouse
look_at(target: object) -> None
Rotate the object to point towards a target.
move_to(target: object, value = 1) -> None
Move the object towards a target at a certain speed.