mp_grid_clear_all

Mark all cells in the grid to be free.

Syntax:

mp_grid_clear_all(id);


Argument Description
id Index of the mp_grid that is to be used


Returns: Boolean.


Description

With this function you can clear an mp_grid of all "forbidden" cells.


Example:

if !instance_exists(obj_Player) mp_grid_clear_all(grid);

The above code will clear the mp_grid indexed in the variable "grid", marking all the cells as free, if an instance of the object "obj_Player" no longer exists in the room.


Back: Motion Planning
Next: mp_grid_clear_cell
© Copyright YoYo Games Ltd. 2018 All Rights Reserved