diff options
| author | ariel- <ariel-@users.noreply.github.com> | 2016-07-30 04:06:37 -0300 |
|---|---|---|
| committer | joschiwald <joschiwald.trinity@gmail.com> | 2017-02-11 17:58:59 +0100 |
| commit | 07f2f37329dc62944a9c22df7c76f5e0e85e7886 (patch) | |
| tree | 1e03d030f555056c9eb9c14f4278177853aa955d | |
| parent | 16463e41225bc2b795fcd86b199d52188640533d (diff) | |
Core/Spell: fix one logic fail when calculating level penalty
(http://wow.gamepedia.com/index.php?title=Spell_power&oldid=1751770#Spells_learned_before_level_20)
(cherry picked from commit c271e196c8bb02705d8a3e4a7432bbc2959f0b1a)
| -rw-r--r-- | src/server/game/Entities/Unit/Unit.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index a295b94bcb2..4c3496e4efd 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -2177,7 +2177,7 @@ float Unit::CalculateLevelPenalty(SpellInfo const* spellProto) const float LvlPenalty = 0.0f; if (spellProto->SpellLevel < 20) - LvlPenalty = 20.0f - spellProto->SpellLevel * 3.75f; + LvlPenalty = (20.0f - spellProto->SpellLevel) * 3.75f; float LvlFactor = (float(spellProto->SpellLevel) + 6.0f) / float(getLevel()); if (LvlFactor > 1.0f) LvlFactor = 1.0f; |
