EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Development::Bug Reports (https://www.eqemulator.org/forums/forumdisplay.php?f=591)
-   -   Skill Up rule Character:SkillUpModifier has no effect (https://www.eqemulator.org/forums/showthread.php?t=42364)

mx4life 03-17-2019 02:09 PM

Skill Up rule Character:SkillUpModifier has no effect
 
The rule Character:SkillUpModifier for modifying skill up rate has no effect on some skills (weapon & defense for example) after skill level 150.

In zone/Client.cpp function CheckIncreaseSkill:

Code:

        int32 Chance = 10 + chancemodi + ((252 - skillval) / 20);

        Chance = (Chance * RuleI(Character, SkillUpModifier) / 100);

        Chance = mod_increase_skill_chance(Chance, against_who);

        if(Chance < 1)
                Chance = 1; // Make it always possible

        if(zone->random.Real(0, 99) < Chance)

The calculation Chance = 10 + chancemodi + ((252 - skillval) / 20) will yield negative chance from skill value 153 for skills that use -15 as chancemodi (weapon, offense and defense).

And since the rule Character:SkillUpModifier is applied before the check that chance is at least 1 the rule will then have no effect at all.

Suggested change.

Just move the check that Chance is at least 1 before the rule Character:SkillUpModifier is applied.

Code:

        int32 Chance = 10 + chancemodi + ((252 - skillval) / 20);

        if(Chance < 1)
                Chance = 1; // Make it always possible

        Chance = (Chance * RuleI(Character, SkillUpModifier) / 100);

        Chance = mod_increase_skill_chance(Chance, against_who);

        if(zone->random.Real(0, 99) < Chance)


mx4life 03-17-2019 02:11 PM

This is my first post here on this forum. I hope I haven't made a fool out of my self. But I have played Everquest for over 10 years and been a software developer for almost 30 years so....


All times are GMT -4. The time now is 12:24 PM.

Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.