Hi all,
This is a TARGET Script tutorial.
Target Script requires Thrustmaster joystick/s or HOTAS hardware.
Saying that the theory can be applied to other scripting tools like Joystick Gremlin etc.
I've read a few forum threads over the last couple years about how hard TARGET Script is to either learn or get working.
Yes...it is not an easy thing and does require some time to get even moderately good at.
The manual is pretty basic, and finding good scripts to learn from is not that easy.
Additionally, you need a basic understanding of programming...which does not come naturally to a lot of people.
But why on Earth would anyone want to even look at scripting for a Joystick?
The most common answer invariably comes when people start to dip their feet into the PvP pond...PIP Management and Joystick Curves.
So, what I've done is create a TARGET script which does that...and pretty much only that.
Now, a lot of people use other tools for these or other joysticks (eg Auto Hot Key, vJoy and Joystick Gremlin are the ones which come readily to mind), this post is not about what's best, easiest, cheapest etc...it's simply a post providing a TARGET script to help people who don't want to invest time learning TARGET script.
(and I don't blame them!)
The attached zip file contains;
The script itself ("EDScript.tmc")
A separate TARGET support file containing some variable definitions that the script uses ("EDGlobalVars.tmh")
A sample windows batch file which will launch the script ("sample.bat")
And a "readme.txt" file.
The script and support files do have some comments in to help people understand what the script is doing and the readme.txt explains a lot more about curves as well as a mini-tutorial on how to modify the script to suit any Thrustmaster joystick that is supported by the TARGET script engine. These include the T16000, T16000L, Cougar, Warthog and the F18 Joystick (not yet released as far as I know).
So, if you have one of these, read on.
While the script was written and tested on a Warthog HOTAS joystick, I've provided instructions on how to modify it for a different stick (T16000) in the readme.txt file.
WARNING!
You need to run the script before you start ED ... AND ...
Running this script the first time will mess with your binds file so back it up BEFORE you run the game with the script running.
I would fully recommend you take note of what keys you bound for each function because there's a good chance you will need to redo some if not most of them.
Here's why...
When you run the script, the TARGET interpreter (the thing that reads, compiles and runs the script) will create a new (emulated) game controller device in windows and any supported Thrustmaster devices which are enabled within the script will disappear from your Joystick control panel and be replaced with one called "Thrustmaster Combined". This is important...read that last sentence again slowly and carefully.
My script ONLY enables the joystick. So if you own a WARTHOG HOTAS, it leaves the Throttle alone.
On my PC, the "Joystick - HOTAS Warthog" will disappear and be replaced by "Thrustmaster Combined".
Of course, once the script is stopped, everything reverts to how it was.
Next, my script uses the following keys and expects these to be set in the Elite Dangerous control bindings.
Z - for FAOff
The four Arrow keys - for PIP Management.
That's it.
If you normally use something different, no sweat, just get into the EDGlobalVars.tmh file and change lines 14-19 to whatever you want.
I've included at the bottom of the EDGlobalVars file the USB Code table (from the manual) which lists every keyboard key that TARGET will recognize.
What does the script do exactly?
1) It uses one of the HAT switches (the DMS or "H3" hat) on the joystick to do PIP Management
a) when you press H3R (H3-Right) once, it fires a sequence of arrow keys which result in a [0, 2, 4] configuration
b) pressing H3L (left) results in [4, 2, 0]
c) pressing H3U (up) results in [0, 4, 2]
d) pressing H3D (down) does the default balance power [2, 2, 2]
The script makes it dead easy for you to configure these any which way you want to distribute the 6 PIPs and includes more in depth explanation in the comments.
Without too much drama, you can use a different HAT if you are already used to using one of the others. These are typically listed in one of the user guides provided by Thrustmaster for your joystick.
If you happen to own a WARTHOG, the other HAT switches are also listed in the table in the EDGlobalVars file.
2) It uses the pinky lever switch on my joystick (S4) to toggle FAOff + apply a joystick curve to the X and Y axis.
In Elite Dangerous Control Binds, set the Flight Assist key ('Z') to TOGGLE.....NOT HOLD
If you'd rather, you can "MapKey" any other button on your joystick to turn the curves ON and OFF at any time.
I can help with this if you can't work it out.
Ok, final stretch...
I would recommend you extract the files from the zip into their own folder on your C: drive.
The sample.bat file uses C:\TargetScripts ... which is as good a folder name as any.
If you decide on sticking these somewhere else and want to use the sample.bat file, just change the path in the bat file to point to where ever you saved the files.
If you encounter any issues either reply to this thread or PM me and I'll do my best to assist.
Cheers
Clicker
This is a TARGET Script tutorial.
Target Script requires Thrustmaster joystick/s or HOTAS hardware.
Saying that the theory can be applied to other scripting tools like Joystick Gremlin etc.
I've read a few forum threads over the last couple years about how hard TARGET Script is to either learn or get working.
Yes...it is not an easy thing and does require some time to get even moderately good at.
The manual is pretty basic, and finding good scripts to learn from is not that easy.
Additionally, you need a basic understanding of programming...which does not come naturally to a lot of people.
But why on Earth would anyone want to even look at scripting for a Joystick?
The most common answer invariably comes when people start to dip their feet into the PvP pond...PIP Management and Joystick Curves.
So, what I've done is create a TARGET script which does that...and pretty much only that.
Now, a lot of people use other tools for these or other joysticks (eg Auto Hot Key, vJoy and Joystick Gremlin are the ones which come readily to mind), this post is not about what's best, easiest, cheapest etc...it's simply a post providing a TARGET script to help people who don't want to invest time learning TARGET script.
(and I don't blame them!)
The attached zip file contains;
The script itself ("EDScript.tmc")
A separate TARGET support file containing some variable definitions that the script uses ("EDGlobalVars.tmh")
A sample windows batch file which will launch the script ("sample.bat")
And a "readme.txt" file.
The script and support files do have some comments in to help people understand what the script is doing and the readme.txt explains a lot more about curves as well as a mini-tutorial on how to modify the script to suit any Thrustmaster joystick that is supported by the TARGET script engine. These include the T16000, T16000L, Cougar, Warthog and the F18 Joystick (not yet released as far as I know).
So, if you have one of these, read on.
While the script was written and tested on a Warthog HOTAS joystick, I've provided instructions on how to modify it for a different stick (T16000) in the readme.txt file.
WARNING!
You need to run the script before you start ED ... AND ...
Running this script the first time will mess with your binds file so back it up BEFORE you run the game with the script running.
I would fully recommend you take note of what keys you bound for each function because there's a good chance you will need to redo some if not most of them.
Here's why...
When you run the script, the TARGET interpreter (the thing that reads, compiles and runs the script) will create a new (emulated) game controller device in windows and any supported Thrustmaster devices which are enabled within the script will disappear from your Joystick control panel and be replaced with one called "Thrustmaster Combined". This is important...read that last sentence again slowly and carefully.
My script ONLY enables the joystick. So if you own a WARTHOG HOTAS, it leaves the Throttle alone.
On my PC, the "Joystick - HOTAS Warthog" will disappear and be replaced by "Thrustmaster Combined".
Of course, once the script is stopped, everything reverts to how it was.
Next, my script uses the following keys and expects these to be set in the Elite Dangerous control bindings.
Z - for FAOff
The four Arrow keys - for PIP Management.
That's it.
If you normally use something different, no sweat, just get into the EDGlobalVars.tmh file and change lines 14-19 to whatever you want.
I've included at the bottom of the EDGlobalVars file the USB Code table (from the manual) which lists every keyboard key that TARGET will recognize.
What does the script do exactly?
1) It uses one of the HAT switches (the DMS or "H3" hat) on the joystick to do PIP Management
a) when you press H3R (H3-Right) once, it fires a sequence of arrow keys which result in a [0, 2, 4] configuration
b) pressing H3L (left) results in [4, 2, 0]
c) pressing H3U (up) results in [0, 4, 2]
d) pressing H3D (down) does the default balance power [2, 2, 2]
The script makes it dead easy for you to configure these any which way you want to distribute the 6 PIPs and includes more in depth explanation in the comments.
Without too much drama, you can use a different HAT if you are already used to using one of the others. These are typically listed in one of the user guides provided by Thrustmaster for your joystick.
If you happen to own a WARTHOG, the other HAT switches are also listed in the table in the EDGlobalVars file.
2) It uses the pinky lever switch on my joystick (S4) to toggle FAOff + apply a joystick curve to the X and Y axis.
In Elite Dangerous Control Binds, set the Flight Assist key ('Z') to TOGGLE.....NOT HOLD
If you'd rather, you can "MapKey" any other button on your joystick to turn the curves ON and OFF at any time.
I can help with this if you can't work it out.
Ok, final stretch...
I would recommend you extract the files from the zip into their own folder on your C: drive.
The sample.bat file uses C:\TargetScripts ... which is as good a folder name as any.
If you decide on sticking these somewhere else and want to use the sample.bat file, just change the path in the bat file to point to where ever you saved the files.
If you encounter any issues either reply to this thread or PM me and I'll do my best to assist.
Cheers
Clicker
Attachments
Last edited: