diff --git a/source/WorldServer/Entity.cpp b/source/WorldServer/Entity.cpp index 90f5944..e3636b7 100644 --- a/source/WorldServer/Entity.cpp +++ b/source/WorldServer/Entity.cpp @@ -3267,7 +3267,7 @@ bool Entity::IsDazeImmune(){ return (immunities[IMMUNITY_TYPE_DAZE] && immunities[IMMUNITY_TYPE_DAZE]->size(true) > 0); } -void Entity::AddImmunity(LuaSpell* spell, int16 type){ +void Entity::AddImmunity(LuaSpell* spell, int8 type){ if (!spell) return; @@ -3277,7 +3277,7 @@ void Entity::AddImmunity(LuaSpell* spell, int16 type){ immunities[type]->Add(spell); } -void Entity::RemoveImmunity(LuaSpell* spell, int16 type){ +void Entity::RemoveImmunity(LuaSpell* spell, int8 type){ MutexList* list = immunities[type]; if (!list || list->size(true) == 0) return; @@ -3285,7 +3285,7 @@ void Entity::RemoveImmunity(LuaSpell* spell, int16 type){ list->Remove(spell); } -bool Entity::IsImmune(int16 type){ +bool Entity::IsImmune(int8 type){ return (immunities[type] && immunities[type]->size(true) > 0); } diff --git a/source/WorldServer/Entity.h b/source/WorldServer/Entity.h index e97ff0d..3ffbf96 100644 --- a/source/WorldServer/Entity.h +++ b/source/WorldServer/Entity.h @@ -1899,9 +1899,9 @@ public: void AddDazeImmunity(LuaSpell* spell); void RemoveDazeImmunity(LuaSpell* spell); bool IsDazeImmune(); - void AddImmunity(LuaSpell* spell, int16 type); - void RemoveImmunity(LuaSpell* spell, int16 type); - bool IsImmune(int16 type); + void AddImmunity(LuaSpell* spell, int8 type); + void RemoveImmunity(LuaSpell* spell, int8 type); + bool IsImmune(int8 type); void AddFlightSpell(LuaSpell* spell); void RemoveFlightSpell(LuaSpell* spell); void AddSafefallSpell(LuaSpell* spell);