public static GameStateDelta ReadDelta(NetIncomingMessage message) { uint sequence = message.ReadUInt32(); uint fromSequence = message.ReadUInt32(); int length = message.ReadInt32(); byte[] bytes; message.ReadBytes(length, out bytes); var delta = new GameStateDelta(bytes); delta.Sequence = sequence; delta.FromSequence = fromSequence; return delta; }
public static GameStateDelta ReadDelta(NetIncomingMessage message) { uint sequence = message.ReadUInt32(); uint fromSequence = message.ReadUInt32(); int length = message.ReadInt32(); byte[] bytes; message.ReadBytes(length, out bytes); var delta = new GameStateDelta(bytes); delta.Sequence = sequence; delta.FromSequence = fromSequence; return(delta); }