mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-16 22:58:34 +00:00
Add more rule-driven behavior
This commit is contained in:
+8
-5
@@ -1239,11 +1239,14 @@ bool Zone::Process() {
|
||||
LogHotReloadDetail("Hot reload timer check...");
|
||||
|
||||
bool perform_reload = true;
|
||||
for (auto &it : entity_list.GetClientList()) {
|
||||
auto client = it.second;
|
||||
if (client->GetAggroCount() > 0) {
|
||||
perform_reload = false;
|
||||
break;
|
||||
|
||||
if (RuleB(HotReload, QuestsRepopWhenPlayersNotInCombat)) {
|
||||
for (auto &it : entity_list.GetClientList()) {
|
||||
auto client = it.second;
|
||||
if (client->GetAggroCount() > 0) {
|
||||
perform_reload = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+14
-3
@@ -27,9 +27,20 @@ void ZoneReload::HotReloadQuests()
|
||||
timer.reset();
|
||||
|
||||
entity_list.ClearAreas();
|
||||
parse->ReloadQuests();
|
||||
zone->Repop(0);
|
||||
|
||||
parse->ReloadQuests(RuleB(HotReload, QuestsResetTimersWithReload));
|
||||
|
||||
if (RuleB(HotReload, QuestsRepopWithReload)) {
|
||||
zone->Repop(0);
|
||||
}
|
||||
zone->SetQuestHotReloadQueued(false);
|
||||
|
||||
LogHotReload("[Quests] Reloading scripts in zone [{}] Time [{:.2f}]", zone->GetShortName(), timer.elapsed());
|
||||
LogHotReload(
|
||||
"[Quests] Reloading scripts in zone [{}] repop_with_reload [{}] reset_timers [{}] when_not_in_combat [{}] Time [{:.4f}]",
|
||||
zone->GetShortName(),
|
||||
(RuleB(HotReload, QuestsRepopWithReload) ? "true" : "false"),
|
||||
(RuleB(HotReload, QuestsResetTimersWithReload) ? "true" : "false"),
|
||||
(RuleB(HotReload, QuestsRepopWhenPlayersNotInCombat) ? "true" : "false"),
|
||||
timer.elapsed()
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user