public void Initialize(string tableName) { this.TableName = tableName; this.List = new List <MapPosition>(); D2oReader reader = new D2oReader("common/" + this.TableName + ".d2o"); foreach (var obj in reader.ReadObjects()) { this.List.Add((MapPosition)obj.Value); } reader.Close(); Console.WriteLine("{0} map positions loaded from d2o.", this.List.Count); }
public void Initialize(string tableName) { this.TableName = tableName; //this.Accessor = new RepositoryAccessor(this.TableName); this.List = new List <Burning.DofusProtocol.Datacenter.Head>(); D2oReader reader = new D2oReader("common/" + this.TableName + ".d2o"); for (int i = 1; i < reader.IndexCount + 1; i++) { try { this.List.Add((Burning.DofusProtocol.Datacenter.Head)reader.ReadObject(i)); } catch { } } reader.Close(); }