public override void Read(BinaryReader file, uint size) { base.Read(file, size); CDynamicInt count = new CDynamicInt(cr2w); count.Read(file, 1); for (int j = 0; j < count.val; j++) { CArray currenttreebundle = new CArray(cr2w); CHandle treetype = new CHandle(cr2w); treetype.Read(file, 4); currenttreebundle.Name = treetype.Handle; CArray currentTrees = new CArray(cr2w); currentTrees.AddVariable(treetype); CDynamicInt treecount = new CDynamicInt(cr2w); treecount.Read(file, 1); for (int i = 0; i < treecount.val; i++) { CTree tree = new CTree(cr2w); tree.Read(file, 29); currentTrees.AddVariable(tree); } currenttreebundle.AddVariable(currentTrees); Trees.AddVariable(currenttreebundle); } file.BaseStream.Seek(1, SeekOrigin.Current); }
public override void Read(BinaryReader file, uint size) { CDynamicInt count = new CDynamicInt(cr2w, null, ""); count.Read(file, size); base.Read(file, size, count.val); padding.Read(file, 4); }
public override void Read(BinaryReader file, uint size) { base.Read(file, size); buffername.Read(file, 2); count.Read(file, size); unk.Read(file, 1); buffer.Read(file, 0, count.val); }
public override void Read(BinaryReader file, uint size) { CDynamicInt count = new CDynamicInt(cr2w); count.Read(file, size); for (int i = 0; i < count.val; i++) { T element = elementFactory.Invoke(cr2w); element.Name = i.ToString(); element.Read(file, size); elements.Add(element); } }
public override void Read(BinaryReader file, uint size) { var startpos = file.BaseStream.Position; base.Read(file, size); var endpos = file.BaseStream.Position; var bytesread = endpos - startpos; if (bytesread < size) { buffername.Read(file, 2); count.Read(file, size); unk.Read(file, 1); buffer.Read(file, 0, count.val); } else if (bytesread > size) { } }