Fix Eluna OnCreatureKill
Signed-off-by: Zwisus <zlt988@gmail.com>
This commit is contained in:
parent
92ea73bbce
commit
551a28f9f9
@ -1038,15 +1038,16 @@ void Unit::JustKilledCreature(Creature* victim, Player* responsiblePlayer)
|
|||||||
{ mapInstance->OnCreatureDeath(victim); }
|
{ mapInstance->OnCreatureDeath(victim); }
|
||||||
|
|
||||||
if (responsiblePlayer) // killedby Player, inform BG
|
if (responsiblePlayer) // killedby Player, inform BG
|
||||||
|
{
|
||||||
if (BattleGround* bg = responsiblePlayer->GetBattleGround())
|
if (BattleGround* bg = responsiblePlayer->GetBattleGround())
|
||||||
{
|
{
|
||||||
bg->HandleKillUnit(victim, responsiblePlayer);
|
bg->HandleKillUnit(victim, responsiblePlayer);
|
||||||
|
}
|
||||||
// Used by Eluna
|
// Used by Eluna
|
||||||
#ifdef ENABLE_ELUNA
|
#ifdef ENABLE_ELUNA
|
||||||
sEluna->OnCreatureKill(responsiblePlayer, victim);
|
sEluna->OnCreatureKill(responsiblePlayer, victim);
|
||||||
#endif /* ENABLE_ELUNA */
|
#endif /* ENABLE_ELUNA */
|
||||||
}
|
}
|
||||||
|
|
||||||
// Notify the outdoor pvp script
|
// Notify the outdoor pvp script
|
||||||
if (OutdoorPvP* outdoorPvP = sOutdoorPvPMgr.GetScript(responsiblePlayer ? responsiblePlayer->GetCachedZoneId() : GetZoneId()))
|
if (OutdoorPvP* outdoorPvP = sOutdoorPvPMgr.GetScript(responsiblePlayer ? responsiblePlayer->GetCachedZoneId() : GetZoneId()))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user