public void TakeOffComputer(int deck) { if (BasicData.Client == true) { return; } if (SaveRoot !.ComputerList.ObjectExist(deck) == false) { return; } SaveRoot.ComputerList.RemoveObjectByDeck(deck); }
private void AddComputer(int deck) { if (BasicData.Client == true) { return; //host does computer. } if (SaveRoot !.ComputerList.ObjectExist(deck) == false) { SimpleDominoInfo thisDomino = _model.DominosList !.GetSpecificItem(deck); SaveRoot.ComputerList.Add(thisDomino); } }
private void AddComputer(DeckRegularDict <RegularSimpleCard> thisCol) { if (PlayerList.Any(items => items.PlayerCategory == EnumPlayerCategory.Computer) == false) { return; } thisCol.ForEach(thisCard => { if (SaveRoot !.ComputerList.ObjectExist(thisCard.Deck) == false) { SaveRoot.ComputerList.Add(thisCard); } }); }
private void RemoveComputer(DeckRegularDict <RegularSimpleCard> ThisCol) { if (PlayerList.Any(items => items.PlayerCategory == EnumPlayerCategory.Computer) == false) { return; } ThisCol.ForEach(thisCard => { if (SaveRoot !.ComputerList.ObjectExist(thisCard.Deck) == true) { SaveRoot.ComputerList.RemoveObjectByDeck(thisCard.Deck); } }); }