Best Enhancement to DCS ever - Page 4 - ED Forums
 


Notices

Reply
 
Thread Tools Display Modes
Old 01-11-2019, 08:51 PM   #31
stuartaston
Member
 
stuartaston's Avatar
 
Join Date: Jan 2009
Location: UK
Posts: 213
Default

After some fiddling around I got to this TARGET script code for the warthog


Code:
MapKey(&Joystick, S1, CHAIN( EXEC("DXAxis(MOUSE_X_AXIS, -14100);" "DXAxis(MOUSE_Y_AXIS, 13000);"),PULSE+MOUSE_LEFT));
the X and Y axis numbers seem to work (though no idea why!) this maps the cursor to the centre of the screen and slightly below your line of sight (fiddle with it to get it right for you, YMMV
__________________


SYSTEM SPECS: Hardware Intel Corei5-6600K @ 4.50 GHz, 16Gb RAM, GeForce GTX1070Ti 8Gb, Dell S2716DG + Iiyama E2407 HDS, Thrustmaster Warthog + TrackIR 5 + TrackClipProSoftware Microsoft Windows 10 Pro x64
stuartaston is offline   Reply With Quote
Old 01-12-2019, 01:20 AM   #32
tdyrsmid
Junior Member
 
Join Date: Nov 2016
Posts: 18
Default

Could you explain how this script is used and how to implement it? Thanks!

Quote:
Originally Posted by lucky-hendrix View Post
I have this : a wireless mouse that has been fitted on a glove with 4switvh on the index . This is my vr "mouse" just need to look at the switch

Sent from my VTR-L09 using Tapatalk
Quote:
Originally Posted by stuartaston View Post
After some fiddling around I got to this TARGET script code for the warthog


Code:
MapKey(&Joystick, S1, CHAIN( EXEC("DXAxis(MOUSE_X_AXIS, -14100);" "DXAxis(MOUSE_Y_AXIS, 13000);"),PULSE+MOUSE_LEFT));
the X and Y axis numbers seem to work (though no idea why!) this maps the cursor to the centre of the screen and slightly below your line of sight (fiddle with it to get it right for you, YMMV
tdyrsmid is offline   Reply With Quote
Old 01-12-2019, 06:00 AM   #33
stuartaston
Member
 
stuartaston's Avatar
 
Join Date: Jan 2009
Location: UK
Posts: 213
Default

You have to have a Thrustmaster Joystick, such as the Warthog, and then use the scripting software TARGET that comes with it, this enables you to map buttons on your joystick, to either kepresees or logical buttons.

Then just add this line replacing, in my case the S1/Master Mode buttton, with the line above, you can use which ever button you like, using the appropriate identification number.

Then run the script... And as soon as you press the button, the mouse cursor appears in game at the specified co-ordinates.

I will post my scripts later today if that will help? This approach will only work with target.
__________________


SYSTEM SPECS: Hardware Intel Corei5-6600K @ 4.50 GHz, 16Gb RAM, GeForce GTX1070Ti 8Gb, Dell S2716DG + Iiyama E2407 HDS, Thrustmaster Warthog + TrackIR 5 + TrackClipProSoftware Microsoft Windows 10 Pro x64
stuartaston is offline   Reply With Quote
Old 01-12-2019, 09:07 AM   #34
stuartaston
Member
 
stuartaston's Avatar
 
Join Date: Jan 2009
Location: UK
Posts: 213
Default

There are three steps to this:

- place both the scripts unzipped into the scripts folder for TARGET (the first is targetdx128.tmh, which allows you to map 120 joystick buttons + one 8 way hat, this is not mine but is the work of Sedenion, and mine F18CBlock20 MkII.tmc, which is mine though derived from the work of many others @ReflexArc @Catseye)

- the first is to amend the script so that it matches your config (I use the coolie switch to use SHIFT CTRL F12 to center Track IR for example)

- the second is to run the script in target (you have to keep this running while the game is playing just minimise the window)

- the third and final step is to remap the joystick buttons to the new buttons generated from the combined Warthog Joystick


this means I can do things like have the EAC switch that works in both directions without having to modify the LUA code for example.
Attached Files
File Type: zip Warthog Joystick Scripts.zip (11.9 KB, 6 views)
__________________


SYSTEM SPECS: Hardware Intel Corei5-6600K @ 4.50 GHz, 16Gb RAM, GeForce GTX1070Ti 8Gb, Dell S2716DG + Iiyama E2407 HDS, Thrustmaster Warthog + TrackIR 5 + TrackClipProSoftware Microsoft Windows 10 Pro x64
stuartaston is offline   Reply With Quote
Old 01-12-2019, 09:27 AM   #35
majapahit
Senior Member
 
Join Date: Jul 2009
Posts: 1,058
Default

Quote:
Originally Posted by stuartaston View Post
targetdx128.tmh, which allows you to map 120 joystick buttons + one 8 way hat
you want to edit the code and add more DX so it can map 2 Hats of the HOTAS (1 on the throttle)
__________________
Autopilot panel | Headtracker | TM HOTAS | G920 HOTAS | Throttle Quadrants | 8600K | GTX 1080 | 16GB RAM| Win 10 x64 | Voicerecognition | 40" 1080p TV | 2x 24" 1080p side monitors | 24" 1080p touchscreen | VR googles
majapahit is offline   Reply With Quote
Old 01-12-2019, 09:44 AM   #36
stuartaston
Member
 
stuartaston's Avatar
 
Join Date: Jan 2009
Location: UK
Posts: 213
Default

targetdx isn't mine; but you essentially max out at 128 buttons either way... as I understand it, all DXHATUP is a proxy for another DX button? does re-mapping it as a hat provide any advantages?
__________________


SYSTEM SPECS: Hardware Intel Corei5-6600K @ 4.50 GHz, 16Gb RAM, GeForce GTX1070Ti 8Gb, Dell S2716DG + Iiyama E2407 HDS, Thrustmaster Warthog + TrackIR 5 + TrackClipProSoftware Microsoft Windows 10 Pro x64
stuartaston is offline   Reply With Quote
Old 01-12-2019, 10:01 AM   #37
majapahit
Senior Member
 
Join Date: Jul 2009
Posts: 1,058
Default

Quote:
Originally Posted by stuartaston View Post
targetdx isn't mine; but you essentially max out at 128 buttons either way... as I understand it, all DXHATUP is a proxy for another DX button? does re-mapping it as a hat provide any advantages?
Oh sorry, it appears you already cleaned up what you have. The original poster (loong time ago) had Coolie and Trim HAT combined
__________________
Autopilot panel | Headtracker | TM HOTAS | G920 HOTAS | Throttle Quadrants | 8600K | GTX 1080 | 16GB RAM| Win 10 x64 | Voicerecognition | 40" 1080p TV | 2x 24" 1080p side monitors | 24" 1080p touchscreen | VR googles
majapahit is offline   Reply With Quote
Old 01-12-2019, 10:04 AM   #38
stuartaston
Member
 
stuartaston's Avatar
 
Join Date: Jan 2009
Location: UK
Posts: 213
Default

ah no worries, I always try and debug "my code" I think pulled the later copy that someone on the same thread had already cleaned up
__________________


SYSTEM SPECS: Hardware Intel Corei5-6600K @ 4.50 GHz, 16Gb RAM, GeForce GTX1070Ti 8Gb, Dell S2716DG + Iiyama E2407 HDS, Thrustmaster Warthog + TrackIR 5 + TrackClipProSoftware Microsoft Windows 10 Pro x64
stuartaston is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT. The time now is 09:39 AM. vBulletin Skin by ForumMonkeys. Powered by vBulletin®.
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.