static Gameplay() { using (Stream stream = Util.ReadResourceStream("Resources.Gameplay0.png")) { TileSet = new Bitmap(stream); } ParseItems(); foreground = new AutoTiler(Util.ReadResource("Resources.ForegroundTiles.xml")); background = new AutoTiler(Util.ReadResource("Resources.BackgroundTiles.xml")); }
private TileGrid GenerateLevelTiles(MapElement level, string objects, int width, int height, AutoTiler tiler, out VirtualMap <char> map) { MapElement tileData = level.SelectFirst(objects); map = ReadMapChar(tileData == null ? string.Empty : tileData.Attr("InnerText"), width, height); return(tiler.GenerateMap(map, true)); }