Core/SAI: do not pass old creatureData to UpdateEntry() and keep current health when changing a NPC's entry. (#23493)
(cherry picked from commit 8967cc96df4c1c5c7465e9fd1fa66400f3e992b3)
This commit is contained in:
@@ -1058,7 +1058,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
|
||||
{
|
||||
for (WorldObject* target : targets)
|
||||
if (IsCreature(target))
|
||||
target->ToCreature()->UpdateEntry(e.action.updateTemplate.creature, target->ToCreature()->GetCreatureData(), e.action.updateTemplate.updateLevel != 0);
|
||||
target->ToCreature()->UpdateEntry(e.action.updateTemplate.creature, nullptr, e.action.updateTemplate.updateLevel != 0);
|
||||
break;
|
||||
}
|
||||
case SMART_ACTION_DIE:
|
||||
|
||||
Reference in New Issue
Block a user