private void comboBoxBoss_SelectedIndexChanged(object sender, EventArgs e)
        {
            if (!_loadingCalculationOptions)
            {
                _loadingCalculationOptions = true;
                CalculationsEnhance calcs = new CalculationsEnhance();
                BossHandler         boss  = bosslist.GetBossFromBetterName(comboBoxBoss.Text);
                _calcOpts.SetBoss(boss);
                CB_TargLvl.Text           = _calcOpts.TargetLevel.ToString();
                CB_TargArmor.Text         = _calcOpts.TargetArmor.ToString();
                cmbLength.Value           = (int)_calcOpts.FightLength;
                CK_InBack.Checked         = _calcOpts.InBack;
                CB_InBackPerc.Value       = _calcOpts.InBackPerc;
                CK_MultiTargs.Checked     = _calcOpts.MultipleTargets;
                CB_MultiTargsMax.Enabled  = CK_MultiTargs.Checked;
                CB_MultiTargsPerc.Enabled = CK_MultiTargs.Checked;
                CB_MultiTargsMax.Value    = _calcOpts.AdditionalTargets;
                CB_MultiTargsPerc.Value   = (int)(_calcOpts.AdditionalTargetPercent * 100 + .001f);

                Stats stats = calcs.GetCharacterStats(Character, null);
                TB_BossInfo.Text = boss.GenInfoString(
                    0,                                                                                             // The Boss' Damage bonuses against you (meaning YOU are debuffed)
                    StatConversion.GetArmorDamageReduction(_calcOpts.TargetLevel, stats.Armor, 0, 0, 0),           // Your Armor's resulting Damage Reduction
                    StatConversion.GetDRAvoidanceChance(Character, stats, HitResult.Miss, _calcOpts.TargetLevel),  // Your chance for Boss to Miss you
                    StatConversion.GetDRAvoidanceChance(Character, stats, HitResult.Dodge, _calcOpts.TargetLevel), // Your chance Dodge
                    StatConversion.GetDRAvoidanceChance(Character, stats, HitResult.Parry, _calcOpts.TargetLevel), // Your chance Parry
                    0,                                                                                             // Your Chance to Block
                    0);                                                                                            // How much you Block when you Block
                // Save the new names

                _loadingCalculationOptions = false;
                Character.OnCalculationsInvalidated();
            }
        }
Exemple #2
0
        public DKTANK()
        {
            // TODO: Add constructor logic here

            weap          = new Stats();
            weap.Strength = 10;
            weapon        = new Item("test", ItemQuality.Common, ItemType.OneHandSword, 10101, "icon.bmp", ItemSlot.OneHand, "", false,
                                     weap, weap, ItemSlot.None, ItemSlot.None, ItemSlot.None, 100, 200, ItemDamageType.Physical, 3.8f, "Death Knight");

            m_char = new Character();
            string szXML = System.IO.File.ReadAllText("..\\..\\..\\..\\Rawr\\Rawr.UnitTests\\testdata\\~Test_Rawr4_Blood2h.xml");

            m_char = Character.LoadFromXml(szXML);
            if (m_char.Class == CharacterClass.Druid)
            {
                // This means it didn't load properly.
                m_char.Class = CharacterClass.DeathKnight;
                // So a weapon, so we have values in weapon specific abilities.
                m_char.MainHand = new ItemInstance(weapon, 0, null, null, null, new Enchant(), new Reforging(), new Tinkering());
                // Some talents.
                // Blood Talents.
                m_char.DeathKnightTalents = new DeathKnightTalents("03322203130022011321000000000000000000000000000000000000000.00000000000000000000000000000");
            }
            m_char.CurrentModel = "TankDK";
            if (m_char.BossOptions == null || m_char.BossOptions.Attacks.Count <= 0)
            {
                BossList    list     = new BossList();
                BossHandler testboss = new BossHandler();
                testboss = list.GetBossFromName("Pit Lord Argaloth");

                m_char.BossOptions = new BossOptions();
                m_char.BossOptions.CloneThis(testboss);
            }
        }
Exemple #3
0
    void Start()
    {
        BossHandler bossHandle = FindObjectOfType <BossHandler>();

        bossHandle.meteorBossListener = this;
        StartCoroutine(SpawnMeteors());
    }
Exemple #4
0
 public BurstCalculations(Stats stats, CalculationOptionsShadowPriest options, BossOptions boss, PriestTalents talents)
 {
     _stats   = stats;
     _boss    = boss;
     _talents = talents;
     _options = options;
 }
Exemple #5
0
        public DKTANK()
        {
            // TODO: Add constructor logic here

            weap = new Stats();
            weap.Strength = 10;
            weapon = new Item("test", ItemQuality.Common, ItemType.OneHandSword, 10101, "icon.bmp", ItemSlot.OneHand, "", false,
                weap, weap, ItemSlot.None, ItemSlot.None, ItemSlot.None, 100, 200, ItemDamageType.Physical, 3.8f, "Death Knight");

            m_char = new Character();
            string szXML = System.IO.File.ReadAllText("..\\..\\..\\..\\Rawr\\Rawr.UnitTests\\testdata\\~Test_Rawr4_Blood2h.xml");
            m_char = Character.LoadFromXml(szXML);
            if (m_char.Class == CharacterClass.Druid)
            {
                // This means it didn't load properly.
                m_char.Class = CharacterClass.DeathKnight;
                // So a weapon, so we have values in weapon specific abilities.
                m_char.MainHand = new ItemInstance(weapon, 0, null, null, null, new Enchant(), new Reforging(), new Tinkering());
                // Some talents.
                // Blood Talents.
                m_char.DeathKnightTalents = new DeathKnightTalents("03322203130022011321000000000000000000000000000000000000000.00000000000000000000000000000");
            }
            m_char.CurrentModel = "TankDK";
            if (m_char.BossOptions == null || m_char.BossOptions.Attacks.Count <= 0)
            {
                BossList list = new BossList();
                BossHandler testboss = new BossHandler();
                testboss = list.GetBossFromName("Pit Lord Argaloth");

                m_char.BossOptions = new BossOptions();
                m_char.BossOptions.CloneThis(testboss);
            }
        }
 void OnTriggerEnter2D(Collider2D hitInfo)
 {
     if (hitInfo.CompareTag("Enemy"))
     {
         EnemyHandler enemy = hitInfo.GetComponent <EnemyHandler>();
         enemy.GetHealthSystem().Damage(dmg);
         enemy.KnockBack(400000);
         CreateText(hitInfo.transform.position);
     }
     else if (hitInfo.CompareTag("EnemyRanged"))
     {
         EnemyRangedHandler enemy = hitInfo.GetComponent <EnemyRangedHandler>();
         enemy.GetHealthSystem().Damage(dmg);
         enemy.KnockBack(400000);
         CreateText(hitInfo.transform.position);
     }
     else if (hitInfo.CompareTag("EnemySlower"))
     {
         EnemySlowerHandler enemy = hitInfo.GetComponent <EnemySlowerHandler>();
         enemy.GetHealthSystem().Damage(dmg);
         enemy.KnockBack(400000);
         CreateText(hitInfo.transform.position);
     }
     else if (hitInfo.CompareTag("Boss"))
     {
         BossHandler boss = hitInfo.GetComponent <BossHandler>();
         boss.GetHealthSystem().Damage(dmg);
         CreateText(hitInfo.transform.position);
     }
 }
Exemple #7
0
    // Use this for initialization
    void Start()
    {
        StartCoroutine(SpawnWaves());

        BossHandler bossHandler = FindObjectOfType <BossHandler>();

        bossHandler.waveBossListener = this;
    }
Exemple #8
0
    void Start()
    {
        scoreText.SetText("Score: 0");
        BossHandler bossHandler = FindObjectOfType <BossHandler>();

        bossHandler.scoreBoardListener = this;
        nextBossSpawnsIn = bossSpawnLimit;
    }
Exemple #9
0
    // Use this for initialization
    void Start()
    {
        scoreBoard  = FindObjectOfType <ScoreBoard>();
        audioSource = GetComponent <AudioSource>();
        BossHandler bossHandler = FindObjectOfType <BossHandler>();

        bossDeathListener = bossHandler;
    }
Exemple #10
0
        private void CB_BossList_SelectedIndexChanged(object sender, SelectionChangedEventArgs e)
        {
            string addInfo = "No Additional Info";

            try {
                if (!isLoading)
                {
                    addInfo = "Not Loading";
                    if (CB_BossList.SelectedIndex != 0)   // "Custom"
                    {
                        addInfo  += "\r\nCB_BossList.SelectedIndex != 0";
                        isLoading = true;
                        // Get Values
                        BossHandler boss = bosslist.GetBossFromBetterName(CB_BossList.SelectedItem.ToString()).Clone(); // "T7 : Naxxramas : 10 man : Patchwerk"
                        BossOptions.CloneThis(boss);
                        addInfo += "\r\nBoss Info Set";

                        // Set Controls to those Values
                        TB_BossInfo.Text = boss.GenInfoString(Character);

                        // Save the new names
                        if (!firstload)
                        {
                            addInfo += "\r\n!firstlost";
                            BossOptions.FilterType = (BossList.FilterType)CB_BL_FilterType.SelectedIndex;
                            BossOptions.Filter     = CB_BL_Filter.SelectedItem.ToString();
                            BossOptions.BossName   = CB_BossList.SelectedItem.ToString();
                        }
                        isLoading = false;
                    }
                    else
                    {
                        addInfo  += "\r\nCB_BossList.SelectedIndex == 0";
                        isLoading = true;
                        BossHandler boss = new BossHandler();
                        //
                        boss.Name            = "Custom";
                        BossOptions.BossName = boss.Name;
                        //
                        TB_BossInfo.Text = boss.GenInfoString(Character);
                        isLoading        = false;
                    }
                    bossOpts_PropertyChanged(null, null);
                }
            } catch (Exception ex) {
                new Base.ErrorBox()
                {
                    Title        = "Error in setting BossPicker Character settings from Boss",
                    Function     = "CB_BossList_SelectedIndexChanged()",
                    TheException = ex,
                }.Show();
                isLoading = false;
            }
        }
    public static BossHandler CreateEnemy(Vector3 spawnPosition, PlayerHandler playerHandler)
    {
        Transform   bossTransform = Instantiate(GameAssets.i.pfBoss, spawnPosition, Quaternion.identity);
        BossHandler bossHandler   = bossTransform.GetComponent <BossHandler>();

        HealthSystem healthSystem = new HealthSystem(700 + ((GameControl.control.lvl * GameControl.control.lvl) * 8));

        HealthBar healthBar = Instantiate(GameAssets.i.pfHealthBar, spawnPosition + new Vector3(0, 2.2f), Quaternion.identity, bossTransform).GetComponent <HealthBar>();

        healthBar.Setup(healthSystem);

        bossHandler.Setup(healthSystem);

        return(bossHandler);
    }
Exemple #12
0
        static void Main(string[] args)
        {
            Console.WriteLine("Hello Chain of Responsibility Pattern!");

            // Test();

            IHandler bossHandler = new BossHandler();
            // IHandler secretaryHandler = new SecretaryHandler();
            IHandler trashHandler = new TrashHandler();

            bossHandler
            // .SetNext(secretaryHandler)
            .SetNext(trashHandler);

            decimal amount = 2000;

            string result = bossHandler.Handle(amount);

            // CacheTest();
        }
 public void SetBoss(BossHandler boss)
 {
     _boss                   = boss;
     _bossName               = boss.Name;
     _targetLevel            = boss.Level;
     _targetArmor            = (int)boss.Armor;
     _fightLength            = boss.BerserkTimer / 60f;
     _inBack                 = ((_inBackPerc = (int)(boss.InBackPerc_Melee * 100f)) != 0);
     _targetFireResistance   = (float)boss.Resistance(ItemDamageType.Fire);
     _targetNatureResistance = (float)boss.Resistance(ItemDamageType.Nature);
     //_additionalTargets = (int)boss.MaxNumTargets - 1;
     {
         float value = 0;
         foreach (TargetGroup tg in boss.Targets)
         {
             if (tg.Chance <= 0 || tg.Frequency <= 0 || tg.Duration <= 0)
             {
                 continue;
             }
             value += tg.Frequency / boss.BerserkTimer * tg.Duration / 1000f;
         }
         float num = value / boss.Targets.Count;
         _additionalTargets = (int)num - 1;
     }
     //_additionalTargetPercent = (float)boss.MultiTargsPerc;
     {
         float time = 0;
         foreach (TargetGroup tg in boss.Targets)
         {
             if (tg.Chance <= 0 || tg.Frequency <= 0 || tg.Duration <= 0)
             {
                 continue;
             }
             time += tg.Frequency / boss.BerserkTimer * tg.Duration / 1000f;
         }
         float perc = time / boss.BerserkTimer;
         _additionalTargetPercent = Math.Max(0f, Math.Min(1f, perc));
     }
     _multipleTargets = _additionalTargets > 0 && _additionalTargetPercent > 0;
 }
    private void BossHandler_OnDead(object sender, System.EventArgs e)
    {
        BossHandler bossHandler = sender as BossHandler;

        FindObjectOfType <AudioManager>().Stop("Boss");
        playerHandler.GetRewards(500 + (lvl * 10), 0);
        GameControl.control.isXpMax = false;
        playerHandler.xp++;
        playerHandler.SaveRewards();
        GameControl.control.CalculateLevel();
        GameControl.control.Save();
        StartCoroutine(WinMessage());
        FindObjectOfType <AudioManager>().Play("MissionSuccess");
        bool asPlayed = false;

        if (!asPlayed)
        {
            StartCoroutine(PlayGuessYouWin());
            asPlayed = true;
        }

        Instantiate(GameAssets.i.psBoss, bossHandler.transform.position, Quaternion.identity);
    }
Exemple #15
0
        private BossHandler GenTheEZModeBoss(BossHandler[] passedList)
        {
            useGoodBoyAvg = true;
            BossHandler retboss = new BossHandler();
            if (passedList.Length < 1) { return retboss; }
            float value = 0f;
            #region Info
            retboss.Name = "An Easy Boss";
            value = (int)BossHandler.TierLevels.T11_25H; foreach (BossHandler boss in passedList) { value = Math.Min(value, (int)boss.Content); } retboss.Content = (BossHandler.TierLevels)Math.Floor(value);
            // Instance Skipped
            retboss.Comment = "An Easy Boss is a compilation of every Boss in your current filter. "
                            + "It takes the lightest values from every point of reference such as Health, "
                            + "Attack Damage, Movement and brings them into a single target.\r\nThe "
                            + "Primary intention of An Easy Boss is to help fresh 85's with getting ready "
                            + "to raid. Once you have the appropriate ilevels for raiding and can surpass the "
                            + "requirements listed above, you should move on to The Average Boss.";
            #endregion
            #region Basics
            value = passedList[0].Level; foreach (BossHandler boss in passedList) { value = Math.Min(value, boss.Level); } retboss.Level = (int)value;
            value = passedList[0].Armor; foreach (BossHandler boss in passedList) { value = Math.Min(value, boss.Armor); } retboss.Armor = (int)value;
            value = passedList[0].Health; foreach (BossHandler boss in passedList) { value = Math.Min(value, boss.Health); } retboss.Health = (int)value;

            {
                value = passedList[0].MobType;
                int[] counts = new int[] { 0, 0, 0, 0, 0, 0, 0 };
                foreach (BossHandler boss in passedList) {
                    counts[boss.MobType]++;
                }
                for (int m = 0; m < 7; m++)
                {
                    if (m != (int)value && counts[m] > counts[(int)value]) { value = m; }
                }
                if (counts[(int)value] == counts[(int)MOB_TYPES.HUMANOID]) { value = (int)MOB_TYPES.HUMANOID; }
                retboss.MobType = (int)value;
            }

            value = 1f; foreach (BossHandler boss in passedList) { value = Math.Max(value, boss.BerserkTimer); } retboss.BerserkTimer = (int)Math.Ceiling(value);
            value = 1f; foreach (BossHandler boss in passedList) { value = Math.Max(value, boss.SpeedKillTimer); } retboss.SpeedKillTimer = (int)Math.Ceiling(value);
            value = 0f; foreach (BossHandler boss in passedList) { value = Math.Max(value, (float)boss.InBackPerc_Melee); } retboss.InBackPerc_Melee = value;
            value = 0f; foreach (BossHandler boss in passedList) { value = Math.Max(value, (float)boss.InBackPerc_Ranged); } retboss.InBackPerc_Ranged = value;
            value = 25f; foreach (BossHandler boss in passedList) { value = Math.Min(value, boss.Min_Tanks); } retboss.Min_Tanks = (int)Math.Ceiling(value);
            value = 25f; foreach (BossHandler boss in passedList) { value = Math.Min(value, boss.Min_Healers); } retboss.Min_Healers = (int)Math.Ceiling(value);
            #endregion
            #region Offensive
            #region Multi-Targets
            {
                // Target Groups
                List<TargetGroup> groups = new List<TargetGroup>();
                foreach (BossHandler boss in passedList)
                {
                    groups.AddRange(boss.Targets.FindAll(a => a.Validate));
                }
                if (groups.Count > 0)
                {
                    TargetGroup toAdd;
                    CalculateEZTargetGroup(groups, retboss.Max_Players, "Easy Target Groups", out toAdd);
                    retboss.Targets.Add(toAdd);
                }
            }
            #endregion
            #region Attacks
            {
                {
                    // Regular Melee
                    List<Attack> attacks = new List<Attack>();
                    foreach (BossHandler boss in passedList) {
                        attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_MELEE) && a.Validate && !a.IsFromAnAdd && a.AttackSpeed < 5 && !a.DamageIsPerc && !a.IsDoT));
                    }
                    if (attacks.Count > 0) {
                        Attack toAdd;
                        CalculateEZAttack(attacks, retboss.Max_Players, "Easy Melee", true, out toAdd);
                        retboss.Attacks.Add(toAdd);
                    }
                }
                {
                    // Special Melee
                    List<Attack> attacks = new List<Attack>();
                    foreach (BossHandler boss in passedList) {
                        attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_MELEE) && a.Validate && a.AttackSpeed >= 5 && !a.DamageIsPerc && !a.IsDoT));
                    }
                    if (attacks.Count > 0) {
                        Attack toAdd;
                        CalculateEZAttack(attacks, retboss.Max_Players, "Easy Special Melee", false, out toAdd);
                        retboss.Attacks.Add(toAdd);
                    }
                }
                {
                    // Melee from Adds
                    List<Attack> attacks = new List<Attack>();
                    foreach (BossHandler boss in passedList) {
                        attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_MELEE) && a.Validate && a.IsFromAnAdd && a.AttackSpeed < 5 && !a.DamageIsPerc && !a.IsDoT));
                    }
                    if (attacks.Count > 0) {
                        Attack toAdd;
                        CalculateEZAttack(attacks, retboss.Max_Players, "Easy Melee from Adds", false, out toAdd);
                        retboss.Attacks.Add(toAdd);
                    }
                }
                {
                    // Ranged
                    List<Attack> attacks = new List<Attack>();
                    foreach (BossHandler boss in passedList) {
                        attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_RANGED) && a.Validate && !a.DamageIsPerc && !a.IsDoT));
                    }
                    if (attacks.Count > 0) {
                        Attack toAdd;
                        CalculateEZAttack(attacks, retboss.Max_Players, "Easy Ranged", false, out toAdd);
                        retboss.Attacks.Add(toAdd);
                    }
                }
                {
                    // AoE
                    List<Attack> attacks = new List<Attack>();
                    foreach (BossHandler boss in passedList) {
                        attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_AOE) && a.Validate && !a.DamageIsPerc && !a.IsDoT));
                    }
                    if (attacks.Count > 0) {
                        Attack toAdd;
                        CalculateEZAttack(attacks, retboss.Max_Players, "Easy AoE", false, out toAdd);
                        retboss.Attacks.Add(toAdd);
                    }
                }
                {
                    // DoTs
                    List<Attack> attacks = new List<Attack>();
                    foreach (BossHandler boss in passedList) {
                        attacks.AddRange(boss.Attacks.FindAll(a => a.IsDoT && a.Validate && !a.DamageIsPerc));
                    }
                    if (attacks.Count > 0) {
                        Attack toAdd;
                        CalculateEZAttack(attacks, retboss.Max_Players, "Easy DoT", false, out toAdd);
                        retboss.Attacks.Add(toAdd);
                    }
                }
            }
            #endregion
            #endregion
            #region Defensive
            foreach (ItemDamageType t in DamageTypes) {
                value = (float)passedList[0].Resistance(t);
                foreach (BossHandler boss in passedList) {
                    value = (float)Math.Min(value, boss.Resistance(t));
                }
                retboss.Resistance(t, value);
            }
            #endregion
            #region Impedances
            calcImp(passedList, ref retboss, 1, 1);
            calcImp(passedList, ref retboss, 2, 1);
            calcImp(passedList, ref retboss, 3, 1);
            calcImp(passedList, ref retboss, 4, 1);
            calcImp(passedList, ref retboss, 5, 1);
            calcImp(passedList, ref retboss, 6, 1);
            #endregion
            //
            return retboss;
        }
Exemple #16
0
 public static ComparisonCalculationBase GetBossCalculations(BossHandler boss, BossHandler easy, Character character, CharacterCalculationsBase currentCalcs)
 {
     return Instance.GetBossCalculations(boss, easy, character, currentCalcs);
 }
Exemple #17
0
 public virtual ComparisonCalculationBase GetBossCalculations(BossHandler boss, BossHandler easy, Character character, CharacterCalculationsBase currentCalcs)
 {
     ClearCache();
     CharacterCalculationsBase calcsEquipped = null;
     CharacterCalculationsBase calcsUnequipped = null;
     // only need to get unequipped value once not every time around the loop
     Character charUnequipped = character.Clone();
     charUnequipped.BossOptions = BossOptions.CloneBossHandler(easy);
     calcsUnequipped = GetCharacterCalculations(charUnequipped, null, false, false, false);
     //
     bool isEquipped = false;
     Character charEquipped = character.Clone();
     charUnequipped.BossOptions = BossOptions.CloneBossHandler(boss);
     calcsEquipped = GetCharacterCalculations(charEquipped, null, false, false, false);
     ComparisonCalculationBase bossCalc = CreateNewComparisonCalculation();
     bossCalc.Name = boss.Name + " (" + boss.ContentString + ")";
     bossCalc.Item = new Item(boss.Name + " (" + boss.ContentString + ")", ItemQuality.Temp, ItemType.None,
         boss.GetHashCode(), null, ItemSlot.None, null,
         false, new Stats(), null, ItemSlot.None, ItemSlot.None, ItemSlot.None,
         0, 0, ItemDamageType.Physical, 0, null);
     bossCalc.Equipped = isEquipped;
     bossCalc.OverallPoints = calcsEquipped.OverallPoints - calcsUnequipped.OverallPoints;
     float[] subPoints = new float[calcsEquipped.SubPoints.Length];
     for (int i = 0; i < calcsEquipped.SubPoints.Length; i++)
     {
         subPoints[i] = calcsEquipped.SubPoints[i] - calcsUnequipped.SubPoints[i];
     }
     bossCalc.SubPoints = subPoints;
     //bossCalc.ImageSource = boss.IconSource;
     //
     return bossCalc;
 }
Exemple #18
0
 private bool IsContent25Man(BossHandler.TierLevels tier) {
     if (tier == BossHandler.TierLevels.T11_25
         || tier == BossHandler.TierLevels.T11_25H
         || tier == BossHandler.TierLevels.T12_25
         || tier == BossHandler.TierLevels.T12_25H
         || tier == BossHandler.TierLevels.T13_LFR
         || tier == BossHandler.TierLevels.T13_25
         || tier == BossHandler.TierLevels.T13_25H)
     {
         return true;
     }
     return false;
 }
Exemple #19
0
 private BossHandler GenTheAvgBoss(BossHandler[] passedList) {
     useGoodBoyAvg = true;
     BossHandler retboss = new BossHandler();
     if (passedList.Length < 1) { return retboss; }
     float value = 0f;
     #region Info
     retboss.Name = "The Average Boss";
     value = 0; foreach (BossHandler boss in passedList) { value += (int)boss.Content; } retboss.Content = (BossHandler.TierLevels)Math.Floor(value / (float)passedList.Length);
     // Instance Skipped
     retboss.Comment = "The Average Boss is a compilation of every Boss in your current filter. "
                     + "It takes averaged values from every point of reference such as Health, "
                     + "Attack Damage, Movement and brings them into a single target.\r\nMost "
                     + "users should perform calculations against this specialized Boss to get a "
                     + "solid view of your current preparedness for any given fight.";
     #endregion
     #region Basics
     value = 0f; foreach (BossHandler boss in passedList) { value += boss.Level; } value /= passedList.Length; retboss.Level = (int)value;
     value = 0f; foreach (BossHandler boss in passedList) { value += boss.Armor; } value /= passedList.Length; retboss.Armor = (int)value;
     {
         value = passedList[0].MobType;
         int[] counts = new int[] { 0, 0, 0, 0, 0, 0, 0 };
         foreach (BossHandler boss in passedList)
         {
             counts[boss.MobType]++;
         }
         for (int m = 0; m < 7; m++)
         {
             if (m != (int)value && counts[m] > counts[(int)value]) { value = m; }
         }
         if (counts[(int)value] == counts[(int)MOB_TYPES.HUMANOID]) { value = (int)MOB_TYPES.HUMANOID; }
         retboss.MobType = (int)value;
     }
     value = 0f; foreach (BossHandler boss in passedList) { value += boss.BerserkTimer; } value /= passedList.Length; retboss.BerserkTimer = (int)Math.Floor(value);
     value = 0f; foreach (BossHandler boss in passedList) { value += boss.SpeedKillTimer; } value /= passedList.Length; retboss.SpeedKillTimer = (int)Math.Floor(value);
     value = 0f; foreach (BossHandler boss in passedList) { value += boss.Health; } value /= passedList.Length; retboss.Health = value;
     value = 0f; foreach (BossHandler boss in passedList) { value += (float)boss.InBackPerc_Melee; } value /= passedList.Length; retboss.InBackPerc_Melee = value;
     value = 0f; foreach (BossHandler boss in passedList) { value += (float)boss.InBackPerc_Ranged; } value /= passedList.Length; retboss.InBackPerc_Ranged = value;
     bool is25 = false;
     foreach (BossHandler boss in passedList) { if (IsContent25Man(boss.Content)) { is25 = true; break; } }
     retboss.Max_Players = is25 ? 25 : 10;
     value = 0f; foreach (BossHandler boss in passedList) { value += boss.Min_Tanks; } value /= passedList.Length; retboss.Min_Tanks = (int)Math.Floor(value);
     value = 0f; foreach (BossHandler boss in passedList) { value += boss.Min_Healers; } value /= passedList.Length; retboss.Min_Healers = (int)Math.Floor(value);
     #endregion
     #region Offensive
     #region MultiTargs
     {
         // Target Groups
         List<TargetGroup> groups = new List<TargetGroup>();
         foreach (BossHandler boss in passedList)
         {
             groups.AddRange(boss.Targets.FindAll(a => a.Validate));
         }
         if (groups.Count > 0)
         {
             TargetGroup toAdd;
             CalculateAvgTargetGroup(groups, retboss.BerserkTimer, retboss.Max_Players, "Avg Target Groups", out toAdd);
             retboss.Targets.Add(toAdd);
         }
     }
     #endregion
     #region Attacks
     {
         {
             // Regular Melee
             List<Attack> attacks = new List<Attack>();
             foreach (BossHandler boss in passedList)
             {
                 attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_MELEE) && a.Validate && !a.IsFromAnAdd && a.AttackSpeed < 5 && !a.DamageIsPerc && !a.IsDoT));
             }
             if (attacks.Count > 0)
             {
                 Attack toAdd;
                 CalculateAvgAttack(attacks, retboss.BerserkTimer, retboss.Max_Players, "Avg Melee", true, out toAdd);
                 toAdd.PhaseTimes[1] = new float[] { 0f, retboss.BerserkTimer }; // Since this is the default melee, force it back to 100% uptime
                 retboss.Attacks.Add(toAdd);
             }
         }
         {
             // Special Melee
             List<Attack> attacks = new List<Attack>();
             foreach (BossHandler boss in passedList)
             {
                 attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_MELEE) && a.Validate && a.AttackSpeed >= 5 && !a.DamageIsPerc && !a.IsDoT));
             }
             if (attacks.Count > 0)
             {
                 Attack toAdd;
                 CalculateAvgAttack(attacks, retboss.BerserkTimer, retboss.Max_Players, "Avg Special Melee", false, out toAdd);
                 retboss.Attacks.Add(toAdd);
             }
         }
         {
             // Melee from Adds
             List<Attack> attacks = new List<Attack>();
             foreach (BossHandler boss in passedList)
             {
                 attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_MELEE) && a.Validate && a.IsFromAnAdd && a.AttackSpeed < 5 && !a.DamageIsPerc && !a.IsDoT));
             }
             if (attacks.Count > 0)
             {
                 Attack toAdd;
                 CalculateAvgAttack(attacks, retboss.BerserkTimer, retboss.Max_Players, "Avg Melee from Adds", true, out toAdd);
                 retboss.Attacks.Add(toAdd);
             }
         }
         {
             // Ranged
             List<Attack> attacks = new List<Attack>();
             foreach (BossHandler boss in passedList)
             {
                 attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_RANGED) && a.Validate && !a.DamageIsPerc && !a.IsDoT));
             }
             if (attacks.Count > 0)
             {
                 Attack toAdd;
                 CalculateAvgAttack(attacks, retboss.BerserkTimer, retboss.Max_Players, "Avg Ranged", false, out toAdd);
                 retboss.Attacks.Add(toAdd);
             }
         }
         {
             // AoE
             List<Attack> attacks = new List<Attack>();
             foreach (BossHandler boss in passedList)
             {
                 attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_AOE) && a.Validate && !a.DamageIsPerc && !a.IsDoT));
             }
             if (attacks.Count > 0)
             {
                 Attack toAdd;
                 CalculateAvgAttack(attacks, retboss.BerserkTimer, retboss.Max_Players, "Avg AoE", false, out toAdd);
                 retboss.Attacks.Add(toAdd);
             }
         }
         {
             // DoTs
             List<Attack> attacks = new List<Attack>();
             foreach (BossHandler boss in passedList)
             {
                 attacks.AddRange(boss.Attacks.FindAll(a => a.IsDoT && a.Validate && !a.DamageIsPerc));
             }
             if (attacks.Count > 0)
             {
                 Attack toAdd;
                 CalculateAvgAttack(attacks, retboss.BerserkTimer, retboss.Max_Players, "Avg DoT", false, out toAdd);
                 retboss.Attacks.Add(toAdd);
             }
         }
     }
     #endregion
     #endregion
     #region Defensive
     foreach (ItemDamageType t in DamageTypes) {
         value = 0f;
         foreach (BossHandler boss in passedList) {
             value += (float)boss.Resistance(t);
         }
         value /= passedList.Length;
         retboss.Resistance(t, value);
     }
     #endregion
     #region Impedances
     calcImp(passedList, ref retboss, 1, 2);
     calcImp(passedList, ref retboss, 2, 2);
     calcImp(passedList, ref retboss, 3, 2);
     calcImp(passedList, ref retboss, 4, 2);
     calcImp(passedList, ref retboss, 5, 2);
     calcImp(passedList, ref retboss, 6, 2);
     #endregion
     //
     return retboss;
 }
Exemple #20
0
 private void calcImp(BossHandler[] passedList, ref BossHandler retboss, int type, int level) {
     List<Impedance> imps = new List<Impedance>();
     foreach (BossHandler boss in passedList)
     {
         switch (type)
         {
             case 1: { imps.AddRange(boss.Moves.FindAll(a => a.Validate)); break; }
             case 2: { imps.AddRange(boss.Stuns.FindAll(a => a.Validate)); break; }
             case 3: { imps.AddRange(boss.Fears.FindAll(a => a.Validate)); break; }
             case 4: { imps.AddRange(boss.Roots.FindAll(a => a.Validate)); break; }
             case 5: { imps.AddRange(boss.Silences.FindAll(a => a.Validate)); break; }
             case 6: { imps.AddRange(boss.Disarms.FindAll(a => a.Validate)); break; }
             default: { break; }
         }
     }
     if (imps.Count > 0)
     {
         Impedance toAdd;
         switch (level)
         {
             case 1: { CalculateEZImpedance(imps, retboss.Max_Players, "Easy ", out toAdd); break; }
             case 2: { CalculateAvgImpedance(imps, retboss.BerserkTimer, retboss.Max_Players, "Avg ", out toAdd); break; }
             case 3:
             default: { CalculateHardImpedance(imps, retboss.Max_Players, "Impossible ", out toAdd); break; }
         }
         switch (type)
         {
             case 1: { toAdd.Name += "Movement"; retboss.Moves.Add(toAdd); break; }
             case 2: { toAdd.Name += "Stuns"; retboss.Stuns.Add(toAdd); break; }
             case 3: { toAdd.Name += "Fears"; retboss.Fears.Add(toAdd); break; }
             case 4: { toAdd.Name += "Roots"; retboss.Roots.Add(toAdd); break; }
             case 5: { toAdd.Name += "Silences"; retboss.Silences.Add(toAdd); break; }
             case 6: { toAdd.Name += "Disarms"; retboss.Disarms.Add(toAdd); break; }
             default: { break; }
         }
     }
 }
Exemple #21
0
    IEnumerator AoE()
    {
        aoe = true;
        audioManager.Play("Explosion");
        gameObject.GetComponent <ParticleSystem>().Play();

        StartCoroutine(FadeTo(aoeCd, aoeFire));

        Collider2D[] enemiesToDamage = Physics2D.OverlapCircleAll(transform.position, attackRange * 4, whatIsEnemies);

        for (int i = 0; i < enemiesToDamage.Length; i++)
        {
            if (enemiesToDamage[i].gameObject.CompareTag("EnemyRanged"))
            {
                EnemyRangedHandler enemy = enemiesToDamage[i].GetComponent <EnemyRangedHandler>();
                enemy.GetHealthSystem().Damage(aoeDmg);
                enemy.KnockBack(1000000);

                CreateText(Color.grey, new Vector3(enemy.transform.position.x, enemy.transform.position.y + 1), new Vector2(0, 5), "-" + aoeDmg);
                if (enemy.GetHealthSystem().GetHealthPercent() < 0.25)
                {
                    enemy.GetComponent <SpriteRenderer>().color = new Color(1f, 1f, 1f, 0.5f);
                }
            }
            else if (enemiesToDamage[i].gameObject.CompareTag("Enemy"))
            {
                EnemyHandler enemy = enemiesToDamage[i].GetComponent <EnemyHandler>();
                enemy.GetHealthSystem().Damage(aoeDmg);
                enemy.KnockBack(1000000);

                CreateText(Color.grey, new Vector3(enemy.transform.position.x, enemy.transform.position.y + 1), new Vector2(0, 5), "-" + aoeDmg);
                if (enemy.GetHealthSystem().GetHealthPercent() < 0.25)
                {
                    enemy.GetComponent <SpriteRenderer>().color = new Color(1f, 1f, 1f, 0.5f);
                }
            }
            else if (enemiesToDamage[i].gameObject.CompareTag("EnemySlower"))
            {
                EnemySlowerHandler enemy = enemiesToDamage[i].GetComponent <EnemySlowerHandler>();
                enemy.GetHealthSystem().Damage(aoeDmg);
                enemy.KnockBack(1000000);

                CreateText(Color.grey, new Vector3(enemy.transform.position.x, enemy.transform.position.y + 1), new Vector2(0, 5), "-" + aoeDmg);
                if (enemy.GetHealthSystem().GetHealthPercent() < 0.25)
                {
                    enemy.GetComponent <SpriteRenderer>().color = new Color(1f, 1f, 1f, 0.5f);
                }
            }
            else if (enemiesToDamage[i].gameObject.CompareTag("Boss"))
            {
                BossHandler boss = enemiesToDamage[i].GetComponent <BossHandler>();
                boss.GetHealthSystem().Damage(aoeDmg);

                CreateText(Color.grey, new Vector3(boss.transform.position.x, boss.transform.position.y + 1), new Vector2(0, 5), "-" + aoeDmg);
                if (boss.GetHealthSystem().GetHealthPercent() < 0.25)
                {
                    boss.GetComponent <SpriteRenderer>().color = new Color(1f, 1f, 1f, 0.5f);
                }
            }
        }
        yield return(new WaitForSeconds(aoeCd));

        aoeFire.color = new Color(1, 1, 1, 1);
        aoe           = false;
    }
Exemple #22
0
 private BossHandler GenTheHardestBoss(BossHandler[] passedList) {
     useGoodBoyAvg = false;
     BossHandler retboss = new BossHandler();
     if (passedList.Length < 1) { return retboss; }
     float value = 0f;
     #region Info
     retboss.Name = "An Impossible Boss";
     value = 0; foreach (BossHandler boss in passedList) { value = Math.Max(value, (int)boss.Content); } retboss.Content = (BossHandler.TierLevels)Math.Ceiling(value);
     // Instance Skipped
     retboss.Comment = "An Impossible Boss is a compilation of every Boss in your current filter. "
                     + "It takes the hardest values from every point of reference such as Health, "
                     + "Attack Damage, Movement and brings them into a single target.\r\nThe "
                     + "Primary intention of An Impossible Boss is really just for kicks, you are not "
                     + "expected to ever surpass these values and no boss in the game would ever be "
                     + "as difficult to beat.";
     #endregion
     #region Basics
     value = 0f; foreach (BossHandler boss in passedList) { value = Math.Max(value, boss.Level); } retboss.Level = (int)value;
     value = 0f; foreach (BossHandler boss in passedList) { value = Math.Max(value, boss.Armor); } retboss.Armor = (int)value;
     {
         value = passedList[0].MobType;
         int[] counts = new int[] { 0, 0, 0, 0, 0, 0, 0 };
         foreach (BossHandler boss in passedList)
         {
             counts[boss.MobType]++;
         }
         for (int m = 0; m < 7; m++)
         {
             if (m != (int)value && counts[m] > counts[(int)value]) { value = m; }
         }
         if (counts[(int)value] == counts[(int)MOB_TYPES.HUMANOID]) { value = (int)MOB_TYPES.HUMANOID; }
         retboss.MobType = (int)value;
     }
     value = 0f; foreach (BossHandler boss in passedList) { value = Math.Max(value, boss.Health); } retboss.Health = value;
     value = passedList[0].BerserkTimer; foreach (BossHandler boss in passedList) { value = Math.Min(value, boss.BerserkTimer); } retboss.BerserkTimer = (int)Math.Floor(value);
     value = passedList[0].SpeedKillTimer; foreach (BossHandler boss in passedList) { value = Math.Min(value, boss.SpeedKillTimer); } retboss.SpeedKillTimer = (int)Math.Floor(value);
     value = 1.00f;      foreach (BossHandler boss in passedList) { value = (float)Math.Min(value, boss.InBackPerc_Melee   ); } retboss.InBackPerc_Melee  = value;
     value = 1.00f;      foreach (BossHandler boss in passedList) { value = (float)Math.Min(value, boss.InBackPerc_Ranged  ); } retboss.InBackPerc_Ranged = value;
     bool is25 = false;
     foreach (BossHandler boss in passedList) { if (IsContent25Man(boss.Content)) { is25 = true; break; } }
     retboss.Max_Players = is25 ? 25 : 10;
     value = 0; foreach (BossHandler boss in passedList) { value = Math.Max(value, boss.Min_Tanks); } retboss.Min_Tanks = (int)value;
     value = 0; foreach (BossHandler boss in passedList) { value = Math.Max(value, boss.Min_Healers); } retboss.Min_Healers = (int)value;
     #endregion
     #region Offensive
     #region MultiTargs
     {
         // Target Groups
         List<TargetGroup> groups = new List<TargetGroup>();
         foreach (BossHandler boss in passedList)
         {
             groups.AddRange(boss.Targets.FindAll(a => a.Validate));
         }
         if (groups.Count > 0)
         {
             TargetGroup toAdd;
             CalculateHardTargetGroup(groups, retboss.Max_Players, "Hard Target Groups", out toAdd);
             retboss.Targets.Add(toAdd);
         }
     }
     #endregion
     #region Attacks
     {
         {
             // Regular Melee
             List<Attack> attacks = new List<Attack>();
             foreach (BossHandler boss in passedList)
             {
                 attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_MELEE) && a.Validate && !a.IsFromAnAdd && a.AttackSpeed < 5 && !a.DamageIsPerc && !a.IsDoT));
             }
             if (attacks.Count > 0)
             {
                 Attack toAdd;
                 CalculateHardAttack(attacks, retboss.Max_Players, "Impossible Melee", true, out toAdd);
                 retboss.Attacks.Add(toAdd);
             }
         }
         {
             // Special Melee
             List<Attack> attacks = new List<Attack>();
             foreach (BossHandler boss in passedList)
             {
                 attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_MELEE) && a.Validate && a.AttackSpeed >= 5 && !a.DamageIsPerc && !a.IsDoT));
             }
             if (attacks.Count > 0)
             {
                 Attack toAdd;
                 CalculateHardAttack(attacks, retboss.Max_Players, "Impossible Special Melee", false, out toAdd);
                 retboss.Attacks.Add(toAdd);
             }
         }
         {
             // Melee from Adds
             List<Attack> attacks = new List<Attack>();
             foreach (BossHandler boss in passedList)
             {
                 attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_MELEE) && a.Validate && a.IsFromAnAdd && a.AttackSpeed < 5 && !a.DamageIsPerc && !a.IsDoT));
             }
             if (attacks.Count > 0)
             {
                 Attack toAdd;
                 CalculateHardAttack(attacks, retboss.Max_Players, "Impossible Melee from Adds", true, out toAdd);
                 retboss.Attacks.Add(toAdd);
             }
         }
         {
             // Ranged
             List<Attack> attacks = new List<Attack>();
             foreach (BossHandler boss in passedList)
             {
                 attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_RANGED) && a.Validate && !a.DamageIsPerc && !a.IsDoT));
             }
             if (attacks.Count > 0)
             {
                 Attack toAdd;
                 CalculateHardAttack(attacks, retboss.Max_Players, "Impossible Ranged", false, out toAdd);
                 retboss.Attacks.Add(toAdd);
             }
         }
         {
             // AoE
             List<Attack> attacks = new List<Attack>();
             foreach (BossHandler boss in passedList)
             {
                 attacks.AddRange(boss.Attacks.FindAll(a => (a.AttackType == ATTACK_TYPES.AT_AOE) && a.Validate && !a.DamageIsPerc && !a.IsDoT));
             }
             if (attacks.Count > 0)
             {
                 Attack toAdd;
                 CalculateHardAttack(attacks, retboss.Max_Players, "Impossible AoE", false, out toAdd);
                 retboss.Attacks.Add(toAdd);
             }
         }
         {
             // DoTs
             List<Attack> attacks = new List<Attack>();
             foreach (BossHandler boss in passedList)
             {
                 attacks.AddRange(boss.Attacks.FindAll(a => a.IsDoT && a.Validate && !a.DamageIsPerc));
             }
             if (attacks.Count > 0)
             {
                 Attack toAdd;
                 CalculateHardAttack(attacks, retboss.Max_Players, "Impossible DoT", false, out toAdd);
                 retboss.Attacks.Add(toAdd);
             }
         }
     }
     #endregion
     #endregion
     #region Defensive
     foreach (ItemDamageType t in DamageTypes) { value = 0f; foreach (BossHandler boss in passedList) { value = (float)Math.Max(value, boss.Resistance(t)); } retboss.Resistance(t, value); }
     #endregion
     #region Impedances
     calcImp(passedList, ref retboss, 1, 3);
     calcImp(passedList, ref retboss, 2, 3);
     calcImp(passedList, ref retboss, 3, 3);
     calcImp(passedList, ref retboss, 4, 3);
     calcImp(passedList, ref retboss, 5, 3);
     calcImp(passedList, ref retboss, 6, 3);
     #endregion
     //
     return retboss;
 }
Exemple #23
0
 public BossHandler[] GenCalledList(FilterType ftype, string Filter) {
     if (Filter.Equals("All",StringComparison.OrdinalIgnoreCase)) {
         // Resets the calledList to the full, unfiltered List
         TheEZModeBoss_Called  = TheEZModeBoss;
         TheAvgBoss_Called     = TheAvgBoss;
         TheHardestBoss_Called = TheHardestBoss;
         return calledList = list;
     }
     // Generate a list based upon the specialized Filter, only 1 thing can be compared at a time though
     List<BossHandler> retList = new List<BossHandler>();
     foreach (BossHandler boss in list) {
         switch (ftype) {
             case FilterType.Content:  { if (boss.ContentString.Equals( Filter,StringComparison.OrdinalIgnoreCase)) { retList.Add(boss); } break; }
             case FilterType.Instance: { if (boss.Instance.Equals(Filter,StringComparison.OrdinalIgnoreCase)) { retList.Add(boss); } break; }
             case FilterType.Name:     { if (boss.Name.Equals(    Filter,StringComparison.OrdinalIgnoreCase)) { retList.Add(boss); } break; }
             default: { /*Invalid type, do nothing*/ break; }
         }
     }
     BossHandler[] retList2 = retList.ToArray();
     // Gen the special bosses based upon this filtered list
     TheEZModeBoss_Called  = GenTheEZModeBoss(retList2);
     TheAvgBoss_Called     = GenTheAvgBoss(retList2);
     TheHardestBoss_Called = GenTheHardestBoss(retList2);
     return calledList = retList2;
 }
Exemple #24
0
 public BossHandler GetBossFromName(string name) {
     BossHandler retBoss = new BossHandler();
     if      (TheEZModeBoss_Called.Name  == name) { retBoss = TheEZModeBoss_Called;  }
     else if (TheAvgBoss_Called.Name     == name) { retBoss = TheAvgBoss_Called;     }
     else if (TheHardestBoss_Called.Name == name) { retBoss = TheHardestBoss_Called; }
     else {
         foreach (BossHandler boss in calledList) {
             if(boss.Name == name){
                 retBoss = boss;
                 break;
             }
         }
     }
     return retBoss;
 }
Exemple #25
0
 public BossHandler GetBossFromBetterName(string name) {
     BossHandler retBoss = new BossHandler();
     if      (TheEZModeBoss_Called.Name  == name) { retBoss = TheEZModeBoss_Called;  }
     else if (TheAvgBoss_Called.Name     == name) { retBoss = TheAvgBoss_Called;     }
     else if (TheHardestBoss_Called.Name == name) { retBoss = TheHardestBoss_Called; }
     else {
         foreach (BossHandler boss in calledList) {
             string checkName = boss.ContentString + " : " + boss.Instance + " : " + boss.Name;
             if(checkName == name){
                 retBoss = boss;
                 break;
             }
         }
     }
     return retBoss;
 }
Exemple #26
0
        // Constructors
        public BossList()
        {
            #region Instance Declarations
            #region ==== Tier 7 Content ====
            // Naxxramas
            //AnubRekhan anubrekhan = new AnubRekhan();
            //GrandWidowFaerlina grandwidow = new GrandWidowFaerlina();
            //Maexxna maexxna = new Maexxna();
            //NoththePlaguebringer noth = new NoththePlaguebringer();
            //HeigantheUnclean heigantheUnclean = new HeigantheUnclean();
            //Loatheb loatheb = new Loatheb();
            //InstructorRazuvious instructorRazuvious = new InstructorRazuvious();
            //GothiktheHarvester gothiktheHarvester = new GothiktheHarvester();
            //FourHorsemen fourHorsemen = new FourHorsemen();
            //Patchwerk patchwerk = new Patchwerk();
            //Grobbulus grobbulus = new Grobbulus();
            //Gluth gluth = new Gluth();
            //Thaddius thaddius = new Thaddius();
            //Sapphiron sapphiron = new Sapphiron();
            //KelThuzad kelThuzad = new KelThuzad();
            // The Obsidian Sanctum
            //Shadron shadron = new Shadron();
            //Tenebron tenebron = new Tenebron();
            //Vesperon vesperon = new Vesperon();
            //Sartharion sartharion = new Sartharion();
            // The Vault of Archavon
            //ArchavonTheStoneWatcher archavon = new ArchavonTheStoneWatcher();
            // The Eye of Eternity
            //Malygos malygos = new Malygos();
            #endregion
            #region ==== Tier 8 Content ====
            // Ulduar
            //IgnistheFurnaceMaster IgnistheFurnaceMaster = new IgnistheFurnaceMaster();
            //Razorscale Razorscale = new Razorscale();
            //XT002Deconstructor XT002Deconstructor = new XT002Deconstructor();
            //AssemblyofIron AssemblyofIron = new AssemblyofIron();
            //Kologarn Kologarn = new Kologarn();
            //Auriaya Auriaya = new Auriaya();
            //Mimiron Mimiron = new Mimiron();
            //Freya Freya = new Freya();
            //Thorim Thorim = new Thorim();
            //Hodir Hodir = new Hodir();
            //GeneralVezax GeneralVezax = new GeneralVezax();
            //YoggSaron YoggSaron = new YoggSaron();
            //AlgalontheObserver AlgalontheObserver = new AlgalontheObserver();
            // Vault of Archavon
            //EmalonTheStormWatcher EmalonTheStormWatcher = new EmalonTheStormWatcher();
            #endregion
            #region ==== Tier 9 Content ====
            // The Vault of Archavon
            //KoralonTheFlameWatcher KoralonTheFlameWatcher = new KoralonTheFlameWatcher();
            // Trial of the Crusader
            //NorthrendBeasts NorthrendBeasts = new NorthrendBeasts();
            //LordJaraxxus LordJaraxxus = new LordJaraxxus();
            //FactionChampions FactionChampions = new FactionChampions();
            //TwinValkyr TwinValkyr = new TwinValkyr();
            //Anubarak Anubarak = new Anubarak();
            #endregion
            #region ==== Tier 10 Content ====
            // The Vault of Archavon
            //ToravonTheIceWatcher ToravonTheIceWatcher = new ToravonTheIceWatcher();
            // Icecrown Citadel
            //LordMarrowgar LordMarrowgar = new LordMarrowgar();
            //LadyDeathwhisper LadyDeathwhisper = new LadyDeathwhisper();
            //DeathbringerSaurfang DeathbringerSaurfang = new DeathbringerSaurfang();
            //Festergut Festergut = new Festergut();
            //Rotface Rotface = new Rotface();
            //ProfessorPutricide ProfessorPutricide = new ProfessorPutricide();
            //BloodPrinceCouncil BloodPrinceCouncil = new BloodPrinceCouncil();
            //BloodQueenLanathel BloodQueenLanathel = new BloodQueenLanathel();
            //ValathriaDreamwalker ValathriaDreamwalker = new ValathriaDreamwalker();
            //Sindragosa Sindragosa = new Sindragosa();
            //TheLichKing TheLichKing = new TheLichKing();
            // Ruby Sanctum
            //Baltharus Baltharus = new Baltharus();
            //SavianaRagefire SavianaRagefire = new SavianaRagefire();
            //GeneralZarithrian GeneralZarithrian = new GeneralZarithrian();
            //Halion Halion = new Halion();
            #endregion
            #region ==== Tier 11 Content ====
            // Baradin Hold
            Argaloth Argaloth = new Argaloth();
            // Blackwing Descent
            Magmaw Magmaw = new Magmaw();
            OmnotronDefenseSystem OmnotronDefenseSystem = new OmnotronDefenseSystem();
            Maloriak Maloriak = new Maloriak();
            Atramedes Atramedes = new Atramedes();
            Chimaron Chimaron = new Chimaron();
            Nefarian Nefarian = new Nefarian();
            // The Bastion of Twilight
            ValionaAndTheralion ValionaAndTheralion = new ValionaAndTheralion();
            HalfusWyrmbreaker HalfusWyrmbreaker = new HalfusWyrmbreaker();
            TwilightAscendantCouncil TwilightAscendantCouncil = new TwilightAscendantCouncil();
            Chogall Chogall = new Chogall();
            LadySinestra LadySinestra = new LadySinestra();
            // Throne of the Four Winds
            ConclaveOfWind ConclaveOfWind = new ConclaveOfWind();
            AlAkir AlAkir = new AlAkir();
            #endregion
            #region ==== Tier 12 Content ====
            // Baradin Hold
            Occuthar Occuthar = new Occuthar();
            // Fireland
            Bethtilac Bethtilac = new Bethtilac();
            LordRhyolith LordRhyolith = new LordRhyolith();
            Alysrazor Alysrazor = new Alysrazor();
            Shannox Shannox = new Shannox();
            Baleroc Baleroc = new Baleroc();
            MajordomoStaghelm MajordomoStaghelm = new MajordomoStaghelm();
            Ragnaros Ragnaros = new Ragnaros();
            #endregion
            #region ==== Tier 13 Content ====
//            // Baradin Hold
//            Alizabal Alizabal = new Alizabal();
//            // Dragon Soul
//            Morchok Morchok = new Morchok();
//            WarlordZonozz WarlordZonozz = new WarlordZonozz();
//            Yorsahj Yorsahj = new Yorsahj();
//            Hagara Hagara = new Hagara();
//            Ultraxion Ultraxion = new Ultraxion();
//            WarmasterBlackhorn WarmasterBlackhorn = new WarmasterBlackhorn();
//            SpineofDeathwing SpineofDeathwing = new SpineofDeathwing();
//            MadnessofDeathwing MadnessofDeathwing = new MadnessofDeathwing();
            #endregion
            #endregion
            list = new BossHandler[] {
                #region ==== Tier 7 Content ====
                // Naxxramas
                //anubrekhan[0],anubrekhan[1],
                //grandwidow[0],grandwidow[1],
                //maexxna[0],maexxna[1],
                //noth[0],noth[1],
                //heigantheUnclean[0],heigantheUnclean[1],
                //loatheb[0],loatheb[1],
                //instructorRazuvious[0],instructorRazuvious[1],
                //gothiktheHarvester[0],gothiktheHarvester[1],
                //fourHorsemen[0],fourHorsemen[1],
                //patchwerk[0],patchwerk[1],
                //grobbulus[0],grobbulus[1],
                //gluth[0],gluth[1],
                //thaddius[0],thaddius[1],
                //sapphiron[0],sapphiron[1],
                //kelThuzad[0],kelThuzad[1],
                // The Obsidian Sanctum
                //shadron[0],shadron[1],
                //tenebron[0],tenebron[1],
                //vesperon[0],vesperon[1],
                //sartharion[0],sartharion[1],
                // Vault of Archavon
                //archavon[0],archavon[1],
                // The Eye of Eternity
                //malygos[0],malygos[1],
                #endregion
                #region ==== Tier 8 Content ====
                // Ulduar
                //IgnistheFurnaceMaster[0],IgnistheFurnaceMaster[1],
                //Razorscale[0],Razorscale[1],
                //XT002Deconstructor[0],XT002Deconstructor[1],
                //AssemblyofIron[0],AssemblyofIron[1],
                //Kologarn[0],Kologarn[1],
                //Auriaya[0],Auriaya[1],
                //Mimiron[0],Mimiron[1],
                //Freya[0],Freya[1],
                //Thorim[0],Thorim[1],
                //Hodir[0],Hodir[1],
                //GeneralVezax[0],GeneralVezax[1],
                //YoggSaron[0],YoggSaron[1],
                //AlgalontheObserver[0],AlgalontheObserver[1],
                // Vault of Archavon
                //EmalonTheStormWatcher[0], EmalonTheStormWatcher[1],
                #endregion
                #region ==== Tier 9 Content ====
                // Vault of Archavon
                //KoralonTheFlameWatcher[0],KoralonTheFlameWatcher[1],
                // Trial of the Crusader
                //NorthrendBeasts[0],NorthrendBeasts[1],NorthrendBeasts[2],NorthrendBeasts[3],
                //LordJaraxxus[0],LordJaraxxus[1],LordJaraxxus[2],LordJaraxxus[3],
                //FactionChampions[0],FactionChampions[1],FactionChampions[2],FactionChampions[3],
                //TwinValkyr[0],TwinValkyr[1],TwinValkyr[2],TwinValkyr[3],
                //Anubarak[0],Anubarak[1],Anubarak[2],Anubarak[3],
                #endregion
                #region ==== Tier 10 Content ====
                // Vault of Archavon
                //ToravonTheIceWatcher[0],ToravonTheIceWatcher[1],
                // Icecrown Citadel
                //LordMarrowgar[0],LordMarrowgar[1],LordMarrowgar[2],LordMarrowgar[3],
                //LadyDeathwhisper[0],LadyDeathwhisper[1],LadyDeathwhisper[2],LadyDeathwhisper[3],
                //DeathbringerSaurfang[0], DeathbringerSaurfang[1], DeathbringerSaurfang[2], DeathbringerSaurfang[3],
                //Festergut[0], Festergut[1], Festergut[2], Festergut[3],
                //Rotface[0], Rotface[1], Rotface[2], Rotface[3],
                //ProfessorPutricide[0], ProfessorPutricide[1], ProfessorPutricide[2], ProfessorPutricide[3],
                //BloodPrinceCouncil[0], BloodPrinceCouncil[1], BloodPrinceCouncil[2], BloodPrinceCouncil[3],
                //BloodQueenLanathel[0], BloodQueenLanathel[1], BloodQueenLanathel[2], BloodQueenLanathel[3],
                //ValathriaDreamwalker[0], ValathriaDreamwalker[1], ValathriaDreamwalker[2], ValathriaDreamwalker[3],
                //Sindragosa[0], Sindragosa[1], Sindragosa[2], Sindragosa[3],
                //TheLichKing[0], TheLichKing[1], TheLichKing[2], TheLichKing[3],
                // Ruby Sanctum
                //Baltharus[0],Baltharus[1],Baltharus[2],Baltharus[3],
                //SavianaRagefire[0],SavianaRagefire[1],SavianaRagefire[2],SavianaRagefire[3],
                //GeneralZarithrian[0],GeneralZarithrian[1],GeneralZarithrian[2],GeneralZarithrian[3],
                //Halion[0],Halion[1],Halion[2],Halion[3],
                #endregion
                #region ==== Tier 11 Content ====
                // Baradin Hold
                Argaloth[0], Argaloth[1],
                // Blackwing Descent
                Magmaw[0],Magmaw[1],Magmaw[2],Magmaw[3],
                OmnotronDefenseSystem[0],OmnotronDefenseSystem[1],OmnotronDefenseSystem[2],OmnotronDefenseSystem[3],
                Maloriak[0], Maloriak[1], Maloriak[2], Maloriak[3],
                Atramedes[0], Atramedes[1], Atramedes[2], Atramedes[3],
                Chimaron[0], Chimaron[1], Chimaron[2], Chimaron[3],
                Nefarian[0], Nefarian[1], Nefarian[2], Nefarian[3],
                // The Bastion of Twilight
                ValionaAndTheralion[0], ValionaAndTheralion[1], ValionaAndTheralion[2], ValionaAndTheralion[3],
                HalfusWyrmbreaker[0], HalfusWyrmbreaker[1], HalfusWyrmbreaker[2], HalfusWyrmbreaker[3],
                TwilightAscendantCouncil[0], TwilightAscendantCouncil[1], TwilightAscendantCouncil[2], TwilightAscendantCouncil[3],
                Chogall[0], Chogall[1], Chogall[2], Chogall[3],
                LadySinestra[0], LadySinestra[1],
                // Throne of the Four Winds
                ConclaveOfWind[0],ConclaveOfWind[1],ConclaveOfWind[2],ConclaveOfWind[3],
                AlAkir[0],AlAkir[1],AlAkir[2],AlAkir[3],
                #endregion
                #region ==== Tier 12 Content ====
                // Baradin Hold
                Occuthar[0], Occuthar[1],
                // Fireland
                Bethtilac[0],Bethtilac[1],Bethtilac[2],Bethtilac[3],
                LordRhyolith[0],LordRhyolith[1],LordRhyolith[2],LordRhyolith[3],
                Alysrazor[0],Alysrazor[1],Alysrazor[2],Alysrazor[3],
                Shannox[0],Shannox[1],Shannox[2],Shannox[3],
                Baleroc[0],Baleroc[1],Baleroc[2],Baleroc[3],
                MajordomoStaghelm[0],MajordomoStaghelm[1],MajordomoStaghelm[2],MajordomoStaghelm[3],
                Ragnaros[0],Ragnaros[1],Ragnaros[2],Ragnaros[3],
                #endregion
                #region ==== Tier 13 Content ====
                // Baradin Hold
//                Alizabal[0], Alizabal[1],
                // Dragon Soul
//                Morchok[0],Morchok[1],Morchok[2],Morchok[3],Morchok[4],
//                WarlordZonozz[0],WarlordZonozz[1],WarlordZonozz[2],WarlordZonozz[3],WarlordZonozz[4],
//                Yorsahj[0],Yorsahj[1],Yorsahj[2],Yorsahj[3],Yorsahj[4],
//                Hagara[0],Hagara[1],Hagara[2],Hagara[3],Hagara[4],
//                Ultraxion[0],Ultraxion[1],Ultraxion[2],Ultraxion[3],Ultraxion[4],
//                WarmasterBlackhorn[0],WarmasterBlackhorn[1],WarmasterBlackhorn[2],WarmasterBlackhorn[3],armasterBlackhorn[4],
//                SpineofDeathwing[0],SpineofDeathwing[1],SpineofDeathwing[2],SpineofDeathwing[3],SpineofDeathwing[4],
//                MadnessofDeathwing[0],MadnessofDeathwing[1],MadnessofDeathwing[2],MadnessofDeathwing[3],MadnessofDeathwing[4],
                #endregion

            };
            TheEZModeBoss  = GenTheEZModeBoss(list);
            TheAvgBoss     = GenTheAvgBoss(list);
            TheHardestBoss = GenTheHardestBoss(list);
            // This one is for filtered lists, defaults to the full list above
            calledList = GenCalledList(FilterType.Content,"All");
        }
Exemple #27
0
 public MindBlast(PriestTalents talents, Stats stats, BossHandler target)
 {
     _talents = talents;
     _stats   = stats;
     _target  = target;
 }
        private void CB_BossList_SelectedIndexChanged(object sender, SelectionChangedEventArgs e) {
            string addInfo = "No Additional Info";
            try {
                if (!isLoading) {
                    addInfo = "Not Loading";
                    if (CB_BossList.SelectedIndex != 0) { // "Custom"
                        addInfo += "\r\nCB_BossList.SelectedIndex != 0";
                        isLoading = true;
                        // Get Values
                        BossHandler boss = bosslist.GetBossFromBetterName(CB_BossList.SelectedItem.ToString()).Clone(); // "T7 : Naxxramas : 10 man : Patchwerk"
                        BossOptions.CloneThis(boss);
                        addInfo += "\r\nBoss Info Set";

                        // Set Controls to those Values
                        TB_BossInfo.Text = boss.GenInfoString(Character);

                        // Save the new names
                        if (!firstload) {
                            addInfo += "\r\n!firstlost";
                            BossOptions.FilterType = (BossList.FilterType)CB_BL_FilterType.SelectedIndex;
                            BossOptions.Filter = CB_BL_Filter.SelectedItem.ToString();
                            BossOptions.BossName = CB_BossList.SelectedItem.ToString();
                        }
                        isLoading = false;
                    } else {
                        addInfo += "\r\nCB_BossList.SelectedIndex == 0";
                        isLoading = true;
                        BossHandler boss = new BossHandler();
                        //
                        boss.Name = "Custom";
                        BossOptions.BossName = boss.Name;
                        //
                        TB_BossInfo.Text = boss.GenInfoString(Character);
                        isLoading = false;
                    }
                    bossOpts_PropertyChanged(null, null);
                }
            } catch (Exception ex) {
                new Base.ErrorBox()
                {
                    Title = "Error in setting BossPicker Character settings from Boss",
                    Function = "CB_BossList_SelectedIndexChanged()",
                    TheException = ex,
                }.Show();
                isLoading = false;
            }
        }
 public BurstCalculations(Stats stats, CalculationOptionsShadowPriest options, BossOptions boss, PriestTalents talents)
 {
     _stats = stats;
     _boss = boss;
     _talents = talents;
     _options = options;
 }
    public void SpawnBoss()
    {
        BossHandler bossHandler = BossHandler.CreateEnemy(new Vector3(playerHandler.transform.position.x, playerHandler.transform.position.y + 5, playerHandler.transform.position.z), playerHandler);

        bossHandler.OnDead += BossHandler_OnDead;
    }
 public MindBlast(PriestTalents talents, Stats stats, BossHandler target)
 {
     _talents = talents;
     _stats = stats;
     _target = target;
 }
Exemple #32
0
    private void HandleAttack()
    {
        if ((Input.GetButtonDown("Basic") || phoneAttack) && timeBtwAttack <= 0)
        {
            StartCoroutine(TmpBusy(0.1f));
            animator.SetTrigger("Attack");
            phoneAttack = false;

            Collider2D[] enemiesToDamage = Physics2D.OverlapCircleAll(attackPoint.position, attackRange, whatIsEnemies);
            if (enemiesToDamage.Length > 0)
            {
                audioManager.Play("SlashSuccess");

                for (int i = 0; i < enemiesToDamage.Length; i++)
                {
                    if (enemiesToDamage[i].gameObject.CompareTag("EnemyRanged"))
                    {
                        EnemyRangedHandler enemy = enemiesToDamage[i].GetComponent <EnemyRangedHandler>();
                        enemy.GetHealthSystem().Damage(basicAtkDmg);
                        enemy.KnockBack(200000);

                        CreateText(Color.grey, new Vector3(enemy.transform.position.x, enemy.transform.position.y + 1), new Vector2(0, 5), "-" + basicAtkDmg);

                        if (enemy.GetHealthSystem().GetHealthPercent() < 0.25)
                        {
                            enemy.GetComponent <SpriteRenderer>().color = new Color(1f, 1f, 1f, 0.5f);
                        }
                    }
                    else if (enemiesToDamage[i].gameObject.CompareTag("Enemy"))
                    {
                        EnemyHandler enemy = enemiesToDamage[i].GetComponent <EnemyHandler>();
                        enemy.GetHealthSystem().Damage(basicAtkDmg);
                        enemy.KnockBack(200000);

                        CreateText(Color.grey, new Vector3(enemy.transform.position.x, enemy.transform.position.y + 1), new Vector2(0, 5), "-" + basicAtkDmg);

                        if (enemy.GetHealthSystem().GetHealthPercent() < 0.25)
                        {
                            enemy.GetComponent <SpriteRenderer>().color = new Color(1f, 1f, 1f, 0.5f);
                        }
                    }
                    else if (enemiesToDamage[i].gameObject.CompareTag("EnemySlower"))
                    {
                        EnemySlowerHandler enemy = enemiesToDamage[i].GetComponent <EnemySlowerHandler>();
                        enemy.GetHealthSystem().Damage(basicAtkDmg);
                        enemy.KnockBack(200000);

                        CreateText(Color.grey, new Vector3(enemy.transform.position.x, enemy.transform.position.y + 1), new Vector2(0, 5), "-" + basicAtkDmg);

                        if (enemy.GetHealthSystem().GetHealthPercent() < 0.25)
                        {
                            enemy.GetComponent <SpriteRenderer>().color = new Color(1f, 1f, 1f, 0.5f);
                        }
                    }
                    else if (enemiesToDamage[i].gameObject.CompareTag("Boss"))
                    {
                        BossHandler boss = enemiesToDamage[i].GetComponent <BossHandler>();
                        boss.GetHealthSystem().Damage(basicAtkDmg);

                        CreateText(Color.grey, new Vector3(boss.transform.position.x, boss.transform.position.y + 1), new Vector2(0, 5), "-" + basicAtkDmg);

                        if (boss.GetHealthSystem().GetHealthPercent() < 0.1)
                        {
                            boss.GetComponent <SpriteRenderer>().color = new Color(1f, 1f, 1f, 0.5f);
                        }
                    }
                }
            }
            else
            {
                audioManager.Play("SlashFail");
            }
            timeBtwAttack = startTimeBtwAttack;
        }
        else
        {
            phoneAttack    = false;
            timeBtwAttack -= Time.deltaTime;
        }
    }
Exemple #33
0
 public void ConvertList_Dsrm(BossHandler[] passedList, BossHandler retboss) {
     BossHandler dummy = new BossHandler(); dummy.BerserkTimer = retboss.BerserkTimer;
     Impedance s;
     List<Impedance> disarms = new List<Impedance>();
     //
     foreach (BossHandler boss in passedList)
     {
         s = boss.DynamicCompiler_Dsrm;
         if (s.Frequency != -1f) {
             disarms.Add(s);
         } else if (useGoodBoyAvg) {
             // Adds a fear that doesn't actually occur
             disarms.Add(new Impedance()
             {
                 Frequency = retboss.BerserkTimer,
                 Duration = 0f, //retboss.BerserkTimer,
                 Chance = 1f,
                 Breakable = true,
             });
         }
     }
     dummy.Disarms = disarms;
     s = dummy.DynamicCompiler_Dsrm;
     if (s.Frequency != -1) { retboss.Disarms.Add(s); }
 }