fix(Core/Unit): Respect Attribute ALLOW_ACTION_DURING_CHANNEL from triggered casts (#26880)

This commit is contained in:
Gultask
2026-08-01 20:14:22 -03:00
committed by GitHub
parent acdb1b0224
commit 4d64135830
2 changed files with 9 additions and 2 deletions
@@ -0,0 +1,4 @@
--
DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 13) AND (`SourceGroup` = 1) AND (`SourceEntry` = 44270) AND (`SourceId` = 0) AND (`ElseGroup` = 0) AND (`ConditionTypeOrReference` = 31) AND (`ConditionTarget` = 0) AND (`ConditionValue1` = 3) AND (`ConditionValue2` = 24707) AND (`ConditionValue3` = 0);
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES
(13, 1, 44270, 0, 0, 31, 0, 3, 24707, 0, 0, 0, 0, '', 'Breathing Tube (44270) Targets Buoy (24707)');
+5 -2
View File
@@ -4181,8 +4181,11 @@ void Unit::SetCurrentCastedSpell(Spell* pSpell)
}
case CURRENT_CHANNELED_SPELL:
{
// channel spells always break generic non-delayed and any channeled spells
InterruptSpell(CURRENT_GENERIC_SPELL, false);
// channel spells always break generic non-delayed and any channeled spells,
// unless the channel itself is allowed to run alongside other actions
if (!pSpell->GetSpellInfo()->IsActionAllowedChannel())
InterruptSpell(CURRENT_GENERIC_SPELL, false);
InterruptSpell(CURRENT_CHANNELED_SPELL, true, true, bySelf);
// it also does break autorepeat if not Auto Shot