You've already forked lidgren-network-gen3
mirror of
https://github.com/lidgren/lidgren-network-gen3.git
synced 2026-05-19 08:36:34 +09:00
Added byte to WriteAt
This commit is contained in:
@@ -101,6 +101,16 @@ namespace Lidgren.Network
|
|||||||
m_bitLength += 8;
|
m_bitLength += 8;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Writes a byte at a given offset in the buffer
|
||||||
|
/// </summary>
|
||||||
|
public void WriteAt(Int32 offset, byte source) {
|
||||||
|
int newBitLength = Math.Max(m_bitLength, offset + 8);
|
||||||
|
EnsureBufferSize(newBitLength);
|
||||||
|
NetBitWriter.WriteByte((byte) source, 8, m_data, offset);
|
||||||
|
m_bitLength = newBitLength;
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Writes a signed byte
|
/// Writes a signed byte
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
Reference in New Issue
Block a user