added checking for enough space on placement