Jump to content
The simFlight Network Forums

Disable Specific Joystick with Lua

Recommended Posts

Hi Akis,

to do this, you would have to use your lua script to receive the axis values and send on the axis controls.

What you need is a lua script to receive your axis values and then send the controls depending upon the state of a flag, also controlled using your button. In your Axis Assignment tab, you need to assign your axis to 'Send to FS as normal axis', and then select the 'LuaValue <your script name>' option. This will send the axis value to a lua variable called ipcPARAM, which you can then optionally use to send the control to the sim, depending upon the state of your button. The lua script should be auto-started (i.e. add it to the '[Auto]' section of your ini. Check the documentation for 'event.param' on page 29 of the Lua Library documentation.

Not sure why you would want to do this though....



Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.