mirror of
https://github.com/mangosfour/server.git
synced 2025-12-19 13:37:01 +00:00
[11490] Alow implicit cast ObjectGuid->uint64 and only explicit uint64->ObjectGuid
Now safe allow this casts in like way after completed convertion to ObjectGuid use. Also simplify code in result allowed auto cast to uint64. Please _not_ add new uint64 storages (local and in structures) for guid values.
This commit is contained in:
parent
ecdb435b1e
commit
249fb836ca
47 changed files with 194 additions and 210 deletions
|
|
@ -305,8 +305,7 @@ void WorldSession::HandleGroupUninviteOpcode(WorldPacket & recv_data)
|
|||
if (!grp)
|
||||
return;
|
||||
|
||||
ObjectGuid guid = grp->GetMemberGuid(membername);
|
||||
if (!guid.IsEmpty())
|
||||
if (ObjectGuid guid = grp->GetMemberGuid(membername))
|
||||
{
|
||||
Player::RemoveFromGroup(grp, guid);
|
||||
return;
|
||||
|
|
@ -546,8 +545,7 @@ void WorldSession::HandleGroupChangeSubGroupOpcode( WorldPacket & recv_data )
|
|||
group->ChangeMembersGroup(player, groupNr);
|
||||
else
|
||||
{
|
||||
ObjectGuid guid = sObjectMgr.GetPlayerGuidByName(name.c_str());
|
||||
if (!guid.IsEmpty())
|
||||
if (ObjectGuid guid = sObjectMgr.GetPlayerGuidByName(name.c_str()))
|
||||
group->ChangeMembersGroup(guid, groupNr);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue