Base object: object with position and size attributes, with helpers

Base object: object with position and size attributes, with helpers

class pymt.baseobject.BaseObject(**kwargs)

Bases: object

Represent a object with position and size information

bottomcenter

coordinate of bottomcenter (x+width/2, y)

bottomright

coordinate of bottomright (x+width, y

center

Object center (cx, cy)

centerleft

coordinate of centerleft (x, y + height / 2)

centerright

coordinate of centerright (x+width, y+height/2)

draw()

Placeholder to draw the object

height

Object height

pos

Object position (x, y)

right

x coordinate of rigth side (x + width)

size

Object size (width, height)

top

y coordinate of top (y + height)

topcenter

coordinate of topcenter (x+width/2, y+height)

topleft

coordinate of topleft (x, y+height)

topright

coordinate of topright (x+width, y+height)

update()

Placeholder to update the object

width

Object width

x

Object X position

y

Object Y position

Previous topic

Base: Main event loop, provider creation, window management...

Next topic

Cache Manager: cache object and delete them automaticly

This Page