Beispiel #1
0
 public override void Serialize(NetworkWriter writer)
 {
     writer.WritePackedUInt32(netId);
     writer.WritePackedUInt32(childIndex);
     writer.WriteBytesAndSize(payload);
 }
Beispiel #2
0
 public override void Serialize(NetworkWriter writer)
 {
     writer.WritePackedUInt32(netId);
     writer.WriteBytesAndSize(parameters);
 }
Beispiel #3
0
 public override void Serialize(NetworkWriter writer)
 {
     writer.WritePackedUInt32(netId);
     writer.WritePackedUInt32((uint)hash);
 }
Beispiel #4
0
 public override void Serialize(NetworkWriter writer)
 {
     writer.WritePackedUInt32(netId);
     writer.Write(eventHash);
     writer.WriteBytesAndSize(payload);
 }
Beispiel #5
0
 public override void Serialize(NetworkWriter writer)
 {
     writer.WritePackedUInt32(netId);
     writer.Write(authority);
 }
Beispiel #6
0
 protected override void SerializeItem(NetworkWriter writer, uint item)
 {
     writer.WritePackedUInt32(item);
 }
Beispiel #7
0
        // zigzag encoding https://gist.github.com/mfuerstenau/ba870a29e16536fdbaba
        public static void WritePackedInt32(this NetworkWriter writer, int i)
        {
            uint zigzagged = (uint)((i >> 31) ^ (i << 1));

            writer.WritePackedUInt32(zigzagged);
        }
Beispiel #8
0
 protected override void SerializeItem(NetworkWriter writer, int item) => writer.WritePackedUInt32((uint)item);
Beispiel #9
0
 public void Serialize(NetworkWriter writer)
 {
     writer.WritePackedUInt32(netId);
     writer.WriteBytesAndSizeSegment(payload);
 }
Beispiel #10
0
 public void Serialize(NetworkWriter writer)
 {
     writer.WritePackedUInt32(netId);
     writer.WriteBoolean(authority);
 }
Beispiel #11
0
 public void Serialize(NetworkWriter writer)
 {
     writer.WritePackedUInt32(netId);
 }
 public override void Serialize(NetworkWriter writer)
 {
     writer.WritePackedUInt32((uint)value);
 }