Exemplo n.º 1
0
        //kontruktor, játékosok, pakli inicializálása
        public Dealer(int gameMode)
        {
            Structures.IComputer cmp = null;

            switch (gameMode)
            {
                case 1: cmp =  new Computer.ComputerRandom();
                    break;
                case 2: cmp = new Computer.ComputerCallingStation();
                    break;
            }

            Player.Player player_ = new Player.Player(startingStack);

            int[] deck = new int[52];

            for (int i = 0; i < deck.Length; i++)
            {
                deck[i] = i;
            }

            this.Deck = deck;
            this.player = player_;
            this.computer = cmp;
            this.computer.CreateComputer(startingStack, bigBlindValue);
        }
Exemplo n.º 2
0
        //kontruktor, játékosok, pakli inicializálása
        public Simulate(int computer1, int computer2)
        {
            int[] deck = new int[52];

            Structures.IComputer comp1 = null;
            Structures.IComputer comp2 = null;

            switch (computer1)
            {
                case 1: comp1 = new Computer.CFold();
                    break;
                case 2: comp1 = new Computer.CCheckFold();
                    break;
                case 3: comp1 = new Computer.C1BetCall();
                    break;
                case 4: comp1 = new Computer.CCheckCall();
                    break;
            }

            switch (computer2)
            {
                case 1: comp2 = new Computer.CFold();
                    break;
                case 2: comp2 = new Computer.CCheckFold();
                    break;
                case 3: comp2 = new Computer.C1BetCall();
                    break;
                case 4: comp2 = new Computer.CCheckCall();
                    break;
            }

            for (int i = 0; i < deck.Length; i++)
            {
                deck[i] = i;
            }

            this.Deck = deck;
            this.computer1 = comp1;
            this.computer2 = comp2;
            this.computer1.CreateComputer(startingStack, bigBlindValue);
            this.computer2.CreateComputer(startingStack, bigBlindValue);
        }