Exemple #1
0
 private void FightSpider(IDynamicObject spider)
 {
     if (spider.DeBuff == DeBuff.Cocoon)
     {
         agilityProgress = 0;
         Strength       += 2;
         Agility++;
         spider.SetState(State.Dead);
         BoardFunctions.ClearDynamicObjectOnTile(spider.X, spider.Y);
         ProducerConsumer.Produce(String.Format("Spider number {0} ate another spider with id {1}", Id, spider.Id));
     }
     else if (Agility > spider.Agility)
     {
         spider.DeBuff = DeBuff.Cocoon;
         ProducerConsumer.Produce(String.Format("Spider number {0} became a cocoone", spider.Id));
     }
 }