* Unsummon pet if direct control spell expire out of visibility range from owner (base on VladimirMangos changes)

* Move repeating code to separate method

--HG--
branch : trunk
This commit is contained in:
azazel committed 2010-08-12 12:14:32 +06:00
1 parent c7b48c1ca9
commit c6b4309f1e
4 files changed
+90 -113

No files matched your search

+2 -2
View File
@@ -15409,8 +15409,8 @@ bool Unit::SetCharmedBy(Unit* charmer, CharmType type)
}
// Set charmed
Map* pMap = GetMap();
if (!IsVehicle() || (IsVehicle() && pMap && !pMap->IsBattleground()))
Map* pMap = GetMap();
if (!IsVehicle() || (IsVehicle() && pMap && !pMap->IsBattleground()))
setFaction(charmer->getFaction());
charmer->SetCharm(this, true);