public IPokerCommand TakeAction(Table data, Func<bool> stopIndicator) { var command = System.Console.ReadLine(); var words = command.Split(' ').ToList(); switch (words[0]) { case "call": return new CallCommand(); case "fold": return new FoldCommand(); case "raise": return new RaiseCommand(int.Parse(words[1])); case "check": return new CheckCommand(); default: return new FoldCommand(); } }
public IPokerCommand TakeAction(Table data, Func<bool> stopIndicator) { return new CallCommand(); }
public IPokerCommand TakeAction(Table data, Func<bool> stopIndicator) { return playerController.TakeAction(data, stopIndicator); }
public IPokerCommand TakeAction(Table data, Func<bool> stopIndicator) { listener = null; while (listener == null) { if (stopIndicator()) { return new FoldCommand(); } } return listener; }