Expression example: Make a 3D layer invisible if facing away from camera

 Apply the following expression to the Opacity property of a 3D layer:
  if (toCompVec([0, 0, 1])[2] > 0 ) value else 0

Dan Ebberts explains this expression on his MotionScript website.