Exemplo n.º 1
0
        public void Init(string startLevel, string[] levelScenes)
        {
            Walls   = new List <Tile>();
            Enemies = new List <Enemy>();
            Bullets = new List <Bullet>();

            Grid = new Grid(Screen.Width, Screen.Height, 30, 20);
            Walls.Add(new Tile(0, 0, Grid.numTileWidth, Grid.numTileHeight, 3));

            levels            = levelScenes;
            nextLevelPend     = false;
            win               = false;
            currentLevelIndex = Array.IndexOf(levelScenes, startLevel);
            Scene.SetUpSceneLevel(startLevel);
            playerDeath = false;

            sw = new Stopwatch();
            sw.Start();

            Pathmanager = new Pathmaster();
        }
Exemplo n.º 2
0
 public Pathmaster()
 {
     instance    = this;
     pathfinding = new Pathfinder();
 }