public void Notify(Match match) { Player opp = match.GetOpponent(this); if (match.GetResult(opp.GetName()) == PlayResult.Defect) { playersWhoDefected.Add(opp.GetName()); } }
public void Notify(Match match) { Player opp = match.GetOpponent(this); if (playerLastAction.ContainsKey(opp.GetName())) { playerLastAction[opp.GetName()] = match.GetResult(opp.GetName()); } else { playerLastAction.Add(opp.GetName(), match.GetResult(opp.GetName())); } }
public void Notify(Match match) { Player opp = match.GetOpponent(this); lastResult[opp.GetName()] = match.GetResult(opp.GetName()); }