public static IAIPlayer CreateAI( IAILogicProvider logicProvider, string name, int chips, Label statusLabel, TextBox chipsTextBox, AnchorStyles cardHoldersPictureBoxesAnchorStyles, int cardHoldersPictureBoxesX, int cardHoldersPictureBoxesY) { IList <PictureBox> cardHolders = GetCardHoldersPictureBoxes(cardHoldersPictureBoxesAnchorStyles, cardHoldersPictureBoxesX, cardHoldersPictureBoxesY); Panel panel = GetPlayerPanel(cardHolders); chipsTextBox.Enabled = false; return(new AI( currentPlayerId, name, statusLabel, chipsTextBox, chips, cardHolders, panel, logicProvider)); }
public static IAIPlayer CreateAI( IAILogicProvider logicProvider, string name, int chips, Label statusLabel, TextBox chipsTextBox, AnchorStyles cardHoldersPictureBoxesAnchorStyles, int cardHoldersPictureBoxesX, int cardHoldersPictureBoxesY) { IList<PictureBox> cardHolders = GetCardHoldersPictureBoxes(cardHoldersPictureBoxesAnchorStyles, cardHoldersPictureBoxesX, cardHoldersPictureBoxesY); Panel panel = GetPlayerPanel(cardHolders); chipsTextBox.Enabled = false; return new AI( currentPlayerId, name, statusLabel, chipsTextBox, chips, cardHolders, panel, logicProvider); }
public AI( int id, string name, Label statusLabel, TextBox chipsTextBoxTextBox, int chips, IList<PictureBox> pictureBoxHolder, Panel panel, IAILogicProvider logicProvider) : base(id, name, statusLabel, chipsTextBoxTextBox, chips, pictureBoxHolder, panel) { this.aiLogicProvider = logicProvider; }
public AI( int id, string name, Label statusLabel, TextBox chipsTextBoxTextBox, int chips, IList <PictureBox> pictureBoxHolder, Panel panel, IAILogicProvider logicProvider) : base(id, name, statusLabel, chipsTextBoxTextBox, chips, pictureBoxHolder, panel) { this.aiLogicProvider = logicProvider; }
private ICollection <IAIPlayer> GetEnemies(IAILogicProvider logicProvider) { IAIPlayer AI1 = PlayerFactory.CreateAI(logicProvider, AppSettigns.SecondPlayerName, AppSettigns.DefaultChipsCount, this.labelBot1Status, this.textboxBot1Chips, AppSettigns.SecondPlayerAnchorStyles, AppSettigns.SecondPlayerPictureBoxX, AppSettigns.SecondPlayerPictureBoxY); IAIPlayer AI2 = PlayerFactory.CreateAI(logicProvider, AppSettigns.ThirdPlayerName, AppSettigns.DefaultChipsCount, this.labelBot2Status, this.textboxBot2Chips, AppSettigns.ThirdPlayerAnchorStyles, AppSettigns.ThirdPlayerPictureBoxX, AppSettigns.ThirdPlayerPictureBoxY); IAIPlayer AI3 = PlayerFactory.CreateAI(logicProvider, AppSettigns.FourthPlayerName, AppSettigns.DefaultChipsCount, this.labelBot3Status, this.textboxBot3Chips, AppSettigns.FourthPlayerAnchorStyles, AppSettigns.FourthPlayerPictureBoxX, AppSettigns.FourthPlayerPictureBoxY); IAIPlayer AI4 = PlayerFactory.CreateAI(logicProvider, AppSettigns.FifthPlayerName, AppSettigns.DefaultChipsCount, this.labelBot4Status, this.textboxBot4Chips, AppSettigns.FifthPlayerAnchorStyles, AppSettigns.FifthPlayerPictureBoxX, AppSettigns.FifthPlayerPictureBoxY); IAIPlayer AI5 = PlayerFactory.CreateAI(logicProvider, AppSettigns.SixthPlayerName, AppSettigns.DefaultChipsCount, this.labelBot5Status, this.textboxBot5Chips, AppSettigns.SixthPlayerAnchorStyles, AppSettigns.SixthPlayerPictureBoxX, AppSettigns.SixthPlayerPictureBoxY); ICollection <IAIPlayer> enemies = new List <IAIPlayer>() { AI1, AI2, AI3, AI4, AI5 }; foreach (var enemy in enemies) { this.AddPlayerUIComponents(enemy); } return(enemies); }
private ICollection<IAIPlayer> GetEnemies(IAILogicProvider logicProvider) { IAIPlayer AI1 = PlayerFactory.CreateAI(logicProvider, AppSettigns.SecondPlayerName, AppSettigns.DefaultChipsCount, this.labelBot1Status, this.textboxBot1Chips, AppSettigns.SecondPlayerAnchorStyles, AppSettigns.SecondPlayerPictureBoxX, AppSettigns.SecondPlayerPictureBoxY); IAIPlayer AI2 = PlayerFactory.CreateAI(logicProvider, AppSettigns.ThirdPlayerName, AppSettigns.DefaultChipsCount, this.labelBot2Status, this.textboxBot2Chips, AppSettigns.ThirdPlayerAnchorStyles, AppSettigns.ThirdPlayerPictureBoxX, AppSettigns.ThirdPlayerPictureBoxY); IAIPlayer AI3 = PlayerFactory.CreateAI(logicProvider, AppSettigns.FourthPlayerName, AppSettigns.DefaultChipsCount, this.labelBot3Status, this.textboxBot3Chips, AppSettigns.FourthPlayerAnchorStyles, AppSettigns.FourthPlayerPictureBoxX, AppSettigns.FourthPlayerPictureBoxY); IAIPlayer AI4 = PlayerFactory.CreateAI(logicProvider, AppSettigns.FifthPlayerName, AppSettigns.DefaultChipsCount, this.labelBot4Status, this.textboxBot4Chips, AppSettigns.FifthPlayerAnchorStyles, AppSettigns.FifthPlayerPictureBoxX, AppSettigns.FifthPlayerPictureBoxY); IAIPlayer AI5 = PlayerFactory.CreateAI(logicProvider, AppSettigns.SixthPlayerName, AppSettigns.DefaultChipsCount, this.labelBot5Status, this.textboxBot5Chips, AppSettigns.SixthPlayerAnchorStyles, AppSettigns.SixthPlayerPictureBoxX, AppSettigns.SixthPlayerPictureBoxY); ICollection<IAIPlayer> enemies = new List<IAIPlayer>() { AI1, AI2, AI3, AI4, AI5 }; foreach (var enemy in enemies) { this.AddPlayerUIComponents(enemy); } return enemies; }