From 8e89c8b6be6a7ba32c30ab43f853ae2f62ca4a9c Mon Sep 17 00:00:00 2001 From: hondacrx Date: Tue, 23 Nov 2021 22:36:07 -0500 Subject: [PATCH] threat assert Port From (https://github.com/TrinityCore/TrinityCore/commit/31dca39c057bf7eef590a060f9e25fed4f4e9eda) --- Source/Game/Entities/Creature/Creature.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Source/Game/Entities/Creature/Creature.cs b/Source/Game/Entities/Creature/Creature.cs index bad4c63b3..14c98a4eb 100644 --- a/Source/Game/Entities/Creature/Creature.cs +++ b/Source/Game/Entities/Creature/Creature.cs @@ -2138,7 +2138,12 @@ namespace Game.Entities target = GetThreatManager().GetAnyTarget(); if (target == null) target = GetCombatManager().GetAnyTarget(); - Cypher.Assert(target != null, $"Creature {GetEntry()} ({GetName()}) is engaged without threat list"); + + if (target == null) + { + Log.outError(LogFilter.Unit, $"Creature {GetEntry()} ({GetName()}) is engaged without threat list"); + return; + } var u_do = new CallOfHelpCreatureInRangeDo(this, target, radius); var worker = new CreatureWorker(this, u_do);