CLASS v1.8.0

tilemap.MapObject

pykraken.tilemap.MapObject

MapObject represents a placed object on an object layer.

More about tilemap.MapObject

Attributes

  • transform (Transform) — Transformation component for the object.
  • visible (bool) — Visibility flag.
  • uid (int) — Unique identifier.
  • name (str) — Object name.
  • type (str) — Object type string.
  • rect (Rect) — Bounding rectangle.
  • tile_id (int) — Associated tile id if the object is a tile.
  • shape_type (ShapeType) — The shape enum for the object.
  • vertices (list[Vec2]) — Vertex list for polygon/polyline shapes.
  • text (TextProperties) — Text properties when shape is text.

Reference

PYTHON API
tilemap.MapObject(/, *args, **kwargs)

Initialize self. See help(type(self)) for accurate signature.

is_visible

property
is_visible: bool

Visibility flag.

name

property
name: str

Object name.

rect

property
rect: Rect

Object bounding rectangle.

shape_type

property

Shape type enum for the object.

text

property

Text properties if the object is text.

tile_id

property
tile_id: int

Associated tile id when the object is a tile.

transform

property
transform: Transform

Transform component for the object.

type

property
type: str

Object type string.

uid

property
uid: int

Unique object identifier.

vertices

property
vertices: list[Vec2]

List of vertices for polygon/polyline shapes.

Find your next step

Start typing to search the manual.