title: Get absolute Camera Position and Rotation
body: <p>I've set up a very simple script system where I can change the position and rotation of the camera in space through string commands in the browser like this</p>
  <pre><code>setCameraPosition(0,0,0); setCameraRotation(1,0,1); 
  </code></pre>
  <p>When I recreate the current camera position into a command and then reexecute this command the camera position is as expected. Even when I change the camera position with Mouse or Touchscreen and execute the command. When I reload the webpage and execute the command again the camera position/rotation is then different from what I saw earlier.</p>
  <p>I am sure it is some kind of misunderstanding on my part.</p>
  <p>I'll recreate the current camera position like this:</p>
  <pre><code>const pos = camera.position
  const rot = camera.rotation
  const args: string[] = []
  args.push(`setCameraPosition(${pos.x}, ${pos.y}, ${pos.z})`)
  args.push(`setCameraRotation(${rot.x}, ${rot.y}, ${rot.z})`)
  return args.join('; ') + ';'
  </code></pre>