# HG changeset patch # User IBBoard # Date 1259426427 0 # Node ID f609bcf7035bc23dc1fa434bc2ba8b3fc20f0072 # Parent a1a6b527cd7026d67b15a175a2b8e0bc84b6b6ff Fixes #222: decimal comma/point not handled correctly (again?) in costMultiplier * Replace two "type.Parse" calls with XmlTools calls All decimals in WarFoundry should use the decimal point (or "period" to Americans) rather than the decimal comma because that's what XML uses in its default type definitions diff -r a1a6b527cd70 -r f609bcf7035b api/Factories/Xml/WarFoundryXmlRaceFactory.cs --- a/api/Factories/Xml/WarFoundryXmlRaceFactory.cs Sat Nov 28 16:22:11 2009 +0000 +++ b/api/Factories/Xml/WarFoundryXmlRaceFactory.cs Sat Nov 28 16:40:27 2009 +0000 @@ -287,7 +287,7 @@ try { - unitEquipItem.IsRequired = bool.Parse(equip.GetAttribute("required")); + unitEquipItem.IsRequired = XmlTools.GetBoolValueFromAttribute(equip, "required"); } catch(FormatException e) { @@ -296,7 +296,7 @@ try { - unitEquipItem.CostMultiplier = double.Parse(equip.GetAttribute("costMultiplier")); + unitEquipItem.CostMultiplier = XmlTools.GetDoubleValueFromAttribute(equip, "costMultiplier"); } catch (FormatException e) {