Skip to content

1681-engine / index / paintTerrain

Function: paintTerrain() ​

ts
function paintTerrain(
   grid, 
   set, 
   out, 
   x, 
   y, 
   terrain
): number[];

Defined in: src/tilemap/autotile.ts:213

Sets cell (x, y) to terrain and retiles around it; the changed indices, as updateAutotile returns them.

Parameters ​

ParameterType
gridTerrainGrid
setAutotileRuleSet
outUint32Array
xnumber
ynumber
terrainnumber

Returns ​

number[]

Released under the MIT License.