UnityEngine.Networking.NetBuffer.ReadBytes C# (CSharp) Method

ReadBytes() public method

public ReadBytes ( byte buffer, uint count ) : void
buffer byte
count uint
return void
        public void ReadBytes(byte[] buffer, uint count)
        {
            if ((this.m_Pos + count) > this.m_Buffer.Length)
            {
                object[] objArray1 = new object[] { "NetworkReader:ReadBytes out of range: (", count, ") ", this.ToString() };
                throw new IndexOutOfRangeException(string.Concat(objArray1));
            }
            for (ushort i = 0; i < count; i = (ushort) (i + 1))
            {
                buffer[i] = this.m_Buffer[this.m_Pos + i];
            }
            this.m_Pos += count;
        }