Fix Vanilla damage adjustment scaling

This commit is contained in:
郑佩茹
2023-04-20 16:59:04 -06:00
parent 1cf462d6ee
commit 63add43ec2
3 changed files with 18 additions and 4 deletions

View File

@@ -143,6 +143,12 @@ void IndividualProgression::AdjustStats(Player* player, float computedAdjustment
player->CastCustomSpell(player, ABSORB_SPELL, &bp1, nullptr, nullptr, false);
}
float IndividualProgression::ComputeVanillaAdjustment(Player *player, float configAdjustmentValue)
{
float adjustmentApplyPercent = (player->getLevel() - 10.0f) / 50.0f;
return player->getLevel() > 10 ? (1.0f - (configAdjustmentValue * adjustmentApplyPercent)) : 1;
}
/**
* Gets the highest progression level achieved by an account
* Note that this method makes a direct, non-sync DB call and should be used sparingly