-- ============================================================================
-- McDonnell Douglas DC-9-30 (TTJ) DCS Configuration
-- Optimized by HawaiianRyan - Dec 2025
--
-- FLIGHT MODEL CHANGELOG:
-- 1. Organization: Grouped all parameters by category (Weights, Aero, Engine, etc.).
-- 2. Thrust: Confirmed JT8D-9 specifications (64.5 kN per engine / 129 kN total).
-- 3. Drag/Lift: Refined SFM drag rise for transonic cruise (Mach 0.78).
-- 4. Fuel: Verified capacity for DC-9-30 extended range (~11,180 kg).
-- 5. Weights: Standardized MTOW to DC-9-32 specs (108k-121k lbs range).
-- 6. Lights: Lights tweaked to remove redundancy and match expectations.
-- ============================================================================

TTJ_DC_9_30 = {

    -- ========================================================================
    -- 1. GENERAL IDENTITY & VISUALS
    -- ========================================================================
    Name                    = 'TTJ_DC_9_30',
    DisplayName             = _('DC-9-30 (TTJ)'),
    date_of_introduction    = 1967.02, -- DC-9 -31 "N8918E" by Eastern Air Lines
    country_of_origin       = "USA",
    Picture                 = "TTJ_DC-9.png",
    Rate                    = "40",
    Shape                   = "TTJ_DC9_30",
    WorldID                 = WSTYPE_PLACEHOLDER,
    defFuelRatio            = 0.8, -- fuel default in fractions of the full (1.0)
    singleInFlight          = true,

    shape_table_data = {
        {
            file        = 'ttj_dc9_30';
            life        = 20;
            vis         = 3;
            desrt       = 'kc-135-oblomok';
            fire        = { 300, 2};
            username    = 'TTJ_DC_9_30';
            index       = WSTYPE_PLACEHOLDER;
            classname   = "lLandPlane";
            positioning = "BYNORMAL";
        },
        {
            name        = "kc-135-oblomok";
            file        = "kc-135-oblomok";
            fire        = { 240, 2};
        },
    },

    mapclasskey     = "P0091000029",
    attribute       = {wsType_Air, wsType_Airplane, wsType_Cruiser, WSTYPE_PLACEHOLDER, "Transports"},
    Categories      = {},

    net_animation = { --TODO full list for animation (model swapping) reflection over multiplay network
        0, 1, 2, 3, 4, 5, 6,  9, 10, 11, 12,  16,  18,  21,  68, 69,  76, 77, 
        190, 191, 192,  208, 209,  408, 
        601, -- 0=rounded tail end / 1=flat tail end
        611  -- 0=original DC-9 tailfin / 0.5=MD-87, B717 tailfin / 1=Fake BAC1-11 tailfin
    },

    -- ========================================================================
    -- 2. DIMENSIONS & WEIGHTS
    -- ========================================================================
    -- Dimensions (Corrected to DC-9-30 actuals)
    length      = 36.37,    -- 119 ft 3 in
    height      = 8.38,     -- 27 ft 6 in
    wing_span   = 28.47,    -- 93 ft 5 in
    wing_area   = 93.0,     -- 1,001 sq ft
    wing_tip_pos = {-4.60, 0.381, 14.00},

    -- Weights (kg)
    M_empty     = 25940,    -- OEW: ~57,200 lbs
    M_nominal   = 48988,    -- Standard Takeoff Weight: ~108,000 lbs
    M_max       = 54885,    -- MTOW (DC-9-32): ~121,000 lbs
    M_fuel_max  = 11180,    -- Fuel: ~24,600 lbs (3,679 gal)

    -- ========================================================================
    -- 3. PERFORMANCE SUMMARY (AI & UI)
    -- ========================================================================
    H_max           = 10668,    -- Ceiling: 35,000 ft
    V_max_sea_level = 180.0,    -- Max Speed SL: ~350 kts
    V_max_h         = 250.0,    -- Max Speed Alt: ~485 kts TAS
    V_opt           = 242.0,    -- Cruise Speed: Mach 0.78
    V_take_off      = 75.0,     -- Takeoff Speed: ~145 kts
    V_land          = 69.0,     -- Landing Speed: ~135 kts
    CAS_min         = 54.0,     -- Stall Speed (approx)
    Mach_max        = 0.84,     -- Mmo
    range           = 2800,     -- Range: ~1,500 nm (Max Payload)
    Vy_max          = 12.7,     -- Climb Rate: ~2,500 fpm

    -- ========================================================================
    -- 4. AERODYNAMICS (SFM)
    -- ========================================================================
    AOA_take_off    = 0.14,
    bank_angle_max  = 30,
    flaps_maneuver  = 0.5,
    Ny_min          = -0.5,
    Ny_max          = 2.5,
    Ny_max_e        = 3.0,
    
    SFM_Data = {
        aerodynamics = {
            Cy0         = 0.05,     -- Cambered wing lift at 0 AoA
            Mzalfa      = 4.8,      -- Pitch stability (High for T-Tail)
            Mzalfadt    = 1.0,      -- Pitch damping
            kjx         = 2.2,      -- Roll inertia
            kjz         = 0.0014,   -- Yaw inertia
            
            -- Directional Stability (Rudder)
            Czbe        = -0.018,   
            
            -- Drag Coefficients
            cx_gear     = 0.035,    -- Gear drag
            cx_flap     = 0.090,    -- Flap drag
            cy_flap     = 1.20,     -- Flap lift
            cx_brk      = 0.08,     -- Speedbrake drag

            -- Aerodynamic Coefficients Table
            -- M      Cx0      Cya     B        B4       Omxmax  Aldop   Cymax
            -- REVISION: Omxmax reduced to ~1.0-1.3 for realistic DC-9 roll rates
            
            table_data = {
				-- Aerodynamic Coefficients Table
				-- 		 M       Cx0     Cya      B        B4    Omxmax   Aldop   Cymax
				-- REVISION: Lowered Cx0/B for better cruise Cd; Cymax to 1.45 clean; minor B4 increase at transonic
				
				-- Low Speed / Takeoff
				[1]  = {0.0,   0.0200,  0.096,  0.040,   0.001,   0.4,    17.0,   1.45},
				[2]  = {0.1,   0.0200,  0.096,  0.040,   0.001,   0.6,    17.0,   1.45},
				[3]  = {0.2,   0.0205,  0.098,  0.041,   0.002,   0.8,    16.5,   1.42},
				
				-- Climb
				[4]  = {0.3,   0.0210,  0.100,  0.042,   0.004,   1.0,    16.0,   1.39},
				[5]  = {0.4,   0.0220,  0.102,  0.044,   0.008,   1.1,    15.5,   1.35},
				[6]  = {0.5,   0.0235,  0.104,  0.046,   0.015,   1.2,    15.0,   1.30},
				[7]  = {0.6,   0.0255,  0.105,  0.048,   0.025,   1.3,    14.5,   1.20},
				
				-- Cruise (Optimal M0.76 - M0.78)
				[8]  = {0.7,   0.0250,  0.105,  0.050,   0.040,   1.3,    14.0,   1.10},
				[9]  = {0.75,  0.0270,  0.104,  0.055,   0.055,   1.3,    13.5,   1.00},
				
				-- Drag Rise / MMO (M0.84)
				[10] = {0.80,  0.0300,  0.100,  0.060,   0.090,   1.2,    13.0,   0.90}, 
				[11] = {0.84,  0.0400,  0.095,  0.100,   0.160,   1.0,    12.0,   0.80}, -- MMO
				
				-- Overspeed Limits
				[12] = {0.90,  0.0650,  0.085,  0.200,   0.320,   0.8,    10.0,   0.55},
				[13] = {1.0,   0.1200,  0.070,  0.400,   0.500,   0.5,    8.0,    0.35},
			
			--[[
                -- Low Speed / Takeoff
                [1]  = {0.0,   0.0200,  0.096,  0.055,   0.001,   0.4,    17.0,   1.55},
                [2]  = {0.1,   0.0200,  0.096,  0.055,   0.001,   0.6,    17.0,   1.55},
                [3]  = {0.2,   0.0205,  0.098,  0.056,   0.002,   0.8,    16.5,   1.50},
                
                -- Climb
                [4]  = {0.3,   0.0210,  0.100,  0.058,   0.004,   1.0,    16.0,   1.45},
                [5]  = {0.4,   0.0220,  0.102,  0.060,   0.008,   1.1,    15.5,   1.40},
                [6]  = {0.5,   0.0235,  0.104,  0.063,   0.015,   1.2,    15.0,   1.35},
                [7]  = {0.6,   0.0255,  0.105,  0.066,   0.022,   1.3,    14.5,   1.25},
                
                -- Cruise (Optimal M0.76 - M0.78)
                [8]  = {0.7,   0.0280,  0.105,  0.075,   0.035,   1.3,    14.0,   1.15},
                [9]  = {0.75,  0.0320,  0.104,  0.090,   0.050,   1.3,    13.5,   1.05},
                
                -- Drag Rise / MMO (M0.84)
                [10] = {0.80,  0.0400,  0.100,  0.120,   0.080,   1.2,    13.0,   0.95}, 
                [11] = {0.84,  0.0550,  0.095,  0.200,   0.150,   1.0,    12.0,   0.85}, -- MMO
                
                -- Overspeed Limits
                [12] = {0.90,  0.0850,  0.085,  0.350,   0.300,   0.8,    10.0,   0.60},
                [13] = {1.0,   0.1400,  0.070,  0.500,   0.500,   0.5,    8.0,    0.40},
			]]
            },
        },

        engine = {
            -- Pratt & Whitney JT8D-9
            -- Total Thrust: ~129 kN (29,000 lbf)
            -- Low-bypass Turbofan (BPR ~1.0)
            Nmg         = 56.0,		-- Idle RPM %, JT8D-9: ~55% – 57% N2
			Nominal_RPM = 12000.0,
            Nominal_Fan_RPM = 8000.0,
            MinRUD      = 0,
            MaxRUD      = 1,
            MaksRUD     = 1,
            ForsRUD     = 1,
            typeng      = 4,        -- E_TURBOFAN
            hMaxEng     = 13.5,     -- Engine ceiling (km)
            dcx_eng     = 0.012,	-- CORRECTED: Engine drag coefficient (from 0.0085)
			
			-- FUEL FLOW (per engine)
			-- Matches JT8D-9 TSFC ~0.59 lb/lbf/hr static (reduced for better cruise match)
			cefor = 0.8,     -- ~0.08 kg/s per engine (Takeoff; reduced)
			cemax = 0.8,     -- ~0.04 kg/s per engine (Cruise; reduced)
			
            -- Altitude Lapse
            -- Tuned for Low-Bypass Turbofan characteristics
            dpdh_m = 3700,	 -- [N/km per engine]
            dpdh_f = 3700,

            
            table_data = {
				-- Thrust vs Mach Table (Total N for both engines)
				-- 2x 64.5 kN = 129 kN Total Static
                -- Ensures ~25kN Net Thrust at M0.78 / 30k ft
				--    Mach,    Newtons,  Newtons (Afterburner)
                [1] = {0.0,    129000,     129000}, -- Static
                [2] = {0.1,    127000,     127000},
                [3] = {0.2,    124000,     124000},
                [4] = {0.3,    120000,     120000},
                [5] = {0.4,    115000,     115000},
                [6] = {0.5,    110000,     110000},
                [7] = {0.6,    105000,     105000},
                [8] = {0.7,    100000,     100000}, -- Boosted
                [9] = {0.8,     94000,      94000}, -- Cruise Base (Net ~26kN at Alt)
                [10]= {0.9,     75000,      75000},
			},
        },
    },

    -- ========================================================================
    -- 5. PROPULSION CONFIGURATION
    -- ========================================================================
    engines_count               = 2,
    thrust_sum_max              = 13154,  	-- 2x 64.5 kN (JT8D-9) (kgf)
    thrust_sum_ab               = 13154,  	-- No Afterburner (kgf)
    average_fuel_consumption    = 0.6,		-- kg/sec total
    has_afteburner              = false,
    has_thrustReverser          = true,
    
	engines_startup_sequence 	= { 1, 0 },	-- Typical for civilian airliners
    engines_nozzles = {
        {
            pos                 = {-10.6, 0.703, -2.733},
            elevation           = 0,
            diameter            = 1.0,
            exhaust_length_ab   = 15.2,	-- Max flame length (meters)
            exhaust_length_ab_K = 0.76,	-- Flame growth coefficient
            smokiness_level     = 0.2,
			engine_number       = 1,
        },  
        {
            pos                 = {-10.6, 0.703, 2.733},
            elevation           = 0,
            diameter            = 0.89,
            exhaust_length_ab   = 15.2,	-- Max flame length (meters)
            exhaust_length_ab_K = 0.76,	-- Flame growth coefficient
            smokiness_level     = 0.2,
			engine_number       = 2,
        },
    },

    -- ========================================================================
    -- 6. LANDING GEAR & BRAKES
    -- ========================================================================
    brakeshute_name             = 0, -- No chute
    has_speedbrake              = true,
    has_differential_stabilizer = false,
	flaps_transmission          = "Hydraulic",
    undercarriage_transmission  = "Hydraulic",
	
	--[[
		tand_gear_max defines the Maximum Nose Wheel Steering Angle using the formula:
		
			tand_gear_max = math.tan(math.rad(gear_max_yaw_angle_deg))
		
		Desired Steering Angle	tand_gear_max 		Use Case
				25°					0.466			Older fighters, limited ground handling.
				30°					0.577			Standard runway operations.
				45°					1.000			High maneuverability (F-16/F-18 style NWS).
				60°					1.732			Carrier deck handling / Tight turns.
				75°					3.732			Extreme castering (rare).
	]]
	tand_gear_max	=	math.tan(math.rad(82)),
	
	
	nose_gear_pos 	= 	{15.156, -2.108, 0}, 			-- Nose gear position (ground under center of the axel: {y,z,x})
		
	main_gear_pos 	= 	{-0.814, -2.286, 2.913},		-- Main gear position (ground under center of the axel: {y,z,x})
														-- automatically mirrored
	
	nose_gear_amortizer_direct_stroke 		 =  0.0,	-- Full Strut Expansion (no weight on wheels) (arg 2)
	nose_gear_amortizer_reversal_stroke 	 = -0.15,	-- Full Strut Compression (maximum+ weight on wheels)
	nose_gear_amortizer_normal_weight_stroke = -0.03048,-- Strut Weight Compression (normal compression with weight on wheels; number is amount of "chrome showing")
	nose_gear_wheel_diameter				 =  0.9742,	-- Diameter of the nose gear wheel (meters)

	main_gear_amortizer_direct_stroke 		 =  0.0,	-- Full Strut Expansion (no weight on wheels) (args 4 and 6)
	main_gear_amortizer_reversal_stroke 	 = -0.22,	-- Full Strut Compression (maximum+ weight on wheels)
	main_gear_amortizer_normal_weight_stroke = -0.04148,-- Strut Weight Compression (normal compression with weight on wheels; number is amount of "chrome showing")
	main_gear_wheel_diameter 				 =  1.0414,	-- Diameter of the main gear wheels (meters)

    -- ========================================================================
    -- 7. SYSTEMS & CREW
    -- ========================================================================
    crew_size = 2,
    crew_members = {
        [1] = { ejection_seat_name = 0, drop_canopy_name = 0, pos = {14.33, 1.3, -0.67} },
        [2] = { ejection_seat_name = 0, drop_canopy_name = 0, pos = {14.33, 1.3,  0.67} },
    },
    
    RCS                     = 35, -- Radar Cross Section
    detection_range_max     = 35,
    radar_can_see_ground    = false,
    IR_emission_coeff       = 0.6,
    IR_emission_coeff_ab    = 0,
    tanker_type             = 0,
    is_tanker               = false,
    stores_number           = 0,
    
    CanopyGeometry = {
        azimuth = {-110.0, 110.0},
        elevation = {-30.0, 60.0},
    },

    HumanRadio = {
		frequency = 127.5,
		editable = true,
		minFrequency = 118.000,
		maxFrequency = 137.000,
		modulation = MODULATION_AM
	},

    Failures = {
        { id = 'asc',       label = _('ASC'),       enable = false, hh = 0, mm = 0, mmint = 1, prob = 100 },
        { id = 'autopilot', label = _('AUTOPILOT'), enable = false, hh = 0, mm = 0, mmint = 1, prob = 100 },
        { id = 'hydro',     label = _('HYDRO'),     enable = false, hh = 0, mm = 0, mmint = 1, prob = 100 },
        { id = 'l_engine',  label = _('L-ENGINE'),  enable = false, hh = 0, mm = 0, mmint = 1, prob = 100 },
        { id = 'r_engine',  label = _('R-ENGINE'),  enable = false, hh = 0, mm = 0, mmint = 1, prob = 100 },
    },

    Pylons = {},
    Tasks = { aircraft_task(Transport) },
    DefaultTask = aircraft_task(Nothing),

    -- ========================================================================
    -- 8. DAMAGE & VISUALS
    -- ========================================================================
    Damage = {
        [1]  = {critical_damage = 5, args = {296}},
        [2]  = {critical_damage = 5, args = {297}},
        [3]  = {critical_damage = 15, args = {65}},
        [9]  = {critical_damage = 6, args = {154}},
        [10] = {critical_damage = 6, args = {153}},
        [11] = {critical_damage = 6, args = {167}},
        [12] = {critical_damage = 6, args = {161}},
        [23] = {critical_damage = 6, args = {223}}, 
        [29] = {critical_damage = 8, args = {224}, deps_cells = {23}},
        [35] = {critical_damage = 20, args = {225}, deps_cells = {23, 29}},
        [24] = {critical_damage = 6, args = {213}},
        [30] = {critical_damage = 8, args = {214}, deps_cells = {24}},
        [36] = {critical_damage = 20, args = {215}, deps_cells = {24, 30}},
        [39] = {critical_damage = 6, args = {244}},
        [40] = {critical_damage = 6, args = {241}},
        [51] = {critical_damage = 6, args = {240}},
        [52] = {critical_damage = 6, args = {238}},
        [53] = {critical_damage = 6, args = {248}},
        [55] = {critical_damage = 20, args = {156, 159}},
        [56] = {critical_damage = 6, args = {158}},
        [57] = {critical_damage = 6, args = {157}},
        [82] = {critical_damage = 6, args = {152}},
    },

    DamageParts = {},

    fires_pos = {
        [1] =   {0, -0.88, 0},
        [2] =   {-0.93, 0, 5.74},
        [3] =   {-0.93, 0, -5.74},
        [4] =   {0.61, -0.09, 2.77},
        [5] =   {0.61, -0.09, -2.77},
        [6] =   {-7.96, 0.58, 2.74},
        [7] =   {-7.96, 0.58, -2.74},
        [8] =   {-1.65, 0.19, 8.14},
        [9] =   {-1.65, 0.19, -8.14},
        [10] =  {-3.9, 0.3, 12.87},
        [11] =  {-3.9, 0.3, -12.87},
    },
	
	-- ============================================================
	-- LIGHTS
	-- ============================================================
	
	--[[
		--------------------------------------------------------------
		------------------  HawaiianRyan overhaul  -------------------
		--------------------------------------------------------------
		DCS World\Scripts\Aircrafts\_Common\Lights.lua
		
		WOLALIGHT_STROBES          = 1		-- White strobe anti-collision lights.
		WOLALIGHT_SPOTS            = 2		-- Take-off and landing high power headlights.
		WOLALIGHT_LANDING_LIGHTS   = 2		-- Take-off and landing high power headlights.
		WOLALIGHT_NAVLIGHTS        = 3		-- P-Z colored navigation (position) wingtip lights..
		WOLALIGHT_FORMATION_LIGHTS = 4		-- Formation / Logo lights.
		WOLALIGHT_TIPS_LIGHTS      = 5		-- Helicopter-specific: rotor anti-collision tips lights.
		WOLALIGHT_TAXI_LIGHTS      = 6		-- Taxi headlights.
		WOLALIGHT_BEACONS          = 7		-- Rotary anti-collision lights.
		WOLALIGHT_CABIN_BOARDING   = 8		-- Cabin incandescence illumination.
		WOLALIGHT_CABIN_NIGHT      = 9		-- Cabin night time (UV) illumination.
		WOLALIGHT_REFUEL_LIGHTS    = 10		-- Refuel apparatus illumination.
		WOLALIGHT_PROJECTORS       = 11		-- Search lights, direction-controlled.
		WOLALIGHT_AUX_LIGHTS       = 12		-- White anti-collision strobes & others
		WOLALIGHT_IR_FORMATION     = 13		-- IR formation strips. Currently not implemented due to engine NVG limitations.
		WOLALIGHT_CABIN_WORK	   = 14		-- Flight instrument illumination of pilots
	]]
    lights_data = { typename = "collection", lights = {

		[WOLALIGHT_STROBES] = { typename = "collection",
			lights = {
				-- {typename  = "strobelight", connector =  "RED_BEACON"   ,argument =  83, 
					-- proto = lamp_prototypes.MSL_3_2, emitter_shift_x = -0.25,},
				-- {typename  = "strobelight", connector =  "RED_BEACON_2" ,argument =  83, 
					-- proto = lamp_prototypes.MSL_3_2, emitter_shift_x = -0.25,},
					
				{	-- Port wingtip, forward quarter
					typename = "Spot", position = { -4.22, 0.385, -14.01 }, -- connector = "BANO_1",
					controller = "VariablePatternStrobe", mode = "2 Flash Long",
					proto = lamp_prototypes.MPS_1, intensity_max = 400.0, period = 0.6, phase_shift = 0.0,
					direction = {azimuth = math.rad(-50.0), elevation = math.rad(0)}, angle_max = math.rad(160.0), angle_min = math.rad(0),
				},
				{	-- Port wingtip, aft facing
					typename = "Spot", position = { -4.22, 0.385, -14.01 }, -- connector = "BANO_1",
					controller = "VariablePatternStrobe", mode = "2 Flash Long",
					proto = lamp_prototypes.MPS_1, intensity_max = 400.0, period = 0.6, phase_shift = 0.0,
					direction = {azimuth = math.rad(-180.0), elevation = math.rad(0)}, angle_max = math.rad(160.0), angle_min = math.rad(0),
				},
				{	-- Starboard wingtip, forward quarter
					typename = "Spot", position = { -4.22, 0.385, 14.01 }, --connector = "BANO_2",
					controller = "VariablePatternStrobe", mode = "2 Flash Long",
					proto = lamp_prototypes.MPS_1, intensity_max = 400.0, period = 0.6, phase_shift = 0.0,
					direction = {azimuth = math.rad(50.0), elevation = math.rad(0)}, angle_max = math.rad(160.0), angle_min = math.rad(0),
				},
				{	-- Starboard wingtip, aft facing
					typename = "Spot", position = { -4.22, 0.385, 14.01 }, --connector = "BANO_2",
					controller = "VariablePatternStrobe", mode = "2 Flash Long",
					proto = lamp_prototypes.MPS_1, intensity_max = 400.0, period = 0.6, phase_shift = 0.0,
					direction = {azimuth = math.rad(180.0), elevation = math.rad(0)}, angle_max = math.rad(160.0), angle_min = math.rad(0),
				},
			},
		},
		[WOLALIGHT_BEACONS] = { typename = "collection",
			lights = {
				{typename  = "strobelight", connector =  "RED_BEACON"  ,argument =  83, 
					proto = lamp_prototypes.MSL_3_2, emitter_shift_x = -0.25, period = 4/3},
				{typename  = "strobelight", connector =  "RED_BEACON_2",argument =  83, 
					proto = lamp_prototypes.MSL_3_2, emitter_shift_x = -0.25, period = 4/3},
			},
		},
		[WOLALIGHT_NAVLIGHTS] = { typename = "collection",
			lights = {
				{
					typename = "Spot", connector = "BANO_0", dir_correction = {azimuth = math.rad(180.0)}, argument = 192,
					proto = lamp_prototypes.HS_2A, angle_max = math.rad(180.0), angle_min = math.rad(170.0),
				},
				{
					typename = "Spot", connector = "BANO_00", dir_correction = {azimuth = math.rad(180.0)},
					proto = lamp_prototypes.HS_2A, angle_max = math.rad(180.0), angle_min = math.rad(170.0),
				},
				{
					typename = "Spot", connector = "BANO_1", dir_correction = {azimuth = math.rad(-45.0), elevation = math.rad(45.0)}, argument = 190,
					proto = lamp_prototypes.BANO_7M_red,
				},
				{
					typename = "Spot", connector = "BANO_2", dir_correction = {azimuth = math.rad(45.0), elevation = math.rad(45.0)}, argument = 191,
					proto = lamp_prototypes.BANO_7M_green,
				},
				{typename = "argumentlight", argument = 68,},		-- Logo Lights ON
			},
		},
		[WOLALIGHT_FORMATION_LIGHTS] = { typename = "collection", 	-- Nav Lights always ON in flights gimick
			lights = {
				{typename = "argumentlight", argument = 192,},
				{typename = "argumentlight", argument = 190,},
				{typename = "argumentlight", argument = 191,},
				{typename  = "strobelight", connector =  "RED_BEACON"  ,argument =  83, 
					proto = lamp_prototypes.MSL_3_2, emitter_shift_x = -0.25, period = 4/3},
				{typename  = "strobelight", connector =  "RED_BEACON_2",argument =  83, 
					proto = lamp_prototypes.MSL_3_2, emitter_shift_x = -0.25, period = 4/3},
			},
		},
		[WOLALIGHT_SPOTS] = { typename = "collection",	-- Landing Lights
			lights = {
				{
					typename = "Spot", connector = "RESERV2_SPOT_PTR", dir_correction = {azimuth = math.rad(-2.0), elevation = math.rad(4.5)}, argument = 208,
					proto = lamp_prototypes.LFS_P_27_600, angle_max = math.rad(21.0), angle_min = math.rad(0),
					cool_down_t = 0.8, exposure = {{0, 0.9, 1.0}},
				},
				{
					typename = "Omni", connector = "RESERV2_SPOT_PTR", pos_correction = {0.3, 0.0, 0.0},
					proto = lamp_prototypes.LFS_P_27_600, range = 6.0,
				},
				{
					typename = "Spot", connector = "RESERV1_SPOT_PTR", dir_correction = {azimuth = math.rad(2.0), elevation = math.rad(4.5)},
					proto = lamp_prototypes.LFS_P_27_600, angle_max = math.rad(21.0), angle_min = math.rad(0),
					cool_down_t = 0.8, exposure = {{0, 0.9, 1.0}},
				},
				{
					typename = "Omni", connector = "RESERV1_SPOT_PTR", pos_correction = {0.3, 0.0, 0.0},
					proto = lamp_prototypes.LFS_P_27_600, range = 6.0,
				},
				{
					typename = "Spot", connector = "MAIN1_SPOT_PTR", dir_correction = {azimuth = math.rad(0.0), elevation = math.rad(4.0)},
					proto = lamp_prototypes.LFS_P_27_600, angle_max = math.rad(21.0), angle_min = math.rad(0), movable = true,
					cool_down_t = 0.8, exposure = {{0, 0.9, 1.0}},
				},
				{
					typename = "Omni", connector = "MAIN1_SPOT_PTR", pos_correction = {0.3, 0.0, 0.0},
					proto = lamp_prototypes.LFS_R_27_180, range = 6.0,
				},
				-- {
					-- typename = "Spot", connector = "GRD_FLL1_PTR", dir_correction = {azimuth = math.rad(-45.0), elevation = math.rad(6.0)},
					-- proto = lamp_prototypes.LFS_R_27_180, angle_max = math.rad(75), angle_min = math.rad(0),
					-- cool_down_t = 0.8, exposure = {{0, 0.9, 1.0}},
				-- },
				-- {
					-- typename = "Spot", connector = "GRD_FLL2_PTR", dir_correction = {azimuth = math.rad(45.0), elevation = math.rad(6.0)},
					-- proto = lamp_prototypes.LFS_R_27_180, angle_max = math.rad(75), angle_min = math.rad(0),
					-- cool_down_t = 0.8, exposure = {{0, 0.9, 1.0}},
				-- },
			},
		},
		[WOLALIGHT_TAXI_LIGHTS] = { typename = "collection",
			lights = {
				{
					typename = "Spot", connector = "MAIN2_SPOT_PTR", dir_correction = {azimuth = math.rad(0.0), elevation = math.rad(2.0)}, argument = 209,
					proto = lamp_prototypes.LFS_R_27_180, angle_max = math.rad(45), angle_min = math.rad(0), movable = true,
					cool_down_t = 0.8, exposure = {{0, 0.9, 1.0}},
				},
				{
					typename = "Omni", connector = "MAIN2_SPOT_PTR", pos_correction = {0.3, 0.0, 0.0},
					proto = lamp_prototypes.LFS_R_27_180, range = 6.0,
				},
				{
					typename = "Spot", connector = "GRD_FLL1_PTR", dir_correction = {azimuth = math.rad(-45.0), elevation = math.rad(6.0)},
					proto = lamp_prototypes.LFS_R_27_180, angle_max = math.rad(75), angle_min = math.rad(0),
					cool_down_t = 0.8, exposure = {{0, 0.9, 1.0}},
				},
				{
					typename = "Spot", connector = "GRD_FLL2_PTR", dir_correction = {azimuth = math.rad(45.0), elevation = math.rad(6.0)},
					proto = lamp_prototypes.LFS_R_27_180, angle_max = math.rad(75), angle_min = math.rad(0),
					cool_down_t = 0.8, exposure = {{0, 0.9, 1.0}},
				},
			},
		},
		[WOLALIGHT_CABIN_NIGHT] = { typename = "collection",
			lights = {
				{typename = "argumentlight", argument = 69,},
			},
		},
		[WOLALIGHT_AUX_LIGHTS] = { typename = "collection",
			lights = {
				{typename = "argumentlight", argument = 68,},		-- Logo Lights ON
				
				{	-- Port wingtip, forward quarter
					typename = "Spot", position = { -4.22, 0.385, -14.01 }, -- connector = "BANO_1",
					controller = "VariablePatternStrobe", mode = "2 Flash Long",
					proto = lamp_prototypes.MPS_1, intensity_max = 400.0, period = 0.6, phase_shift = 0.0,
					direction = {azimuth = math.rad(-50.0), elevation = math.rad(0)}, angle_max = math.rad(160.0), angle_min = math.rad(0),
				},
				{	-- Port wingtip, aft facing
					typename = "Spot", position = { -4.22, 0.385, -14.01 }, -- connector = "BANO_1",
					controller = "VariablePatternStrobe", mode = "2 Flash Long",
					proto = lamp_prototypes.MPS_1, intensity_max = 400.0, period = 0.6, phase_shift = 0.0,
					direction = {azimuth = math.rad(-180.0), elevation = math.rad(0)}, angle_max = math.rad(160.0), angle_min = math.rad(0),
				},
				{	-- Starboard wingtip, forward quarter
					typename = "Spot", position = { -4.22, 0.385, 14.01 }, --connector = "BANO_2",
					controller = "VariablePatternStrobe", mode = "2 Flash Long",
					proto = lamp_prototypes.MPS_1, intensity_max = 400.0, period = 0.6, phase_shift = 0.0,
					direction = {azimuth = math.rad(50.0), elevation = math.rad(0)}, angle_max = math.rad(160.0), angle_min = math.rad(0),
				},
				{	-- Starboard wingtip, aft facing
					typename = "Spot", position = { -4.22, 0.385, 14.01 }, --connector = "BANO_2",
					controller = "VariablePatternStrobe", mode = "2 Flash Long",
					proto = lamp_prototypes.MPS_1, intensity_max = 400.0, period = 0.6, phase_shift = 0.0,
					direction = {azimuth = math.rad(180.0), elevation = math.rad(0)}, angle_max = math.rad(160.0), angle_min = math.rad(0),
				},
			},
		},
	}},
}

add_aircraft(TTJ_DC_9_30)