Updates networking to make pipe writer awaitable (#290)
- [X] Updates result so it is preallocated - [X] Updates PipeWriter so it is awaitable - [X] Simplifies NetState code to match changes - [X] Adds a byte for empty checking so incoming/outgoing can have full pipes. Bumps release version
This commit is contained in:
parent
99bfff40df
commit
5f7e4bf050
8 changed files with 292 additions and 210 deletions
|
|
@ -277,9 +277,9 @@ namespace Server.Network
|
|||
}
|
||||
}
|
||||
|
||||
public static int ProcessPacket(NetState ns, ref CircularBuffer<byte> buffer)
|
||||
public static int ProcessPacket(NetState ns, ArraySegment<byte>[] buffer)
|
||||
{
|
||||
var reader = new CircularBufferReader(ref buffer);
|
||||
var reader = new CircularBufferReader(buffer);
|
||||
|
||||
var packetId = reader.ReadByte();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue