public void Hit(Wall wall, CompositeExplosion compositeExplosion) { if (wall.isDestroyable()) { MapManagerStub MapManagerStub = new MapManagerStub(); MapManagerStub.CreateExplosion(wall.Coordinates, wall, compositeExplosion); } }
public void CreateExplosion(Coordinates cord, Wall wall, CompositeExplosion compositeExplosion) { Explosion explosion = new Explosion(cord, wall); Map map = Map.GetInstance; map.AddMapObj(explosion); compositeExplosion.AddChildren(explosion); }
public void Explode(CompositeExplosion compositeExplosion) { if (exploded == false) { player.DecreasePlacedBombCount(); exploded = true; compositeExplosion.AddChildren(explosionFacade.Explode(this)); } }
public void accept(IVisitor visitor, CompositeExplosion composite) { visitor.visit(this); }
public void Hit(Bomb bomb, CompositeExplosion compositeExplosion) { bomb.Explode(compositeExplosion); }
public void visit(Wall wall, CompositeExplosion composite) { WallHitAdapter wallHitAdapter = new WallHitAdapter(); wallHitAdapter.Hit(wall, composite); }
public void visit(Bomb bomb, CompositeExplosion composite) { BombHitAdapter bombHitAdapter = new BombHitAdapter(); bombHitAdapter.Hit(bomb, composite); }