tilemap.ImageLayer
pykraken.tilemap.ImageLayer ImageLayer displays a single image as a layer.
More about tilemap.ImageLayer
Attributes
- opacity (
float) — Layer opacity. - texture (
Texture) — The layer image texture.
Methods
- draw — Draw the image layer.
Inherits Layer
At a glance
8 membersReference
PYTHON APIConstructor
methodtilemap.ImageLayer(/, *args, **kwargs)Initialize self. See help(type(self)) for accurate signature.
name
propertyname: strLayer name.
offset
propertyoffset: Vec2Per-layer drawing offset.
opacity
propertyopacity: floatLayer opacity from 0.0 to 1.0.
texture
propertytexture: TextureTexture used by the image layer.
type
propertytype: tilemap.LayerTypeLayer type enum.
visible
propertyvisible: boolWhether the layer is visible.
draw
methodDraw the image layer.
Args
- angle (
float, optional) — Rotation angle in degrees. Defaults to 0.0. - pivot (
Vec2, optional) — Rotation pivot as normalized coordinates relative to the map size. Defaults to (0.5, 0.5).