aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortartalo <none@none>2009-12-02 12:42:58 +0100
committertartalo <none@none>2009-12-02 12:42:58 +0100
commit49ee73a36d20e22881522fb919572132ae76b55a (patch)
tree0612c0b7e3060dbeeaea0b2e0de324da47388d90
parent327a400e0bda46db7e2881ed8e17ddbb5cd0e744 (diff)
Teleport in-dungeon players to recall position when difficulty changes to avoid an exploit. Closes #58
--HG-- branch : trunk
-rw-r--r--src/game/Group.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/game/Group.cpp b/src/game/Group.cpp
index 56a2539a798..4657136ddf4 100644
--- a/src/game/Group.cpp
+++ b/src/game/Group.cpp
@@ -1461,6 +1461,9 @@ void Group::SetDifficulty(uint8 difficulty)
continue;
player->SetDifficulty(difficulty);
player->SendDungeonDifficulty(true);
+ //send player to recall positio nis a dungeon (to avoid an exploit)
+ if (sMapStore.LookupEntry(player->GetMap()->IsDungeon()))
+ player->TeleportTo(player->m_recallMap, player->m_recallX, player->m_recallY, player->m_recallZ, player->m_recallO);
}
}