mirror of
https://github.com/EQEmu/Server.git
synced 2026-06-10 06:40:26 +00:00
[Quest API] Add GetDeityName() to Perl/Lua (#4180)
# Perl - Add `$mob->GetDeityName()`. # Lua - Add `mob:GetDeityName()`. # Notes - Allows operators to get a mob's deity name.
This commit is contained in:
@@ -3297,6 +3297,12 @@ bool Lua_Mob::IsAlwaysAggro()
|
||||
return self->AlwaysAggro();
|
||||
}
|
||||
|
||||
std::string Lua_Mob::GetDeityName()
|
||||
{
|
||||
Lua_Safe_Call_String();
|
||||
return EQ::deity::GetDeityName(static_cast<EQ::deity::DeityType>(self->GetDeity()));
|
||||
}
|
||||
|
||||
luabind::scope lua_register_mob() {
|
||||
return luabind::class_<Lua_Mob, Lua_Entity>("Mob")
|
||||
.def(luabind::constructor<>())
|
||||
@@ -3522,6 +3528,7 @@ luabind::scope lua_register_mob() {
|
||||
.def("GetDefaultRaceSize", (float(Lua_Mob::*)(int))&Lua_Mob::GetDefaultRaceSize)
|
||||
.def("GetDefaultRaceSize", (float(Lua_Mob::*)(int,int))&Lua_Mob::GetDefaultRaceSize)
|
||||
.def("GetDeity", &Lua_Mob::GetDeity)
|
||||
.def("GetDeityName", &Lua_Mob::GetDeityName)
|
||||
.def("GetDisplayAC", &Lua_Mob::GetDisplayAC)
|
||||
.def("GetDrakkinDetails", &Lua_Mob::GetDrakkinDetails)
|
||||
.def("GetDrakkinHeritage", &Lua_Mob::GetDrakkinHeritage)
|
||||
|
||||
Reference in New Issue
Block a user