-- C-101CC clickable data description dofile(LockOn_Options.script_path.."../Common/clickabledata_common.lua") dofile(LockOn_Options.script_path.."devices.lua") local gettext = require("i_18n") _ = gettext.translate --================================================================ FORWARD COCKPIT ================================================================== --== RED PANEL LIGHT ADJUSTMENTS ==================================================================================================================== -- FORWARD CPT --elements["PNT-RL-LTP"] = default_axis_limited("ADJUST RED LIGHT - TOP CENTER PANEL", 0, devices.SYSTEMS, device_commands.Button_229, 260, 0.0, 0.1, {0,1}, true) -- REAR CPT --elements["PNT-RL-LTP-BACK"] = default_axis_limited("ADJUST RED LIGHT - TOP CENTER PANEL", 1, devices.SYSTEMS, device_commands.Button_660, 265, 0.0, 0.1, {0,1}, true) --===============MANUAL POWER RESERVE (MPR)==================== -- FORWARD COCKPIT elements["PNT-MPR-LGT"] = default_button_axis(_("MPR Lamp Test"), 0, devices.SYSTEMS, device_commands.Button_702, device_commands.Button_704, 1312, 1313) -- REAR COCKPIT elements["PNT-MPR-LGT-BACK"] = default_button_axis(_("MPR Lamp Test"), 1, devices.SYSTEMS, device_commands.Button_703, device_commands.Button_705, 1317, 1318) --== FLIGHT DIRECTOR ================================================================================================================================ -- FORWARD CPT elements["PNT-FD-HDG"] = default_button(_("HEADING MODE"),0,devices.SYSTEMS,device_commands.Button_171,210,1,{0,1},true,sounds.sound_FD) elements["PNT-FD-ALT"] = default_button(_("ALTITUDE MODE"),0,devices.SYSTEMS,device_commands.Button_172,215,1,{0,1},true,sounds.sound_FD) elements["PNT-FD-NAV"] = default_button(_("NAV MODE"),0,devices.SYSTEMS,device_commands.Button_174,211,1,{0,1},true,sounds.sound_FD) elements["PNT-FD-APR"] = default_button(_("APPROACH MODE"),0,devices.SYSTEMS,device_commands.Button_175,212,1,{0,1},true,sounds.sound_FD) elements["PNT-FD-BC"] = default_button(_("BACK COURSE MODE"),0,devices.SYSTEMS,device_commands.Button_176,213,1,{0,1},true,sounds.sound_FD) elements["PNT-FD-VOR"] = default_button(_("VOR APPROACH MODE"),0,devices.SYSTEMS,device_commands.Button_177,214,1,{0,1},true,sounds.sound_FD) --elements["PNT-FD-BLK"] = default_button(_("NO FUNCTION"),0,devices.SYSTEMS,device_commands.Button_253,216,1,{0,1},true,sounds.sound_FD) elements["PNT-FD-VS"] = default_button(_("VERTICAL SPEED MODE"),0,devices.SYSTEMS,device_commands.Button_178,217,1,{0,1},true,sounds.sound_FD) elements["PNT-FD-IAS"] = default_button(_("INDICATED AIR SPEED MODE"),0,devices.SYSTEMS,device_commands.Button_179,218,1,{0,1},true,sounds.sound_FD) elements["PNT-FD-SBY"] = default_button(_("STANDBY MODE"),0,devices.SYSTEMS,device_commands.Button_170,219,1,{0,1},true,sounds.sound_FD) --== FD BRIGHTNESS KNOB ============================================================================================================================ -- FORWARD CPT elements["PNT-FD-KNB-RP"] = multiposition_switch(_("FD Panel Brightness"),0,devices.SYSTEMS,device_commands.Button_195,343,2,1.0,true) -- REAR CPT elements["PNT-FD-KNB-RP-BACK"] = multiposition_switch(_("FD Panel Brightness"),1,devices.SYSTEMS,device_commands.Button_661,916,2,1.0,true) --== V/UHF RADIO ====================================================================================================================================== local VUHF_freq_anim_speed = anim_speed_default * 0.06 local VUHF_025_freq_anim_speed = anim_speed_default * 0.13 local VUHF_preset_channel_anim_speed = anim_speed_default * 0.05 local VUHF_func_dial_anim_speed = anim_speed_default * 0.1 local VUHF_freq_mode_anim_speed = anim_speed_default * 0.5 -- FORWARD CPT elements["PNT-UHF-1S-CP"] = multiposition_switch(_("100 MHz Selector"),0,devices.VTWU740,device_commands.Button_2,226,3,0.1,false,false,0,sounds.sound_knob,true,VUHF_freq_anim_speed) elements["PNT-UHF-2S-CP"] = multiposition_switch_cycled_relative(_("10 MHz Selector"),0,devices.VTWU740,device_commands.Button_3,227,11,0.1,false,0,sounds.sound_knob,VUHF_freq_anim_speed) elements["PNT-UHF-3S-CP"] = multiposition_switch_cycled_relative(_("1 MHz Selector"),0,devices.VTWU740,device_commands.Button_4,228,11,0.1,false,0,sounds.sound_knob,VUHF_freq_anim_speed) elements["PNT-UHF-4S-CP"] = multiposition_switch_cycled_relative(_("0.1 MHz Selector"),0,devices.VTWU740,device_commands.Button_5,229,11,0.1,false,0,sounds.sound_knob,VUHF_freq_anim_speed) elements["PNT-UHF-5S-CP"] = multiposition_switch_cycled_relative(_("0.025 MHz Selector"),0,devices.VTWU740,device_commands.Button_6,230,5,0.25,false,0,sounds.sound_knob,VUHF_025_freq_anim_speed) elements["PNT-UHF-CHS-CP"] = multiposition_switch_cycled_relative(_("Preset Channel Selector"),0,devices.VTWU740,device_commands.Button_11,231,21,0.05,false,0,sounds.sound_knob,VUHF_preset_channel_anim_speed) elements["PNT-UHF-FS-CP"] = multiposition_switch(_("Function Dial"),0,devices.VTWU740,device_commands.Button_7,232,4,0.1,false,false,0,sounds.sound_knob,true,VUHF_func_dial_anim_speed) elements["PNT-UHF-MD-CP"] = multiposition_switch(_("Frequency Mode Dial"),0,devices.VTWU740,device_commands.Button_8,233,3,0.5,false,false,0,sounds.sound_knob,true,VUHF_freq_mode_anim_speed) elements["PNT-UHF-TS-CP"] = springloaded_2pos_switch(_("TEST SELECTOR SWITCH"), 0, devices.VTWU740, device_commands.Button_1, device_commands.Button_12, 234) elements["PNT-UHF-SQL-CP"] = multiposition_switch(_("Squelch Switch"),0,devices.VTWU740,device_commands.Button_9,236,2,1.0,true) elements["PNT-UHF-PW-CP"] = multiposition_switch(_("POWER TRANSMIT SELECTOR"),0,devices.VTWU740,device_commands.Button_10,235,2,1.0,true) -- REAR CPT elements["PNT-UHF-1S-CP-BACK"] = multiposition_switch(_("100 MHz Selector"),1,devices.VTWU740,device_commands.Button_22,862,3,0.1,false,false,0,sounds.sound_knob,true,VUHF_freq_anim_speed) elements["PNT-UHF-2S-CP-BACK"] = multiposition_switch_cycled_relative(_("10 MHz Selector"),1,devices.VTWU740,device_commands.Button_23,863,11,0.1,false,0,sounds.sound_knob,VUHF_freq_anim_speed) elements["PNT-UHF-3S-CP-BACK"] = multiposition_switch_cycled_relative(_("1 MHz Selector"),1,devices.VTWU740,device_commands.Button_24,864,11,0.1,false,0,sounds.sound_knob,VUHF_freq_anim_speed) elements["PNT-UHF-4S-CP-BACK"] = multiposition_switch_cycled_relative(_("0.1 MHz Selector"),1,devices.VTWU740,device_commands.Button_25,865,11,0.1,false,0,sounds.sound_knob,VUHF_freq_anim_speed) elements["PNT-UHF-5S-CP-BACK"] = multiposition_switch_cycled_relative(_("0.025 MHz Selector"),1,devices.VTWU740,device_commands.Button_26,866,5,0.25,false,0,sounds.sound_knob,VUHF_025_freq_anim_speed) elements["PNT-UHF-CHS-CP-BACK"] = multiposition_switch_cycled_relative(_("Preset Channel Selector"),1,devices.VTWU740,device_commands.Button_31,867,21,0.05,false,0,sounds.sound_knob,VUHF_preset_channel_anim_speed) elements["PNT-UHF-FS-CP-BACK"] = multiposition_switch(_("Function Dial"),1,devices.VTWU740,device_commands.Button_27,868,4,0.1,false,false,0,sounds.sound_knob,true,VUHF_func_dial_anim_speed) elements["PNT-UHF-MD-CP-BACK"] = multiposition_switch(_("Frequency Mode Dial"),1,devices.VTWU740,device_commands.Button_28,869,3,0.5,false,false,0,sounds.sound_knob,true,VUHF_freq_mode_anim_speed) elements["PNT-UHF-TS-CP-BACK"] = springloaded_2pos_switch(_("TEST SELECTOR SWITCH"), 1, devices.VTWU740, device_commands.Button_21, device_commands.Button_32, 875) elements["PNT-UHF-SQL-CP-BACK"] = multiposition_switch(_("Squelch Switch"),1,devices.VTWU740,device_commands.Button_29,872,2,1.0,true) elements["PNT-UHF-PW-CP-BACK"] = multiposition_switch(_("POWER TRANSMIT SELECTOR"),1,devices.VTWU740,device_commands.Button_30,876,2,1.0,true) --== VHF COMM/NAV ======================================================================================================================================== local VHF_COMM_freq_knob_gain = 1 local VHF_COMM_pwr_vol_knob_gain = 0.5 local VHF_COMM_pwr_knob_anim_speed = 7.0 local VHF_COMM_vol_knob_anim_speed = 1.0 local function VHF_COMM_freq_MHz_pwr_control(hint, seat_, cmd_thumb, cmd_lev, arg_thumb, arg_lev) local res = { class = {class_type.TUMB, class_type.TUMB, class_type.LEV}, hint = hint, device = devices.VHF20B, action = {cmd_thumb, cmd_thumb, cmd_lev}, arg = {arg_thumb, arg_thumb, arg_lev}, arg_value = {-0.5, 0.5, 1}, arg_lim = {{0, 1}, {0, 1}, {0, 1}}, relative = {false, false, true}, gain = {VHF_COMM_pwr_vol_knob_gain, VHF_COMM_pwr_vol_knob_gain, VHF_COMM_freq_knob_gain}, animated = {true, true, false}, animation_speed = {VHF_COMM_pwr_knob_anim_speed, VHF_COMM_pwr_knob_anim_speed, 0}, --use_release_message = {true, true, false}, --use_OBB = true, cycle = false, } if use_seat_assignments == true then res.crew_member_access = {seat_ or 0} end return res end local function VHF_COMM_freq_KHz_volume_control(hint, seat_, cmd_thumb, cmd_lev, arg_thumb, arg_lev) local res = { class = {class_type.TUMB, class_type.TUMB, class_type.LEV}, hint = hint, device = devices.VHF20B, action = {cmd_thumb, cmd_thumb, cmd_lev}, arg = {arg_thumb, arg_thumb, arg_lev}, arg_value = {-0.1, 0.1, 1}, arg_lim = {{0, 1}, {0, 1}, {0, 1}}, relative = {false, false, true}, gain = {VHF_COMM_pwr_vol_knob_gain, VHF_COMM_pwr_vol_knob_gain, VHF_COMM_freq_knob_gain}, animated = {true, true, false}, animation_speed = {VHF_COMM_vol_knob_anim_speed, VHF_COMM_vol_knob_anim_speed, 0}, --use_release_message = {true, true, false}, --use_OBB = true, cycle = false, } if use_seat_assignments == true then res.crew_member_access = {seat_ or 0} end return res end local VHF_NAV_freq_knob_gain = 1 local VHF_NAV_mode_vol_knob_gain = 0.5 local VHF_NAV_mode_knob_anim_speed = 4.0 local VHF_NAV_vol_knob_anim_speed = 1.0 local function VHF_NAV_freq_MHz_mode_control(hint, seat_, cmd_thumb, cmd_lev, arg_thumb, arg_lev) local res = { class = {class_type.TUMB, class_type.TUMB, class_type.LEV}, hint = hint, device = devices.VIR31A_DME40, action = {cmd_thumb, cmd_thumb, cmd_lev}, arg = {arg_thumb, arg_thumb, arg_lev}, arg_value = {-0.25, 0.25, 1}, arg_lim = {{0, 1}, {0, 1}, {0, 1}}, relative = {false, false, true}, gain = {VHF_NAV_mode_vol_knob_gain, VHF_NAV_mode_vol_knob_gain, VHF_NAV_freq_knob_gain}, animated = {true, true, false}, animation_speed = {VHF_NAV_mode_knob_anim_speed, VHF_NAV_mode_knob_anim_speed, 0}, --use_release_message = {true, true, false}, --use_OBB = true, cycle = false, } if use_seat_assignments == true then res.crew_member_access = {seat_ or 0} end return res end local function VHF_NAV_freq_KHz_volume_control(hint, seat_, cmd_thumb, cmd_lev, arg_thumb, arg_lev) local res = { class = {class_type.TUMB, class_type.TUMB, class_type.LEV}, hint = hint, device = devices.VIR31A_DME40, action = {cmd_thumb, cmd_thumb, cmd_lev}, arg = {arg_thumb, arg_thumb, arg_lev}, arg_value = {-0.1, 0.1, 1}, arg_lim = {{0, 1}, {0, 1}, {0, 1}}, relative = {false, false, true}, gain = {VHF_NAV_mode_vol_knob_gain, VHF_NAV_mode_vol_knob_gain, VHF_NAV_freq_knob_gain}, animated = {true, true, false}, animation_speed = {VHF_NAV_vol_knob_anim_speed, VHF_NAV_vol_knob_anim_speed, 0}, --use_release_message = {true, true, false}, --use_OBB = true, cycle = false, } if use_seat_assignments == true then res.crew_member_access = {seat_ or 0} end return res end -- FORWARD CPT -- VHF COMM elements["PNT-COMM-PWR-RP"] = VHF_COMM_freq_MHz_pwr_control(_("OFF/PWR/TEST switch/Frequency control (100 MHz). Rotate mouse wheel to make channel selection"), 0, device_commands.Button_4, device_commands.Button_1, 653, 0) elements["PNT-COMM-VOL-RP"] = VHF_COMM_freq_KHz_volume_control(_("Volume control/Frequency control (10 kHz). Right mouse click to select FREQUENCY SELECTOR (0.025 MHz). Rotate mouse wheel to select channel"), 0, device_commands.Button_3, device_commands.Button_2, 655, 0) -- VHF NAV -- args: --645 - Mhz (knob and frequency) --646 - Khz (knob and frequency) --650 - NAV TEST sw --657 - MODE selector --659 - volume elements["PNT-COMMN-TB-RP"] = multiposition_switch(_("NAV TEST SWITCH"),0,devices.VIR31A_DME40,device_commands.Button_5,650,3,1.0,false,false,-1.0) elements["PNT-NAV-MS-RP"] = VHF_NAV_freq_MHz_mode_control(_("Control switch/Frequency control (1 MHz). Rotate mouse wheel to make channel selection"), 0, device_commands.Button_4, device_commands.Button_1, 657, 0) elements["PNT-NAV-VOL-RP"] = VHF_NAV_freq_KHz_volume_control(_("Volume control/Frequency control (50 kHz). Right mouse click to select FREQUENCY SELECTOR (50 kHz). Rotate mouse wheel to make channel selection"), 0, device_commands.Button_3, device_commands.Button_2, 659, 0) -- REAR CPT -- VHF COMM elements["PNT-COMM-PWR-RP-BACK"] = VHF_COMM_freq_MHz_pwr_control(_("OFF/PWR/TEST switch/Frequency control (1 MHz). Rotate mouse wheel to change frequency"), 1, device_commands.Button_14, device_commands.Button_11, 917, 0) elements["PNT-COMM-VOL-RP-BACK"] = VHF_COMM_freq_KHz_volume_control(_("Volume control/Frequency control (0.025 MHz). Left/right mouse click to adjust volume. Rotate mouse wheel to change frequency"), 1, device_commands.Button_13, device_commands.Button_12, 919, 0) -- VHF NAV -- args: --906 - Mhz (knob and frequency) --907 - Khz (knob and frequency) --915 - NAV TEST sw --921 - MODE selector --923 - volume elements["PNT-COMMN-TB-RP"] = multiposition_switch(_("NAV TEST SWITCH"),1,devices.VIR31A_DME40,device_commands.Button_15,915,3,1.0,false,false,-1.0) elements["PNT-NAV-MS-RP-BACK"] = VHF_NAV_freq_MHz_mode_control(_("Control switch/Frequency control (1 MHz).Rotate mouse wheel to make channel selection"), 1, device_commands.Button_14, device_commands.Button_11, 921, 0) elements["PNT-NAV-VOL-RP-BACK"] = VHF_NAV_freq_KHz_volume_control(_("Volume control/Frequency control (50 kHz). Left/right mouse click to adjust volume. Rotate mouse wheel to change frequency"), 1, device_commands.Button_13, device_commands.Button_12, 923, 0) --== INTERCOM PANEL ================================================================================================================================= -- FORWARD CPT -- ADF elements["PNT-INT-ADF-RP"] = intercom_rotate_tumb(_("ADF Switch"),0,devices.INTERCOM,device_commands.Button_14,device_commands.Button_15, 849, 853) -- DME elements["PNT-INT-DME-RP"] = intercom_rotate_tumb(_("DME Switch"),0,devices.INTERCOM,device_commands.Button_16,device_commands.Button_17, 284, 398) -- V/UHF elements["PNT-INT-VUHF-RP"] = intercom_rotate_tumb(_("V/UHF Switch"),0,devices.INTERCOM,device_commands.Button_18,device_commands.Button_19, 268, 269) -- MAIN SELECTOR elements["PNT-INT-MAINS-RP"] = multiposition_switch(_("MAIN MODE SELECTOR"),0,devices.INTERCOM,device_commands.Button_20,404,7,0.1,false,true,0,sounds.sound_rotary) -- REAR CPT -- ADF elements["PNT-INT-ADF-RP-BACK"] = intercom_rotate_tumb(_("ADF Switch"),1,devices.INTERCOM,device_commands.Button_37,device_commands.Button_38, 1140,1141) -- DME elements["PNT-INT-DME-RP-BACK"] = intercom_rotate_tumb(_("DME Switch"),1,devices.INTERCOM,device_commands.Button_39,device_commands.Button_40, 888, 898) -- V/UHF elements["PNT-INT-VUHF-RP-BACK"] = intercom_rotate_tumb(_("V/UHF Switch"),1,devices.INTERCOM,device_commands.Button_41,device_commands.Button_42, 1109, 1110) -- MAIN SELECTOR elements["PNT-INT-MAINS-RP-BACK"] = multiposition_switch(_("MAIN MODE SELECTOR"),1,devices.INTERCOM,device_commands.Button_43,947,7,0.1,false,true,0,sounds.sound_rotary) --== ADI KNOB ======================================================================================================================================= -- ADI DH set/ADI/HSI digital displays dimmer local function ADI_DecisionHeight_DIM_knob(seat_, cmd_DH, cmd_DIM, arg_DH, arg_DIM) local res = { class = {class_type.LEV, class_type.LEV}, hint = _("Decision Height setting / ADI/HSI digital displays brightness"), device = devices.SYSTEMS, action = {cmd_DH, cmd_DIM}, arg = {arg_DH, arg_DIM}, arg_value = {0.0, 1.0}, arg_lim = {{0.0, 1.0}, {0.0, 1.0}}, relative = {true, false}, animated = {false, false}, animation_speed = {0.7, 0.7}, gain = {0.1, 0.1}, cycle = false, } if use_seat_assignments == true then res.crew_member_access = {seat_ or 0} end return res end -- FORWARD CPT elements["PNT-ADI-DH-CP"] = default_button(_("RADIO ALTITUDE SWITCH TEST ADI"),0,devices.SYSTEMS,device_commands.Button_346,683,1,{0,1},true,sounds.sound_fuel_test) --elements["PNT-ADI-SET-CP"] = default_axis(_("DH SET RADIO ALTIMETER"),0,devices.SYSTEMS,device_commands.Button_347,685) --elements["PNT-ADI-DIM-CP"] = default_axis(_("DIM ADI RADIO ALTIMETER"),0,devices.SYSTEMS,device_commands.Button_348,684) -- ADI DH set/ADI/HSI digital displays dimmer -- single clickspot implementation elements["PNT-ADI-DH-DIM-RP"] = ADI_DecisionHeight_DIM_knob(0, device_commands.Button_347, device_commands.Button_161, 412, 411) -- REAR CPT elements["PNT-ADI-DH-CP-BACK"] = default_button(_("RADIO ALTITUDE SWITCH TEST ADI"),1,devices.SYSTEMS,device_commands.Button_600,1045,1,{0,1},true,sounds.sound_fuel_test) --elements["PNT-ADI-SET-CP-BACK"] = default_axis(_("DH SET RADIO ALTIMETER"),1,devices.SYSTEMS,device_commands.Button_601,288) --elements["PNT-ADI-DIM-CP-BACK"] = default_axis(_("DIM ADI RADIO ALTIMETER"),1,devices.SYSTEMS,device_commands.Button_602,278) -- single clickspot implementation elements["PNT-ADI-DH-DIM-RP-BACK"] = ADI_DecisionHeight_DIM_knob(1, device_commands.Button_601, device_commands.Button_443, 924, 923) --== STANDBY ALTIMETER ============================================================================================================================== -- FORWARD CPT elements["PNT-RA-KB-CP"] = default_axis(_("Standby Altimeter Baro Adjust"), 0, devices.SYSTEMS, device_commands.Button_344, 620, 1, 0.05, false, true) elements["PNT-BACK-ALT-GL"] = default_button(_("Tap Glass"), 0, devices.SYSTEMS, device_commands.Button_549, 1190, 1, {0, 1}, true, sounds.sound_glass) -- REAR CPT elements["PNT-RA-KB-CP-BACK"] = default_axis(_("Standby Altimeter Baro Adjust"), 1, devices.SYSTEMS, device_commands.Button_605, 1021, 1, 0.05, false, true) elements["PNT-BACK-ALT-GL-BACK"] = default_button(_("Tap Glass"), 1, devices.SYSTEMS, device_commands.Button_550, 1191, 1, {0, 1}, true, sounds.sound_glass) --== EQUIPMENT SWITCHES PANEL (unofficial name) ===================================================================================================== -- FORWARD CPT elements["PNT-DME-CP"] = multiposition_switch(_("DME selector"),0,devices.VIR31A_DME40,device_commands.Button_6,340,2,1,true) elements["PNT-RALT-CP"] = multiposition_switch(_("Radio altimeter"),0,devices.SYSTEMS,device_commands.Button_28,341,2,1,true) elements["PNT-ELT-CP"] = springloaded_1pos_switch2(_("Emergency locator tranmsitter"),0,devices.SYSTEMS,device_commands.Button_26,device_commands.Button_26,339,false,sounds.sound_sw2) ---common with eb but different switch elements["PNT-AUHF-CP"] = multiposition_switch(_("UHF ANTENNA SELECTION"),0,devices.SYSTEMS,device_commands.Button_221,338,3,0.5) -- REAR CPT elements["PNT-DME-CP-BACK"] = multiposition_switch(_("DME selector"),1,devices.VIR31A_DME40,device_commands.Button_16,965,2,1,true) elements["PNT-ERCR-CP-BACK"] = springloaded_thumb(_("Fast Erect"),1,devices.SYSTEMS,device_commands.Button_512,966,1,{0,1}) --== SCAR DISPLAY UNIT ============================================================================================================================== -- FORWARD CPT elements["PNT-SCARD-IC-KB-CP"] = multiposition_switch(_("INITIAL CANNON LOAD"),0,devices.SYSTEMS,device_commands.Button_270,569,10,0.11,false,true,0) -- C-101CC elements["PNT-SCARD-CB-BT-CP"] = default_button(_("MODE SELECTOR/CANCEL"),0,devices.SYSTEMS,device_commands.Button_271,573,1,{0,1},true,sounds.sound_korry) -- C-101CC -- REAR CPT elements["PNT-SCARD-IC-KB-CP-BACK"] = multiposition_switch(_("INITIAL CANNON LOAD"),1,devices.SYSTEMS,device_commands.Button_637,1285,10,0.11,false,true,0) -- C-101CC elements["PNT-SCARD-CB-BT-CP-BACK"] = default_button(_("MODE SELECTOR/CANCEL"),1,devices.SYSTEMS,device_commands.Button_638,1289,1,{0,1},true,sounds.sound_korry) -- C-101CC --== EMERGENCY JETTISON UNIT ======================================================================================================================== -- FORWARD CPT elements["PNT-SCAR-EJ-BT-CP"] = default_button(_("EMERGENCY JETTISON"),0,devices.SYSTEMS,device_commands.Button_268,567,1,{0,1},true,sounds.sound_fuel_test) -- C-101CC elements["PNT-SCAR-LT-BT-CP"] = default_button(_("SCAR LIGHT TEST"),0,devices.SYSTEMS,device_commands.Button_269,568,1,{0,1},true,sounds.sound_fuel_test) -- C-101CC -- REAR CPT elements["PNT-SCAR-EJ-BT-CP-BACK"] = default_button(_("EMERGENCY JETTISON"),1,devices.SYSTEMS,device_commands.Button_639,597,1,{0,1},true,sounds.sound_fuel_test) -- C-101CC elements["PNT-SCAR-LT-BT-CP-BACK"] = default_button(_("SCAR LIGHT TEST"),1,devices.SYSTEMS,device_commands.Button_640,598,1,{0,1},true,sounds.sound_fuel_test) -- C-101CC --== SIGHT HEAD RANGE SELECTOR ====================================================================================================================== -- FORWARD CPT --elements["PNT-THRT-SIGHT-LP"] = default_movable_axis(_("SIGHT HEAD RANGE SELECTOR"),0,devices.SYSTEMS,device_commands.Button_295,1028, 0.0, 0.1, true, false) -- REAR CPT --elements["PNT-THRT-SIGHT-LP-BACK"] = default_movable_axis(_("SIGHT HEAD RANGE SELECTOR"),1,devices.SYSTEMS,device_commands.Button_659,1031, 0.0, 0.1, true, false) --==SIGHT GLASS====================================================================================================================================== -- FORWARD CPT elements["PNT-SIGHTGLASS-KNB-RP"] = default_axis_limited(_("Gunsight Sun Filter"),0,devices.LIGHTS,device_commands.Button_670,1112) -- REAR CPT elements["PNT-SIGHTGLASS-KNB-RP-BACK"] = default_axis_limited(_("Gunsight Sun Filter"),1,devices.LIGHTS,device_commands.Button_671,1113) --== ALTIMETER ====================================================================================================================================== -- FORWARD CPT elements["PNT-AL-YLL-BT"] = default_button(_("Altimeter Test Adjust"),0,devices.SYSTEMS,device_commands.Button_364,607) -- REAR CPT elements["PNT-AL-YLL-BT-BACK"] = default_button(_("Altimeter Test Adjust"),1,devices.SYSTEMS,device_commands.Button_658,798) --== COLIMADOR ====================================================================================================================================== local sightDepressionAnimSpeed = 0.6 -- FORWARD CPT elements["PNT-HUD-1-RE-CP"] = default_axis_limited(_("Sight Brightness"),0,devices.SYSTEMS,device_commands.Button_310,722) -- C-101CC --elements["PNT-HUD-2-RE-CP"] = default_axis_limited(_("HUD ON/OFF"),0,devices.SYSTEMS,device_commands.Button_311,723) -- C-101CC elements["PNT-VIDEO-1-SW-CP"] = multiposition_switch(_("Video ON/STB/OFF"),0,devices.SYSTEMS,device_commands.Button_312,720,3,0.5) --elements["PNT-VIDEO-2-SW-CP"] = multiposition_switch(_("VIDEO REC"),0,devices.SYSTEMS,device_commands.Button_313,721,2,1.0,true,true,0) elements["PNT-HUD-1S-CP"] = multiposition_switch(_("DEPRESSION 0XX"),0,devices.SYSTEMS,device_commands.Button_314,587,3,0.1,false,false,0,sounds.sound_knob,true,sightDepressionAnimSpeed) elements["PNT-HUD-2S-CP"] = multiposition_switch_cycled_relative(_("DEPRESSION X0X"),0,devices.SYSTEMS,device_commands.Button_315,588,11,0.1,false,0,sounds.sound_knob,sightDepressionAnimSpeed) elements["PNT-HUD-3S-CP"] = multiposition_switch_cycled_relative(_("DEPRESSION XX0"),0,devices.SYSTEMS,device_commands.Button_316,589,11,0.1,false,0,sounds.sound_knob,sightDepressionAnimSpeed) elements["PNT-HUD-ON-SW-CP"] = multiposition_switch(_("OPTICAL SIGHT ON/OFF"),0,devices.SYSTEMS,device_commands.Button_318,591,2,1.0,true) -- AUTO/MAN/TEST elements["PNT-HUD-MS-SW-CP"] = { class = {class_type.TUMB, class_type.TUMB}, hint = _("DEPRESSION AUTO/MAN/TEST"), device = devices.SYSTEMS, action = {device_commands.Button_317, device_commands.Button_317}, stop_action = {device_commands.Button_319, device_commands.Button_319}, arg = {590, 590}, arg_value = {-0.5, 0.5}, arg_lim = {{0, 1}, {0, 1}}, use_release_message = {true, true}, updatable = true, use_OBB = true, cycle = false, } if use_seat_assignments == true then elements["PNT-HUD-MS-SW-CP"].crew_member_access = {0} end -- REAR CPT elements["PNT-HUD-1-RE-CP-BACK"] = default_axis_limited(_("Sight Brightness"),1,devices.SYSTEMS,device_commands.Button_654,713) --elements["PNT-HUD-2-RE-CP-BACK"] = multiposition_switch(_("HUD ON/OFF"),1,devices.SYSTEMS,device_commands.Button_655,723,20,0.05,false,true,0) --== HSI KNOB ======================================================================================================================================= -- FORWARD CPT elements["PNT-HSI-BR-CP"] = default_button(_("BEARING SELECT PUSHBUTTON"),0,devices.SYSTEMS,device_commands.Button_349,689,1,{0,1},true,sounds.sound_fuel_test) -- REAR CPT elements["PNT-HSI-BR-CP-BACK"] = default_button(_("BEARING SELECT PUSHBUTTON"),1,devices.SYSTEMS,device_commands.Button_651,698,1,{0,1},true,sounds.sound_fuel_test) --== CANOPY EMERGENCY FRACTURING ==================================================================================================================== -- FORWARD CPT elements["PNT-CANO-FRAC"] = default_axis_limited(_("CANOPY EMERGENCY FRACTURING"), 0, devices.SYSTEMS, device_commands.Button_343, 294, 0.0, 0.1, {0,1}, true) elements["PNT-CANO-FRAC-PIN"] = default_axis_limited(_("CANOPY EMERGENCY FRACTURING SAFETY PIN"), 0, devices.SYSTEMS, device_commands.Button_990, 1354, 0.0, -0.1, {0,1}, true) -- REAR CPT elements["PNT-CANO-FRAC-BACK"] = default_axis_limited(_("CANOPY EMERGENCY FRACTURING"), 1, devices.SYSTEMS, device_commands.Button_652, 277, 0.0, 0.1, {0,1}, true) elements["PNT-CANO-FRAC-PIN-BACK"] = default_axis_limited(_("CANOPY EMERGENCY FRACTURING SAFETY PIN"), 1, devices.SYSTEMS,device_commands.Button_991, 1355, 0.0, -0.1, {0,1}, true) --== RUDDER TRIM ==================================================================================================================================== -- FORWARD CPT elements["PNT-CB-TRIM-LP"] = springloaded_2pos_switch(_("Rudder Trim Switch"), 0, devices.SYSTEMS, device_commands.Button_350, device_commands.Button_353, 717) -- REAR CPT elements["PNT-CB-TRIM-LP-BACK"] = springloaded_2pos_switch(_("Rudder Trim Switch"), 1, devices.SYSTEMS, device_commands.Button_604, device_commands.Button_609, 1105) --===================================================== FORWARD COCKPIT ONLY FUNCTIONS ============================================================== --== SCAR CONTROL UNIT ============================================================================================================================== elements["PNT-SCAR-RC-CP"] = multiposition_switch(_("MASTER MODE COVER"),0,devices.SYSTEMS,device_commands.Button_254,690,2,1.0,true,false,0,sounds.sound_cover) -- C-101CC elements["PNT-SCAR-RC-SW-CP"] = multiposition_switch(_("MASTER MODE"),0,devices.SYSTEMS,device_commands.Button_255,691,3,0.5,false,false,0,sounds.sound_sw2) -- C-101CC elements["PNT-SCAR-MA-SW-CP"] = multiposition_switch(_("MASTER ARM"),0,devices.SYSTEMS,device_commands.Button_256,692,2,1.0,true,false,0,sounds.sound_sw2) -- C-101CC elements["PNT-SCAR-BA-KB-CP"] = multiposition_switch(_("BOMB ARMING SELECTOR"),0,devices.SYSTEMS,device_commands.Button_257,693,4,0.33,false,false,0,nil,true,anim_speed_default * 0.3) -- C-101CC elements["PNT-SCAR-MS-KB-CP"] = multiposition_switch(_("MODE SELECTOR"),0,devices.SYSTEMS,device_commands.Button_258,694,8,0.142,false,false,0,nil,true,anim_speed_default * 0.15) -- C-101CC elements["PNT-SCAR-RT-KB-CP"] = multiposition_switch(_("RIPPLE TIME"),0,devices.SYSTEMS,device_commands.Button_259,695,5,0.25,false,false,0,nil,true,anim_speed_default * 0.3) -- C-101CC elements["PNT-SCAR-JS-KB-CP"] = multiposition_switch(_("SELECTIVE JETTISON SELECTOR"),0,devices.SYSTEMS,device_commands.Button_260,696,4,0.33,false,false,0,nil,true,anim_speed_default * 0.5) -- C-101CC elements["PNT-SCAR-SJ-BT-CP"] = default_button(_("SELECTIVE JETTISON"),0,devices.SYSTEMS,device_commands.Button_261,697,1,{0,1},true,sounds.sound_fuel_test) -- C-101CC elements["PNT-SCAR-1P-BT-CP"] = default_button(_("PYLON SELECT #1"),0,devices.SYSTEMS,device_commands.Button_262,542,1,{0,1},true,sounds.sound_korry) -- C-101CC elements["PNT-SCAR-2P-BT-CP"] = default_button(_("PYLON SELECT #2"),0,devices.SYSTEMS,device_commands.Button_263,543,1,{0,1},true,sounds.sound_korry) -- C-101CC elements["PNT-SCAR-3P-BT-CP"] = default_button(_("PYLON SELECT #3"),0,devices.SYSTEMS,device_commands.Button_264,544,1,{0,1},true,sounds.sound_korry) -- C-101CC elements["PNT-SCAR-4P-BT-CP"] = default_button(_("PYLON SELECT #4"),0,devices.SYSTEMS,device_commands.Button_265,545,1,{0,1},true,sounds.sound_korry) -- C-101CC elements["PNT-SCAR-5P-BT-CP"] = default_button(_("PYLON SELECT #5"),0,devices.SYSTEMS,device_commands.Button_266,546,1,{0,1},true,sounds.sound_korry) -- C-101CC elements["PNT-SCAR-6P-BT-CP"] = default_button(_("PYLON SELECT #6"),0,devices.SYSTEMS,device_commands.Button_267,547,1,{0,1},true,sounds.sound_korry) -- C-101CC --== ADF ============================================================================================================================================ function ADF_freq_set_knob(hint_, seat_, command_btn1, command_btn2, command_lev) local res = { class = {class_type.BTN, class_type.BTN, class_type.LEV}, hint = _(hint_), device = devices.ADF_60, action = {command_btn1, command_btn2, command_lev}, stop_action = {command_btn1, command_btn2, 0}, arg = {0, 0, 0}, arg_value = {1, 1, 1}, arg_lim = {{0, 1}, {0, 1}, {0, 1}}, use_release_message = {true, true, false}, --animated = {false,false,false}, --animation_speed = {0, 0, 0.5}, relative = {false, false, true}, updatable = false, use_OBB = false, gain = {1.0, 1.0, 1.0}, cycle = true, } if use_seat_assignments == true then res.crew_member_access = {seat_ or 0} end return res end local ADF_freq_set_hint = "frequency selector: mousewheel - middle knob, left+mousewheel - lower knob, right+mousewheel - upper knob" elements["PNT-ADF-1-RP"] = ADF_freq_set_knob("Left "..ADF_freq_set_hint, 0, device_commands.Button_1, device_commands.Button_2, device_commands.Button_3) elements["PNT-ADF-3-RP"] = ADF_freq_set_knob("Right "..ADF_freq_set_hint, 0, device_commands.Button_4, device_commands.Button_5, device_commands.Button_6) -- OFF, ANT, ADF, TEST local ADF_mod_selector_anim_speed = 1.0 elements["PNT-ADF-2-RP"] = { class = {class_type.TUMB, class_type.TUMB, class_type.LEV}, hint = _("Function Selector Switch/Gain control. Left/right mouse click to cycle selector. Rotate mouse wheel to change Gain value"), device = devices.ADF_60, action = {device_commands.Button_7, device_commands.Button_7, device_commands.Button_9}, stop_action = {device_commands.Button_8, device_commands.Button_8, device_commands.Button_9}, arg = {677, 677, 678}, arg_value = {-0.1, 0.1, 1}, arg_lim = {{0, 0.3}, {0, 0.3}, {0, 1}}, relative = {false, false, false}, gain = {1, 1, 0.1}, animated = {true, true, false}, animation_speed = {ADF_mod_selector_anim_speed, ADF_mod_selector_anim_speed, 0}, use_release_message = {true, true, false}, use_OBB = true, cycle = false, } if use_seat_assignments == true then elements["PNT-ADF-2-RP"].crew_member_access = {0} end elements["PNT-ADF-ONOFF-RP"] = multiposition_switch(_("ADF Tone Switch"), 0, devices.ADF_60, device_commands.Button_10, 679, 2, 1.0, false, false, 0, sounds.sound_knob, true, anim_speed_default * 1.5) elements["PNT-ADF-TFR-RP"] = multiposition_switch(_("Transfer Switch"), 0, devices.ADF_60, device_commands.Button_11, 680, 2, 1.0, false, true, 0, sounds.sound_knob, true, anim_speed_default) --== TELEBRIEFING =================================================================================================================================== elements["PNT-CB-TELEBRIEFING-LP"] = default_button_axis(_("TELEBRIEFING"), 0, devices.SYSTEMS, device_commands.Button_320, device_commands.Button_554, 718, 851, 1.0, 1.0, sounds.sound_fuel_test_no_axis_snd) -- LIGHT 719 --== GYRO PLATFORM CONTROL PANEL ==================================================================================================================== elements["PNT-IFF-1"] = multiposition_switch(_("Function Selector"),0,devices.SYSTEMS,device_commands.Button_321,728,3,0.5) -- arg 1305 for push, command - Button_324 elements["PNT-IFF-2"] = default_axis_limited(_("Synchnonizer and Heading Set"),0,devices.SYSTEMS,device_commands.Button_322,729,0.5) elements["PNT-IFF-3"] = default_axis_limited(_("Latitude Correction"),0,devices.SYSTEMS,device_commands.Button_323,730,0.5) elements["PNT-IFF-5"] = default_button(_("Fast Erect"),0,devices.SYSTEMS,device_commands.Button_325,732,1,{0,1},true,sounds.sound_fuel_test) elements["PNT-IFF-6"] = multiposition_switch(_("Mag Var Control"),0,devices.SYSTEMS,device_commands.Button_326,733,3,0.5) elements["PNT-IFF-7"] = multiposition_switch(_("Hemisphere Switch"),0,devices.SYSTEMS,device_commands.Button_327,734,2,1,true) --== WEAPONS BREAKERS =============================================================================================================================== elements["PNT-CB-ARM-1-LP"] = multiposition_switch(_("BREAKER PYLON OUT RIGHT"),0,devices.SYSTEMS,device_commands.Button_329,699,2,1,true) elements["PNT-CB-ARM-2-LP"] = multiposition_switch(_("BREAKER PYLON MID RIGHT"),0,devices.SYSTEMS,device_commands.Button_330,700,2,1,true) elements["PNT-CB-ARM-3-LP"] = multiposition_switch(_("BREAKER PYLON IN RIGHT"),0,devices.SYSTEMS,device_commands.Button_331,701,2,1,true) elements["PNT-CB-ARM-4-LP"] = multiposition_switch(_("BREAKER EMERG"),0,devices.SYSTEMS,device_commands.Button_332,702,2,1,true) elements["PNT-CB-ARM-5-LP"] = multiposition_switch(_("BREAKER NORMAL"),0,devices.SYSTEMS,device_commands.Button_333,703,2,1,true) --elements["PNT-CB-ARM-6-LP"] = multiposition_switch(_("BREAKER 115 VAC SIGHT"),0,devices.SYSTEMS,device_commands.Button_334,704,2,1,true) elements["PNT-CB-ARM-7-LP"] = multiposition_switch(_("BREAKER 115 VAC SIGHT"),0,devices.SYSTEMS,device_commands.Button_335,705,2,1,true) elements["PNT-CB-ARM-8-LP"] = multiposition_switch(_("BREAKER PYLON OUT LEFT"),0,devices.SYSTEMS,device_commands.Button_336,706,2,1,true) elements["PNT-CB-ARM-9-LP"] = multiposition_switch(_("BREAKER PYLON MID LEFT"),0,devices.SYSTEMS,device_commands.Button_337,707,2,1,true) elements["PNT-CB-ARM-10-LP"] = multiposition_switch(_("BREAKER PYLON IN LEFT"),0,devices.SYSTEMS,device_commands.Button_338,708,2,1,true) elements["PNT-CB-ARM-11-LP"] = multiposition_switch(_("BREAKER MACHINE GUN 1"),0,devices.SYSTEMS,device_commands.Button_339,709,2,1,true) elements["PNT-CB-ARM-12-LP"] = multiposition_switch(_("BREAKER MACHINE GUN 2"),0,devices.SYSTEMS,device_commands.Button_340,710,2,1,true) elements["PNT-CB-ARM-13-LP"] = multiposition_switch(_("BREAKER ARMING CONTROL"),0,devices.SYSTEMS,device_commands.Button_341,711,2,1,true) elements["PNT-CB-ARM-14-LP"] = multiposition_switch(_("BREAKER SIGHT CAMERA"),0,devices.SYSTEMS,device_commands.Button_342,712,2,1,true) elements["PNT-CB-UHF-RACAL"] = multiposition_switch(_("UHF RACAL"),0,devices.SYSTEMS,device_commands.Button_680,704,2,1,true) --== KNOB AOA ======================================================================================================================================= elements["PNT-AOA-IN-KB-CP"] = default_axis_limited(_("AOA INDICATOR KNOB"),0,devices.SYSTEMS,device_commands.Button_345,290,1) --== EMERGENCY FUEL ================================================================================================================================== elements["PNT-CB-FUEL-EMER-TA"] = multiposition_switch(_("EMERGENCY FUEL Cover"),0,devices.SYSTEMS,device_commands.Button_351,716,2,1.0,true,true,0,sounds.sound_cover) elements["PNT-CB-FUEL-EMER-LP"] = default_button(_("EMERGENCY FUEL Valve"),0,devices.SYSTEMS,device_commands.Button_352,715,1,{0,1},true,sounds.sound_korry) --== REGULATOR FUEL ================================================================================================================================= elements["PNT-FUEL-2-RE-CP"] = multiposition_switch(_("EMERGENCY FUEL LEVER"),0,devices.SYSTEMS,device_commands.Button_354,726,9,0.1) --== CIRCUIT BREAKERS =============================================================================================================================== -- Primary 28 DC elements["PNT-CB-10-LP"] = multiposition_switch(_("GYRO PLATFORM"),0,devices.SYSTEMS,device_commands.Button_538,436,2,1,true) elements["PNT-CB-11-LP"] = multiposition_switch(_("DME"),0,devices.SYSTEMS,device_commands.Button_539,437,2,1,true) elements["PNT-CB-12B-LP"] = multiposition_switch(_("FD BREAKER"),0,devices.SYSTEMS,device_commands.Button_291,1382,2,1,true) elements["PNT-CB-24B-LP"] = multiposition_switch(_("IFF BREAKER"),0,devices.SYSTEMS,device_commands.Button_292,1383,2,1,true) -- Secondary 28 DC elements["PNT-CB-27-LP"] = multiposition_switch(_("VHF"),0,devices.SYSTEMS,device_commands.Button_92,532,2,1,true) elements["PNT-CB-29-LP"] = multiposition_switch(_("RADIO ALTIMETER"),0,devices.SYSTEMS,device_commands.Button_540,455,2,1,true) elements["PNT-CB-39-LP"] = multiposition_switch(_("ADF DC"),0,devices.SYSTEMS,device_commands.Button_543,465,2,1,true) -- Essential 28 DC elements["PNT-CB-40-LP"] = multiposition_switch(_("U/VHF"),0,devices.SYSTEMS,device_commands.Button_95,466,2,1,true) elements["PNT-CB-43-LP"] = multiposition_switch(_("RED COCKPIT LIGHTING"),0,devices.SYSTEMS,device_commands.Button_90,469,2,1,true) elements["PNT-CB-44-LP"] = multiposition_switch(_("BACKUP ADI"),0,devices.SYSTEMS,device_commands.Button_59,470,2,1,true) elements["PNT-CB-45-LP"] = multiposition_switch(_("INTERPHONE"),0,devices.SYSTEMS,device_commands.Button_93,471,2,1,true) -- 115 AC elements["PNT-CB-31-LP"] = multiposition_switch(_("AIR DATA COMPUTER/FLIGHT DIRECTOR"),0,devices.SYSTEMS,device_commands.Button_541,457,2,1,true) elements["PNT-CB-32-LP"] = multiposition_switch(_("GYRO PLAT 115 VAC"),0,devices.SYSTEMS,device_commands.Button_542,458,2,1,true) elements["PNT-CB-33-LP"] = multiposition_switch(_("CONSOLE LIGHTS"),0,devices.SYSTEMS,device_commands.Button_99,459,2,1,true) -- 26 AC elements["PNT-CB-34-LP"] = multiposition_switch(_("VOR AC"),0,devices.SYSTEMS,device_commands.Button_78,460,2,1,true) elements["PNT-CB-35-LP"] = multiposition_switch(_("VERT GYRO"),0,devices.SYSTEMS,device_commands.Button_544,461,2,1,true) elements["PNT-CB-36-LP"] = multiposition_switch(_("HOR GYRO"),0,devices.SYSTEMS,device_commands.Button_545,462,2,1,true) elements["PNT-CB-36B-LP"] = multiposition_switch(_("ADF 26 VAC"),0,devices.SYSTEMS,device_commands.Button_293,1189,2,1,true) elements["PNT-CB-46-LP"] = multiposition_switch(_("DME 26 VAC"),0,devices.SYSTEMS,device_commands.Button_546,472,2,1,true) elements["PNT-CB-47-LP"] = multiposition_switch(_("GYRO PLAT 26 VAC"),0,devices.SYSTEMS,device_commands.Button_547,473,2,1,true) elements["PNT-CB-48-LP"] = multiposition_switch(_("FLIGHT DIRECTOR 26 VAC"),0,devices.SYSTEMS,device_commands.Button_100,474,2,1,true) elements["PNT-CB-48B-LP"] = multiposition_switch(_("ADC BREAKER"),0,devices.SYSTEMS,device_commands.Button_294,596,2,1,true) -- REAR CPT -- Primary 28 DC elements["PNT-CB-18-LP-BACK"] = multiposition_switch(_("STALL WARNING SYSTEM"),1,devices.SYSTEMS,device_commands.Button_548,903,2,1,true) --===================================================== REAR COCKPIT ONLY FUNCTIONS ================================================================= --== STALL SYSTEM =================================================================================================================================== elements["PNT-APL-TEST-CPL-BACK"] = springloaded_2pos_switch(_("STALL WARNING TEST"),1,devices.SYSTEMS,device_commands.Button_606,device_commands.Button_608,1208) elements["PNT-APR-CPL-BACK"] = multiposition_switch(_("STALL WARNING POWER"),1,devices.SYSTEMS,device_commands.Button_607,1209,2,1.0,true) ---------------------- --elements["PNT-AIRS-KNB-CP-BACK"] = default_axis(_("Airspeed Indicator Bug"),1,devices.SYSTEMS,device_commands.Button_615,803) --=================================================================================================================================================== elements["PNT-AOA-IN-KB-CP-BACK"] = default_axis_limited(_("AOA Adjust"),1,devices.SYSTEMS,device_commands.Button_653,279,1) --== EMERGENCY PITCH TRIM =========================================================================================================================== elements["PNT-EMETBREAK-LP-BACK"] = multiposition_switch(_("PITCH TRIM BREAKER"),1,devices.SYSTEMS,device_commands.Button_473,842,2,1,true) for i,o in pairs(elements) do if o.class[1] == class_type.TUMB or (o.class[2] and o.class[2] == class_type.TUMB) or (o.class[3] and o.class[3] == class_type.TUMB) then o.updatable = true o.use_OBB = true end end