Manually typed out the first script and decided to post here so others don't have to
///@descrition tile_meeting(x,y,layer)
///@param x
///@param y
///@param layer
var _layer = argument[2],
_tm = layer_tilemap_get_id(_layer);
if (_tm == -1 || layer_get_element_type(_tm) != layerelementtype_tilemap) {
show_debug_message("Checking collision for non existent layer / tilemap")
return false;
}
var _x1 = tilemap_get_cell_x_at_pixel(_tm, bbox_left + (argument[0]-x),y ),
_y1 = tilemap_get_cell_y_at_pixel(_tm, x,bbox_top + (argument[1]-y) ),
_x2 = tilemap_get_cell_x_at_pixel(_tm, bbox_right + (argument[0] - x),y ),
_y2 = tilemap_get_cell_y_at_pixel(_tm, x, bbox_bottom + (argument[1]-y) );
for(var _x = _x1; _x <= _x2; _x++){
for(var _y = _y1; _y <= _y2; _y++) {
if (tilemap_get(_tm,_x,_y)) {
return true;
}
}
}
return false;