|
VR-Engage
2.2
|
This component captures gamepad/joystick and keyboard/mouse inputs for left and right vehicle blinkers. When the user activates a blinker via a button press or keypress, this class receives the input and sends a corresponding joystick message to the simulation engine backend where the blinker state is updated.
#include <vehicleBlinkerControlLogic.h>
Public Member Functions | |
| DtVehicleBlinkerControlLogic () | |
| virtual | ~DtVehicleBlinkerControlLogic () override |
| virtual const char * | type () const override |
| virtual bool | initialize (makVre::DtPlayerStation *player, makVre::DtInitTable &config) override |
| virtual void | setLeftBlinker (double val) |
| virtual void | setRightBlinker (double val) |
Public Member Functions inherited from makVre::DtEntityControlLogic | |
| DtEntityControlLogic () | |
| virtual | ~DtEntityControlLogic () override |
| virtual bool | postInitialize () override |
| virtual void | tick (double dt) override |
| virtual void | shutdown () override |
| virtual void | setExtendedData (const std::string &key, const std::string &value, DtEntityIdentifier entity=DtEntityIdentifier::nullId()) |
| virtual void | setMouseControlEnabled (bool enabled) |
| virtual bool | isMouseControlEnabled () |
| virtual bool | isMouseControlSupportAllowed () const |
| virtual void | setMouseControlSupportAllowed (bool enable) |
| virtual const std::vector< std::string > & | joystickGroups () const |
| virtual makVre::DtVreMessageResult | handleSimState (makVre::DtVreMessage *msg) |
| virtual makVre::DtVreMessageResult | handleStateMessages (makVre::DtVreMessage *message) |
| virtual makVre::DtVreMessageResult | handleReset (makVre::DtVreMessage *message) |
| virtual void | reset (float val) |
| virtual void | resetInPlace (float val) |
| virtual void | toggleMouseControl (float val) |
| virtual void | enableMouseControl (float val) |
| virtual makVre::DtVreMessageResult | handleFocusMessage (makVre::DtVreMessage *message) |
Public Member Functions inherited from makVre::DtPlayerComponent | |
| DtPlayerComponent () | |
| virtual | ~DtPlayerComponent () |
| virtual void | setName (const std::string &name) |
| virtual const std::string & | name () |
| virtual DtPlayerStation & | player () |
| virtual DtAttributeHandle & | playerAttributeStore () |
| virtual const DtAttributeHandle & | playerAttributeStore () const |
Protected Member Functions | |
| virtual void | sendJoystickMessage (const std::string &function, double val, double delay=0) |
Protected Member Functions inherited from makVre::DtEntityControlLogic | |
| virtual void | takeControlOfPlayerEntity () |
| virtual void | releaseControlOfPlayerEntity () |
Protected Member Functions inherited from makVre::DtPlayerComponent | |
| virtual void | initializeStateAttributes () |
Protected Attributes | |
| makVre::DtInputLogic | myInputLogic |
| std::string | myMainJoystickGroup |
Protected Attributes inherited from makVre::DtEntityControlLogic | |
| std::vector< std::string > | myJoystickFunctionGroups |
| DtInputLogic | myCommonInputLogic |
| std::string | myInputConfigFile |
| bool | myMouseControlEnabled |
| bool | myMouseControlSupportAllowed |
Protected Attributes inherited from makVre::DtPlayerComponent | |
| std::string | myName |
| DtInitTable | myConfig |
| DtPlayerStation * | myPlayer |
| makVrv::DtDe * | myDe |
| DtEntityResolver * | myResolver |
| DtAttributeCallbackManager | myAttributeCallbacks |
| DtVehicleBlinkerControlLogic::DtVehicleBlinkerControlLogic | ( | ) |
|
overridevirtual |
|
overridevirtual |
Returns the component type identifier.
Returns the type identifier string for this component, which is used by the VR-Engage framework for component identification and management. The returned value matches DtEntityControlLogicType.
Reimplemented from makVre::DtEntityControlLogic.
|
overridevirtual |
Initializes the entity control logic.
| player | Pointer to the player station this component belongs to |
| config | Configuration table with initialization parameters |
Initializes the entity control component with the specified player station and configuration. Registers message handlers and sets up input mappings.
Reimplemented from makVre::DtEntityControlLogic.
References makVre::DtPlayerComponent::player().
|
virtual |
|
virtual |
|
protectedvirtual |
|
protected |
|
protected |