[Crash] Fix crash where Raid invite could be accepted after forming group with the Raid invitor. (#3837)

* [Crash] Fix a crash where a raid invite could be accepted affter joining a group with the invitor.

* [Crash] Fix a crash where a raid invite could be accepted after joining a group with the invitor.
This commit is contained in:
Aeadoin
2024-01-06 16:59:35 -05:00
committed by GitHub
parent 076aab50e8
commit a8eb2832ce
2 changed files with 8 additions and 0 deletions
+7
View File
@@ -12053,6 +12053,13 @@ void Client::Handle_OP_RaidCommand(const EQApplicationPacket* app)
{
auto player_sending_invite_group = player_sending_invite->GetGroup();
Group* group = GetGroup();
/* Prevent scenario where player had joined group with Raid invitor before accepting Raid invite */
if (group && group == player_sending_invite_group) {
player_sending_invite->MessageString(Chat::Red, INVITE_GROUP_LEADER);
return;
}
if (group) //if our target has a group
{
raid = new Raid(player_sending_invite);