diff options
author | Shauren <shauren.trinity@gmail.com> | 2011-03-19 13:59:53 +0100 |
---|---|---|
committer | Shauren <shauren.trinity@gmail.com> | 2011-03-19 13:59:53 +0100 |
commit | 31b9951f20298c0e87647f60c8b9e483a9fea9c0 (patch) | |
tree | d310cf4fa13716cbc725d8f8079cd60db126edad /src | |
parent | 7d0b5bfff98928495a5eaa9edcf9494327b8e269 (diff) |
Core/Players: Corrected pending bind logic (prevent attempting to bind (and failing) when player left the instance by areatrigger before timer finished)
Diffstat (limited to 'src')
-rwxr-xr-x | src/server/game/Entities/Player/Player.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp index fe784b1ec9e..13a39e98122 100755 --- a/src/server/game/Entities/Player/Player.cpp +++ b/src/server/game/Entities/Player/Player.cpp @@ -1728,7 +1728,9 @@ void Player::Update(uint32 p_time) { if (_pendingBindTimer <= p_time) { - BindToInstance(); + // Player left the instance + if (_pendingBind->GetInstanceId() == GetInstanceId()) + BindToInstance(); SetPendingBind(NULL, 0); } else @@ -17907,10 +17909,6 @@ InstancePlayerBind* Player::BindToInstance(InstanceSave *save, bool permanent, b void Player::BindToInstance() { - // Player left the instance - if (_pendingBind->GetInstanceId() != GetInstanceId()) - return; - WorldPacket data(SMSG_INSTANCE_SAVE_CREATED, 4); data << uint32(0); GetSession()->SendPacket(&data); |