/// <summary>Allows you to warp to the target point with the specified separation distance.</summary> public void WarpTo(SgtPosition position, double distance) { // Make sure we don't warp directly onto the star var direction = SgtPosition.Direction(ref Point.Position, ref position); position.LocalX -= direction.x * distance; position.LocalY -= direction.y * distance; position.LocalZ -= direction.z * distance; position.SnapLocal(); WarpTo(position); }
private void FloatingCameraPositionChanged(SgtFloatingCamera floatingCamera) { var direction = SgtPosition.Direction(ref cachedObject.Point.Position, ref SgtFloatingOrigin.CurrentPoint.Position); transform.forward = direction; }
private void PreCull(Camera camera) { var direction = SgtPosition.Direction(ref cachedObject.Point.Position, ref SgtFloatingOrigin.CurrentPoint.Position); transform.forward = direction; }