I'm trying to make a square appear on my terrain. The square is moved by the mouse but is always snapped to the grid on the terrain which is basically. The corners of the square are the terrains vertices. Really would appreciate any help.
Here is what I got so far and as I predicted it was completely wrong: