mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-17 10:21:28 +00:00
[Targeting] /tar <bad target> should not untarget existing target (#3383)
* [Targeting] /tar <bad target> should not untarget existing target * Forgot string Id file. * removed unneeded this->
This commit is contained in:
parent
548eb65e1d
commit
ae53efc52c
@ -14419,11 +14419,6 @@ void Client::Handle_OP_TargetCommand(const EQApplicationPacket *app)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (GetTarget())
|
|
||||||
{
|
|
||||||
GetTarget()->IsTargeted(-1);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Locate and cache new target
|
// Locate and cache new target
|
||||||
ClientTarget_Struct* ct = (ClientTarget_Struct*)app->pBuffer;
|
ClientTarget_Struct* ct = (ClientTarget_Struct*)app->pBuffer;
|
||||||
pClientSideTarget = ct->new_target;
|
pClientSideTarget = ct->new_target;
|
||||||
@ -14432,6 +14427,11 @@ void Client::Handle_OP_TargetCommand(const EQApplicationPacket *app)
|
|||||||
Mob *nt = entity_list.GetMob(ct->new_target);
|
Mob *nt = entity_list.GetMob(ct->new_target);
|
||||||
if (nt)
|
if (nt)
|
||||||
{
|
{
|
||||||
|
if (GetTarget())
|
||||||
|
{
|
||||||
|
GetTarget()->IsTargeted(-1);
|
||||||
|
}
|
||||||
|
|
||||||
SetTarget(nt);
|
SetTarget(nt);
|
||||||
bool inspect_buffs = false;
|
bool inspect_buffs = false;
|
||||||
// rank 1 gives you ability to see NPC buffs in target window (SoD+)
|
// rank 1 gives you ability to see NPC buffs in target window (SoD+)
|
||||||
@ -14460,21 +14460,7 @@ void Client::Handle_OP_TargetCommand(const EQApplicationPacket *app)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
SetTarget(nullptr);
|
MessageString(Chat::Red, DONT_SEE_TARGET);
|
||||||
SetHoTT(0);
|
|
||||||
UpdateXTargetType(TargetsTarget, nullptr);
|
|
||||||
|
|
||||||
Group *g = GetGroup();
|
|
||||||
|
|
||||||
if (g && g->HasRole(this, RoleAssist))
|
|
||||||
g->SetGroupAssistTarget(0);
|
|
||||||
|
|
||||||
if (g && g->HasRole(this, RoleTank))
|
|
||||||
g->SetGroupTankTarget(0);
|
|
||||||
|
|
||||||
if (g && g->HasRole(this, RolePuller))
|
|
||||||
g->SetGroupPullerTarget(0);
|
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -100,6 +100,7 @@
|
|||||||
#define DUP_LORE 290 //Duplicate lore items are not allowed.
|
#define DUP_LORE 290 //Duplicate lore items are not allowed.
|
||||||
#define TGB_ON 293 //Target other group buff is *ON*.
|
#define TGB_ON 293 //Target other group buff is *ON*.
|
||||||
#define TGB_OFF 294 //Target other group buff is *OFF*.
|
#define TGB_OFF 294 //Target other group buff is *OFF*.
|
||||||
|
#define DONT_SEE_TARGET 303 //I don't see anyone by that name around here...
|
||||||
#define DISARMED_TRAP 305 //You have disarmed the trap.
|
#define DISARMED_TRAP 305 //You have disarmed the trap.
|
||||||
#define LDON_SENSE_TRAP1 306 //You do not Sense any traps.
|
#define LDON_SENSE_TRAP1 306 //You do not Sense any traps.
|
||||||
#define TRADESKILL_NOCOMBINE 334 //You cannot combine these items in this container type!
|
#define TRADESKILL_NOCOMBINE 334 //You cannot combine these items in this container type!
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user