tryPlaceAt

fun tryPlaceAt(agent: A, voxel: Voxel): Boolean(source)

Conditional placement for single-occupancy grids: returns true if the voxel was free (or already held this agent) and the placement succeeded; false if the voxel was occupied by another agent. Always succeeds for multi-occupancy grids.