I am using a face tracker to place a rectangle of texture on my scene. When the user is too far back, the rectangle disappears. I believe this is because the object is passing through some of the layers and becoming obscured.
What I would like to do is add reactional instructions to "move camera closer" when the user is a certain distance away from the camera. Is there a way to ascertain the users distance on the z axis and trigger the instruction visibility?
Here is a snippet of what I have been trying to script.
// Load in the required modules
const FaceTracking = require('FaceTracking');
const Reactive = require('Reactive');
// Gather Face Tracker
const face = FaceTracking.face(0);
var show = face.cameraTransform.z.gt(someNumber);
Instruction.bind(show, 'move_camera_closer');