Renders a filled shape (rectangle or circumference)

maskRenderer.shape    = MaskShape.Rectangle;
maskRenderer.width = 32;
maskRenderer.height = 32;
maskRenderer.color = "#000000";
maskRenderer.offset = new Vector2(0, 0);
maskRenderer.rotation = 0;
maskRenderer.opacity = 1;
maskRenderer.layer = "Default";
maskRenderer.shape    = MaskShape.Circumference;
maskRenderer.radius = 16;
maskRenderer.color = "#000000";
maskRenderer.offset = new Vector2(0, 0);
maskRenderer.opacity = 1;
maskRenderer.layer = "Default";

Constructors

Properties

color: string

The color of the mask

height: number = 0

Mask height in pixels

layer: string = defaultRenderLayer

The render layer

offset: Vector2 = ...

X-axis and Y-axis offset

opacity: number = 1

Change the opacity between 1 and 0

radius: number = 0

Mask radius in pixels (only for circumference)

rotation: number = 0

Mask rotation in radians

shape: MaskShape

Mask shape: Rectangle or Circumference

width: number = 0

Mask width in pixels