Exemple #1
0
        // Generally this shouldn't be used outside of the static constructor
        public static Playfields LoadXml(string fileName)
        {
            XmlSerializer serializer = new XmlSerializer(typeof(Playfields));
            TextReader    reader     = new StreamReader(fileName);
            Playfields    data       = (Playfields)serializer.Deserialize(reader);

            reader.Close();
            return(data);
        }
 static Playfields()
 {
     Instance = LoadXml(Path.Combine("XML Data", "Playfields.xml"));
 }
Exemple #3
0
 static Playfields()
 {
     Instance = LoadXml(Path.Combine("XML Data", "Playfields.xml"));
 }