We’re trying to make a first person puzzle game where we can change sizes of cubes and connect them together to make “keys” so player can open the exit door. But I can’t find an algorithm or code for my specific problem. I can put snapping points to cubes but then if one of cubes is too small there would be an empty space between two of them. I thought about raycasting but I couldn’t think of a way that can attach, for example, a 1x1x1 cube at 0x,0y,0z and another 1x1x1 cube at 0x,1y,1z easily. These cubes can change sizes before player attaches them together. I hope I explained the situation properly. How can I do it?