This function returns the global bit mask value, the one used for all tile maps.
The function returns the current mask value or -1 if there is an error.
For further information on global tile map bit masks, see the function tilemap_set_global_mask.
tilemap_get_global_mask()
Real (the global mask value or -1 in case of an error)
var _mask = tilemap_get_global_mask(map_id);
var _new_mask = tile_mirror | tile_flip | tile_rotate | 255;
if (_mask != _new_mask)
{
tilemap_set_global_mask(_new_mask);
}
The above code gets the global mask value associated with all tile maps. If it is not the same as the value defined in the variable _new_mask, then it is set to that value.