Why when we try to stampmesh based on a hitPoint and line of sight, the stamp position is calculated in a way that half of the stamped mesh is inside the other one in many cases? Also when on a flat terrain, even AddBlock adds the blocks in a way that half of the block is inside the terrain

Am i doing anything wrong? What is the reason for this behavior and can it be changed so you snap objects in a position were the whole shape is outside of the other. Btw I'm using Unity and your unity plugin but since this was general engine behavior , thought that asking here is more appropriate 

0 0
AddBlock and StampMesh are different interfaces when it comes to positioning where changes will occur.

StampMesh takes a general transform, here it is up to you (the application) to decide where to position the mesh in world coordinates. If you are using StampMesh, you can compute the right transform to produce the effect you seek.

AddBlock, in contrast, assumes a global grid to which the new block can be snapped or not. If snapping is ON, and you point to a surface within the imaginary snap grid, that block in the snap grid will be filled. If you point to a surface that lies on the imaginary snap grid, then the block will be added on the exterior of the surface. If snapping is OFF, a one voxel imaginary snap grid is used, and the center of the added block will be placed at the hit point.
0 0