From e5916c5c03f5f5176cefcc1ba34c912f975a9a23 Mon Sep 17 00:00:00 2001 From: hg <4683435+hgtw@users.noreply.github.com> Date: Fri, 6 Nov 2020 20:05:26 -0500 Subject: [PATCH] Add rule to enable "In Dynamic Zone" status Live doesn't appear to ever update with this status --- common/ruletypes.h | 1 + zone/expedition.cpp | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/common/ruletypes.h b/common/ruletypes.h index 7acf0b1b4..5ff662c50 100644 --- a/common/ruletypes.h +++ b/common/ruletypes.h @@ -792,6 +792,7 @@ RULE_INT(Expedition, EmptyDzShutdownDelaySeconds, 1500, "Seconds to set dynamic RULE_INT(Expedition, WorldExpeditionProcessRateMS, 6000, "Timer interval (ms) that world checks expedition states") RULE_BOOL(Expedition, AlwaysNotifyNewLeaderOnChange, false, "Always notify clients when made expedition leader. If false (live-like) new leaders are only notified when made leader via /dzmakeleader") RULE_REAL(Expedition, LockoutDurationMultiplier, 1.0, "Multiplies lockout duration by this value when new lockouts are added") +RULE_BOOL(Expedition, EnableInDynamicZoneStatus, false, "Enables the 'In Dynamic Zone' member status in expedition window. If false (live-like) players inside the dz will show as 'Online'") RULE_CATEGORY_END() RULE_CATEGORY(DynamicZone) diff --git a/zone/expedition.cpp b/zone/expedition.cpp index 8223adec1..77dd25b0a 100644 --- a/zone/expedition.cpp +++ b/zone/expedition.cpp @@ -629,6 +629,11 @@ void Expedition::UpdateMemberStatus(uint32_t update_member_id, ExpeditionMemberS return; } + if (status == ExpeditionMemberStatus::InDynamicZone && !RuleB(Expedition, EnableInDynamicZoneStatus)) + { + status = ExpeditionMemberStatus::Online; + } + auto outapp_member_status = CreateMemberListStatusPacket(member_data.name, status); for (auto& member : m_members)