diff --git a/db/re/job_stats.yml b/db/re/job_stats.yml index b74f08294e..b299530fed 100644 --- a/db/re/job_stats.yml +++ b/db/re/job_stats.yml @@ -9213,7 +9213,7 @@ Body: Vit: 1 Int: 1 - Level: 13 - Agi: 1 + Dex: 1 Spl: 1 - Level: 14 Sta: 1 @@ -9229,7 +9229,7 @@ Body: Int: 1 Dex: 1 - Level: 19 - Dex: 1 + Int: 1 - Level: 20 Vit: 1 Int: 1 diff --git a/src/map/battle.cpp b/src/map/battle.cpp index 0a1bc9173b..fc90b4999f 100644 --- a/src/map/battle.cpp +++ b/src/map/battle.cpp @@ -8164,8 +8164,8 @@ struct Damage battle_calc_magic_attack(struct block_list *src,struct block_list case WL_SUMMON_ATK_WATER: case WL_SUMMON_ATK_WIND: case WL_SUMMON_ATK_GROUND: - skillratio += -100 + (1 + skill_lv) / 2 * (status_get_lv(src) + (sd ? sd->status.job_level : 0)); - RE_LVL_DMOD(100); // ! TODO: Confirm new formula + skillratio += 200; + RE_LVL_DMOD(100); break; case LG_RAYOFGENESIS: skillratio += -100 + 350 * skill_lv + sstatus->int_; // !TODO: What's the INT bonus? @@ -8719,7 +8719,11 @@ struct Damage battle_calc_magic_attack(struct block_list *src,struct block_list (sc->getSCE(SC_EARTH_INSIGNIA) && sc->getSCE(SC_EARTH_INSIGNIA)->val1 == 3 && s_ele == ELE_EARTH)) skillratio += 25; } - +#ifdef RENEWAL + // SMATK needs to be applied before the skill ratio to prevent rounding issues + if (sd && sstatus->smatk > 0) + ad.damage += ad.damage * sstatus->smatk / 100; +#endif MATK_RATE(skillratio); //Constant/misc additions from skills @@ -8750,9 +8754,6 @@ struct Damage battle_calc_magic_attack(struct block_list *src,struct block_list ad.damage -= (int64)ad.damage*i/100; #ifdef RENEWAL - if (sd && sstatus->smatk > 0) - ad.damage += ad.damage * sstatus->smatk / 100; - // MRes reduces magical damage by a percentage and // is calculated before MDEF and other reductions. // This should be the official formula. [Rytech]