Exemplo n.º 1
0
        public static void DoSim()
        {
            Player player = new Player(playerBase, playerBase.Equipment, playerBase.Talents);

            foreach (Item i in player.Equipment.Values.Where(i => i != null))
            {
                i.Player = player;
            }

            //player.CalculateAttributes();
            player.Attributes    = playerBase.Attributes;
            player.WindfuryTotem = playerBase.WindfuryTotem;
            player.Cooldowns     = playerBase.Cooldowns;

            Boss boss = new Boss(bossBase);

            /*
             * if(toWeight != null)
             * {
             *  player.Attributes.SetValue(weighted, player.Attributes.GetValue(weighted) + 10);
             * }
             */

            Simulation s = new Simulation(player, boss, fightLength);

            s.StartSim();
        }
Exemplo n.º 2
0
        public static void DoSim()
        {
            Player player;

            switch (playerBase.Class)
            {
            case Player.Classes.Druid:
                player = new Druid(playerBase);
                break;

            case Player.Classes.Hunter:
                player = new Hunter(playerBase);
                break;

            case Player.Classes.Mage:
                player = new Mage(playerBase);
                break;

            case Player.Classes.Paladin:
                player = new Paladin(playerBase);
                break;

            case Player.Classes.Priest:
                player = new Priest(playerBase);
                break;

            case Player.Classes.Rogue:
                player = new Rogue(playerBase);
                break;

            case Player.Classes.Shaman:
                player = new Shaman(playerBase);
                break;

            case Player.Classes.Warlock:
                player = new Warlock(playerBase);
                break;

            case Player.Classes.Warrior:
                player = new Warrior(playerBase);
                break;

            default:
                throw new NotSupportedException("This class isn't supported : " + playerBase.Class);
            }

            Boss boss = new Boss(bossBase);

            Simulation s = new Simulation(player, boss, fightLength, bossAutoLife, bossLowLifeTime);

            s.StartSim();
        }