mirror of
https://github.com/azerothcore/mod-ale
synced 2025-11-29 15:38:17 +08:00
Add function to check if player is immune to everything (divine shield)
This commit is contained in:
@@ -561,6 +561,7 @@ ElunaRegister<Player> PlayerMethods[] =
|
|||||||
{ "IsInGroup", &LuaPlayer::IsInGroup },
|
{ "IsInGroup", &LuaPlayer::IsInGroup },
|
||||||
{ "IsInGuild", &LuaPlayer::IsInGuild },
|
{ "IsInGuild", &LuaPlayer::IsInGuild },
|
||||||
{ "IsGM", &LuaPlayer::IsGM },
|
{ "IsGM", &LuaPlayer::IsGM },
|
||||||
|
{ "IsImmuneToDamage", &LuaPlayer::IsImmuneToDamage },
|
||||||
{ "IsAlliance", &LuaPlayer::IsAlliance },
|
{ "IsAlliance", &LuaPlayer::IsAlliance },
|
||||||
{ "IsHorde", &LuaPlayer::IsHorde },
|
{ "IsHorde", &LuaPlayer::IsHorde },
|
||||||
#ifndef CLASSIC
|
#ifndef CLASSIC
|
||||||
|
|||||||
@@ -429,6 +429,13 @@ namespace LuaPlayer
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
int IsImmuneToDamage(lua_State* L, Player* player)
|
||||||
|
{
|
||||||
|
Eluna::Push(L, player->isTotalImmune());
|
||||||
|
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns 'true' if the [Player] satisfies all requirements to complete the quest entry.
|
* Returns 'true' if the [Player] satisfies all requirements to complete the quest entry.
|
||||||
*
|
*
|
||||||
|
|||||||
Reference in New Issue
Block a user