aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorKudlaty <none@none>2009-06-18 17:47:12 +0200
committerKudlaty <none@none>2009-06-18 17:47:12 +0200
commit1f871af996eb837d7a191fb947bcf565f4592c1c (patch)
treeac5e6d183fb4a3789e5158f68caa86add4ea84eb /src
parentc41e432834bd03708f3e3ceb1e28a16cc9adf8ad (diff)
parent4f10fa008dca092bb7a9ad36e0df7d568b3ef22f (diff)
*merge
--HG-- branch : trunk
Diffstat (limited to 'src')
-rw-r--r--src/game/Player.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/game/Player.cpp b/src/game/Player.cpp
index 07b3f62c3c5..212ada7f450 100644
--- a/src/game/Player.cpp
+++ b/src/game/Player.cpp
@@ -1838,6 +1838,11 @@ void Player::RemoveFromWorld()
sOutdoorPvPMgr.HandlePlayerLeaveZone(this, m_zoneUpdateId);
}
+ ///- Do not add/remove the player from the object storage
+ ///- It will crash when updating the ObjectAccessor
+ ///- The player should only be removed when logging out
+ Unit::RemoveFromWorld();
+
for(int i = PLAYER_SLOT_START; i < PLAYER_SLOT_END; ++i)
{
if(m_items[i])
@@ -1847,11 +1852,6 @@ void Player::RemoveFromWorld()
for (ItemMap::iterator iter = mMitems.begin(); iter != mMitems.end(); ++iter)
iter->second->RemoveFromWorld();
- ///- Do not add/remove the player from the object storage
- ///- It will crash when updating the ObjectAccessor
- ///- The player should only be removed when logging out
- Unit::RemoveFromWorld();
-
if(m_uint32Values)
{
if(WorldObject *viewpoint = GetViewpoint())