Skip to content

Commit

Permalink
Fix using items on enemy units by command
Browse files Browse the repository at this point in the history
  • Loading branch information
celguar committed Jan 27, 2025
1 parent d495808 commit bf06a3a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion playerbot/strategy/actions/UseItemAction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,7 @@ bool UseAction::UseItemInternal(Player* requester, uint32 itemId, Unit* unit, Ga
if (spellTargets == 0)
{
// Unit target
if ((spellInfo->EffectImplicitTargetA[0] == TARGET_UNIT) || // Unit Target
if ((spellInfo->EffectImplicitTargetA[0] == TARGET_UNIT || spellInfo->EffectImplicitTargetA[0] == TARGET_UNIT_ENEMY) || // Unit Target
(proto->Class == ITEM_CLASS_CONSUMABLE && proto->SubClass == ITEM_SUBCLASS_SCROLL) || // Scrolls
(proto->Class == ITEM_CLASS_TRADE_GOODS && proto->SubClass == ITEM_SUBCLASS_EXPLOSIVES) || // Explosives
(spellData.SpellCategory == 150) || // First aid
Expand Down

0 comments on commit bf06a3a

Please sign in to comment.