aboutsummaryrefslogtreecommitdiff
path: root/src/game/Player.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/Player.cpp')
-rw-r--r--src/game/Player.cpp22
1 files changed, 21 insertions, 1 deletions
diff --git a/src/game/Player.cpp b/src/game/Player.cpp
index e7c7a8aba23..9a6ebb558fe 100644
--- a/src/game/Player.cpp
+++ b/src/game/Player.cpp
@@ -2498,7 +2498,7 @@ void Player::GiveXP(uint32 xp, Unit* victim)
level = getLevel();
nextLvlXP = GetUInt32Value(PLAYER_NEXT_LEVEL_XP);
}
-
+ newXP = GetSession()->HandleOnGetXP(newXP);
SetUInt32Value(PLAYER_XP, newXP);
}
@@ -6003,6 +6003,14 @@ void Player::CheckExploreSystem()
if (isInFlight())
return;
+ if(!m_AreaID)
+ m_AreaID = GetAreaId();
+ if(m_AreaID != GetAreaId())
+ {
+ m_AreaID = GetAreaId();
+ GetSession()->HandleOnAreaChange(GetAreaEntryByAreaID(m_AreaID));
+ }
+
uint16 areaFlag = GetBaseMap()->GetAreaFlag(GetPositionX(),GetPositionY(),GetPositionZ());
if(areaFlag==0xffff)
return;
@@ -22089,3 +22097,15 @@ void Player::ActivateSpec(uint8 spec)
SetPower(pw, 0);
}
+void Player::SetReputation(uint32 factionentry, uint32 value)
+{
+ GetReputationMgr().SetReputation(sFactionStore.LookupEntry(factionentry),value);
+}
+uint32 Player::GetReputation(uint32 factionentry)
+{
+ return GetReputationMgr().GetReputation(sFactionStore.LookupEntry(factionentry));
+}
+std::string Player::GetGuildName()
+{
+ return objmgr.GetGuildById(GetGuildId())->GetName();
+}