using System; using System.Collections.Generic; using System.Linq; using System.Text; using Frontend; using WorldOfPeacecraft; using System.Threading; namespace inf3 { public class ParserTest { static void Main() { Parser p = new Parser(); p.AddToBuffer("begin:5"); //Console.WriteLine(p.getBuffer().Dequeue()); p.AddToBuffer("begin:upd"); p.AddToBuffer("begin:player"); p.AddToBuffer("id:3"); p.AddToBuffer("typ:Player"); p.AddToBuffer("busy:false"); p.AddToBuffer("desc:Player3"); p.AddToBuffer("x:3"); p.AddToBuffer("y:15"); p.AddToBuffer("points:0"); p.AddToBuffer("end:player"); p.AddToBuffer("end:upd"); p.AddToBuffer("end:5"); /* p.AddToBuffer("begin:24"); p.AddToBuffer("begin:players"); p.AddToBuffer("begin:player"); p.AddToBuffer("id:3"); p.AddToBuffer("typ:Player"); p.AddToBuffer("busy:false"); p.AddToBuffer("desc:Player3"); p.AddToBuffer("x:3"); p.AddToBuffer("y:15"); p.AddToBuffer("pnts:0"); p.AddToBuffer("end:player"); p.AddToBuffer("begin:player"); p.AddToBuffer("id:6"); p.AddToBuffer("typ:Player"); p.AddToBuffer("busy:false"); p.AddToBuffer("desc:Player6"); p.AddToBuffer("x:17"); p.AddToBuffer("y:13"); p.AddToBuffer("pnts:0"); p.AddToBuffer("end:player"); p.AddToBuffer("end:players"); p.AddToBuffer("end:24"); */ /*begin:14 begin:map width:5 height:5 begin:cells begin:cell row:0 col:0 begin:props WALL end:props end:cell begin:cell row:0 col:1 begin:props WALL end:props end:cell begin:cell row:0 col:2 begin:props WALL end:props end:cell begin:cell row:0 col:3 begin:props WALL end:props end:cell begin:cell row:0 col:4 begin:props WALL end:props end:cell begin:cell row:1 col:0 begin:props WALL end:props end:cell begin:cell row:1 col:1 begin:props WALKABLE end:props end:cell begin:cell row:1 col:2 begin:props FOREST WALKABLE end:props end:cell begin:cell row:1 col:3 begin:props FOREST WALKABLE end:props end:cell begin:cell row:1 col:4 begin:props FOREST WALKABLE end:props end:cell begin:cell row:2 col:0 begin:props WALL end:props end:cell begin:cell row:2 col:1 begin:props WALKABLE end:props end:cell begin:cell row:2 col:2 begin:props FOREST WALKABLE end:props end:cell begin:cell row:2 col:3 begin:props FOREST WALKABLE end:props end:cell begin:cell row:2 col:4 begin:props FOREST WALKABLE end:props end:cell begin:cell row:3 col:0 begin:props WALL end:props end:cell begin:cell row:3 col:1 begin:props WALKABLE end:props end:cell begin:cell row:3 col:2 begin:props FOREST WALKABLE end:props end:cell begin:cell row:3 col:3 begin:props WALL end:props end:cell begin:cell row:3 col:4 begin:props WALL end:props end:cell begin:cell row:4 col:0 begin:props WALL end:props end:cell begin:cell row:4 col:1 begin:props WALKABLE end:props end:cell begin:cell row:4 col:2 begin:props FOREST WALKABLE end:props end:cell begin:cell row:4 col:3 begin:props FOREST WALKABLE end:props end:cell begin:cell row:4 col:4 begin:props FOREST WALKABLE end:props end:cell */ Thread.Sleep(1000); Console.WriteLine(p.getDummyPlayer()); Console.ReadLine(); } } }