Options
All
  • Public
  • Public/Protected
  • All
Menu
classdesc

Creates a DuckEngine TileMap

description

The TileMap Class. Creates a tilemap of images

since

1.0.0

Hierarchy

Index

Constructors

constructor

Properties

culled

culled: boolean
memberof

Map

description

Determines if the Map should be visible by the current scene's current camera

since

2.1.0

game

game: Game
memberof

Map

description

Game instance

since

2.0.0

Readonly id

id: string
memberof

Map

description

A unique identifier for the Map

since

2.0.0

origin

origin: Vector2
memberof

Map

description

The map origin point

since

2.0.0

scene

scene: Scene
memberof

Map

description

Scene instance

since

2.0.0

Readonly shape

shape: string
memberof

Map

description

"Shape" of the map, always "Map", used by Scene.displayList to distinguish between Renderables

since

2.0.0

tileLayers

tileLayers: TileLayer[]
memberof

Map

description

An array of TileLayers

since

2.0.0

visible

visible: boolean
memberof

Map

description

Determines if the Map is visible or not

since

2.0.0

zIndex

zIndex: number
memberof

Map

description

Used for depth sorting, default: 2

since

2.0.0

Methods

_draw

  • _draw(): void
  • description

    Draws the tilemap.

    DO NOT CALL MANUALLY, CALLED IN GAME LOOP USING SCENE.displayList

    Returns void

sortTileLayers

  • sortTileLayers(filter?: boolean): TileLayer[]
  • memberof

    Tilemap

    description

    Gets visible layers based on filter, then depth sorts the layers

    since

    2.0.0

    Parameters

    • filter: boolean = true

    Returns TileLayer[]

Generated using TypeDoc