mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-17 07:18:37 +00:00
[Bug Fix] Alleviate some lag with crosszone/worldwide spell casting. (#2016)
- Spell casting was using SpellFinished which casts the spell, and if the spell was a group spell each member of the group would cast it on all the other members, causing a chain reaction. - This fix utilizes ApplySpellBuff(spell_id, duration) so that it only casts the spell on the target, as with the crosszone and worldwide methods you will be affecting your target based on identifiers regardless. - This should alleviate some of the crosszone/worldwide casting crashes on larger servers such as Lazarus.
This commit is contained in:
+2
-2
@@ -2450,7 +2450,7 @@ void Lua_Mob::SetSeeInvisibleUndeadLevel(uint8 invisible_level)
|
||||
|
||||
void Lua_Mob::ApplySpellBuff(int spell_id) {
|
||||
Lua_Safe_Call_Void();
|
||||
self->ApplySpellBuff(spell_id, 0);
|
||||
self->ApplySpellBuff(spell_id);
|
||||
}
|
||||
|
||||
void Lua_Mob::ApplySpellBuff(int spell_id, int duration) {
|
||||
@@ -2470,7 +2470,7 @@ int Lua_Mob::GetBuffStatValueBySpell(int spell_id, const char* identifier) {
|
||||
|
||||
void Lua_Mob::SetBuffDuration(int spell_id) {
|
||||
Lua_Safe_Call_Void();
|
||||
self->SetBuffDuration(spell_id, 0);
|
||||
self->SetBuffDuration(spell_id);
|
||||
}
|
||||
|
||||
void Lua_Mob::SetBuffDuration(int spell_id, int duration) {
|
||||
|
||||
Reference in New Issue
Block a user