public override void VisitShieldBrick(ShieldBrick m)
        {
            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            pColPair.SetCollision(this, m);
            pColPair.NotifyListeners();
        }
        public override void VisitMissile(Missile m)
        {
            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            pColPair.SetCollision(m, this);
            pColPair.NotifyListeners();
        }
        public override void VisitBomb(Bomb b)
        {
            //Debug.WriteLine(" ---> Done");
            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            pColPair.SetCollision(b, this);
            pColPair.NotifyListeners();
        }
 public override void VisitMissile(Missile m)
 {
     if (m.bMarkForDeath == false)
     {
         CollisionPair pColPair = CollisionPairManager.GetActiveColPair();
         pColPair.SetCollision(m, this);
         pColPair.NotifyListeners();
     }
 }
        public override void VisitShip(Ship m)
        {
            // Missile vs WallTop
            //Debug.WriteLine(" ---> Done");
            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            pColPair.SetCollision(m, this);
            pColPair.NotifyListeners();
        }
Exemplo n.º 6
0
        public override void VisitFlyingSaucer(FlyingSaucer fs)
        {
            // Notify Observers
            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            Debug.Assert(pColPair != null);
            pColPair.SetCollision(fs, this);
            pColPair.NotifyListeners();
        }
Exemplo n.º 7
0
 public override void VisitMissile(Missile m)
 {
     if (this.bMarkForDeath == false && m.bMarkForDeath == false)// to fix bug with collision with null objs
     {
         CollisionPair pColPair = CollisionPairManager.GetActiveColPair();
         pColPair.SetCollision(m, this);
         pColPair.NotifyListeners();
     }
 }
        public override void VisitGroup(AlienGrid a)
        {
            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            Debug.Assert(pColPair != null);

            pColPair.SetCollision(a, this);
            pColPair.NotifyListeners();
        }
Exemplo n.º 9
0
        // TODO Remove - Shouldn't need this one for TopWall
        public override void VisitMissile(Missile m)
        {
            // Missile vs TopWall
            //       Debug.WriteLine("collide: {0} with {1}", this, a);

            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            Debug.Assert(pColPair != null);
            pColPair.SetCollision(this, m);
            pColPair.NotifyListeners();
        }
Exemplo n.º 10
0
 public override void VisitBomb(Bomb b)
 {
     if (this.bMarkForDeath == false)// to fix bug with collision with null objs
     {
         // Bomb vs ShieldBrick
         //Debug.WriteLine(" ---> Done");
         CollisionPair pColPair = CollisionPairManager.GetActiveColPair();
         pColPair.SetCollision(b, this);
         pColPair.NotifyListeners();
     }
 }
Exemplo n.º 11
0
        public override void VisitFlyingSaucer(FlyingSaucer fs)
        {
            // Debug.WriteLine("collide: {0} with {1}", a, this);

            // FlyingSaucer vs Wall
            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            Debug.Assert(pColPair != null);
            pColPair.SetCollision(fs, this);
            pColPair.NotifyListeners();
        }
Exemplo n.º 12
0
        public override void VisitBomb(Bomb b)
        {
            // Debug.WriteLine("collide: {0} with {1}", a, this);

            // Bomb vs CoreCannon
            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            Debug.Assert(pColPair != null);
            pColPair.SetCollision(b, this);
            pColPair.NotifyListeners();
        }
Exemplo n.º 13
0
        public override void VisitCoreCannon(CoreCannon cc)
        {
            // CoreCannon vs RightBumper
            // Debug.WriteLine("collide: {0} with {1}", this, a);

            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            Debug.Assert(pColPair != null);
            pColPair.SetCollision(cc, this);
            pColPair.NotifyListeners();
        }
Exemplo n.º 14
0
        public override void VisitAlienGrid(AlienGrid a)
        {
            // AlienGrid vs LeftWall
            // Debug.WriteLine("collide: {0} with {1}", this, a);

            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            Debug.Assert(pColPair != null);
            pColPair.SetCollision(a, this);
            pColPair.NotifyListeners();
        }
Exemplo n.º 15
0
        public override void VisitBomb(Bomb b)
        {
            // Bomb vs Missile

            // Notify Observers
            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            Debug.Assert(pColPair != null);
            pColPair.SetCollision(this, b);
            pColPair.NotifyListeners();
        }
Exemplo n.º 16
0
        public override void VisitBottomWall(BottomWall w)
        {
            //ShieldBrick vs Bomb
            //Debug.WriteLine("         collide:  {0} <-> {1}", w.GetName(), this.name);

            // Notify Observers
            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            Debug.Assert(pColPair != null);
            pColPair.SetCollision(w, this);
            pColPair.NotifyListeners();
        }
Exemplo n.º 17
0
        public override void VisitShieldBrick(ShieldBrick sb)
        {
            //ShieldBrick vs Missile
            //Debug.WriteLine("         collide:  {0} <-> {1}", sb.GetName(), this.name);

            // Notify Observers
            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            Debug.Assert(pColPair != null);
            pColPair.SetCollision(sb, this);
            pColPair.NotifyListeners();
        }
Exemplo n.º 18
0
        public override void VisitAlien(Alien a)
        {
            //Alien vs Missile
            //Debug.WriteLine("         collide:  {0} <-> {1}", a.GetName(), this.name);

            // Notify Observers
            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            Debug.Assert(pColPair != null);
            pColPair.SetCollision(a, this);
            pColPair.NotifyListeners();
        }
        public override void VisitGroup(AlienGrid a)
        {
            // AlienGroup vs WallRight
            //Debug.WriteLine("\ncollide: {0} with {1}", this, a);
            //Debug.WriteLine("               --->DONE<----");

            CollisionPair pColPair = CollisionPairManager.GetActiveColPair();

            Debug.Assert(pColPair != null);

            pColPair.SetCollision(a, this);
            pColPair.NotifyListeners();
        }