Пример #1
0
        private static string ParseClassId(BigEndianBinaryReader reader)
        {
            int length = reader.ReadInt32();

            if (length == 0)
            {
                length = 4;
            }

            return(Encoding.ASCII.GetString(reader.ReadBytes(length)).TrimEnd('\0'));
        }
Пример #2
0
        private static string ParseKey(BigEndianBinaryReader reader)
        {
            int length = reader.ReadInt32();

            if (length == 0)
            {
                length = 4;
            }

            byte[] bytes = reader.ReadBytes(length);

            return(Encoding.ASCII.GetString(bytes));
        }