private string DisplayLoss(Choice choiceOne, Choice choiceTwo) { string output; Rules rule = new Rules(choiceTwo, choiceOne); output = rule.DisplayWinner(); return output + "\nPlayer 2 wins!"; }
public Game() { rules = new Rules(); }
public static Moves[] DefeatedBy(this Moves move) => Rules .Where(r => r.LosingMove == move) .Select(r => r.WinningMove) .ToArray();
public static bool Defeats(this Moves move, Moves otherMove) => Rules.Exists(r => r.WinningMove == move && r.LosingMove == otherMove);