Jump to content

How to set up toggle switches (a tutorial)


Recommended Posts

I have checked the bindings and they are all there. But you seem to be mixing things up. There are two possibilities:

1. You use the UP and DOWN commands to move the switch through its 3 positions. I tried this with the bindings shown in the attachmant and it works just fine.

2. You use the 3 commands to set the absolute switch positions Att, Alt and Off.

Do not make a mix of the 2 methods! There is no need to modify .lua files.

 

Hey LeCuvier. Thanks very much for the guides. I'm doing the best I can to edit the my F18C's 'default.lua' as you instruct, but the new command doesn't show in game. Here's what I have:

 

-- Master Arm Panel
{	down = SMS_commands.AA_MasterModeSw,	up = SMS_commands.AA_MasterModeSw,	cockpit_device_id = devices.SMS,	value_down =  1.0,	value_up = 0.0,	name = _('Master Mode Button - A/A'),		category = {_('Instrument Panel'), _('Master Arm Panel')}},
{	down = SMS_commands.AG_MasterModeSw,	up = SMS_commands.AG_MasterModeSw,	cockpit_device_id = devices.SMS,	value_down =  1.0,	value_up = 0.0,	name = _('Master Mode Button - A/G'),		category = {_('Instrument Panel'), _('Master Arm Panel')}},
{	down = SMS_commands.MasterArmSw_EXT,										cockpit_device_id = devices.SMS,	value_down =  1.0,					name = _('Master Arm Switch - ARM/SAFE'),	category = {_('Instrument Panel'), _('Master Arm Panel')}},
{	down = SMS_commands.MasterArmSw,											cockpit_device_id = devices.SMS,	value_down =  1.0,					name = _('Master Arm Switch - ARM'),		category = {_('Instrument Panel'), _('Master Arm Panel')}},
{	down = SMS_commands.MasterArmSw,											cockpit_device_id = devices.SMS,	value_down =  0.0,					name = _('Master Arm Switch - SAFE'),		category = {_('Instrument Panel'), _('Master Arm Panel')}},
{	down = SMS_commands.MasterArmSw, 		up = SMS_commands.MasterArmSw,		cockpit_device_id = devices.SMS,	value_down =  1.0,	value_up = 0.0	name = _('Steve Arm'),						category = {_('Instrument Panel'), _('Master Arm Panel')}},

 

What I'm trying to do is add an on/off for the master arm switch. Any ideas what I'm doing wrong?

 

Thanks!

Link to comment
Share on other sites

LeCuvier. I know the key strokes work in the setup window. But that doesn't transfer to the pit. I think the default.lua is set up to use key binds or a direct x hardware. The X Keys is not direct x....it just sends the key strokes.

 

 

I also know it doesn't make sense to me! If DCS is getting a key stroke why not use it right? I flip the switch it shows in the setup window. I turn off the switch and the other keystroke lights up in the setup window. But get in the pit and nothing happens! :(

 

 

I never tried this until now. While in the pit and the switch not working I pressed the u on the key board and the switch flips up. As well as the other keys.

 

So to recap.

 

1)the X Keys sends the key.

2)DCS gets the key stroke from X Keys verified in the setup window

3a)Go into the sim toggle on X Keys moved to up position. Nothing happens

b)Move toggle with mouse to up position and then do the same on the X Key toggle and then return it to off position. The switch in game moves to off position.

c)after putting in your two lines I am able to use a switch as normal on Warthog of course.

4)Your switch code is greyed out in the keyboard column so I can't add a key to it.

 

 

Prior to last update I was able to add the key to my hacked switch code and it worked.

 

 

 

 

Menessis

 

 

PS Did you ever think that looking at all our key profiles would be your full time job? 71 pages so far!


Edited by Menessis
Link to comment
Share on other sites

@Menessis:

 

1. I tested the key strokes "u" and "v" (from my keyboard of course) in a mission and they work. I suspect your problem originates in your X-Key set-up, or X-key does not send the correct sequences..

2. If you want to bind my code to keyboard strokes you have to add it into the "default.lua" under "...\Eagle Dynamics\DCS World OpenBeta\Mods\aircraft\F-16C\Input\F-16C\keyboard". All commands that are to be bound to keyboard strokes must be defined in the "default.lua" in the folder "...\keyboard", and all commands to be bound to game controller buttons must be defined in the one under "...\joystick".

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Link to comment
Share on other sites

Thanks LeCuvier. Seems kinda like command sense!

 

 

The thing is DCS sees the keystrokes from the X Keys

 

 

Menessis

Yes that's weird, but I've seen it before. You may want to delete the entire folder structure "...\Saved Games\DCS.openbeta\Config\Input\F-16C_50" and redo your bindings from scratch.

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Link to comment
Share on other sites

I want to add some F/A-18C stuff (like Gear, Fuel Probe etc.) to the switches on my Warthog Throttle. The guide on the first page is a little bit outdated. And reading 71(!) pages isn't really efficient.

 

 

Can someone point me to a actual good guide how to do this?

SYSTEM: Mainboard MSI MEG X570 | CPU Ryzen 7 5800X @ 4.5 GHz | RAM 64 GB @ 3200 MHz | GPU GIGABYTE RTX 4090 | 1 TB SSD | Win 10 x64

DEVICES: ASUS 27" LCD | TrackIR 5 | LukeClip | Quest 3 | PointCTRL | Virpil HOTAS | MFG Crosswind | TableMount MonsterTech

MODULES: To much to list. But I stopped buying more, because of too much bugs in e.g. A-10C(II). @ED: Fix the bugs and I spend money on modules again. Promised.

PROJECTS: OpenFlightSchool: DE / EN

Link to comment
Share on other sites

I want to add some F/A-18C stuff (like Gear, Fuel Probe etc.) to the switches on my Warthog Throttle. The guide on the first page is a little bit outdated. And reading 71(!) pages isn't really efficient.

 

 

Can someone point me to a actual good guide how to do this?

I posted a tutorial under post #214. Here is some stuff I added to my "default.lua" for the Hornet. It includes some commands I made for others.

{down = SMS_commands.MasterArmSw, up = SMS_commands.MasterArmSw, cockpit_device_id = devices.SMS, value_down =  1.0, value_up = 0.0, name = _('Master Arm Switch 2-Pos ARM/SAFE'), category = {_('Instrument Panel'), _('Master Arm Panel')}},
{down = hotas_commands.THROTTLE_EXTERIOR_LIGTHS, up = hotas_commands.THROTTLE_EXTERIOR_LIGTHS,    cockpit_device_id = devices.HOTAS,    value_down =  1.0, value_up = 0.0,    name = _('Exterior Lights 2-Pos ONOFF'), category = {_('Throttle Grip'), _('HOTAS')}},
{down = iCommandPlaneGearUp, up = iCommandPlaneGearDown, name = _('Landing Gear Control Handle 2-Pos UP/DOWN'),    category = {_('Left Vertical Panel')}},
{down = gear_commands.HookHandle, up = gear_commands.HookHandle, cockpit_device_id = devices.GEAR_INTERFACE, value_down =  1.0, value_up =  0.0, name = _('Arresting Hook Handle 2-Pos UP/DOWN'), category = {_('Right Vertical Panel')}},
{down = HUD_commands.HUD_AltitudeSw, up = HUD_commands.HUD_AltitudeSw, cockpit_device_id = devices.HUD,    value_down =  1.0, value_up =  0.0, name = _('Altitude Switch 2-Pos BARO/RADAR'), category = {_('Instrument Panel'), _('HUD Control Panel')}},
{down = cpt_commands.CanopySwitchClose, up = cpt_commands.CanopySwitchOpen, cockpit_device_id = devices.CPT_MECHANICS, value_down =  -1.0, value_up = 1.0, name = _('Canopy Control Switch 2-Pos OPEN/CLOSE'), category = {_('Right Wall'), _('Systems')}},
{down = oxygen_commands.OBOGS_ControlSw, up = oxygen_commands.OBOGS_ControlSw, cockpit_device_id = devices.OXYGEN_INTERFACE, value_down =  1.0,    value_up = 0.0,    name = _('OBOGS Control Switch 2-Pos ON/OFF'), category = {_('Left Console')}},
{down = cptlights_commands.HookBypass, up = cptlights_commands.HookBypass,    cockpit_device_id = devices.CPT_LIGTHS,    value_down =  -1.0,    value_up = 1.0,    name = _('Hook Bypass 2-Pos Switch FIELD/CARRIER'), category = {_('Left Vertical Panel')}},
{down = gear_commands.LaunchBarSw, up = gear_commands.LaunchBarSw, cockpit_device_id = devices.GEAR_INTERFACE, value_down =  -1.0, value_up = 1.0,    name = _('Launch Bar Control 2-Pos Switch RETRACT/EXTEND'), category = {_('Left Vertical Panel')}},
{down = extlights_commands.LdgTaxi,    up = extlights_commands.LdgTaxi, cockpit_device_id = devices.EXT_LIGHTS, value_down =  1.0,    value_up =  0.0, name = _('LDG/TAXI LIGHT Switch 2-Pos ON/OFF'), category = {_('Left Vertical Panel')}},
{down = ctrl_commands.WingFoldPull, pressed  = ctrl_commands.WingFoldSelect, cockpit_device_id = devices.CONTROL_INTERFACE, value_down = 1.0, value_pressed = -1.0, name = _('Wing Fold Control PULL-FOLD'), category = {_('Right Vertical Panel')}},
{down = ctrl_commands.WingFoldSelect, up  = ctrl_commands.WingFoldPull, cockpit_device_id = devices.CONTROL_INTERFACE, value_down = 1.0, value_up = 0.0, name = _('Wing Fold Control SPREAD-STOW'), category = {_('Right Vertical Panel')}},
{down = fuel_commands.DumpSw, up = fuel_commands.DumpSw, cockpit_device_id = devices.FUEL_INTERFACE, value_down =  1.0, value_up = -1.0, name = _('Fuel Dump Switch 2-Pos ON/OFF'), category = {_('Left Console'), _('Fuel Control Panel')}},
{down = fuel_commands.DumpSw, cockpit_device_id = devices.FUEL_INTERFACE, value_down =  1.0, name = _('Fuel Dump Switch ON'), category = {_('Left Console'), _('Fuel Control Panel')}},
{down = fuel_commands.DumpSw, cockpit_device_id = devices.FUEL_INTERFACE, value_down =  -1.0, name = _('Fuel Dump Switch OFF'), category = {_('Left Console'), _('Fuel Control Panel')}},
{down = 3256, up = 3256, cockpit_device_id = 0,    value_down =  -1.0,    value_up =  0.0, name = _('Flashlight 2-Pos ON/OFF'), category = {_('View Cockpit'), _('Right Console')}},
{down = iCommandPlaneShowKneeboard,    up = iCommandPlaneShowKneeboard, value_down = 1.0, value_up = -1.0,    name = _('Kneeboard 2-Pos SHOW/HIDE'), category = _('Kneeboard')},
{down=gear_commands.EmergParkHandleSelectPark, up=gear_commands.EmergParkHandleOnOff,cockpit_device_id=devices.GEAR_INTERFACE,value_down=1.0,value_up=-1.0,name=_('Emergency/Parking Brake Handle - CCW+Pull'),category=_('[13] Front Left - Vertical Panel')},
{down = hotas_commands.THROTTLE_SPEED_BRAKE, up = hotas_commands.THROTTLE_SPEED_BRAKE, cockpit_device_id = devices.HOTAS, value_down = -1.0, value_up = 1.0, name = _('Speed Brake Switch 2-Pos EXTEND/RETRACT'), category = {_('Throttle Grip'), _('HOTAS')}},

I recommend you look at the tutorial before you start messing with the .lua file though! Greetings to my home-Land!

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Link to comment
Share on other sites

Hi LeCuvier,

thank you very much for the Link and your guide.

As soon as I understand everything and have my modifications working, I want to write a german guide based on your work in our OpenFlightSchool project.

May I use and link your work? I will, of course, acknowledge you as a source.

Greetings back from your home-Land! :)

SYSTEM: Mainboard MSI MEG X570 | CPU Ryzen 7 5800X @ 4.5 GHz | RAM 64 GB @ 3200 MHz | GPU GIGABYTE RTX 4090 | 1 TB SSD | Win 10 x64

DEVICES: ASUS 27" LCD | TrackIR 5 | LukeClip | Quest 3 | PointCTRL | Virpil HOTAS | MFG Crosswind | TableMount MonsterTech

MODULES: To much to list. But I stopped buying more, because of too much bugs in e.g. A-10C(II). @ED: Fix the bugs and I spend money on modules again. Promised.

PROJECTS: OpenFlightSchool: DE / EN

Link to comment
Share on other sites

Yes of course, kein Problem!

If you want to, send me your work for proof-reading.

Tschüs!

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Link to comment
Share on other sites

I am trying to get some dedicated On and Off Keybindings in Ka-50. So far I got already pretty well started, with most of the switches. I am, however, stuck with some switch covers. For example for Battery 1, I would have:

 

 

  {down = 3006, value_down = 1.0,cockpit_device_id = 2, name = _('Battery 1 Cover Open'), category = _('MODDED')},
 {down = 3006, value_down = 0.0,cockpit_device_id = 2, name = _('Battery 1 Cover Close'), category = _('MODDED')},

 

 

No joy, both keys just flip the cover open and close, back and forth.

Any ideas how I could fix it. With the underlying On/Off switch I get with the same formulation the dedicated On or dedicated Off functionality.

Link to comment
Share on other sites

Battery switch cover

 

@Jyge:

Your first line is ok. But for the second line, use "value_down = -1.0"!

{down = 3006, value_down = -1.0,cockpit_device_id = 2, name = _('Battery 1 Cover Close'), category = _('MODDED')},

It works on my rig. Good luck!

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Link to comment
Share on other sites

Pardon me if this is not directly related.

 

I have VKB MCG PRO joystick which has a trigger than can be in the up or down position.

In DCS Ka-50, I set the VKB trigger down position to Gun Select "C" which would allow me to use the trigger to release rockets or Vikhr.

When I flip the trigger up, it would also trigger Gun Select "C" but this time, it would allow me to fire the cannon.

 

Sometimes, the cockpit joystick trigger is not synced properly with my VKB Joystick trigger even though the "Synchronize Cockpit Controls with HOTAS Controls at Mission Start" is checked.

For example, VKB Joystick trigger would be in the up position but cockpit trigger would be down.

 

 

How to fix this?

Thanks.

1921480331_gunselect.thumb.PNG.292a3f862b9d415cce06d2deaf92e740.PNG

664677768_VKBTrigger2.png.2a2fb4d832a93a358573564bf942a420.png

Link to comment
Share on other sites

@Jyge:

Your first line is ok. But for the second line, use "value_down = -1.0"!

{down = 3006, value_down = -1.0,cockpit_device_id = 2, name = _('Battery 1 Cover Close'), category = _('MODDED')},

It works on my rig. Good luck!

 

 

Hi, the problem with the first line is that it keeps on toggling the switch open and close. I would want an explicit open the switch cover and keep it open nevermind how often I press it successively...

Link to comment
Share on other sites

Hi, the problem with the first line is that it keeps on toggling the switch open and close. I would want an explicit open the switch cover and keep it open nevermind how often I press it successively...

I can get the behaviour you describe only if I do something illogical.

When the cover is DOWN (closed) and I push the button bound to "Open" the cover goes to the UP (open) position and stays open. Next, when I push the button bound to "Close" the cover goes to the DOWN (closed) position and stays there. I'm using spring-loaded pushbuttons that provide a momentary contact closure (pulse). That's the normal or "logical" sequence of operation.

If however the cover is DOWN (closed) and I hit the button bound to "Close" then I get the cycling behaviour you describe. Same if the cover is open and you hit the button bound to "Open". But that's what I refer to as "illogical" sequence of operation. When the cover is closed, the pilot would not try to close it even more, would he?

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Link to comment
Share on other sites

Pardon me if this is not directly related.

 

I have VKB MCG PRO joystick which has a trigger than can be in the up or down position.

In DCS Ka-50, I set the VKB trigger down position to Gun Select "C" which would allow me to use the trigger to release rockets or Vikhr.

When I flip the trigger up, it would also trigger Gun Select "C" but this time, it would allow me to fire the cannon.

 

Sometimes, the cockpit joystick trigger is not synced properly with my VKB Joystick trigger even though the "Synchronize Cockpit Controls with HOTAS Controls at Mission Start" is checked.

For example, VKB Joystick trigger would be in the up position but cockpit trigger would be down.

 

 

How to fix this?

Thanks.

Unfortunately the "Gun Select" ("C") is a stupid toggle command. Each time you issue this command, the safety latch goes to the opposite of the current position. So it cycles between Up and Down each time you issue the "C" command. The fact that you have two separate switches bound to "C" doesn't matter. The game logic only "sees" the "C" command and it cannot distinguish whether it came from one or the other switch.

The switches on the cyclic stick are not clickable, and therefore they are not defined in the file "clickabledata.lua", and therefore I have no way of creating a custom command.

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Link to comment
Share on other sites

Unfortunately the "Gun Select" ("C") is a stupid toggle command. Each time you issue this command, the safety latch goes to the opposite of the current position. So it cycles between Up and Down each time you issue the "C" command.

 

Yes. But depending on the input device and the used software there is a 'workaround'.

I am using TARGET for Warthog and this code:

MapKey(&Joystick,  TG1, GunCover);
MapKeyR(&Joystick, TG1, GunCover);
MapKey(&Joystick,  TG2, Gun);

Stays always in sync and works like a charm.

Link to comment
Share on other sites

Unfortunately the "Gun Select" ("C") is a stupid toggle command. Each time you issue this command, the safety latch goes to the opposite of the current position. So it cycles between Up and Down each time you issue the "C" command. The fact that you have two separate switches bound to "C" doesn't matter. The game logic only "sees" the "C" command and it cannot distinguish whether it came from one or the other switch.

The switches on the cyclic stick are not clickable, and therefore they are not defined in the file "clickabledata.lua", and therefore I have no way of creating a custom command.

 

 

Thanks. I doubt it will get the attention of the ED Team.

Link to comment
Share on other sites

Concerning the switches with a cover I tried to mimic the solution which works for the F18:

https://forums.eagle.ru/showpost.php?p=4168935&postcount=655

 

But I had no success with the "down - pressed - up" in the BlackShark config. Any thoughts on this?

I tried some lines of code but could not get anything useful. But I would never sacrifice switches for these commands anyway. If I ever do a manual cold start on the Hornet I will just click into the cockpit.

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Link to comment
Share on other sites

If however the cover is DOWN (closed) and I hit the button bound to "Close" then I get the cycling behaviour you describe. Same if the cover is open and you hit the button bound to "Open". But that's what I refer to as "illogical" sequence of operation. When the cover is closed, the pilot would not try to close it even more, would he?

 

The problem is that the hardware switch needs to be synchronous with the virtual one in the beginning. However, I found the solution for Ka-50. I noticed that if the cover is closed, but I still press the switch itself, for example "On", it will open the cover and with the second press it actuates the switch.

 

 

So the easy solution is to use T.A.R.G.E.T and put the switch On command twice into the switch. So if the cover is closed, it will be opened and the switch is turned on. Even if the cover was closed it will still switch On and the second command is unnecessary but does not cause any reaction. I could add the switch cover toggle command to the CHAIN and then it would close the cover after the action...

Link to comment
Share on other sites

I tried setting up a 3 position switch for the MiG21 and Mig19 flaps as per instructions given in the "how to Edit controls...".pdf. More specifically within this guide, the section with MiG21 as an example:

5.6 Creating a 3-Position Flaps control (Mig-21bis)

 

Didn't work for me! When I go onto controls changes (in-game), two entries have been created but they are unrelated to flaps. Here is my MiG 21 entry in default.lua in joystick folder:

 

--FLAPS Modified

{down=device_commands.Flaps0,cockpit_device_id=devices.FLAPS,up=device_commands.Flaps25,cockpit_device_id=devices.FLAPS,value_down=1.0,value_up=1.0,name=_('Flaps_3_Pos_Up'),category=_('Flight Controls')},

{down=device_commands.Flaps45,cockpit_device_id=devices.FLAPS,,up=device_commands.Flaps25,cockpit_device_id=devices.FLAPS,value_down=1.0,value_up=1.0,name=_('Flaps_3_Pos_Down'),category=_('Flight Controls')},

 

Any guidance on this please?

Thanks

Link to comment
Share on other sites

I tried setting up a 3 position switch for the MiG21 and Mig19 flaps as per instructions given in the "how to Edit controls...".pdf. More specifically within this guide, the section with MiG21 as an example:

5.6 Creating a 3-Position Flaps control (Mig-21bis)

 

Didn't work for me! When I go onto controls changes (in-game), two entries have been created but they are unrelated to flaps. Here is my MiG 21 entry in default.lua in joystick folder:

 

--FLAPS Modified

{down=device_commands.Flaps0,cockpit_device_id=devices.FLAPS,up=device_commands.Flaps25,cockpit_device_id=devices.FLAPS,value_down=1.0,value_up=1.0,name=_('Flaps_3_Pos_Up'),category=_('Flight Controls')},

{down=device_commands.Flaps45,cockpit_device_id=devices.FLAPS,,up=device_commands.Flaps25,cockpit_device_id=devices.FLAPS,value_down=1.0,value_up=1.0,name=_('Flaps_3_Pos_Down'),category=_('Flight Controls')},

 

Any guidance on this please?

Thanks

I have not looked at the original code, but based on your snippets, you might try:

{down=device_commands.Flaps0,up=device_commands.Flaps25,cockpit_device_id=devices.FLAPS,value_down=1.0,value_up=1.0,name=_('Flaps_3_Pos_Up'),category=_('Flight Controls')},

{down=device_commands.Flaps45,up=device_commands.Flaps25,cockpit_device_id=devices.FLAPS,value_down=1.0,value_up=1.0,name=_('Flaps_3_Pos_Down'),category=_('Flight Controls')},

Punk

 

[sIGPIC][/sIGPIC]

Link to comment
Share on other sites

I tried setting up a 3 position switch for the MiG21 and Mig19 flaps as per instructions given in the "how to Edit controls...".pdf. More specifically within this guide, the section with MiG21 as an example:

5.6 Creating a 3-Position Flaps control (Mig-21bis)

 

Didn't work for me! When I go onto controls changes (in-game), two entries have been created but they are unrelated to flaps. Here is my MiG 21 entry in default.lua in joystick folder:

 

--FLAPS Modified

{down=device_commands.Flaps0,cockpit_device_id=devices.FLAPS,up=device_commands.Flaps25,cockpit_device_id=devices.FLAPS,value_down=1.0,value_up=1.0,name=_('Flaps_3_Pos_Up'),category=_('Flight Controls')},

{down=device_commands.Flaps45,cockpit_device_id=devices.FLAPS,,up=device_commands.Flaps25,cockpit_device_id=devices.FLAPS,value_down=1.0,value_up=1.0,name=_('Flaps_3_Pos_Down'),category=_('Flight Controls')},

 

Any guidance on this please?

Thanks

The code in the tutorial is what I have in my "default.lua", and it works as I just verified. The code in your post is different from what the tutorial shows.

I repeat the correct code from the tutorial:

{down=device_commands.Flaps0,up=device_commands.Flaps25,cockpit_device_id=devices.FLAPS,value_down=1.0,value_up=1.0,name ='Flaps 3-Pos Up’, category='Flight Controls'}, {down=device_commands.Flaps45,up=device_commands.Flaps25,cockpit_device_id=devices.FLAPS,value_down=1.0,value_up=1.0,name='Flaps 3-Pos Down’, category ='Flight Controls'},

Compare yourself!

LeCuvier

Windows 10 Pro 64Bit | i7-4790 CPU |16 GB RAM|SSD System Disk|SSD Gaming Disk| MSI GTX-1080 Gaming 8 GB| Acer XB270HU | TM Warthog HOTAS | VKB Gladiator Pro | MongoosT-50 | MFG Crosswind Pedals | TrackIR 5

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...