Exemple #1
0
 private void readActive(XmlReader inReader, ValueGroup inValues)
 {
     while (inReader.Read())
     {
         if (inReader.NodeType == XmlNodeType.Element)
         {
             if (inReader.Name.ToLower() == "item")
             {
                 try
                 {
                     inValues.addActive(inReader.GetAttribute("type"),
                         Convert.ToDouble(inReader.GetAttribute("value")));
                 }
                 catch (FormatException)
                 {
                     Console.WriteLine("Value has invalid type.");
                 }
             }
         }
     }
 }
Exemple #2
0
 public Upgrade()
 {
     Values = new ValueGroup();
 }
Exemple #3
0
 public Building()
 {
     Type = BuildingTypes.None;
     Values = new ValueGroup();
     Upgrades = new List<Upgrade>();
 }