[9515] Fix a possible exploit in CMSG_HEARTH_AND_RESURRECT

Signed-off-by: Lightguard <Lightguard@tauri.hu>
This commit is contained in:
tomrus88 2010-03-04 09:45:43 +01:00 committed by Lightguard
parent 6af247d34f
commit 9626d3333e
3 changed files with 33 additions and 29 deletions

View file

@ -240,7 +240,7 @@ enum AreaFlags
AREA_FLAG_OUTDOOR_PVP = 0x01000000, // Wintergrasp and it's subzones
AREA_FLAG_UNK9 = 0x02000000, // unknown
AREA_FLAG_UNK10 = 0x04000000, // unknown
AREA_FLAG_OUTDOOR_PVP2 = 0x08000000 // Wintergrasp and it's subzones
AREA_FLAG_CAN_HEARTH_AND_RES = 0x08000000 // Wintergrasp and it's subzones
// 0x20000000 not flyable?
};

View file

@ -1578,6 +1578,10 @@ void WorldSession::HandleHearthandResurrect(WorldPacket & /*recv_data*/)
{
sLog.outDebug("WORLD: CMSG_HEARTH_AND_RESURRECT");
AreaTableEntry const* atEntry = sAreaStore.LookupEntry(_player->GetAreaId());
if(!atEntry || !(atEntry->flags & AREA_FLAG_CAN_HEARTH_AND_RES))
return;
// Can't use in flight
if (_player->isInFlight())
return;

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "9514"
#define REVISION_NR "9515"
#endif // __REVISION_NR_H__