I'm looking at the example on http://threejs.org site (http://threejs.org/examples/webgl_interactive_draggablecubes.html) and I see they are moving the selected cube along a plane relative to the camera. I get how the unprojection works with raycaster. What I don't get is how to set this up to always move the object along the ground (plane) even if the camera is at an angle. The idea is to have the user use a the mouse to move the object along the ground even if the camera is at an angle and is NOT looking perfectly down at it. I'm new to using Three.js so you might want to be verbose in explaining what I'm missing. Or maybe ask questions back if I didn't explain myself.
My project looks like this and I'm looking to move the boxes around with a mouse.
plane
; the example usesplane.setFromNormalAndCoplanarPoint( camera.getWorldDirection( plane.normal ), INTERSECTED.position );
while you need theY = 0
plane instead. Something likeplane = new THREE.Plane( new THREE.Vector3( 0, 1, 0 ), 0);
– Chris G