mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-13 23:01:30 +00:00
[Bug Fix] Fix Group ID 0 in Group::SaveGroupLeaderAA() (#4487)
This commit is contained in:
parent
bcd943a964
commit
78aee0780a
@ -2117,15 +2117,20 @@ void Group::UnDelegateMarkNPC(const char *OldNPCMarkerName)
|
|||||||
|
|
||||||
void Group::SaveGroupLeaderAA()
|
void Group::SaveGroupLeaderAA()
|
||||||
{
|
{
|
||||||
// Stores the Group Leaders Leadership AA data from the Player Profile as a blob in the group_leaders table.
|
const uint32 group_id = GetID();
|
||||||
// This is done so that group members not in the same zone as the Leader still have access to this information.
|
|
||||||
|
|
||||||
std::string aa((char *) &LeaderAbilities, sizeof(GroupLeadershipAA_Struct));
|
if (!group_id) {
|
||||||
auto results = GroupLeadersRepository::UpdateLeadershipAA(database, aa, GetID());
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (!results) {
|
// Stores the Group Leaders Leadership AA data from the Player Profile as a blob in the group_leaders table.
|
||||||
LogError("Unable to store GroupLeadershipAA for group_id: [{}]", GetID());
|
// This is done so that group members not in the same zone as the Leader still have access to this information.
|
||||||
}
|
|
||||||
|
std::string aa((char*) &LeaderAbilities, sizeof(GroupLeadershipAA_Struct));
|
||||||
|
|
||||||
|
if (!GroupLeadersRepository::UpdateLeadershipAA(database, aa, group_id)) {
|
||||||
|
LogError("Unable to store GroupLeadershipAA for group_id: [{}]", group_id);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Group::UnMarkNPC(uint16 ID)
|
void Group::UnMarkNPC(uint16 ID)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user