public override void Enact()
    {
        System.Random rng = new System.Random();
        int           num;

        Character[] enemies = new Character[4];
        enemies[0] = new Expirimentor();
        for (int i = 1; i < 4; i++)
        {
            num = rng.Next(10);
            if (num == 0)
            {
                enemies[i] = new MathMajor();
            }
            else if (num == 1)
            {
                enemies[i] = new EnglishMajor();
            }
            else if (num == 2)
            {
                enemies[i] = new MechanicalEngineer();
            }
            else if (num == 3)
            {
                enemies[i] = new ChemistryMajor();
            }
            else if (num == 4)
            {
                enemies[i] = new FootballPlayer();
            }
            else if (num == 5)
            {
                enemies[i] = new CJMajor();
            }
            else if (num == 6)
            {
                enemies[i] = new PsychMajor();
            }
            else if (num == 7)
            {
                enemies[i] = new CSMajor();
            }
            else if (num == 8)
            {
                enemies[i] = new CulinaryMajor();
            }
            else
            {
                enemies[i] = new BusinessMajor();
            }
        }
        options1 = new LinkedList <TimedMethod>();
        options1.AddLast(new TimedMethod(0, "Battle", new object[] { enemies }));
    }
    public TimedMethod[] Summon()
    {
        System.Random rng = new System.Random();
        int           seed;
        Character     current;

        for (int i = 0; i < 3; i++)
        {
            seed = rng.Next(10);
            if (seed == 0)
            {
                current = new CSMajor();
            }
            else if (seed == 1)
            {
                current = new MusicMajor();
            }
            else if (seed == 2)
            {
                current = new PoliticalScientist();
            }
            else if (seed == 3)
            {
                current = new FootballPlayer();
            }
            else if (seed == 4)
            {
                current = new BusinessMajor();
            }
            else if (seed == 5)
            {
                current = new EnglishMajor();
            }
            else if (seed == 6)
            {
                current = new ChemistryMajor();
            }
            else if (seed == 7)
            {
                current = new CJMajor();
            }
            else if (seed == 8)
            {
                current = new CulinaryMajor();
            }
            else
            {
                current = new PsychMajor();
            }
            current.SetRecruitable(false);
            Party.AddEnemy(current);
        }
        return(new TimedMethod[] { new TimedMethod(60, "Log", new object[] { ToString() + "Surrounded themself with minions" }) });
    }
    public Character[] GetChoices()
    {
        Character[] choices = new Character[2];
        switch (Map.currentPosition)
        {
        case "tower":
            choices[0] = new CJMajor();
            choices[1] = new PoliticalScientist();
            break;

        case "dining":
            choices[0] = new CulinaryMajor();
            choices[1] = new EnglishMajor();
            break;

        case "research":
            choices[0] = new ChemistryMajor();
            choices[1] = new MathMajor();
            break;

        case "sports":
            choices[0] = new FootballPlayer();
            choices[1] = new AerospaceEngineer();
            break;

        case "art":
            choices[0] = new DanceMajor();
            choices[1] = new MusicMajor();
            break;

        case "health":
            choices[0] = new PreMed();
            choices[1] = new PsychMajor();
            break;

        case "lecture":
            choices[0] = new HistoryMajor();
            choices[1] = new BusinessMajor();
            break;
        }
        return(choices);
    }
Ejemplo n.º 4
0
        static void Main(string[] args)
        {
            StudentCnt cont = StudentCnt.Instance;

            LanguageMajor lStud1 = new LanguageMajor("Anders", "12345678", 2, 7);
            LanguageMajor lStud2 = new LanguageMajor("Maria", "434543", 1, 2);
            LanguageMajor lStud3 = new LanguageMajor("Lars", "534342", 3, 12);

            ScienceMajor sStud1 = new ScienceMajor("Martin", "321543", 1, 7);
            ScienceMajor sStud2 = new ScienceMajor("Per", "676556", 1, 2);
            ScienceMajor sStud3 = new ScienceMajor("Sofie", "1235232", 3, -3);

            BusinessMajor bStud1 = new BusinessMajor("Heine", "5434343154", 1, 4);
            BusinessMajor bStud2 = new BusinessMajor("Hamid", "54343254", 1, 2);
            BusinessMajor bStud3 = new BusinessMajor("Chriss", "5431112354", 1, 7);

            Student s = new BusinessMajor("der","der", 1, 5);
            cont.addStudent(s);

            cont.addStudent(lStud1);
            cont.addStudent(lStud2);
            cont.addStudent(lStud3);

            cont.addStudent(sStud1);
            cont.addStudent(sStud2);
            cont.addStudent(sStud3);

            cont.addStudent(bStud1);
            cont.addStudent(bStud2);
            cont.addStudent(bStud3);

            cont.printPassed();
            cont.printFailed();

            Console.ReadLine();
        }
Ejemplo n.º 5
0
    public void Load(int seed)
    {
        Party.Clear();
        Character c;

        if (seed == 0)
        {
            c = new CSMajor();
            c.SetChampion(true); c.SetStrength(4); c.SetMaxHP(30); c.SetHealth(30); c.SetQuirk(new Ninja(c));
            Party.AddPlayer(c);
            Party.SetItems(new Item[] { new Pizza(), new Smartphone(), new Textbook(), new Pizza(), new Wire(), null, null, null, null, null });
        }
        else if (seed == 1)
        {
            c = new ChemistryMajor();
            c.SetChampion(true); c.SetStrength(4); c.SetMaxHP(30); c.SetHealth(30); c.SetQuirk(new Ill(c));
            Party.AddPlayer(c);
            Party.PostBattle();
            Party.SetItems(new Item[] { new Flask(), new Flask(), new ToxicSolution(), new MysteryGoo(), new MysteryGoo(), null, null, null, null, null });
        }
        else if (seed == 2)
        {
            c = new MusicMajor();
            c.SetChampion(true); c.SetStrength(4); c.SetMaxHP(30); c.SetHealth(30); c.SetQuirk(new Bandwagon(c));
            Party.AddPlayer(c);
            Party.SetItems(new Item[] { new Tuba(), new Smartphone(), new Donut(), new Wire(), new Heels(), null, null, null, null, null });
        }
        else if (seed == 3)
        {
            c = new HistoryMajor();
            c.SetChampion(true); c.SetStrength(5); c.SetMaxHP(35); c.SetHealth(35); c.SetQuirk(new Vaccinated(c));
            Party.AddPlayer(c);
            Party.SetItems(new Item[] { new Sword(), new Sword(), new Textbook(), new Curry(), new Celery(), null, null, null, null, null });
        }
        else if (seed == 4)
        {
            c = new CJMajor();
            c.SetChampion(true); c.SetStrength(5); c.SetMaxHP(30); c.SetHealth(30); c.SetBaseAccuracy(15); c.SetQuirk(new Vengeful(c));
            Party.AddPlayer(c);
            Party.SetItems(new Item[] { new Sword(), new Tazer(), new ProteinBar(), new Whistle(), new SlimeGoo(), null, null, null, null, null });
        }
        else if (seed == 5)
        {
            c = new PreMed();
            c.SetChampion(true); c.SetStrength(5); c.SetMaxHP(25); c.SetHealth(25); c.SetQuirk(new Recovery(c));
            Party.AddPlayer(c);
            Party.SetItems(new Item[] { new Sanitizer(), new Antibiotics(), new Rice(), new MysterySolution(), new ToxicSolution(), null, null, null, null, null });
        }
        else if (seed == 6)
        {
            c = new EnglishMajor();
            c.SetChampion(true); c.SetStrength(4); c.SetMaxHP(30); c.SetHealth(30); c.SetQuirk(new SleepDeprived(c));
            Party.AddPlayer(c);
            Party.SetItems(new Item[] { new Pencil(), new VotedBadge(), new Textbook(), new Pendulum(), new Celery(), null, null, null, null, null });
        }
        else if (seed == 7)
        {
            c = new BusinessMajor();
            c.SetChampion(true); c.SetStrength(4); c.SetMaxHP(35); c.SetHealth(35); c.SetQuirk(new Paranoid(c));
            Party.AddPlayer(c);
            Party.SetItems(new Item[] { new Briefcase(), new Smartphone(), new PinkSlip(), new Pizza(), new Pendulum(), null, null, null, null, null });
        }
        else if (seed == 8)
        {
            c = new PsychMajor();
            c.SetChampion(true); c.SetStrength(4); c.SetMaxHP(35); c.SetHealth(35); c.SetQuirk(new Dodgy(c));
            Party.AddPlayer(c);
            Party.SetItems(new Item[] { new Pendulum(), new Tuba(), new Textbook(), new Rice(), new Milk(), null, null, null, null, null });
        }
        else
        {
            c = new MechanicalEngineer();
            c.SetChampion(true); c.SetStrength(4); c.SetMaxHP(35); c.SetHealth(35); c.SetQuirk(new Overconfident(c));
            Party.AddPlayer(c);
            Party.SetItems(new Item[] { new Smartphone(), new Calculator(), new Pizza(), new Oil(), new Shuttle(), null, null, null, null, null });
        }
        ToName();
    }