diff --git a/src/Parser.cs b/src/Parser.cs index e60ce59..7b8d830 100644 --- a/src/Parser.cs +++ b/src/Parser.cs @@ -213,7 +213,7 @@ namespace WorldOfPeacecraft //TODO -> Samed int id = challengeBlock.GetIntValue("id"); String type; - switch (challengeBlock.GetType().ToString()) + switch (challengeBlock.GetStringValue()) { case "DRAGON": type = "Dragon"; @@ -226,6 +226,7 @@ namespace WorldOfPeacecraft break; } bool accepted = challengeBlock.GetBoolValue("accepted"); + //Challenge c = new Challenge(id, type, accepted); //CHALLENGE: "begin:challenge","id:",INT,"type:",("DRAGON"|"STAGHUNT"|"SKIRMISH"),"accepted:",BOOLEAN,"end:challenge" } @@ -277,6 +278,7 @@ namespace WorldOfPeacecraft string desc = dragonBlock.GetStringValue("desc"); int x = dragonBlock.GetIntValue("x"); int y = dragonBlock.GetIntValue("y"); + //Dragon d p = new Dragon(id, busy, desc, x, y); //DRAGON: "begin:dragon", "id:",INT,"type:Dragon","busy:"BOOLEAN,"desc:"STRING,"x:",INT,"y:",INT,"end:dragon" }