TLChangeAreaGroundTiles(object, int, int, int, float)

Changes the tiles of an entire area.

void TLChangeAreaGroundTiles(
    object oArea,
    int nGroundTileConst,
    int nColumns,
    int nRows,
    float fZOffset = -0.4f
);

Parameters

oArea

Area to change the tiles of

nGroundTileConst

X2_TL_GROUNDTILE_*

nColumns

Columns in the area

nRows

Rows in the area

fZOffset

Z-axis coordinate for the tile magic. (Default: -0.4f)


Description

change the type of the ground or (by default) sub ground tiles (i.e. water) to the specified type.



Remarks

This function will flood the entire area with the tile in question. nColumns and nRows indicate the size of the area. For instance, a 4 * 6 area will have 4 columns and 6 rows.

You may not want to flood your entire area, but this function will give you a pretty good idea how to use the tile magic (tm). Basically, you just create an invisible object in the center of a tile, and apply a permanent visual effect to that invisible object.


Requirements

#include "x2_inc_toollib"

Version

1.61

See Also

functions: TLResetAreaGroundTiles
categories: Area Functions | Visual Effects Functions
constants: X2_TL_GROUNDTILE_* Constants


 author: Lilac Soul
 Send comments on this topic.