$success = pcwrite($file, "occ", $occlusion, "P", P, "N: Vector", N);
The point cloud gets twisted and inverted and lovely like the image to the left. This happens even when the code is simple like:
$success = pcwrite($file, "P", P, "N: Vector", N);
as it is in the actual pcwrite node. I found a pcwrite node that someone else made here, but the code is the same, just containing five elements. I may end up just using that until I can figure out why mine doesn't work.