Restrict movement within the volume

cool! the two variants solved it