Exemplo n.º 1
0
 public Archerman(IWeapon weapon, IRefillBehavior refillBehavior, IRepairBehavior repairBehavior)
     : base(weapon, refillBehavior, repairBehavior)
 {
     this.hitPoints = 20;
     Console.WriteLine("Archerman created.");
 }
Exemplo n.º 2
0
 public Paladin(IWeapon weapon, IRefillBehavior refillBehavior, IRepairBehavior repairBehavior)
     : base(weapon, refillBehavior, repairBehavior)
 {
     this.hitPoints = 80;
     Console.WriteLine("Paladin created.");
 }
Exemplo n.º 3
0
 public void ChangeRefill(IRefillBehavior refillBehavior)
 {
     this.refillBehavior = refillBehavior;
 }
Exemplo n.º 4
0
 public Robot(IWeapon weapon, IRefillBehavior refillBehavior, IRepairBehavior repairBehavior)
     : base(weapon, refillBehavior, repairBehavior)
 {
     this.hitPoints = 150;
     Console.WriteLine("Robot created.");
 }
Exemplo n.º 5
0
 public Soldier(IWeapon weapon, IRefillBehavior refillBehavior, IRepairBehavior repairBehavior)
 {
     this.weapon         = weapon;
     this.repairBehavior = repairBehavior;
     this.refillBehavior = refillBehavior;
 }