Avatar orientation conversion: use quaternions rather than Orientation class, generalize rotations so that avatars can be reoriented based on gravity.