[TC] Gaming Forums
Scripting - Automatic shifting configuration. - Printable Version

+- [TC] Gaming Forums (https://forum.city-driving.co.uk)
+-- Forum: General Information (/forumdisplay.php?fid=1)
+--- Forum: General Discussions (/forumdisplay.php?fid=4)
+---- Forum: Tutorials & Guides (/forumdisplay.php?fid=48)
+---- Thread: Scripting - Automatic shifting configuration. (/showthread.php?tid=2697)



Scripting - Automatic shifting configuration. - McGherkin - 2012-04-05 22:59

Alright, I thought I'd share the scripts I came up with to switch between paddles and gearstick for shifting. This works best on DFP and DFGT, as they have sequential shifters. I haven't tried with G25/7 but I think it might be possible.

What these scripts do is set up the wheel according to the type of car you're driving. If the car has a paddleshift gearbox (and sequential in my case), then you use the paddles on the back of the wheel to change gear. If it has a standard H-box, you use the stick to shift. The wheel sets itself automatically when you enter the track and displays a message to tell you what method is in action. (SHIFT USING PADDLES or SHIFT USING STICK)


I also set up a button which overrides the setting so you can use the paddles in a normal car if you so wish.

This is a relatively simple set of scripts to set up. Make two scripts, called paddleswap.lfs and stickswap.lfs in LFS>data>script. (text documents, but make sure that the .txt is changed to .lfs)

Paste the following into each.

paddleswap.lfs
Code:
/button 4 shift_up
/button 5 shift_down
/button 13 clutch
/button 12 handbrake

/echo ^1SHIFT USING ^3PADDLES

/ctrlf 2 /run stickswap

stickswap.lfs
Code:
/button 12 shift_up
/button 13 shift_down
/button 5 clutch
/button 4 handbrake

/echo ^1SHIFT USING ^3STICK

/ctrlf 2 /run paddleswap

Replace the following with your desired values.
12 > Whichever button number your right paddle is
13 > Whichever button number your left paddle is
5 > Whichever button number shift down (push away) on the stick is
4 > Whichever button number shift up (pull towards) on the stick is
ctrlf 4 > whichever assignment you've set in LFS to toggle between stick and paddles. Choice of altf 1-12 or ctrlf 1-12.
clutch and handbrake > you can set this to whatever you like really. It's what you will have assigned to the paddles when using the stick to shift and vice versa.

Now go into the following three scripts and insert the line shown.
road.lfs > /run stickswap
sequential.lfs > /run paddleswap (you can put stickswap if you want to use the stick for these cars.)
paddle.lfs > /run paddleswap

Now go into LFS>Options>Controls and find the ctrlf or altf function you placed in the script and set it to: /run paddleswap. Also assign the wheel button you want to use to toggle between modes to this function.


Done! You should now be able to use the paddles on cars such as the XFR and MRT and stick on cars such as the UF1 and FXO.


By the way, if the manual toggle button only works once or not at all, check that the right ctrlf or altf value is in both paddleshift and stickshift scripts.

If a button works in stick mode but not in paddle mode (or vice versa), check what buttons you assigned to that function in each script.

PM me if you have any problems, enjoy.