Esempio n. 1
0
 public static void WriteRigidbody(ref UdpBitStream stream, Rigidbody rigidbody)
 {
     UdpBitStreamExt.WriteVector3(ref stream, rigidbody.position);
     UdpBitStreamExt.WriteQuaternion(ref stream, rigidbody.rotation);
     UdpBitStreamExt.WriteVector3(ref stream, rigidbody.velocity);
     UdpBitStreamExt.WriteVector3(ref stream, rigidbody.angularVelocity);
 }
Esempio n. 2
0
 public static void WritePlane(ref UdpBitStream stream, Plane plane)
 {
     UdpBitStreamExt.WriteVector3(ref stream, plane.normal);
     stream.WriteFloat(plane.distance);
 }
Esempio n. 3
0
 public static void WriteRay(ref UdpBitStream stream, Ray ray)
 {
     UdpBitStreamExt.WriteVector3(ref stream, ray.origin);
     UdpBitStreamExt.WriteVector3(ref stream, ray.direction);
 }
Esempio n. 4
0
 public static void WriteBounds(ref UdpBitStream stream, Bounds b)
 {
     UdpBitStreamExt.WriteVector3(ref stream, b.center);
     UdpBitStreamExt.WriteVector3(ref stream, b.size);
 }
Esempio n. 5
0
 public static void WriteTransform(ref UdpBitStream stream, Transform transform)
 {
     UdpBitStreamExt.WriteVector3(ref stream, transform.position);
     UdpBitStreamExt.WriteQuaternion(ref stream, transform.rotation);
 }