mirror of
https://github.com/EQEmu/Server.git
synced 2026-03-05 17:42:24 +00:00
Fix additional logic cases for merc disbanding.
This commit is contained in:
parent
f8d000d660
commit
9c08d6f25b
@ -6549,9 +6549,30 @@ void Client::Handle_OP_GroupDisband(const EQApplicationPacket *app)
|
|||||||
|
|
||||||
if (group->GroupCount() < 3)
|
if (group->GroupCount() < 3)
|
||||||
{
|
{
|
||||||
group->DisbandGroup();
|
if (!RuleB(Mercs, AllowMercSuspendInCombat)) {
|
||||||
if (GetMerc())
|
if (GetMerc())
|
||||||
GetMerc()->Suspend();
|
{
|
||||||
|
Mob* mercOwner = GetMerc()->GetOwner();
|
||||||
|
if (mercOwner && mercOwner->IsClient()) {
|
||||||
|
if (mercOwner->CastToClient()->CheckCanSpawnMerc(mercOwner->CastToClient()->GetMercInfo().MercTemplateID)) {
|
||||||
|
group->DisbandGroup();
|
||||||
|
GetMerc()->Suspend();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
group->DisbandGroup();
|
||||||
|
if (GetMerc())
|
||||||
|
GetMerc()->Suspend();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
group->DisbandGroup();
|
||||||
|
if (GetMerc())
|
||||||
|
GetMerc()->Suspend();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (group->IsLeader(this) && GetTarget() == nullptr)
|
else if (group->IsLeader(this) && GetTarget() == nullptr)
|
||||||
{
|
{
|
||||||
@ -6562,9 +6583,30 @@ void Client::Handle_OP_GroupDisband(const EQApplicationPacket *app)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
group->DisbandGroup();
|
if (!RuleB(Mercs, AllowMercSuspendInCombat)) {
|
||||||
if (GetMerc())
|
if (GetMerc())
|
||||||
GetMerc()->Suspend();
|
{
|
||||||
|
Mob* mercOwner = GetMerc()->GetOwner();
|
||||||
|
if (mercOwner && mercOwner->IsClient()) {
|
||||||
|
if (mercOwner->CastToClient()->CheckCanSpawnMerc(mercOwner->CastToClient()->GetMercInfo().MercTemplateID)) {
|
||||||
|
group->DisbandGroup();
|
||||||
|
GetMerc()->Suspend();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
group->DisbandGroup();
|
||||||
|
if (GetMerc())
|
||||||
|
GetMerc()->Suspend();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
group->DisbandGroup();
|
||||||
|
if (GetMerc())
|
||||||
|
GetMerc()->Suspend();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (group->IsLeader(this) && (GetTarget() == this || memberToDisband == this))
|
else if (group->IsLeader(this) && (GetTarget() == this || memberToDisband == this))
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user