Ok so you know how blueprints have two tabs by default in the graph view, Event Graph and Construction Script?
The construction script is where you can run blueprint scripts when placing or manipulating objects in the editor viewport.
I put together the script for you, but there’s a problem. It should work theoretically, but does not in 4.7 preview presumably because of “UE-9724 Actor rerun construction script doesn’t run when making changes to components.”
I haven’t tried it in 4.6, but it might work for you there.
Here:
On running construction script, check if public boolean “execute” is true. If so, run a for loop from 0 to number of spline points - 1, firing a trace from each spline point’s X and Y at StartZ (I used 10000) to each spline point’s X and Y and EndZ (I used -1000). If the trace hits something, Set World Location at Spline Point to its current X and Y at the hit location’s (or Impact point’s) Z plus OffsetZ. When the loop is completed, set “execute” to false.
Then when you want to snap the spline, just set “execute” to true from the Details pane in the map tab.
EDIT: tried it in 4.6, no dice. Could someone else chime in with a peer review of my script? Maybe I’m missing something.