Beispiel #1
0
 /// <summary>
 /// Resolves the Night Visit Event
 /// </summary>
 /// <param name="game">The GameState</param>
 /// <param name="logic">The artificial intelligence component</param>
 private static void PlayNightVisit(GameState game, DecisionMaker logic)
 {
     Console.WriteLine("Dracula is playing Night Visit");
     if (HunterPlayingGoodLuckToCancelDraculaEvent(game, Event.NightVisit, Event.NightVisit, logic) > 0)
     {
         Console.WriteLine("Night Visit cancelled");
         return;
     }
     var bittenHunters = new List<HunterPlayer>();
     foreach (var h in game.Hunters)
     {
         if (h != null && h.BiteCount > 0)
         {
             bittenHunters.Add(h);
         }
     }
     var victim = logic.ChooseNightVisitVictim(bittenHunters);
     Console.WriteLine("{0} is visited in the night and loses 2 health", victim.Hunter.Name());
     victim.AdjustHealth(-2);
     CheckForHunterDeath(game);
 }