mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-26 20:02:25 +01:00
Core/Guild: Add validation for guild tabard colors
This commit is contained in:
@@ -191,6 +191,12 @@ void WorldSession::HandleSaveGuildEmblem(WorldPackets::Guild::SaveGuildEmblem& p
|
||||
if (GetPlayer()->HasUnitState(UNIT_STATE_DIED))
|
||||
GetPlayer()->RemoveAurasByType(SPELL_AURA_FEIGN_DEATH);
|
||||
|
||||
if (!emblemInfo.ValidateEmblemColors())
|
||||
{
|
||||
Guild::SendSaveEmblemResult(this, ERR_GUILDEMBLEM_INVALID_TABARD_COLORS);
|
||||
return;
|
||||
}
|
||||
|
||||
if (Guild* guild = GetPlayer()->GetGuild())
|
||||
guild->HandleSetEmblem(this, emblemInfo);
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user