aboutsummaryrefslogtreecommitdiff
path: root/src/server/scripts/Commands
diff options
context:
space:
mode:
authorTreeston <treeston.mmoc@gmail.com>2018-01-04 04:46:22 +0100
committerShauren <shauren.trinity@gmail.com>2021-05-16 21:56:05 +0200
commit5aee452943e5c76f54f58eea9e6880b54a61ec9c (patch)
treef604cbf92a9207d6d9f8d94ff1a8d8b08f3d248f /src/server/scripts/Commands
parent83159544b52bf48e8ba3a6eb98c1f4918c0b7bbe (diff)
Core/Misc: A variety of clean-up changes, mostly following up on 532ab1c to fix legacy bugs exposed by it:
- Triggers can no longer have a threat list (this may expose some ugliness in old legacy scripts) - Threat entries are forced to OFFLINE if the AI refuses to attack the target - Clean up passive creature evade behavior to be more consistent - Fix a months old issue in spawn group management that would cause "Inactive" to incorrectly show in .list respawns for system groups outside of map 0 - Valithria script cleanups, remove old hacks and make it work with the new system. Closes #21174. - Some strings cleanup (cherry picked from commit 9f9507e6a1fd50a5ce643a4096c1712700244a61)
Diffstat (limited to 'src/server/scripts/Commands')
-rw-r--r--src/server/scripts/Commands/cs_debug.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/server/scripts/Commands/cs_debug.cpp b/src/server/scripts/Commands/cs_debug.cpp
index b46b8cfd978..8efbd353ed0 100644
--- a/src/server/scripts/Commands/cs_debug.cpp
+++ b/src/server/scripts/Commands/cs_debug.cpp
@@ -856,8 +856,6 @@ public:
handler->PSendSysMessage("%s (%s) is not alive.", target->GetName().c_str(), target->GetGUID().ToString().c_str());
return true;
}
- if (!target->CanHaveThreatList())
- handler->PSendSysMessage("%s (%s) cannot have a threat list.", target->GetName().c_str(), target->GetGUID().ToString().c_str());
uint32 count = 0;
auto const& threatenedByMe = target->GetThreatManager().GetThreatenedByMeList();
@@ -875,8 +873,8 @@ public:
}
if (!mgr.CanHaveThreatList())
- return true;
- if (mgr.IsEngaged())
+ handler->PSendSysMessage("%s (%s) cannot have a threat list.", target->GetName().c_str(), target->GetGUID().ToString().c_str());
+ else if (mgr.IsEngaged())
{
count = 0;
handler->PSendSysMessage("Threat list of %s (%s, SpawnID %u)", target->GetName().c_str(), target->GetGUID().ToString().c_str(), target->GetTypeId() == TYPEID_UNIT ? target->ToCreature()->GetSpawnId() : 0);