The DtBullseyeController provides functionality for selecting, tracking, and reporting bullseye reference points in tactical simulations. It handles user selection of bullseye targets and communicates position updates to other simulation components.
#include <bullseyeController.h>
|
| static DtSimComponent * | creator (const DtString &name, DtLocalObject *owner, DtSimulationServices *simManager, DtComponentDescriptor *desc=0, DtReaderWriterRegistry *parentRegistry=0) |
| |
◆ DtBullseyeController() [1/3]
| makVre::DtBullseyeController::DtBullseyeController |
( |
| ) |
|
|
private |
Default constructor (not implemented)
Default constructor is private and not implemented to prevent creation of instances without proper initialization.
Referenced by DtBullseyeController(), and operator=().
◆ DtBullseyeController() [2/3]
Copy constructor (not implemented)
Copy constructor is private and not implemented to prevent copy construction.
References DtBullseyeController().
◆ DtBullseyeController() [3/3]
| makVre::DtBullseyeController::DtBullseyeController |
( |
const DtString & | name, |
|
|
DtLocalObject * | owner, |
|
|
DtSimulationServices * | simManager, |
|
|
DtComponentDescriptor * | desc = 0, |
|
|
DtReaderWriterRegistry * | parentRegistry = 0 ) |
Constructor.
- Parameters
-
| name | The name of this component |
| owner | The local object that owns this component |
| simManager | The simulation services manager |
| desc | Optional component descriptor |
| parentRegistry | Optional parent registry for reader/writer functionality |
Creates a new bullseye controller component with the specified parameters.
◆ ~DtBullseyeController()
| virtual makVre::DtBullseyeController::~DtBullseyeController |
( |
| ) |
|
|
overridevirtual |
Virtual destructor.
Cleans up resources used by the bullseye controller component.
◆ operator=()
Assignment operator (not implemented)
- Returns
- Reference to this object
Assignment operator is private and not implemented to prevent assignment.
References DtBullseyeController().
◆ type()
| virtual const char * makVre::DtBullseyeController::type |
( |
| ) |
const |
|
overridevirtual |
Gets the type identifier for this component.
- Returns
- String identifying the component type (DtBullseyeControllerType)
Implements the DtSimComponent::type() method to return the type identifier for this component.
◆ init()
| virtual bool makVre::DtBullseyeController::init |
( |
| ) |
|
|
overridevirtual |
Initializes the component.
- Returns
- True if initialization is successful, false otherwise
Registers message handlers for bullseye-related messages, particularly vrfSetBullseyeIdMessage which is sent by pilotSimLogic.
◆ creator()
| static DtSimComponent * makVre::DtBullseyeController::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
-
| name | The name for the new component |
| owner | The local object that will own this component |
| simManager | The simulation services manager |
| desc | Optional component descriptor |
| parentRegistry | Optional 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.
◆ createPSR()
| virtual DtBullseyePSR * makVre::DtBullseyeController::createPSR |
( |
| ) |
|
|
virtual |
Creates the process state repository for this component.
- Returns
- Pointer to the newly created bullseye process state repository
Creates the myProcessState data member and adds it to the process state repository manager. Passes the name and type specified in the component descriptor (if they exist) to the DtVrfProcessStateRepository::createRepository factory method. If name and/or type are not specified, uses the appropriate default strings defined in procSRTypes.h.
◆ processSetLocationComplete()
| void makVre::DtBullseyeController::processSetLocationComplete |
( |
const DtLocalObject * | obj | ) |
|
Updates bullseye status when the target entity's location changes.
- Parameters
-
| obj | Pointer to the local object that has changed location |
Called when the bullseye target entity's location is updated. Updates the stored bullseye world position and sends status updates.
◆ processSimObjectAdded()
| void makVre::DtBullseyeController::processSimObjectAdded |
( |
const DtLocalObject * | obj | ) |
|
Handles simulation object addition events.
- Parameters
-
| obj | Pointer to the newly added local object |
Handles the case where a VRF scenario reloads. VR Engage will reset the bullseye target according to the saved bullseyeID when the target object is added to the simulation.
◆ processSimObjectToBeRemoved()
| void makVre::DtBullseyeController::processSimObjectToBeRemoved |
( |
const DtLocalObject * | obj | ) |
|
Handles simulation object removal events.
- Parameters
-
| obj | Pointer to the local object being removed |
Removes all callbacks related to the bullseye object when it's about to be removed from the simulation.
◆ handleSetBullseyeId()
Handles bullseye target selection messages.
- Parameters
-
- Returns
- Message processing result
Processes SetBullseyeIdMessage sent from the user interface and updates the current bullseye object based on the selected entity ID.
◆ handleBullseyeStatusRequest()
◆ sendBullseyeStatusUpdate()
| virtual void makVre::DtBullseyeController::sendBullseyeStatusUpdate |
( |
| ) |
|
|
protectedvirtual |
Sends bullseye status update to interested components.
Sends a BullseyeStatusUpdateMessage to the controlling entity with the selected bullseye's geocentric world location. Used to update HUD displays and other tactical information systems.
◆ setNewBullseye()
| virtual void makVre::DtBullseyeController::setNewBullseye |
( |
DtSimObjectReference | obj | ) |
|
|
protectedvirtual |
Sets a new bullseye target.
- Parameters
-
| obj | Reference to the simulation object to use as the bullseye target |
Updates the current bullseye object, stores its location, and sends a bullseye status update to all interested components.
◆ preFirstTickInit()
| virtual void makVre::DtBullseyeController::preFirstTickInit |
( |
| ) |
|
|
overrideprotectedvirtual |
Performs initialization before the first tick.
Sets up initial state and connections needed before the first simulation tick is processed.
◆ tick()
| virtual void makVre::DtBullseyeController::tick |
( |
| ) |
|
|
overrideprotectedvirtual |
Updates the controller state each simulation frame.
Performs periodic updates and processing during each simulation cycle.
◆ defaultPSRType()
| const char * makVre::DtBullseyeController::defaultPSRType |
( |
| ) |
const |
|
protected |
Gets the default process state repository type.
- Returns
- String identifying the default PSR type (DtBullseyePSRType)
Returns the default process state repository type for this component.
◆ myBullseyeIsValid
| bool makVre::DtBullseyeController::myBullseyeIsValid |
|
protected |
Flag indicating if the bullseye reference is currently valid.
◆ myLastBullseyeWorldPosition
| DtVector makVre::DtBullseyeController::myLastBullseyeWorldPosition |
|
protected |
Last known geocentric position of the bullseye target.
◆ myProcessState
Pointer to the bullseye process state repository.
The documentation for this class was generated from the following file: