mirror of
https://github.com/EQEmu/Server.git
synced 2026-06-10 02:31:03 +00:00
[Quest API] Add ApplySpell() and SetBuffDuration() overloads to Perl/Lua (#3576)
# Perl - Add `$bot->ApplySpell(spell_id, duration, level)`. - Add `$bot->ApplySpell(spell_id, duration, level, allow_pets)`. - Add `$bot->ApplySpellGroup(spell_id, duration, level)`. - Add `$bot->ApplySpellGroup(spell_id, duration, level, allow_pets)`. - Add `$bot->ApplySpellRaid(spell_id)`. - Add `$bot->ApplySpellRaid(spell_id, duration)`. - Add `$bot->ApplySpellRaid(spell_id, duration, level)`. - Add `$bot->ApplySpellRaid(spell_id, duration, level, allow_pets)`. - Add `$bot->ApplySpellRaid(spell_id, duration, level, allow_pets, is_raid_group_only)`. - Add `$bot->SetSpellDuration(spell_id, duration, level)`. - Add `$bot->SetSpellDuration(spell_id, duration, level, allow_pets)`. - Add `$bot->SetSpellDurationGroup(spell_id, duration, level)`. - Add `$bot->SetSpellDurationGroup(spell_id, duration, level, allow_pets)`. - Add `$bot->SetSpellDurationRaid(spell_id)`. - Add `$bot->SetSpellDurationRaid(spell_id, duration)`. - Add `$bot->SetSpellDurationRaid(spell_id, duration, level)`. - Add `$bot->SetSpellDurationRaid(spell_id, duration, level, allow_pets)`. - Add `$bot->SetSpellDurationRaid(spell_id, duration, level, allow_pets, is_raid_group_only)`. - Add `$client->ApplySpell(spell_id, duration, level)`. - Add `$client->ApplySpell(spell_id, duration, level, allow_pets)`. - Add `$client->ApplySpellGroup(spell_id, duration, level)`. - Add `$client->ApplySpellGroup(spell_id, duration, level, allow_pets)`. - Add `$client->ApplySpellRaid(spell_id, duration, level)`. - Add `$client->ApplySpellRaid(spell_id, duration, level, allow_pets)`. - Add `$client->ApplySpellRaid(spell_id, duration, level, allow_pets, is_raid_group_only)`. - Add `$client->ApplySpellRaid(spell_id, duration, level, allow_pets, is_raid_group_only, allow_bots)`. - Add `$client->SetSpellDuration(spell_id, duration, level)`. - Add `$client->SetSpellDuration(spell_id, duration, level, allow_pets)`. - Add `$client->SetSpellDurationGroup(spell_id, duration, level)`. - Add `$client->SetSpellDurationGroup(spell_id, duration, level, allow_pets)`. - Add `$client->SetSpellDurationRaid(spell_id, duration, level)`. - Add `$client->SetSpellDurationRaid(spell_id, duration, level, allow_pets)`. - Add `$client->SetSpellDurationRaid(spell_id, duration, level, allow_pets, is_raid_group_only)`. - Add `$client->SetSpellDurationRaid(spell_id, duration, level, allow_pets, is_raid_group_only, allow_bots)`. - Add `$mob->ApplySpellBuff(spell_id, duration, level)`. - Add `$mob->SetSpellDuration(spell_id, duration, level)`. # Lua - Add `bot:ApplySpell(spell_id, duration, level)`. - Add `bot:ApplySpell(spell_id, duration, level, allow_pets)`. - Add `bot:ApplySpellGroup(spell_id, duration, level)`. - Add `bot:ApplySpellGroup(spell_id, duration, level, allow_pets)`. - Add `bot:ApplySpellRaid(spell_id)`. - Add `bot:ApplySpellRaid(spell_id, duration)`. - Add `bot:ApplySpellRaid(spell_id, duration, level)`. - Add `bot:ApplySpellRaid(spell_id, duration, level, allow_pets)`. - Add `bot:ApplySpellRaid(spell_id, duration, level, allow_pets, is_raid_group_only)`. - Add `bot:SetSpellDuration(spell_id, duration, level)`. - Add `bot:SetSpellDuration(spell_id, duration, level, allow_pets)`. - Add `bot:SetSpellDurationGroup(spell_id, duration, level)`. - Add `bot:SetSpellDurationGroup(spell_id, duration, level, allow_pets)`. - Add `bot:SetSpellDurationRaid(spell_id, duration, level)`. - Add `bot:SetSpellDurationRaid(spell_id, duration, level, allow_pets)`. - Add `bot:SetSpellDurationRaid(spell_id, duration, level, allow_pets, is_raid_group_only)`. - Add `client:ApplySpell(spell_id, duration, level)`. - Add `client:ApplySpell(spell_id, duration, level, allow_pets)`. - Add `client:ApplySpellGroup(spell_id, duration, level)`. - Add `client:ApplySpellGroup(spell_id, duration, level, allow_pets)`. - Add `client:ApplySpellRaid(spell_id, duration, level)`. - Add `client:ApplySpellRaid(spell_id, duration, level, allow_pets)`. - Add `client:ApplySpellRaid(spell_id, duration, level, allow_pets, is_raid_group_only)`. - Add `client:ApplySpellRaid(spell_id, duration, level, allow_pets, is_raid_group_only, allow_bots)`. - Add `client:SetSpellDuration(spell_id, duration, level)`. - Add `client:SetSpellDuration(spell_id, duration, level, allow_pets)`. - Add `client:SetSpellDurationGroup(spell_id, duration, level)`. - Add `client:SetSpellDurationGroup(spell_id, duration, level, allow_pets)`. - Add `client:SetSpellDurationRaid(spell_id, duration, level)`. - Add `client:SetSpellDurationRaid(spell_id, duration, level, allow_pets)`. - Add `client:SetSpellDurationRaid(spell_id, duration, level, allow_pets, is_raid_group_only)`. - Add `client:SetSpellDurationRaid(spell_id, duration, level, allow_pets, is_raid_group_only, allow_bots)`. - Add `mob:ApplySpellBuff(spell_id, duration, level)`. - Add `mob:SetSpellDuration(spell_id, duration, level)`. # Notes - This allows operators to override the spell level.
This commit is contained in:
+14
-2
@@ -2532,6 +2532,11 @@ void Lua_Mob::ApplySpellBuff(int spell_id, int duration) {
|
||||
self->ApplySpellBuff(spell_id, duration);
|
||||
}
|
||||
|
||||
void Lua_Mob::ApplySpellBuff(int spell_id, int duration, int level) {
|
||||
Lua_Safe_Call_Void();
|
||||
self->ApplySpellBuff(spell_id, level);
|
||||
}
|
||||
|
||||
int Lua_Mob::GetBuffStatValueBySlot(uint8 slot, const char* identifier) {
|
||||
Lua_Safe_Call_Int();
|
||||
return self->GetBuffStatValueBySlot(slot, identifier);
|
||||
@@ -2552,6 +2557,11 @@ void Lua_Mob::SetBuffDuration(int spell_id, int duration) {
|
||||
self->SetBuffDuration(spell_id, duration);
|
||||
}
|
||||
|
||||
void Lua_Mob::SetBuffDuration(int spell_id, int duration, int level) {
|
||||
Lua_Safe_Call_Void();
|
||||
self->SetBuffDuration(spell_id, duration, level);
|
||||
}
|
||||
|
||||
Lua_Mob Lua_Mob::GetUltimateOwner() {
|
||||
Lua_Safe_Call_Class(Lua_Mob);
|
||||
return Lua_Mob(self->GetUltimateOwner());
|
||||
@@ -3166,7 +3176,8 @@ luabind::scope lua_register_mob() {
|
||||
.def("AddToHateList", (void(Lua_Mob::*)(Lua_Mob,int64,int64,bool,bool))&Lua_Mob::AddToHateList)
|
||||
.def("AddToHateList", (void(Lua_Mob::*)(Lua_Mob,int64,int64,bool,bool,bool))&Lua_Mob::AddToHateList)
|
||||
.def("ApplySpellBuff", (void(Lua_Mob::*)(int))&Lua_Mob::ApplySpellBuff)
|
||||
.def("ApplySpellBuff", (void(Lua_Mob::*)(int, int))&Lua_Mob::ApplySpellBuff)
|
||||
.def("ApplySpellBuff", (void(Lua_Mob::*)(int,int))&Lua_Mob::ApplySpellBuff)
|
||||
.def("ApplySpellBuff", (void(Lua_Mob::*)(int,int,int))&Lua_Mob::ApplySpellBuff)
|
||||
.def("Attack", (bool(Lua_Mob::*)(Lua_Mob))&Lua_Mob::Attack)
|
||||
.def("Attack", (bool(Lua_Mob::*)(Lua_Mob,int))&Lua_Mob::Attack)
|
||||
.def("Attack", (bool(Lua_Mob::*)(Lua_Mob,int,bool))&Lua_Mob::Attack)
|
||||
@@ -3613,7 +3624,8 @@ luabind::scope lua_register_mob() {
|
||||
.def("SetBucket", (void(Lua_Mob::*)(std::string,std::string))&Lua_Mob::SetBucket)
|
||||
.def("SetBucket", (void(Lua_Mob::*)(std::string,std::string,std::string))&Lua_Mob::SetBucket)
|
||||
.def("SetBuffDuration", (void(Lua_Mob::*)(int))&Lua_Mob::SetBuffDuration)
|
||||
.def("SetBuffDuration", (void(Lua_Mob::*)(int, int))&Lua_Mob::SetBuffDuration)
|
||||
.def("SetBuffDuration", (void(Lua_Mob::*)(int,int))&Lua_Mob::SetBuffDuration)
|
||||
.def("SetBuffDuration", (void(Lua_Mob::*)(int,int,int))&Lua_Mob::SetBuffDuration)
|
||||
.def("SetCurrentWP", &Lua_Mob::SetCurrentWP)
|
||||
.def("SetDestructibleObject", (void(Lua_Mob::*)(bool))&Lua_Mob::SetDestructibleObject)
|
||||
.def("SetDisableMelee", (void(Lua_Mob::*)(bool))&Lua_Mob::SetDisableMelee)
|
||||
|
||||
Reference in New Issue
Block a user