feat(rails): answer RequestRailActivatorState

The client's rail activator sends RequestRailActivatorState (1479, no
payload) when it is added to the world (LWORailActivatorComponent::
SendMessage 0x00c00da0) and live answered with
NotifyRailActivatorStateChange (1478, bActive) to that client; the client
stores rail_activator_active and updates the rail's pick type (usable or
not). Live: 152 requests, 413 answers, every one bActive = true. DLU
dropped the request and never answered.

RailActivatorComponent keeps the level key rail_activator_active
(default true; every rail in the live levels sets it to 1) and the
request is answered with it.

Check in game: in Ninjago Monastery and Nimbus Station, rails (spinjitzu
posts, the Nexus Tower rails) show as usable and work as before when
first loading the world and after zone changes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Aaron Kimbrell
2026-09-29 03:23:47 -05:00
parent e9ff5f402d
commit 3672b64dec
6 changed files with 68 additions and 0 deletions

View File

@@ -44,6 +44,7 @@ RailActivatorComponent::RailActivatorComponent(Entity* parent, const int32_t com
m_NotifyArrived = parent->GetVar<bool>(u"rail_notify_activator_arrived");
m_ShowNameBillboard = levelOr(u"rail_show_name_billboard", tableData.showNameBillboard);
m_UseDB = parent->GetVar<bool>(u"rail_use_db");
m_Active = levelOr(u"rail_activator_active", true);
m_CameraLocked = tableData.cameraLocked;
m_CollisionEnabled = tableData.playerCollision;
}

View File

@@ -38,6 +38,11 @@ public:
void OnCancelRailMovement(Entity* originator);
bool GetDamageImmune() const { return m_DamageImmune; }
/**
* Whether the rail can be used (level key rail_activator_active; every rail in the live levels has it set)
*/
bool GetActive() const { return m_Active; }
bool GetNoAggro() const { return m_NoAggro; }
bool GetShowNameBillboard() const { return m_ShowNameBillboard; }
private:
@@ -111,6 +116,8 @@ private:
*/
bool m_DamageImmune;
bool m_Active{ true };
/**
* Client flag
*/