|
VR-Engage
2.3
|
This page covers pilot flight controls, rendering lifecycle, and sensor-input additions in vrePilotFrontend headers. Update custom role configuration and derived components together.
DtFlightControlsInputLogic adds a required middle argument in vrePilotFrontend/flightControlsInputLogic.h:
| 2.2 | 2.3 |
|---|---|
virtual void initialize(bool isFixedWing, bool useRTD) | virtual void initialize(bool isFixedWing, bool useDroneFunctionGroup, bool useRTD) |
virtual std::string setFlightControls(bool isFixedWing, bool useRTD) | virtual std::string setFlightControls(bool isFixedWing, bool useDroneFunctionGroup, bool useRTD) |
Pass false in the new position to retain the existing function-group selection. Pass true when flight input must use the "drone" function group. Update derived overrides and calls; leaving an old two-argument override does not override the new virtual method. vrePilotFrontend/pilotSimLogic.h adds the role parameter PilotSimLogicConfig::useDroneFunctionGroup ("useDroneFunctionGroup", default false) to select this behavior.
DtPilotSimLogic::handleEntityStateStringMessage(DtVreMessage*) is no longer declared in vrePilotFrontend/pilotSimLogic.h. Remove derived overrides or subscriptions that depend on this callback. Observe the SelectedWeaponLabel player attribute for the former callback's state-property value. The postInitialize() override aliases stateProperties.SelectedWeapon to SelectedWeaponLabel instead of handling EntityStateStringMessage directly. The separate SelectedWeapon attribute identifies the selected weapon system.
DtInstrumentTextureReplacer::Geometry moved from protected to public in vrePilotFrontend/pilotRenderUpdater.h. Its original normal, plane, box, min, and max members remain. The structure also contains center, width, height, right, and up. Review derived classes that initialize or copy all geometry fields; old aggregate initializers do not set the added fields explicitly.
DtPilotRenderUpdater::finalizeInitTick(double dt) and DtPilotObserverUpdater::finalizeInitTick(double dt) now override the Player Station readiness stage. The render updater waits for cockpit objects and deferred sensor views. The observer updater completes mimic attachment and terrain setup. Derived classes that override these methods must retain base readiness behavior before reporting DtInitTickStatus::Ready; do not move these actions into engaged-frame tick().
DtPilotSimLogic also overrides postInitialize() and reset(float val). The reset override restores a fixed-wing aircraft to its saved location and clamps a ground-level saved location to terrain.
vrePilotFrontend/instrumentsInputLogic.h adds virtual void sensorElevationAbsolute(double val) and virtual void sensorZoomPercent(double val) for absolute sensor settings. They supplement the existing relative sensorElevation(double) and sensorZoom(double) methods. Both new inputs use values in [-1.0, 1.0].
DtInstrumentTextureReplacer adds Geometry getGeometry(). DtHudGeometryFinder derives from it and offers DtHudGeometryFinder(const std::string& nodeName) for locating geometry without replacing textures. DtPilotRenderUpdater adds updateHudContactsVR() for VR-head-position-aware HUD contact rendering.