tile_layer_depth

Moves all tiles at a given depth to a new depth.

Syntax:

tile_layer_depth(depth, newdepth);


Argument Description
depth The current depth of the tile layer.
newdepth The depth to change the layer to.


Returns: N/A


Description

With this function you can change the draw depth of a whole layer of tiles.


Example:

if change
   {
   tile_layer_depth(10000, -10000);
   }
else
   {
   tile_layer_depth(-10000, 10000);
   }

The above code will set the depth of a tile layer depending on whether a variable returns true or false.


Back: Background Tiles
Next: tile_layer_find
© Copyright YoYo Games Ltd. 2018 All Rights Reserved