mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-16 22:58:34 +00:00
Fix item clicks being TGBable
This commit is contained in:
+4
-4
@@ -1348,7 +1348,7 @@ void Mob::CastedSpellFinished(uint16 spell_id, uint32 target_id, uint16 slot,
|
||||
|
||||
}
|
||||
|
||||
bool Mob::DetermineSpellTargets(uint16 spell_id, Mob *&spell_target, Mob *&ae_center, CastAction_type &CastAction) {
|
||||
bool Mob::DetermineSpellTargets(uint16 spell_id, Mob *&spell_target, Mob *&ae_center, CastAction_type &CastAction, uint16 slot) {
|
||||
|
||||
/*
|
||||
The basic types of spells:
|
||||
@@ -1682,7 +1682,7 @@ bool Mob::DetermineSpellTargets(uint16 spell_id, Mob *&spell_target, Mob *&ae_ce
|
||||
case ST_Group:
|
||||
case ST_GroupNoPets:
|
||||
{
|
||||
if(IsClient() && CastToClient()->TGB() && IsTGBCompatibleSpell(spell_id)) {
|
||||
if(IsClient() && CastToClient()->TGB() && IsTGBCompatibleSpell(spell_id) && slot != USE_ITEM_SPELL_SLOT) {
|
||||
if( (!target) ||
|
||||
(target->IsNPC() && !(target->GetOwner() && target->GetOwner()->IsClient())) ||
|
||||
(target->IsCorpse()) )
|
||||
@@ -1974,7 +1974,7 @@ bool Mob::SpellFinished(uint16 spell_id, Mob *spell_target, uint16 slot, uint16
|
||||
|
||||
//determine the type of spell target we have
|
||||
CastAction_type CastAction;
|
||||
if(!DetermineSpellTargets(spell_id, spell_target, ae_center, CastAction))
|
||||
if(!DetermineSpellTargets(spell_id, spell_target, ae_center, CastAction, slot))
|
||||
return(false);
|
||||
|
||||
Log.Out(Logs::Detail, Logs::Spells, "Spell %d: target type %d, target %s, AE center %s", spell_id, CastAction, spell_target?spell_target->GetName():"NONE", ae_center?ae_center->GetName():"NONE");
|
||||
@@ -2370,7 +2370,7 @@ bool Mob::ApplyNextBardPulse(uint16 spell_id, Mob *spell_target, uint16 slot) {
|
||||
//determine the type of spell target we have
|
||||
Mob *ae_center = nullptr;
|
||||
CastAction_type CastAction;
|
||||
if(!DetermineSpellTargets(spell_id, spell_target, ae_center, CastAction)) {
|
||||
if(!DetermineSpellTargets(spell_id, spell_target, ae_center, CastAction, slot)) {
|
||||
Log.Out(Logs::Detail, Logs::Spells, "Bard Song Pulse %d: was unable to determine target. Stopping.", spell_id);
|
||||
return(false);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user