Skip to content

Commit

Permalink
[Game] UnitReqs fix for TargetBuffTag if no target is selected (AAEmu…
Browse files Browse the repository at this point in the history
…#1002)

- Added a fallback to caster if no target is selected for the TargetBuffTag check. This fixes some glider skills.
  • Loading branch information
ZeromusXYZ committed Jul 10, 2024
1 parent 50130e2 commit 4274470
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion AAEmu.Game/Models/Game/Units/UnitReqs.cs
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,8 @@ UnitReqsValidationResult RetWithValue(SkillResultKeys errorKey, uint value, bool
return RetWithValue(SkillResultKeys.skill_urk_nobuff, Value1, unit != null && !unit.Buffs.CheckBuff(Value1));

case UnitReqsKindType.TargetBuffTag:
return RetWithValue(SkillResultKeys.skill_urk_target_buff_tag, Value1, targetUnit?.Buffs.CheckBuffTag(Value1) ?? false);
var targetBuffTarget = targetUnit ?? unit;
return RetWithValue(SkillResultKeys.skill_urk_target_buff_tag, Value1, targetBuffTarget?.Buffs.CheckBuffTag(Value1) ?? false);

// case UnitReqsKindType.CorpseRange:
// case UnitReqsKindType.EquipWeaponType:
Expand Down

0 comments on commit 4274470

Please sign in to comment.