public GameStage(int id) { Id = id; Objs = new Obj[7][]; Tiles = new Tile[7][]; m_textureCache = new Dictionary<string, ZTexture>(); Players = new ZDictionary<int, Player>(); Load(); }
private Story(byte[] memory) { this.memory = memory; this.version = Header.ReadVersion(memory); this.serialNumber = Header.ReadSerialNumber(memory); this.releaseNumber = Header.ReadReleaseNumber(memory); this.checksum = Header.ReadChecksum(memory); this.actualChecksum = Header.CalculateChecksum(memory); this.routinesOffset = Header.ReadRoutinesOffset(memory); this.stringsOffset = Header.ReadStringsOffset(memory); this.instructionCache = new InstructionCache((memory.Length - Header.ReadStaticMemoryBase(memory)) / 8); this.ztext = new ZText(memory); this.memoryMap = new MemoryMap(memory); this.informData = new InformData(memory, this.memoryMap, ztext); this.objectTable = new ZObjectTable(memory, ztext); this.globalVariablesTable = new GlobalVariablesTable(memory); this.dictionary = new ZDictionary(this, ztext); this.mainRoutineAddress = Header.ReadMainRoutineAddress(memory); RegisterInterpreter(new DefaultInterpreter()); }