X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=tools%2Ftilemanager%2FTileSet.cs;h=0718760989559a1df3f0ada99562a1040cdfe497;hb=89634be9afb1e7886af06659d733b60f365b9309;hp=831ee96d35dcfb6c5d260f704b29d49784556856;hpb=6085c7c802719571bab55ca749c67674b835ddfd;p=supertux.git diff --git a/tools/tilemanager/TileSet.cs b/tools/tilemanager/TileSet.cs index 831ee96d3..071876098 100644 --- a/tools/tilemanager/TileSet.cs +++ b/tools/tilemanager/TileSet.cs @@ -44,6 +44,15 @@ public class TileGroup { } public class TileSet { + private bool tooNew = false; + + /// Whether version of tileset file is too new + public bool TooNew { + get { + return tooNew; + } + } + public ArrayList Tiles = new ArrayList(); public ArrayList TileGroups = new ArrayList(); @@ -90,6 +99,7 @@ public class TileSet { } public void ParseTiles(Lisp.Parser parser) { + tooNew = false; int d = parser.Depth; while(parser.Parse() && parser.Depth >= d) { if(parser.Depth == d && parser.Type != Parser.LispType.START_LIST) { @@ -118,7 +128,15 @@ public class TileSet { Tiles.Add(null); Tiles[tile.ID] = tile; break; - default: + case "tiles": + SkipList(parser); + tooNew = true; + Console.WriteLine( + "Warning: new syntax of \"More tiles in one image\" file isn't currently supported"); + Console.WriteLine( + "And this means: YOU WON'T BE ABLE TO SAVE YOUR CHANGES !!!"); + break; + default: throw new Exception("Unexpected listentry: " + parser.SymbolValue); }