Beispiel #1
0
        private int GeneratePassiveSkill(PetParameters parameters, PetPassiveBonusCollection passiveBonuses)
        {
            //not realized yet
            //return -1;

            return(passiveBonuses.randomBonus);
        }
Beispiel #2
0
 private int GetPassiveSkill(PetParameters parameters, PetDropSettings settings, PetPassiveBonusCollection passiveBonuses)
 {
     if (settings.generatePassiveSkill)
     {
         return(GeneratePassiveSkill(parameters, passiveBonuses));
     }
     else
     {
         return(settings.overwritePassiveSkill);
     }
 }
Beispiel #3
0
        public PetInfo Drop(PetParameters parameters, PetDropSettings settings, PetSkillCollection skills, PetPassiveBonusCollection passiveBonuses)
        {
            PetInfo pet = new PetInfo();

            pet.SetId(Guid.NewGuid().ToString());
            pet.SetExp(0);

            pet.SetColor(GetColor(parameters, settings));
            pet.SetType(GetType(parameters, settings));
            pet.SetPassiveSkill(GetPassiveSkill(parameters, settings, passiveBonuses));
            pet.SetActiveSkills(GetActiveSkills(pet.color, parameters, settings, skills));
            pet.SetActive(false);


            float attackBaseAdd  = Rand.Float(parameters.damage.BaseMin(), parameters.damage.BaseMax());
            float attackColorAdd = Rand.Float(parameters.damage.ColorMin(), parameters.damage.ColorMax());
            float attackLevelAdd = Rand.Float(parameters.damage.LevelMin(), parameters.damage.LevelMax());

            pet.SetAttackParameters(attackBaseAdd, attackColorAdd, attackLevelAdd);

            float hpBaseAdd  = Rand.Float(parameters.hp.BaseMin(), parameters.hp.BaseMax());
            float hpColorAdd = Rand.Float(parameters.hp.ColorMin(), parameters.hp.ColorMax());
            float hpLevelAdd = Rand.Float(parameters.hp.LevelMin(), parameters.hp.LevelMax());

            pet.SetHpParameters(hpBaseAdd, hpColorAdd, hpLevelAdd);

            float odBaseAdd  = Rand.Float(parameters.od.BaseMin(), parameters.od.BaseMax());
            float odColorAdd = Rand.Float(parameters.od.ColorMin(), parameters.od.ColorMax());
            float odLevelAdd = Rand.Float(parameters.od.LevelMin(), parameters.od.LevelMax());

            pet.SetOptimalDistanceParameters(odBaseAdd, odColorAdd, odLevelAdd);

            pet.SetDamageType(GetDamageType(parameters, settings));
            pet.SetMastery(GetMastery(parameters, settings));
            return(pet);
        }