예제 #1
0
        }

        private static void PopulateExampleMap(ref Gears.Cartography.Map map)
        {
            map.VERSION = "0.1.5";

            map.BGM_FILE_LOC = "BGM_FILE_LOC DIRECTORY test";
            map.FADE_IN_FILE_LOC = "FADE_IN_FILE_LOC DIRECTORY test";
            map.FADE_OUT_FILE_LOC = "FADE_OUT_FILE_LOC DIRECTORY test";
            map.BG_IMAGE_FILE_LOC = "BG_IMAGE_FILE_LOC DIRECTORY test";

            map.NUM_LAYERS = 5;
예제 #2
0
        private static void PopulateExampleMap(ref Gears.Cartography.Map map)
        {
            map.VERSION = "0.1.5";

            map.BGM_FILE_LOC = "BGM_FILE_LOC DIRECTORY test";
            map.FADE_IN_FILE_LOC = "FADE_IN_FILE_LOC DIRECTORY test";
            map.FADE_OUT_FILE_LOC = "FADE_OUT_FILE_LOC DIRECTORY test";
            map.BG_IMAGE_FILE_LOC = "BG_IMAGE_FILE_LOC DIRECTORY test";

            map.NUM_LAYERS = 5;
            map.LAYER_WIDTH_TILES = 80;
            map.LAYER_HEIGHT_TILES = 35;
            map.TILE_DATA = "453tgfd,346tw,4e5trfr5,34tegdr,45tr";
        }
예제 #3
0
 public void DebugSerialize(string SAVE_LOCATION)
 {
     map0 = new Map();
     PopulateFields();
     SerializeToXML(map0, SAVE_LOCATION);
 }
예제 #4
0
 private static void SerializeToXML(Map map, string SAVE_LOCATION)
 {
     using (TextWriter textWriter = new StreamWriter(SAVE_LOCATION))
     {
         XmlSerializer serializer = new XmlSerializer(typeof(Map));
         serializer.Serialize(textWriter, map);
         textWriter.Close();
     }
 }
예제 #5
0
        //ASSIGNMENTS ARE FOR TESTING PURPOSES ONLY!!!
        protected Map(Map copyMe)
        {
            VERSION = copyMe.VERSION;
            BGM_FILE_LOC = copyMe.BGM_FILE_LOC;
            FADE_IN_FILE_LOC = copyMe.FADE_IN_FILE_LOC;
            FADE_OUT_FILE_LOC = copyMe.FADE_OUT_FILE_LOC;
            BG_IMAGE_FILE_LOC = copyMe.BG_IMAGE_FILE_LOC;
            NUM_LAYERS = copyMe.NUM_LAYERS;
            LAYER_WIDTH_TILES = copyMe.LAYER_WIDTH_TILES;
            LAYER_HEIGHT_TILES = copyMe.LAYER_HEIGHT_TILES;
            LAYERS = new layer[copyMe.LAYERS.Length];

            for (int i = 0; i < LAYERS.Length; i++)
                LAYERS[i] = copyMe.LAYERS[i];
        }