title: How can I move a node in ARSCNView with a pan gesture recognizer?
body: <p>I have the following code in <code>viewDidLoad</code></p>
  
  <pre><code>let scene = SCNScene(named: "funModel")!
  myNode = scene.rootNode.childNode(withName: "blah")!
  myNode.position = SCNVector3Make(0, 0, -1)
  sceneView.scene = scene
  let pan = UIPanGestureRecognizer(target: self, action: #selector(panGesture(recognizer:)))
  view.addGestureRecognizer(pan)
  </code></pre>
  
  <p>and then the following code in <code>panGesture</code> from <a href="https://stackoverflow.com/a/25154025/957768">another SO answer</a>, but it's not working. The node just goes to 0, 0, 0 it seems like. I just want to be able to drag the node around the screen.</p>
  
  <pre><code>let projectedOrigin = sceneView.projectPoint(SCNVector3Zero)
  let vp = recognizer.location(in: sceneView)
  let vpWithZ = SCNVector3(x: Float(vp.x), y: Float(vp.y), z: Float(projectedOrigin.z))
  let worldPoint = sceneView.unprojectPoint(vpWithZ)
  myNode.position = worldPoint
  </code></pre>