Beispiel #1
0
        public BisPerks(Weapon bisWeapon)
        {
            //string[] Variationen = GetPermutation(3, new char[] { '1', '2', '3' });
            //string[] Variationen = GetPermutation(3, new char[] { '1', '2', '3', '4', '5' });
            Perk        myPerk   = new Perk(PerkQuality.Legendary);
            List <Perk> listPerk = myPerk.PicList();

            int[] iCombos = new int[listPerk.Count];
            for (int i = 0; i < listPerk.Count; i++)
            {
                iCombos[i] = i;
            }
            //string[] sVariationen = GetPermutation(4, iCombos);

            //CalcDPS(bisWeapon, sVariationen);
        }
Beispiel #2
0
        private void CalcDPS(Weapon myWeapon, string[] sVariatonen)
        {
            Perk        myPerk     = new Perk(PerkQuality.Legendary);
            Perk        myPerkLvL1 = new Perk(PerkQuality.Legendary);
            List <Perk> listPerk   = myPerk.PicList();

            char[] charSplit = new char[] { ',' };
            double dDPSHigh  = 0;

            int[] iComboHigh = new int[5];

            foreach (string sCombo in sVariatonen)
            {
                string[] sComboArray = sCombo.Split(charSplit, StringSplitOptions.RemoveEmptyEntries);
                int[]    iCombo      = new int[5];

                for (int i = 0; i < sComboArray.Length; i++)
                {
                    iCombo[i] = System.Convert.ToInt32(sComboArray[i]);
                }

                Perk perk1 = listPerk[iCombo[0]];
                Perk perk2 = listPerk[iCombo[1]];
                Perk perk3 = listPerk[iCombo[2]];
                Perk perk4 = listPerk[iCombo[3]];
                //Perk perk5 = listPerk[iCombo[4]];
                Perk perk5 = myPerkLvL1.PicList()[13];
                //Perk perk6 = new Perk(HeroMain.UrbanAssault);
                //Perk perk7 = new Perk(HeroSup.AssaultCritDamage);
                //Perk perk6 = new Perk(HeroMain.Nothing);
                //Perk perk7 = new Perk(HeroMain.Nothing);

                Perk   PerkSum = perk1.SummuaryPerk(perk1, perk2, perk3, perk4, perk5);
                double dDPS    = DPS.TrueDPS(myWeapon, PerkSum);

                if (dDPS > dDPSHigh)
                {
                    dDPSHigh   = dDPS;
                    iComboHigh = iCombo;
                }
            }
        }