VR-Engage  2.2
Loading...
Searching...
No Matches
makVre::DtVreParachuteController Class Reference

Detailed Description

DtVreParachuteController extends the base parachute controller to add joystick control capabilities. This allows direct user control of parachute steering and deployment through joystick inputs. The controller also provides automated guidance for CGF entities to navigate to designated landing locations.

Uses Descriptor Type: DtParachuteControllerDescriptor

#include <vreParachuteController.h>

Inheritance diagram for makVre::DtVreParachuteController:
[legend]

Public Member Functions

 DtVreParachuteController (const DtString &name, DtLocalObject *owner, DtSimulationServices *simManager, DtComponentDescriptor *desc=0, DtReaderWriterRegistry *parentRegistry=0)
 
virtual ~DtVreParachuteController () override
 
virtual void tick () override
 
virtual const char * type () const override
 
- Public Member Functions inherited from makVre::DtVreSimComponent< DtParachuteController >
 DtVreSimComponent (const DtString &name, DtLocalObject *owner, DtSimulationServices *simManager, DtComponentDescriptor *desc=0, DtReaderWriterRegistry *parentRegistry=0)
 
virtual ~DtVreSimComponent ()
 
bool isPlayerControlled (const std::string &role="") const
 
DtString entitySystemName () const
 

Static Public Member Functions

static DtSimComponent * creator (const DtString &name, DtLocalObject *owner, DtSimulationServices *simManager, DtComponentDescriptor *desc=0, DtReaderWriterRegistry *parentRegistry=0)
 

Protected Member Functions

virtual DtVector projectLandingLocation (DtSimObjectReference entity)
 
virtual void calcAndSetPortValues (const DtString &functionGroup, const DtString &function, double value, bool repeat) override
 
virtual void joystickConnected () override
 
virtual void joystickDisconnected () override
 
virtual void processParachuteTolocationTask (DtSimMessage *msg) override
 

Private Member Functions

 DtVreParachuteController ()
 
 DtVreParachuteController (const DtVreParachuteController &orig)
 
const DtVreParachuteControlleroperator= (const DtVreParachuteController &orig)
 

Constructor & Destructor Documentation

◆ DtVreParachuteController() [1/3]

makVre::DtVreParachuteController::DtVreParachuteController ( const DtString & name,
DtLocalObject * owner,
DtSimulationServices * simManager,
DtComponentDescriptor * desc = 0,
DtReaderWriterRegistry * parentRegistry = 0 )

Constructor.

Parameters
nameThe name of this component
ownerThe local object that owns this component
simManagerThe simulation services manager
descComponent descriptor with configuration parameters
parentRegistryOptional parent registry for reader/writer functionality

Creates a new parachute controller component with the specified parameters.

Referenced by DtVreParachuteController(), and operator=().

◆ ~DtVreParachuteController()

virtual makVre::DtVreParachuteController::~DtVreParachuteController ( )
overridevirtual

Virtual destructor.

Cleans up resources used by the parachute controller component. This is mostly a no-op as the component doesn't maintain many resources.

◆ DtVreParachuteController() [2/3]

makVre::DtVreParachuteController::DtVreParachuteController ( )
private

Default constructor (not implemented)

Default constructor is private and not implemented to prevent creation of instances without proper initialization.

◆ DtVreParachuteController() [3/3]

makVre::DtVreParachuteController::DtVreParachuteController ( const DtVreParachuteController & orig)
private

Copy constructor (not implemented)

Copy constructor is private and not implemented to prevent copy construction.

References DtVreParachuteController().

Member Function Documentation

◆ tick()

virtual void makVre::DtVreParachuteController::tick ( )
overridevirtual

Updates the controller state each simulation frame.

Handles CGF (Computer Generated Forces) control of steering and parachute deployment. For non-player entities, calculates the appropriate steering inputs to guide the entity toward its designated landing location.

◆ type()

virtual const char * makVre::DtVreParachuteController::type ( ) const
overridevirtual

Gets the type identifier for this component.

Returns
String identifying the component type (DtVreParachuteControllerType)

Implements the DtSimComponent::type() method to return the type identifier for this component.

◆ creator()

static DtSimComponent * makVre::DtVreParachuteController::creator ( const DtString & name,
DtLocalObject * owner,
DtSimulationServices * simManager,
DtComponentDescriptor * desc = 0,
DtReaderWriterRegistry * parentRegistry = 0 )
static

Factory method to create a new instance of this component.

Parameters
nameThe name for the new component
ownerThe local object that will own this component
simManagerThe simulation services manager
descOptional component descriptor
parentRegistryOptional parent registry for reader/writer functionality
Returns
Pointer to the newly created component

Static factory method used by the component creation system to instantiate new instances of this component type.

◆ projectLandingLocation()

virtual DtVector makVre::DtVreParachuteController::projectLandingLocation ( DtSimObjectReference entity)
protectedvirtual

Projects the expected landing location of an entity.

Parameters
entityReference to the entity to project landing location for
Returns
The projected landing location as a 3D vector

Calculates the expected landing location of a parachuting entity based on its current position, velocity, and environmental factors such as wind. This is used for both visualization and to guide autonomous entities toward their intended landing zones.

◆ calcAndSetPortValues()

virtual void makVre::DtVreParachuteController::calcAndSetPortValues ( const DtString & functionGroup,
const DtString & function,
double value,
bool repeat )
overrideprotectedvirtual

Processes joystick input and sets corresponding port values.

Parameters
functionGroupThe function group identifier for the input
functionThe specific function name for the input
valueThe input value (typically in range [-1.0, 1.0])
repeatFlag indicating whether the function should repeat

Handles joystick input by translating joystick function calls into appropriate parachute control values. Maps joystick axes and buttons to steering and deployment controls for the parachute.

◆ joystickConnected()

virtual void makVre::DtVreParachuteController::joystickConnected ( )
overrideprotectedvirtual

Handles joystick connection events.

Required by the DtJoystickControllerInterface, but currently a no-op. Called when a joystick is connected to the system.

◆ joystickDisconnected()

virtual void makVre::DtVreParachuteController::joystickDisconnected ( )
overrideprotectedvirtual

Handles joystick disconnection events.

Required by the DtJoystickControllerInterface, but currently a no-op. Called when a joystick is disconnected from the system.

◆ processParachuteTolocationTask()

virtual void makVre::DtVreParachuteController::processParachuteTolocationTask ( DtSimMessage * msg)
overrideprotectedvirtual

Processes parachute-to-location task messages.

Parameters
msgThe simulation message containing task parameters

Overridden to fix a task parameter name mismatch. The incorrect capitalization in the method name ("Tolocation" instead of "ToLocation") is maintained to match the base class implementation for compatibility purposes.

◆ operator=()

const DtVreParachuteController & makVre::DtVreParachuteController::operator= ( const DtVreParachuteController & orig)
private

Assignment operator (not implemented)

Returns
Reference to this object

Assignment operator is private and not implemented to prevent assignment.

References DtVreParachuteController().


The documentation for this class was generated from the following file: