[Bug Fix] Disciplines Getting Focuses Fix (#3884)

* [Bug Fix] Discs Getting Focuses Fix

Focus effects shouldn't extend discipline timers except for War Cries

* Update to Logic
This commit is contained in:
Fryguy 2024-01-07 16:02:17 -05:00 committed by GitHub
parent 00eb462d47
commit 4490a53ba0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 23 additions and 0 deletions

View File

@ -204,6 +204,13 @@
#define SPELL_GUIDE_HASTE 39854
#define SPELL_VAMPIRIC_EMBRACE 821
#define SPELL_VAMPIRIC_EMBRACE_OF_SHADOW 822
#define SPELL_BATTLE_CRY 5027
#define SPELL_WAR_CRY 5028
#define SPELL_BATTLE_CRY_OF_DRAVEL 5029
#define SPELL_WAR_CRY_OF_DRAVEL 5030
#define SPELL_BATTLE_CRY_OF_THE_MASTRUQ 5031
#define SPELL_ANCIENT_CRY_OF_CHAOS 5032
#define SPELL_BLOODTHIRST 8476
// discipline IDs.
#define DISC_UNHOLY_AURA 4520

View File

@ -592,6 +592,22 @@ int32 Mob::GetActSpellCost(uint16 spell_id, int32 cost)
int32 Mob::GetActSpellDuration(uint16 spell_id, int32 duration)
{
// focuses don't affect discipline duration (Except War Cries)
if (
IsDiscipline(spell_id) &&
(
spell_id != SPELL_BATTLE_CRY &&
spell_id != SPELL_WAR_CRY &&
spell_id != SPELL_BATTLE_CRY_OF_DRAVEL &&
spell_id != SPELL_WAR_CRY_OF_DRAVEL &&
spell_id != SPELL_BATTLE_CRY_OF_THE_MASTRUQ &&
spell_id != SPELL_ANCIENT_CRY_OF_CHAOS &&
spell_id != SPELL_BLOODTHIRST
)
) {
return duration;
}
int increase = 100;
increase += GetFocusEffect(focusSpellDuration, spell_id);
int tic_inc = 0;