Profile image

Two examples of FT transmissions

6,220 11qazxc  2.5 years ago

There's two sets of setters (for manual transmission and transmission with paddle-shifters) and few notes on how to make it work like automatic one.
I hope it will work, and i hope nobody need it.
If you don't know how to set variables and what is activator, you can read this guide, maybe it will help you: https://snowflake0s.github.io/funkyguide/ #Link was changed to snow's guide because original one died. Don't die, github!


.
These two setters will increment or decrement SelectedGear if Activate1 or Activate2 is switched. You will need it only for transmission with paddle shifters. (i.e. switching AG1 will select previous gear, and switching AG2 will select next gear)
Here A is number of forward gears, and B is number of reverse gears.
SelectedGear=clamp(SelectedGear+1,-B,A-1) activator=(abs(rate(Activate2))>0)
SelectedGear=clamp(SelectedGear-1,-B,A-1) activator=(abs(rate(Activate1))>0)
.
.
These setters will set transmissionGearRatio based on selected gear. Values here is how much RPM will engine shaft have if wheel will be moved with speed of 1 meter per second, i.e. it isn't only gear ratio, but also depends on wheel diameter, differential etc.. For these examples values is taken from M10A1 GMC.
.
for manual transmission, you can use combination of AGs or position of VTOL as activator
transmissionGearRatio=1/-17.6546/0.0000510696*1.55 activator=Activate1&Activate2&Activate3
transmissionGearRatio=1/13.19426/0.0000510696*1.55 activator=!Activate1&!Activate2&Activate3
transmissionGearRatio=1/32.0735/0.0000510696*1.55 activator=!Activate1&Activate2&!Activate3
transmissionGearRatio=1/56.0386/0.0000510696*1.55 activator=!Activate1&Activate2&Activate3
transmissionGearRatio=1/89.8636/0.0000510696*1.55 activator=Activate1&!Activate2&!Activate3
transmissionGearRatio=1/136.642/0.0000510696*1.55 activator=Activate1&!Activate2&Activate3
.
for transmission with paddle shifters you can use contents of SelectedGear variable that was showed upper
transmissionGearRatio=1/-17.6546/0.0000510696*1.55 activator=(SelectedGear=-1)
transmissionGearRatio=1/13.19426/0.0000510696*1.55 activator=(SelectedGear=0)
transmissionGearRatio=1/32.0735/0.0000510696*1.55 activator=(SelectedGear=1)
transmissionGearRatio=1/56.0386/0.0000510696*1.55 activator=(SelectedGear=2)
transmissionGearRatio=1/89.8636/0.0000510696*1.55 activator=(SelectedGear=3)
transmissionGearRatio=1/136.642/0.0000510696*1.55 activator=(SelectedGear=4)
.
for automatic transmission you can use comparsion between GS and constants as activator, like ((GS*sign(sin(AngleOfSlip)))>0)&((GS*sign(sin(AngleOfSlip)))<1.2172)
.
.
If transmissionGearRatio will be multiplied by speed we will get RPM of engine shaft. But GS is unsigned, so we need to multiply it by sign(cos(AngleOfSlip)).
But real-life engine will be synchronized with wheels only if clutch is engaged. If clutch isn't engaged, engine must have idle RPM.
Here C is input that engages clutch, D is idle RPM of engine, and E is how many RPMs engine can get or lost per second.
For clutch of automatic transmission or transmission with paddle shifters you can use same input as throttle
transmissionEngineRPM=smooth((C)?(sign(cos(AngleOfSlip))*GS*transmissionGearRatio):D,E)
.
.
And finally, RPM and throttle level is used to get output power of engine.
Basically it's Power VS PRM curve of engine multiplied by throttle.
(in this example it's attempt to get imitation of Ford GAA)
transmissionEnginePower=((sin(transmissionEngineRPM/23.8-29)*525-(sin(transmissionEngineRPM/8+180)*35)+10)*max(sign(sin(transmissionEngineRPM/12.8-39)),0))*Throttle
This variable can be used as input of engine, but don't forget to divide it by power of engine part.