Exemple #1
0
        static void Main(string[] args)
        {
            Player player1 = new Player();

            player1.Name = "Bob";


            Player player2 = new Player();

            player2.Name = "Sue";
            player2.Play(player1);
            Console.WriteLine("-------------------");


            Player player3 = new Player();

            player3.Name = "Wilma";
            player3.Play(player2);
            Console.WriteLine("-------------------");


            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";
            large.Play(player3);
            Console.WriteLine("-------------------");


            SmackTalkingPlayer player5 = new SmackTalkingPlayer();

            player5.Name = "Fred";
            player5.Play(large);
            Console.WriteLine("-------------------");


            OneHigherPlayer player6 = new OneHigherPlayer();

            player6.Name = "Geroge";
            player6.Play(player5);
            Console.WriteLine("-------------------");


            HumanPlayer player7 = new HumanPlayer();

            player7.Name = "Taylor";
            player7.Play(player6);
            Console.WriteLine("-------------------");



            List <Player> players = new List <Player>()
            {
                player1, player2, player3, large, player5, player6, player7
            };

            PlayMany(players);
        }
Exemple #2
0
        static void Main(string[] args)
        {
            Player player1 = new Player();

            player1.Name = "Bob";

            Player player2 = new Player();

            player2.Name = "Sue";

            SmackTalkingPlayer smackTalker = new SmackTalkingPlayer();

            smackTalker.Name = "Joe";

            OneHigherPlayer higherRoller = new OneHigherPlayer();

            higherRoller.Name = "Cheater";

            HumanPlayer human = new HumanPlayer();

            human.Name = "Ryan";

            CreativeSmackTalkingPlayer haha = new CreativeSmackTalkingPlayer();

            haha.Name = "Ronald";

            SoreLoserPlayer madchad = new SoreLoserPlayer();

            madchad.Name = "Chad";

            Player player3 = new Player();

            player3.Name = "Wilma";


            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            UpperHalfPlayer lucky = new UpperHalfPlayer();

            lucky.Name = "Lucy";

            SoreLoserUpperHalfPlayer sorecheater = new SoreLoserUpperHalfPlayer();

            sorecheater.Name = "Walter";

            List <Player> players = new List <Player>()
            {
                player1, player2, player3, large, smackTalker, higherRoller, haha, madchad, sorecheater, lucky
            };

            PlayMany(players);
        }
Exemple #3
0
        static void Main(string[] args)
        {
            Player player1 = new CreativeSmackTalkingPlayer();

            player1.Name = "Bob";

            Player player2 = new HumanPlayer();

            player2.Name = "Sue";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            Player player3 = new OneHigherPlayer();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            Player player4 = new SoreLoserPlayer();

            player4.Name = "Chad";

            Player player5 = new UpperHalfPlayer();

            player5.Name = "Steve";

            Player player6 = new SoreLoserUpperHalfPlayer();

            player6.Name = "Jeff";

            player4.Play(player1);
            player5.Play(player2);
            player6.Play(player2);

            List <Player> players = new List <Player>()
            {
                player1, player2, player3, player4, player5, player6, large
            };

            PlayMany(players);
        }
Exemple #4
0
        static void Main(string[] args)
        {
            Player player1 = new Player();

            player1.Name = "Bob";

            Player player2 = new Player();

            player2.Name = "Sue";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            Player player3 = new Player();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            Player player4 = new SmackTalkingPlayer();

            player4.Name = "Geena Davis";

            player4.Play(player1);

            Console.WriteLine("-------------------");

            Player player5 = new OneHigherPlayer();

            player5.Name = "Madonna in A League of Their Own";

            player5.Play(player4);

            Console.WriteLine("-------------------");

            List <Player> players = new List <Player>()
            {
                player1, player2, player3, large, player4, player5
            };

            PlayMany(players);
        }
Exemple #5
0
        static void Main(string[] args)
        {
            Player player0 = new CreativeSmackTalkingPlayer();

            player0.Name = "Smack Talk Jimmy";

            Player player4 = new SoreLoserPlayer();

            player4.Name = "Karen";

            Player player5 = new SoreLoserPlayer();

            player4.Name = "Karen";


            Player player1 = new SmackTalkingPlayer();

            player1.Name = "Bob";

            Player player2 = new OneHigherPlayer();

            player2.Name = "Sue";



            Player player3 = new HumanPlayer();

            player3.Name = "Wilma";


            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";



            List <Player> players = new List <Player>()
            {
                player5, player4, player0, player1, player2, player3, large
            };

            PlayMany(players);
        }
Exemple #6
0
        static void Main(string[] args)
        {
            SmackTalkingPlayer player1 = new SmackTalkingPlayer();

            player1.Name = "Bob";

            OneHigherPlayer player2 = new OneHigherPlayer();

            player2.Name = "Sue";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            HumanPlayer player3 = new HumanPlayer();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            CreativeSmackTalkingPlayer player4 = new CreativeSmackTalkingPlayer();

            player4.Name = "Sir Quipsalot";

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player4.Play(large);

            Console.WriteLine("-------------------");

            List <Player> players = new List <Player>()
            {
                player1, player2, player3, large
            };

            PlayMany(players);
        }
Exemple #7
0
        static void Main(string[] args)
        {
            Player player1 = new Player();

            player1.Name = "Bob";
            player1.Taunt();

            Player player2 = new OneHigherPlayer();

            player2.Name = "Sue";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            Player player3 = new Player();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            List <Player> players = new List <Player>()
            {
                player1,
                player2,
                player3,
                large
            };

            PlayMany(players);
        }
        static void Main(string[] args)
        {
            SmackTalkingPlayer smack = new SmackTalkingPlayer();

            smack.Name = "Silky Johnson";

            OneHigherPlayer oneHigher = new OneHigherPlayer();

            oneHigher.Name = "OneUp Willy";

            HumanPlayer hooman = new HumanPlayer();

            hooman.Name = "I is Hooman";

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            SmackTalker insult = new SmackTalker();

            insult.Name = "Dan Berry";

            smack.Play(oneHigher);
            Console.WriteLine("-------------------");
            insult.Play(smack);
            Console.WriteLine("-------------------");
            oneHigher.Play(insult);
            Console.WriteLine("-------------------");
            large.Play(oneHigher);
            Console.WriteLine("-------------------");

            List <Player> players = new List <Player>()
            {
                smack, oneHigher, hooman, large
            };

            // PlayMany(players);
        }
Exemple #9
0
        static void Main(string[] args)
        {
            Player player1 = new Player();

            player1.Name = "Bob";

            Player player2 = new Player();

            player2.Name = "Sue";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            Player player3 = new Player();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            SmackTalkingPlayer mackthesmack = new SmackTalkingPlayer();

            mackthesmack.Name  = "Mack";
            mackthesmack.Taunt = "You're a loser who always loses.";

            mackthesmack.Play(player2);
            Console.WriteLine("-------------------");

            OneHigherPlayer highBall = new OneHigherPlayer();

            highBall.Name = "Willie";

            highBall.Play(player3);
            Console.WriteLine("-------------------");

            HumanPlayer dumbmortal = new HumanPlayer();

            dumbmortal.Name = "BillyBob";

            dumbmortal.Play(large);
            Console.WriteLine("-------------------");

            CreativeSmackTalkingPlayer Mack2 = new CreativeSmackTalkingPlayer();

            Mack2.Name = "Mackie";
            Mack2.Play(player1);
            Console.WriteLine("-------------------");

            SoreLoserPlayer sadBoi = new SoreLoserPlayer();

            sadBoi.Name = "Brandon";

            sadBoi.Play(player2);
            Console.WriteLine("-------------------");

            UpperHalfPlayer cheater = new UpperHalfPlayer();

            cheater.Name = "Andy";

            cheater.Play(player2);
            Console.WriteLine("-------------------");

            SoreLoserUpperHalfPlayer grumpiBoi = new SoreLoserUpperHalfPlayer();

            grumpiBoi.Name  = "YoMomma";
            grumpiBoi.Taunt = "You suck.";

            grumpiBoi.Play(player2);
            Console.WriteLine("-------------------");

            List <Player> players = new List <Player>()
            {
                player1,
                player2,
                player3,
                large,
                mackthesmack,
                highBall,
                dumbmortal,
                sadBoi,
                cheater,
                grumpiBoi
            };

            PlayMany(players);
        }
Exemple #10
0
        static void Main(string[] args)
        {
            Console.Clear();
            Player player1 = new Player();

            player1.Name = "Bob";

            Player player2 = new Player();

            player2.Name = "Sue";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            Player player3 = new Player();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            SmackTalkingPlayer CardinalBiggles = new SmackTalkingPlayer()
            {
                Name  = "Cardinal Biggles",
                Taunt = "NO ONE EXPECTS THE SPANISH INQUISITION!"
            };

            OneHigherPlayer ImUp = new OneHigherPlayer()
            {
                Name = "I'm Up"
            };

            HumanPlayer cheatmaster = new HumanPlayer()
            {
                Name = "Karen"
            };

            CreativeSmackTalkingPlayer smackyMcSmackmouth = new CreativeSmackTalkingPlayer()
            {
                Name   = "Smackmouth",
                Taunts = new List <string> ()
                {
                    "You can blame it on your parents. Won't that be a relief",
                    "Don't taunt elephants. Don't stand next to anyone who taunts elephants.",
                    "You pet your dog with those hands?"
                }
            };

            SoreLoserPlayer Donnie = new SoreLoserPlayer()
            {
                Name = "Donnie"
            };

            UpperHalfPlayer upperHand = new UpperHalfPlayer()
            {
                Name = "UpperHand"
            };

            SoreLoserUpperHalfPlayer BigDonnie = new SoreLoserUpperHalfPlayer()
            {
                Name = "Big Donnie"
            };
            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            List <Player> players = new List <Player> ()
            {
                player1,
                player2,
                player3,
                large,
                CardinalBiggles,
                ImUp,
                cheatmaster,
                smackyMcSmackmouth,
                Donnie,
                upperHand,
                BigDonnie
            };

            try { PlayMany(players); } catch {
                Console.WriteLine("I Hate You!");
            }
        }
Exemple #11
0
        static void Main(string[] args)
        {
            Player player1 = new Player();

            player1.Name = "Bob";

            Player player2 = new Player();

            player2.Name = "Sue";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            Player player3 = new Player();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            SmackTalkingPlayer person = new SmackTalkingPlayer();

            person.Name  = "Person";
            person.Taunt = "this are mean words";
            person.Play(player2);

            Console.WriteLine("-------------------");
            OneHigherPlayer winner = new OneHigherPlayer();

            winner.Name = "Winner";
            winner.Play(player1);


            Console.WriteLine("-------------------");
            HumanPlayer human = new HumanPlayer();

            human.Play(player3);

            Console.WriteLine("-------------------");
            CreativeSmackTalkingPlayer creative = new CreativeSmackTalkingPlayer();

            creative.Name = "meanPerson";
            creative.Play(player1);


            Console.WriteLine("-------------------");
            SoreLoserPlayer sore = new SoreLoserPlayer();

            sore.Name = "Sore Loser Player";
            sore.Play(player3);

            Console.WriteLine("-------------------");
            UpperHalfPlayer upper = new UpperHalfPlayer();

            upper.Name = "Upper";
            upper.Play(player3);

            Console.WriteLine("-------------------");
            SoreLoserUpperHalfPlayer soreAndUpper = new SoreLoserUpperHalfPlayer();

            soreAndUpper.Name = "Sore and Upper";
            soreAndUpper.Play(player2);

            List <Player> players = new List <Player>()
            {
                player1, player2, player3, large, winner, human, sore, upper, soreAndUpper
            };

            PlayMany(players);
        }
Exemple #12
0
        static void Main(string[] args)
        {
            Player player1 = new Player();

            player1.Name = "Bob";

            SmackTalkingPlayer smackTalker = new SmackTalkingPlayer();

            smackTalker.Name = "Sue Smacktalker";

            OneHigherPlayer oneHigher = new OneHigherPlayer();

            oneHigher.Name = "Wilma Onehigher";

            LargeDicePlayer large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            HumanPlayer human = new HumanPlayer();

            human.Name = "Henry Human";

            CreativeSmackTalkingPlayer creative = new CreativeSmackTalkingPlayer();

            creative.Name = "Creative Conan";

            SoreLoserPlayer sore = new SoreLoserPlayer();

            sore.Name = "Sally Soreloser";

            UpperHalfPlayer upper = new UpperHalfPlayer();

            upper.Name = "Uffie Upperhalf";

            SoreLoserUpperHalfPlayer soreUpper = new SoreLoserUpperHalfPlayer();

            soreUpper.Name = "Stephen Soreupper";

            smackTalker.Play(player1);
            Console.WriteLine("-------------------");

            oneHigher.Play(player1);
            Console.WriteLine("-------------------");

            large.Play(smackTalker);
            Console.WriteLine("-------------------");

            human.Play(player1);
            Console.WriteLine("-------------------");

            creative.Play(smackTalker);
            Console.WriteLine("-------------------");

            sore.Play(player1);
            Console.WriteLine("-------------------");

            upper.Play(player1);
            Console.WriteLine("-------------------");

            soreUpper.Play(player1);
            Console.WriteLine("-------------------");

            List <Player> players = new List <Player>()
            {
                player1,
                smackTalker,
                oneHigher,
                large,
                human,
                creative,
                upper,
                sore,
                soreUpper
            };

            PlayMany(players);
        }
        static void Main(string[] args)
        {
            // DWB update
            SmackTalkingPlayer player1 = new SmackTalkingPlayer();

            player1.Name = "Bob";

            OneHigherPlayer player2 = new OneHigherPlayer();

            player2.Name = "Sue";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            HumanPlayer player3 = new HumanPlayer();

            player3.Name = "Human Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");
            CreativeSmackTalkingPlayer smartass = new CreativeSmackTalkingPlayer();

            smartass.Name = "Smartass Sal";

            smartass.Play(large);

            Console.WriteLine("-------------------");

            SoreLoserPlayer exceptional = new SoreLoserPlayer();

            exceptional.Name = "SoreLoser Exceptional Ed";

            exceptional.Play(player1);

            Console.WriteLine("-------------------");

            UpperHalfPlayer upperPlayer = new UpperHalfPlayer();

            upperPlayer.Name = "UpperHalf Hal";

            upperPlayer.Play(large);

            Console.WriteLine("-------------------");

            SoreLoserUpperHalfPlayer soreUpper = new SoreLoserUpperHalfPlayer();

            soreUpper.Name = "UpperHalf Hater";

            soreUpper.Play(large);

            Console.WriteLine("-------------------");

            HumanPlayer moreHumanThanHuman = new HumanPlayer();

            moreHumanThanHuman.Name = "Human Uberman Neitzsche";

            moreHumanThanHuman.Play(player3);

            Console.WriteLine("Object Type:");
            Console.WriteLine(moreHumanThanHuman.GetType().Equals(typeof(HumanPlayer)));

            Console.WriteLine("-------------------");

            List <Player> players = new List <Player>()
            {
                player1,
                player2,
                player3,
                large,
                smartass,
                exceptional,
                upperPlayer,
                soreUpper,
                moreHumanThanHuman
            };

            PlayMany(players);
        }
Exemple #14
0
        static void Main(string[] args)
        {
            SmackTalkingPlayer player1 = new SmackTalkingPlayer();

            player1.Name = "Bob";
            //player1.Taunt = "Hey... They Call me Robert Paulsen and you are a LOOOOSSSSEEERRRR";

            OneHigherPlayer player2 = new OneHigherPlayer();

            player2.Name = "Sue";

            player1.Play(player2);
            Console.WriteLine("-------------------");

            HumanPlayer player3 = new HumanPlayer();

            player3.Name = "Bert";

            player3.Play(player1);

            Console.WriteLine("-------------------");

            CreativeSmackTalkingPlayer player4 = new CreativeSmackTalkingPlayer();

            player4.Name = "Jimbo";

            Player player5 = new Player();

            player5.Name = "Drew";

            player4.Play(player5);
            Console.WriteLine("-------------------");

            LargeDicePlayer large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            UpperHalfPlayer player6 = new UpperHalfPlayer();

            player6.Name = "The Dude";

            Player player7 = new Player();

            player7.Name = "Other Guy";

            player6.Play(player7);
            Console.WriteLine("-------------------");

            SoreLoserUpperHalfPlayer player8 = new SoreLoserUpperHalfPlayer();

            player8.Name = "Sad Panda  but with Bamboo";

            SoreLoserPlayer player9 = new SoreLoserPlayer();

            player9.Name = "Sad Panda";

            List <Player> players = new List <Player>()
            {
                player1,
                player2,
                player3,
                player4,
                player5,
                player6,
                player7,
                player8,
                player9,
                large
            };

            PlayMany(players);
        }
Exemple #15
0
        static void Main(string[] args)
        {
            SmackTalkingPlayer Buba = new SmackTalkingPlayer();

            Buba.Name  = "Bubba";
            Buba.Taunt = "BOOOOOO!!!!";
            SmackTalkingPlayer Bobly = new SmackTalkingPlayer();

            Bobly.Name = "Bobbily";

            UpperHalfPlayer pierre = new UpperHalfPlayer();

            pierre.Name = "Pierre Artoise";

            pierre.Play(Buba);

            OneHigherPlayer lucky = new OneHigherPlayer();

            lucky.Name = "Lucky MacDucky";

            lucky.Play(Buba);

            CreativeSmackTalkingPlayer Frenchie = new CreativeSmackTalkingPlayer();

            Frenchie.Name  = "Hercule";
            Frenchie.Taunt = Frenchie.SelectTaunt();

            Frenchie.Play(Buba);

            HumanPlayer user1 = new HumanPlayer();

            Console.Write("What's your name? ");
            user1.Name = Console.ReadLine();

            Bobly.Play(user1);

            SoreLoserPlayer steve = new SoreLoserPlayer();

            steve.Name = "steve";

            SoreLoserUpperHalfPlayer stephan = new SoreLoserUpperHalfPlayer();

            stephan.Name = "stephan Artoise";

            stephan.Play(Bobly);

            steve.Play(Frenchie);

            Player player1 = new Player();

            player1.Name = "Bob";

            Player player2 = new Player();

            player2.Name = "Sue";

            player2.Play(player1);
            Buba.Play(player1);

            Console.WriteLine("-------------------");

            Player player3 = new Player();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            stephan.Play(user1);

            List <Player> players = new List <Player>()
            {
                player1,
                player2,
                player3,
                Buba,
                Bobly,
                large
            };

            PlayMany(players);
        }
Exemple #16
0
        static void Main(string[] args)
        {
            SmackTalkingPlayer player1 = new SmackTalkingPlayer();

            player1.Name = "Caitlin";

            OneHigherPlayer player2 = new OneHigherPlayer();

            player2.Name = "Joe";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            HumanPlayer player3 = new HumanPlayer();

            player3.Name = "Barry";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            CreativeSmackTalkingPlayer player4 = new CreativeSmackTalkingPlayer();

            player4.Name = "Cisco";

            player4.Play(player3);

            Console.WriteLine("-------------------");

            SoreLoserPlayer player5 = new SoreLoserPlayer();

            player5.Name = "Henry";
            // this is the try/catch to catch the Exception
            try
            {
                player5.Play(player4);
            }
            catch
            {
                Console.Write("you cheated");
            }

            Console.WriteLine("-------------------");

            UpperHalfPlayer player6 = new UpperHalfPlayer();

            player6.Name = "Iris";

            player6.Play(player5);

            Console.WriteLine("-------------------");

            SoreLoserUpperHalfPlayer player7 = new SoreLoserUpperHalfPlayer();

            player7.Name = "Cecile";
            // this is the try/catch to catch the Exception
            try
            {
                player7.Play(player6);
            }
            catch
            {
                Console.Write("You read my mind");
            }

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            List <Player> players = new List <Player>()
            {
                player1,
                player2,
                player3,
                player4,
                player5,
                player6,
                player7,
                large
            };

            PlayMany(players);
        }
Exemple #17
0
        static void Main(string[] args)
        {
            Player player1 = new Player();

            player1.Name = "Bob";

            Player player2 = new Player();

            player2.Name = "Sue";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            Player player3 = new Player();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            // Smack talking player
            SmackTalkingPlayer smackTalking = new SmackTalkingPlayer();

            smackTalking.Name = "Rick James";
            smackTalking.AddInsult("My dog rolls better than that!");
            large.Play(smackTalking);

            Console.WriteLine("-------------------");

            // One higher player
            Player oneHigher = new OneHigherPlayer();

            oneHigher.Name = "Slick Rick";
            oneHigher.Play(large);

            Console.WriteLine("-------------------");

            // Human Player
            Player human = new HumanPlayer();

            human.Name = "Ricky";
            player1.Play(human);

            Console.WriteLine("-------------------");

            // Creative Smack Talking Player
            Player creativeSmack = new CreativeSmackTalkingPlayer();

            creativeSmack.Name = "Rick Roll";
            large.Play(creativeSmack);

            Console.WriteLine("-------------------");

            // Sore Loser Player
            Player soreLoser = new SoreLoserPlayer();

            soreLoser.Name = "Ricky Williams";
            // Try/Catch to handle exception message when SoreLoserPlayer loses
            try
            {
                soreLoser.Play(player2);
            }
            catch (Exception ex)
            {
                Console.WriteLine($"{soreLoser.Name} says: You Cheated!");
            }

            Console.WriteLine("-------------------");

            // Upper Half Player
            Player upperHalf = new UpperHalfPlayer();

            upperHalf.Name = "Rick Grimes";
            upperHalf.Play(player3);

            Console.WriteLine("-------------------");

            // Sore Loser Upper Half Player
            Player sluhPlayer = new SoreLoserPlayer();

            sluhPlayer.Name = "Rick Sanchez";
            // Try/Catch to handle exception message when SoreLoserUpperHalfPlayer loses
            try
            {
                sluhPlayer.Play(large);
            }
            catch (Exception ex)
            {
                Console.WriteLine($"{sluhPlayer.Name} says: This game is rigged!");
            }

            Console.WriteLine("-------------------");

            List <Player> players = new List <Player>()
            {
                player1,
                player2,
                player3,
                large,
                smackTalking,
                oneHigher,
                human,
                creativeSmack,
                upperHalf
            };

            PlayMany(players);
        }
Exemple #18
0
        static void Main(string[] args)
        {
            Player player1 = new Player();

            player1.Name = "Bob";

            Player player2 = new Player();

            player2.Name = "Sue";

            // player2.Play(player1);

            // Console.WriteLine("-------------------");

            Player player3 = new Player();

            player3.Name = "Wilma";

            // player3.Play(player2);

            // Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            // player1.Play(large);

            // Console.WriteLine("-------------------");

            SmackTalkingPlayer player4 = new SmackTalkingPlayer("Ima come at you like a spider monkey!");

            player4.Name = "Slick Rick";

            // player4.Play(large);

            // Console.WriteLine("-------------------");

            Player plusOne = new OneHigherPlayer();

            plusOne.Name = "Turd Ferguson";

            // plusOne.Play(player4);

            // Console.WriteLine("-------------------");

            Player human = new HumanPlayer();

            human.Name = "Jeremy Jam";

            // human.Play(player4);

            // Console.WriteLine("-------------------");


            CreativeSmackTalkingPlayer smack = new CreativeSmackTalkingPlayer();

            smack.Name = "Joe Mama";

            // smack.Play(player2);

            // Console.WriteLine("-------------------");

            Player loser = new SoreLoserPlayer();

            loser.Name = "Freddie";
            // loser.Play(player3);

            // Console.WriteLine("-------------------");

            Player ups = new UpperHalfPlayer();

            ups.Name = "Mr. Bigglesworth";

            // ups.Play(player4);

            // Console.WriteLine("-------------------");

            Player upSore = new SoreLoserUpperHalfPlayer();

            upSore.Name = "Bing Crosby";

            // upSore.Play(human);

            // Console.WriteLine("-------------------");

            List <Player> players = new List <Player>()
            {
                player1, player2, player3, large, player4, plusOne, human, smack, loser, ups, upSore
            };

            PlayMany(players);
        }
Exemple #19
0
        static void Main(string[] args)
        {
            Player player1 = new Player();

            player1.Name = "Bob";

            Player player2 = new Player();

            player2.Name = "Sue";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            Player player3 = new Player();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            SmackTalkingPlayer person = new SmackTalkingPlayer("\"Come at me bro\"");

            person.Name = "Sara SmackTalk";
            // person.Play(player2);
            OneHigherPlayer cheater = new OneHigherPlayer();

            cheater.Name = "Peter Peter";
            // cheater.Play(player1);
            HumanPlayer hancho = new HumanPlayer();

            hancho.Name = "Head Hancho";
            // hancho.Play(player1);
            CreativeSmackTalkingPlayer Karen = new CreativeSmackTalkingPlayer();

            Karen.Name = "Karen NoCares";
            // Karen.Play(player1);
            SoreLoserPlayer Ted = new SoreLoserPlayer();

            Ted.Name = "Ted";
            // Ted.Play(player1);
            SoreLoserUpperHalfPlayer Tony = new SoreLoserUpperHalfPlayer();

            Tony.Name = "Tony";
            // Tony.Play(player1);



            List <Player> players = new List <Player>()
            {
                player1, player2, Tony, player3, large, person, cheater, hancho, Karen, Ted,
            };

            PlayMany(players);
        }
        static void Main(string[] args)
        {
            // instantiating new players
            SmackTalkingPlayer player1 = new SmackTalkingPlayer();

            player1.Name = "Smack Talker";

            OneHigherPlayer player2 = new OneHigherPlayer();

            player2.Name = "One Higher";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            HumanPlayer player3 = new HumanPlayer();

            player3.Name = "Human";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            CreativeSmackTalkingPlayer player4 = new CreativeSmackTalkingPlayer();

            player4.Name = "Creative Smack Talker";

            player4.Play(player3);

            Console.WriteLine("-------------------");

            SoreLoserPlayer player5 = new SoreLoserPlayer();

            player5.Name = "Sore Loser Player";
            // catching the exception
            try
            {
                player5.Play(player4);
            }
            catch
            {
                Console.WriteLine($"You cheated!");
            }

            Console.WriteLine("-------------------");

            UpperHalfPlayer player6 = new UpperHalfPlayer();

            player6.Name = "Upper Half Player";

            player6.Play(player5);

            Console.WriteLine("-------------------");
            SoreLoserUpperHalfPlayer player7 = new SoreLoserUpperHalfPlayer();

            player7.Name = "Sore Loser Upper Half Player";
            // catching the exception
            try
            {
                player7.Play(player6);
            }
            catch
            {
                Console.WriteLine($"You cheated!");
            }

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            // creating a list of players
            List <Player> players = new List <Player>()
            {
                player1,
                player2,
                player3,
                player4,
                player5,
                player6,
                player7,
                large
            };

            PlayMany(players);
        }
Exemple #21
0
        static void Main(string[] args)
        {
            // Make new players

            // ROUND ONE
            // One Higher Player
            OneHigherPlayer highPlayer = new OneHigherPlayer();

            highPlayer.Name = "High Kite Kyle";

            // Smack Talking Player
            SmackTalkingPlayer smackPlayer = new SmackTalkingPlayer()
            {
                Name  = "Smacktalking Smoochie Susan",
                Taunt = "\"You're gonna eat my lips!!!\""
            };

            // Smack Talking Player plays the High Roller
            smackPlayer.Play(highPlayer);

            Console.WriteLine("-------------------");

            // ROUND TWO: Creative Smack Talking Player vs Smack Talking Player
            // Creative Smack Talking Player
            CreativeSmackTalkingPlayer creativePlayer = new CreativeSmackTalkingPlayer()
            {
                Name = "Mean Bean Jim"
            };

            creativePlayer.Play(smackPlayer);

            Console.WriteLine("-------------------");

            // ROUND Three: Always Higher Player vs Large Dice Player
            Player largePlayer = new LargeDicePlayer()
            {
                Name = "Big Booty Roller"
            };

            highPlayer.Play(largePlayer);

            Console.WriteLine("-------------------");

            // ROUND Four: Human Player vs Sore Loser Player
            HumanPlayer humanPlayer = new HumanPlayer()
            {
                Name = "Human Manny"
            };

            SoreLoserPlayer sorePlayer = new SoreLoserPlayer()
            {
                Name = "Sore Sunny"
            };

            humanPlayer.Play(sorePlayer);

            List <Player> players = new List <Player>()
            {
                highPlayer, smackPlayer, creativePlayer, largePlayer, humanPlayer, sorePlayer
            };

            PlayMany(players);
        }
Exemple #22
0
        static void Main(string[] args)
        {
            Player player1 = new Player();

            player1.Name = "Bob";

            Player player2 = new Player();

            player2.Name = "Sue";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            Player player3 = new Player();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            large.Play(player3);

            Console.WriteLine("-------------------");

            CreativeSmackTalkingPlayer smackTalkPlayer = new CreativeSmackTalkingPlayer();

            smackTalkPlayer.Name = "badmouth mcgee";

            smackTalkPlayer.Play(player3);

            Console.WriteLine("-------------------");

            OneHigherPlayer higherPlayer = new OneHigherPlayer();

            higherPlayer.Name = "vanquisher";

            higherPlayer.Play(player3);

            Console.WriteLine("-------------------");

            HumanPlayer u = new HumanPlayer();

            u.Name = "You";

            u.Play(player3);

            Console.WriteLine("-------------------");

            SmackTalkingPlayer smack = new SmackTalkingPlayer();

            smack.Name  = "smacky";
            smack.Taunt = "About to win me a new pair of shoes";

            smack.Play(player1);

            Console.WriteLine("-------------------");

            SoreLoserPlayer Loser = new SoreLoserPlayer();

            Loser.Name = "wack";

            Loser.Play(player1);

            Console.WriteLine("-------------------");

            UpperHalfPlayer Upper = new UpperHalfPlayer();

            Upper.Name = "Up";

            Upper.Play(player3);

            Console.WriteLine("-------------------");

            SoreLoserUpperHalfPlayer bigWack = new SoreLoserUpperHalfPlayer();

            bigWack.Name = "biggerWack";

            bigWack.Play(player3);


            Console.WriteLine("-------------------");

            List <Player> players = new List <Player>()
            {
                player1, player2, player3, large, smackTalkPlayer, higherPlayer, smack, Loser, Upper, bigWack, u
            };

            PlayMany(players);
        }
Exemple #23
0
        static void Main(string [] args)
        {
            SmackTalkingPlayer player1 = new SmackTalkingPlayer();

            player1.Name = "Chad";

            OneHigherPlayer player2 = new OneHigherPlayer();

            player2.Name = "Rob";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            HumanPlayer player3 = new HumanPlayer();

            player3.Name = "Todd";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Napoleon the SMALL";

            player1.Play(large);

            Console.WriteLine("-------------------");

            CreativeSmackTalkingPlayer player4 = new CreativeSmackTalkingPlayer();

            player4.Name = "Dan";

            player4.Play(large);

            Console.WriteLine("-------------------");

            SoreLoserPlayer player5 = new SoreLoserPlayer();

            player5.Name = "Greg";

            player5.Play(player4);

            Console.WriteLine("-------------------");

            UpperHalfPlayer player6 = new UpperHalfPlayer();

            player6.Name = "Kris";

            player6.Play(player4);

            Console.WriteLine("-------------------");

            List <Player> players = new List <Player> ()
            {
                player1,
                player2,
                player3,
                player4,
                player5,
                player6,
                large
            };

            PlayMany(players);
        }
        static void Main(string[] args)
        {
            Player player1 = new Player();

            player1.Name = "Bob";

            Player player2 = new Player();

            player2.Name = "Sue";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            Player player3 = new Player();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player player4 = new SmackTalkingPlayer();

            player4.Name = "Brady";

            Player player5 = new OneHigherPlayer();

            player5.Name = "Erik";

            player5.Play(player4);

            Console.WriteLine("-------------------");

            Player player6 = new HumanPlayer();

            player6.Name = "Ember";

            // player4.Play(player6);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            Player player7 = new CreativeSmackTalkingPlayer();

            player7.Name = "Travis";

            player7.Play(player4);

            Console.WriteLine("-------------------");

            Player player8 = new SoreLoserPlayer();

            player8.Name = "Sam";

            try
            {
                player8.Play(player4);
            }
            catch (RageQuitException)
            {
                Console.WriteLine($"{player8.Name} rage quit");
            }

            List <Player> players = new List <Player>()
            {
                player1,
                player2,
                player3,
                player4,
                large
            };

            PlayMany(players);
        }
Exemple #25
0
        static void Main(string[] args)
        {
            Player player1 = new Player();

            player1.Name = "Bob";

            Player player2 = new Player();

            player2.Name = "Sue";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            Player player3 = new Player();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            large.Play(player3);

            Console.WriteLine("-------------------");

            Player smackTalker = new SmackTalkingPlayer();

            smackTalker.Name = "Punk";
            smackTalker.Play(large);

            Console.WriteLine("-------------------");

            Player oneHigher = new OneHigherPlayer();

            oneHigher.Name = "OneUpper";
            oneHigher.Play(smackTalker);

            Console.WriteLine("-------------------");

            Player hooman = new HumanPlayer();

            hooman.Name = "Earthling";
            hooman.Play(oneHigher);

            Console.WriteLine("-------------------");

            Player creativeSmackTalker = new CreativeSmackTalkingPlayer();

            creativeSmackTalker.Name = "ArtisticPunk";
            creativeSmackTalker.Play(hooman);

            Console.WriteLine("-------------------");

            Player todd = new SoreLoserPlayer();

            todd.Name = "Todd";
            todd.Play(creativeSmackTalker);

            Console.WriteLine("-------------------");

            Player smug = new UpperHalfPlayer();

            smug.Name = "McGee";
            smug.Play(todd);

            Console.WriteLine("-------------------");

            Player worst = new SoreLoserUpperHalfPlayer();

            worst.Name = "The Worst";
            worst.Play(player1);

            List <Player> players = new List <Player>()
            {
                player1,
                player2,
                player3,
                large,
                smackTalker,
                oneHigher,
                hooman,
                creativeSmackTalker,
                todd,
                smug,
                worst
            };

            PlayMany(players);
        }
Exemple #26
0
        static void Main(string[] args)
        {
            Console.WriteLine("-------------------");
            SmackTalkingPlayer player1 = new SmackTalkingPlayer();

            player1.Name = "Smack";
            HumanPlayer human = new HumanPlayer();

            human.Name = "human";

            human.Play(player1);

            Console.WriteLine("-------------------");

            SoreLoserPlayer playerSore = new SoreLoserPlayer();

            playerSore.Name = "Sore Loser";

            CreativeSmackTalkingPlayer playerSmack = new CreativeSmackTalkingPlayer();

            playerSmack.Name = "Creative Smack";

            playerSore.Play(playerSmack);

            Console.WriteLine("-------------------");

            Console.WriteLine("-------------------");


            UpperHalfPlayer upperHalfPlayer = new UpperHalfPlayer();

            upperHalfPlayer.Name = "Upper Half Player";

            upperHalfPlayer.Play(playerSmack);

            Console.WriteLine("-------------------");

            CreativeSmackTalkingPlayer player2 = new CreativeSmackTalkingPlayer();

            player2.Name = "Creative Smack";

            player2.Play(player1);

            Console.WriteLine("-------------------");

            OneHigherPlayer player3 = new OneHigherPlayer();

            player3.Name = "Wilma";

            player3.Play(player2);

            Console.WriteLine("-------------------");

            Player large = new LargeDicePlayer();

            large.Name = "Bigun Rollsalot";

            player1.Play(large);

            Console.WriteLine("-------------------");

            SoreLoserUpperHalfPlayer soreUpper = new SoreLoserUpperHalfPlayer();

            soreUpper.Play(player1);
            soreUpper.Name = "sore Upper";

            List <Player> players = new List <Player>()
            {
                player1, player2, player3, large, human, playerSmack, playerSore, upperHalfPlayer, soreUpper
            };

            PlayMany(players);
        }