This function can be used to find the maximum value for all the cells found within the defined disk area of a grid, as shown in the image below:

ds_grid_get_disk_max(index, xm, ym, r);
| Argument | Type | Description |
|---|---|---|
| index | DS Grid | The index of the grid. |
| xm | Real | The x position of the disk center in the grid. |
| ym | Real | The y position of the disk center in the grid. |
| r | Real | The radius of the disk in the grid. |
val = ds_grid_get_disk_max(grid, 5, 5, 2)
The above code will set the variable "val" to the maximum value contained within the given disk of the DS grid indexed in the variable "grid".