[Fix] Fix Spell Cast Time reduction issues (#1369)

Remove the overloads that don't make sense (bots probably doesn't make
sense either, but too lazy)

Fix the formulas

Removed the Spells:MaxCastTimeReduction rule since this is HARDCODED in
the client so it doesn't really make sense to have it as a customization
point. If you want to hack the client, change the hardcode as well I
guess.
This commit is contained in:
Michael Cook (mackal)
2021-05-24 21:21:39 -04:00
committed by GitHub
parent 93329b4b06
commit e5b9d72b81
7 changed files with 17 additions and 65 deletions
-13
View File
@@ -2756,19 +2756,6 @@ int32 Merc::GetActSpellCost(uint16 spell_id, int32 cost)
return cost;
}
int32 Merc::GetActSpellCasttime(uint16 spell_id, int32 casttime)
{
int32 cast_reducer = 0;
cast_reducer += GetFocusEffect(focusSpellHaste, spell_id);
if (cast_reducer > RuleI(Spells, MaxCastTimeReduction))
cast_reducer = RuleI(Spells, MaxCastTimeReduction);
casttime = (casttime*(100 - cast_reducer)/100);
return casttime;
}
int8 Merc::GetChanceToCastBySpellType(uint32 spellType) {
int mercStance = (int)GetStance();
int8 mercClass = GetClass();