TileMap.setCell

Sets the tile index for the cell given by a Vector2. An index of -1 clears the cell. Optionally, the tile can also be flipped, transposed, or given autotile coordinates. The autotile coordinate refers to the column and row of the subtile. Note: Data such as navigation polygons and collision shapes are not immediately updated for performance reasons. If you need these to be immediately updated, you can call updateDirtyQuadrants. Overriding this method also overrides it internally, allowing custom logic to be implemented when tiles are placed/removed:

More...
struct TileMap
@nogc nothrow
void
setCell
(
in long x
,
in long y
,
in long tile
,
in bool flip_x = false
,
in bool flip_y = false
,
in bool transpose = false
,
in Vector2 autotile_coord = Vector2(0, 0)
)

Detailed Description

func set_cell(x, y, tile, flip_x=false, flip_y=false, transpose=false, autotile_coord=Vector2()): # Write your custom logic here. # To call the default method: .set_cell(x, y, tile, flip_x, flip_y, transpose, autotile_coord)

Meta