mirror of
https://github.com/azerothcore/mod-ale
synced 2025-11-29 15:38:17 +08:00
Added support for GameObject::GetLootRecipient()
This commit is contained in:
@@ -120,6 +120,28 @@ namespace LuaGameObject
|
||||
return 1;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the [Player] that can loot the [GameObject]
|
||||
*
|
||||
* @return [Player] player
|
||||
*/
|
||||
int GetLootRecipient(Eluna* /*E*/, lua_State* L, GameObject* go)
|
||||
{
|
||||
Eluna::Push(L, go->GetLootRecipient());
|
||||
return 1;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the [Group] that can loot the [GameObject]
|
||||
*
|
||||
* @return [Group] group
|
||||
*/
|
||||
int GetLootRecipientGroup(Eluna* /*E*/, lua_State* L, GameObject* go)
|
||||
{
|
||||
Eluna::Push(L, go->GetLootRecipientGroup());
|
||||
return 1;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the state of a [GameObject]
|
||||
*
|
||||
|
||||
@@ -855,6 +855,8 @@ ElunaRegister<GameObject> GameObjectMethods[] =
|
||||
{ "GetDisplayId", &LuaGameObject::GetDisplayId },
|
||||
{ "GetGoState", &LuaGameObject::GetGoState },
|
||||
{ "GetLootState", &LuaGameObject::GetLootState },
|
||||
{ "GetLootRecipient", &LuaGameObject::GetLootRecipient },
|
||||
{ "GetLootRecipientGroup", &LuaGameObject::GetLootRecipientGroup },
|
||||
|
||||
// Setters
|
||||
{ "SetGoState", &LuaGameObject::SetGoState },
|
||||
|
||||
Reference in New Issue
Block a user