Exemplo n.º 1
0
 public TKEYBlock(Stream stream, bool isMain, GXTFileVersion version) : base(stream, version)
 {
     this.IsMain = isMain;
     Parse(stream);
     ParseEntries(stream);
     ParseTDATBlock(stream);
     FindAssociatedValues(stream);
 }
Exemplo n.º 2
0
        public void ReadVersionFromStream(Stream stream)
        {
            byte[] buf = new byte[4];
            stream.Seek(0, SeekOrigin.Begin);
            stream.Read(buf, 0, buf.Length);

            if (Encoding.ASCII.GetString(buf) == "TKEY")
            {
                fileVersion = GXTFileVersion.III;
            }

            if (Encoding.ASCII.GetString(buf) == "TABL")
            {
                fileVersion = GXTFileVersion.VC;
            }

            if (BitConverter.ToInt32(buf, 0) == 0x080004)
            {
                fileVersion = GXTFileVersion.SA;
            }
        }
Exemplo n.º 3
0
 public TKEYEntry(Stream stream, GXTFileVersion version) : base(version)
 {
     Parse(stream);
 }
Exemplo n.º 4
0
 public TDATBlock(Stream stream, GXTFileVersion version) : base(stream, version)
 {
     Parse(stream);
 }
Exemplo n.º 5
0
 public GXTFileBlockEntry(GXTFileVersion version)
 {
     Version = version;
 }
Exemplo n.º 6
0
 public TABLBlock(Stream stream, GXTFileVersion version) : base(stream, version)
 {
     Parse(stream);
     ParseEntries(stream);
     FindAssociatedBlocks(stream);
 }
Exemplo n.º 7
0
        /// <summary>
        /// List of child <see cref="GXTFileBlockEntry"/> entries
        /// </summary>
        /// <summary xml:lang="ru">
        /// Список дочерних элементов <see cref="GXTFileBlockEntry"/>
        /// </summary>
        //public List<GXTFileBlockEntry> Entries { get; set; }

        public GXTFileBlock(Stream stream, GXTFileVersion version)
        {
            BlockOffset = stream.Position;
            Version     = version;
        }