private void ReadIndexFile() { var indexPath = Path.Combine(this.GamePath, string.Format("{0}.000", this.GameId)); int blockCount = 0; using (var reader = new ScummBinaryReader(new ScummStream(indexPath, this.ScummVersion))) { var blockType = new string(reader.ReadChars(4)); var itemSize = reader.ReadUInt32BigEndian(); while (reader.BaseStream.Position <= reader.BaseStream.Length) { blockCount++; ReadIndexBlock(reader, blockType); blockType = new string(reader.ReadChars(4)); itemSize = reader.ReadUInt32BigEndian(); if (blockCount >= 9) { break; } } } }