aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Reputation/ReputationMgr.cpp
diff options
context:
space:
mode:
authorCarbenium <carbenium@outlook.com>2015-04-23 01:19:23 +0200
committerCarbenium <carbenium@outlook.com>2015-04-23 01:19:23 +0200
commit915828bb1ff3d8c8c43c253a4b645abbf5efa4f0 (patch)
tree320eec9039891d80910f8648f818fa2f9d04ec53 /src/server/game/Reputation/ReputationMgr.cpp
parentac318ae517361e7f5f43466993da92fa643b92c4 (diff)
parent1c13154e0b2268f817f7eb9892ce9e6d6ec5b6d6 (diff)
Merge pull request #14593 from DJScias/factionopcodes
Core/PacketIO: Updated and enabled CMSG_SET_FACTION_AT_WAR, CMSG_SET_FAC...
Diffstat (limited to 'src/server/game/Reputation/ReputationMgr.cpp')
-rw-r--r--src/server/game/Reputation/ReputationMgr.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/server/game/Reputation/ReputationMgr.cpp b/src/server/game/Reputation/ReputationMgr.cpp
index 48f3bf79088..5fea62655b3 100644
--- a/src/server/game/Reputation/ReputationMgr.cpp
+++ b/src/server/game/Reputation/ReputationMgr.cpp
@@ -27,6 +27,7 @@
#include "ScriptMgr.h"
#include "Opcodes.h"
#include "WorldSession.h"
+#include "CharacterPackets.h"
const int32 ReputationMgr::PointsInRank[MAX_REPUTATION_RANK] = {36000, 3000, 3000, 3000, 6000, 12000, 21000, 1000};
@@ -225,15 +226,15 @@ void ReputationMgr::SendStates()
SendState(&(itr->second));
}
-void ReputationMgr::SendVisible(FactionState const* faction, bool visible /* = true*/) const
+void ReputationMgr::SendVisible(FactionState const* faction, bool visible) const
{
if (_player->GetSession()->PlayerLoading())
return;
// make faction visible/not visible in reputation list at client
- WorldPacket data(visible ? SMSG_SET_FACTION_VISIBLE : SMSG_SET_FACTION_NOT_VISIBLE, 4);
- data << faction->ReputationListID;
- _player->SendDirectMessage(&data);
+ WorldPackets::Character::SetFactionVisible packet(visible);
+ packet.FactionIndex = faction->ReputationListID;
+ _player->SendDirectMessage(packet.Write());
}
void ReputationMgr::Initialize()