Extend DRE with VoiceAttack using DRE Lynx
DRE Lynx connects DRE to VoiceAttack. It lets a VoiceAttack profile invoke DRE actions, react to DRE events, and access selected DRE variables.
Lynx runs locally through a Windows named pipe. It does not open a network port and does not provide remote access between PCs.
Requirements
You need:
- DRE with a Performance subscription or higher
- VoiceAttack installed on the same Windows PC as DRE
- DRE Lynx installed through DRE Settings
DRE does not currently publish an exact minimum supported VoiceAttack version.
Install DRE Lynx
- Install VoiceAttack.
- Open DRE Settings and find the Lynx API settings.
- Install DRE Lynx.DRE copies the plugin into:
VoiceAttack\Apps\DRE.Lynx\ - Restart DRE and VoiceAttack.
- Import
DRE Lynx Example-Profile.vapinto VoiceAttack. - Enable the Lynx API in DRE Settings.
- Run the example
Connectcommand in VoiceAttack.
If needed, Lynx can start DRE using the StartDRE plugin context.
How VoiceAttack calls Lynx
Add an Execute an External Plugin Function action to a VoiceAttack command. Select DRE Lynx and set the plugin context for the operation you want to perform.
Available contexts include:
Connection
ConnectDisconnectStartDRE
DRE actions
GetAllActionsInvokeAction
DRE variables
GetAllVariablesGetVariableOnceEnableVariableDisableVariableSubscribeVariableUnsubscribeVariable
DRE events
GetAllEventsSubscribeEventUnsubscribeEvent
Use GetAllActions, GetAllVariables, and GetAllEvents to retrieve the identifiers available in your installed DRE version.
Invoke a DRE action
Use the InvokeAction context and set these VoiceAttack text variables:
action: the DRE action intentparameters: optional parameters, separated by semicolons
Use the action intent rather than one of DRE’s spoken phrases. Spoken phrases can change or be translated, while the intent is the stable action identifier.
Example: “Are we there yet?”
Create a VoiceAttack command with the spoken phrase:
Are we there yet?
Add an external plugin action with:
- Context:
InvokeAction action:TimeLeftparameters: leave empty
DRE will run its normal session-time-left action.
Example: ask for oil temperature every 20 seconds
Create an external plugin action with:
- Context:
InvokeAction action:PlayerOilTemperatureparameters: leave empty
Use VoiceAttack’s own repeating-command or scheduling features to run the command every 20 seconds. Lynx invokes the DRE action but does not provide the timer.
React to DRE events
Use SubscribeEvent with these VoiceAttack text variables:
event: the DRE event identifiercallback: the name of an existing VoiceAttack command
When the event occurs, Lynx runs the callback command.
Event arguments are passed through VoiceAttack variables such as:
~passedBoolean1~passedText1~passedInteger1~passedDecimal1~passedDate1
The numbering is separate for each value type.
Example: play sounds when entering or leaving the car
Subscribe to:
event:EnteredExitedCarcallback: the name of your VoiceAttack sound command
Inside the callback, inspect:
{BOOL:~passedBoolean1}
True: the player entered the carFalse: the player left the car
Use that value to select the appropriate sound.
Coordinate speech with other VoiceAttack plugins
DRE exposes the Boolean variable TTSSpeaking.
True: DRE is currently speakingFalse: DRE has finished speaking
DRE also exposes:
TTSSpeakingTimestampUTC: when the latest DRE speech startedTTSSpeakingEndTimestampUTC: when the latest DRE speech ended
A VoiceAttack profile or custom plugin can monitor TTSSpeaking and delay its own speech while DRE is talking. The end timestamp can be used if your speech coordinator needs a short delay after DRE finishes.
Lynx does not impose a coordination policy. Your VoiceAttack profile decides whether to wait, cancel, queue, or lower the priority of competing speech.
Access DRE variables
Lynx exposes Boolean, text, integer, decimal, date, and enum values.
VoiceAttack token formats include:
- Boolean:
{BOOL:name} - Text or enum:
{TXT:name} - Integer:
{INT:name} - Float or double:
{DEC:name} - Date and time:
{DATE:name}
Use the exact variable identifier and casing returned by GetAllVariables.
A subscription sends the current value and then sends updates when the value changes.
Example: write current weather values to the VoiceAttack log
Enable or subscribe to these variables:
CurrentTrackTempCrewFloatCurrentWindStrengthFloatWeatherAirTempCurrent
Then use:
{DEC:CurrentTrackTempCrewFloat}
{DEC:CurrentWindStrengthFloat}
{TXT:WeatherAirTempCurrent}
Migrating from DRE 3
DRE can import much of your DRE 3 configuration, including keybinds and several DRE configuration files. The importer may overwrite existing DRE settings, so back up your current configuration first.
VoiceAttack profiles and custom plugins are separate from the DRE configuration importer. They are not migrated automatically.
A practical migration process is:
- Keep a backup of your existing VoiceAttack profile and custom plugins.
- Import your DRE 3 configuration into DRE.
- Install DRE Lynx through DRE.
- Import the DRE Lynx example profile.
- Test
Connect, one action, and one event. - Replace old DRE 3 integrations one command at a time.
- Map old spoken commands to DRE action intents.
- Replace old callbacks with Lynx event subscriptions.
- Update custom speech coordination to monitor
TTSSpeaking. - Keep your original profile available until every required integration has been tested.
Existing VoiceAttack command phrases can usually remain unchanged. Change the actions behind those phrases to call Lynx.
Current limitations
- Lynx connects DRE and VoiceAttack on the same Windows PC.
- It does not provide remote communication between two PCs.
- DRE does not currently publish an exact VoiceAttack compatibility range.
- VoiceAttack scheduling, sound playback, command queues, and speech-priority rules remain the responsibility of your VoiceAttack profile.
- DRE 3 VoiceAttack profiles and custom plugins are not converted automatically.
- Do not use DRE’s internal
/inputbridge. It is a development feature, not the supported Lynx action interface.
Validate your setup
Before adapting a large profile:
- Connect VoiceAttack to DRE with
Connect. - Run
GetAllActions,GetAllVariables, andGetAllEvents. - Invoke
TimeLeft. - Subscribe to
EnteredExitedCarand test entering and leaving the car. - Monitor
TTSSpeakingwhile DRE speaks. - Confirm every variable required by your profile updates correctly.
Once these checks pass, migrate the rest of your VoiceAttack commands in small groups.