//initializing player public Player(string n,int i,Deck d) { name = n; pile = new List<Card>(d.CardDeck.Count/2); for(int c=0 ; c < d.CardDeck.Count/2 ; i++,c++) //creating player's deck { pile.Add(d.CardDeck[i]); } }
private void SetupDialogue() { int Nplayer; Console.Write("How many deck? :"); try { Nplayer = Convert.ToInt32(Console.ReadLine()); } catch(Exception e) { Nplayer = 1; } cardDeck = new Deck(Nplayer); }