	
E1B =  {
      
		Name 			= 'E1B',--AG
		DisplayName		= _('Grumman Tracer E1B Static'),--AG
        Picture 		= "E1B.png",
        Rate 			= "50",
        Shape			= "E1B",--AG	
        WorldID			=  WSTYPE_PLACEHOLDER,
				
        
	shape_table_data 	= 
	{
		{
			file  	 	= 'E1B';--AG
			life  	 	= 20; -- lifebar
			vis   	 	= 3; -- visibility gain.
			desrt    	= 'E-2C-OBLOMOK'; -- Name of destroyed object file name
			fire  	 	= { 300, 2}; 			-- Fire on the ground after destoyed: 300sec 2m
			username	= 'E1B';--AG
			index       =  WSTYPE_PLACEHOLDER;
			classname   = "lLandPlane";
			positioning = "BYNORMAL";
		},
		{
			name  		= "E-2C-OBLOMOK";
			file  		= "E-2C-OBLOMOK";
			fire  		= { 240, 2};
		},
	},

--[[	
	LandRWCategories = 
        {
            [1] = 
            {
                Name = "AircraftCarrier",
            }, -- end of [1]
        }, -- end of LandRWCategories
        TakeOffRWCategories = 
        {
            [1] = 
            {
                Name = "AircraftCarrier With Catapult",
            }, -- end of [1]
			[2] = 
            {
				Name = "AircraftCarrier With Tramplin",
            }, -- end of [2]
        }, -- end of TakeOffRWCategories	
]]	

		mapclasskey 		= "P0091000063",
	attribute  			= {wsType_Air, wsType_Airplane, wsType_Cruiser, WSTYPE_PLACEHOLDER ,
        "Aux", "Refuelable", "Datalink", "Link16"},

singleInFlight 	= false,
		
		
		M_empty		=	8618,
		M_nominal	=	12000,
		M_max		=	13155,
		M_fuel_max	=	2580,
		H_max		=	7620,
		average_fuel_consumption	=	0.05158,
		CAS_min		=	42.1844,
		V_opt		=	129.722,
		V_take_off	=	54.0167,
		V_land		=	57.6,
		has_afteburner	=	false,
		has_speedbrake	=	false,
		has_thrustReverser	=	true,
		has_differential_stabilizer = false,
		radar_can_see_ground	=	true,


		main_gear_pos = {-0.638,  0.00,   3.016},
		
		nose_gear_pos = {6.514,	  0.00,    0},


		AOA_take_off	=	0.14,
		stores_number	=	0,
		bank_angle_max	=	45,
		Ny_min			=	0,
		Ny_max			=	2.75,
		tand_gear_max	=	3.73,
		V_max_sea_level	=	145.556,
		V_max_h			=	145.556,
		tanker_type		=	0,
		wing_area		=	41.81,
		wing_span		=	21.44,
		wing_type 		= 	0,
		thrust_sum_max	=	3470,
		thrust_sum_ab	=	3470,
		Vy_max			=	10.2,
		length			=	19.73,
		height			=	6.97,
		flaps_maneuver	=	1,
		Mach_max		=	0.45,
		range			=	1350,
		crew_size		=	2,
		RCS				=	30,
		Ny_max_e		=	2.75,
		detection_range_max	=	400,
		IR_emission_coeff	=	0.5,
		IR_emission_coeff_ab	=	0,
		engines_count	=	2,
		wing_tip_pos = 	{-0.614, 0.0, 10.55},
		nose_gear_wheel_diameter	=	0.754,
		main_gear_wheel_diameter	=	0.972,
		engines_nozzles = 
		{
			[1] = 
			{
				pos = 	{-2.004,	0.438,	-3.293},
				elevation	=	0,
				diameter	=	1.085,
				exhaust_length_ab	=	8.629,
				exhaust_length_ab_K	=	0.76,
				smokiness_level     = 	0.1, 
			}, -- end of [1]
			[2] = 
			{
				pos = 	{-2.004,	0.438,	3.293},
				elevation	=	0,
				diameter	=	1.085,
				exhaust_length_ab	=	8.629,
				exhaust_length_ab_K	=	0.76,
				smokiness_level     = 	0.1, 
			}, -- end of [2]
		}, -- end of engines_nozzles
		crew_members = 
		{
			[1] = 
			{
				ejection_seat_name	=	0,
				drop_canopy_name	=	0,
				pos = 	{7.916,	0.986,	0},
			}, -- end of [1]
			[2] = 
			{
				ejection_seat_name	=	0,
				drop_canopy_name	=	0,
				pos = 	{3.949,	1.01,	0},
			}, -- end of [2]
		}, -- end of crew_members
		brakeshute_name	=	0,
		is_tanker	=	false,
		air_refuel_receptacle_pos = 	{17.3,	1.3,	0},
		fires_pos = 
		{
			[1] = 	{0.048,	1.008,	0},
			[2] = 	{0.048,	1.008,	2.322},
			[3] = 	{0.048,	1.008,	-2.322},
			[4] = 	{-0.82,	0.265,	2.774},
			[5] = 	{-0.82,	0.265,	-2.774},
			[6] = 	{-0.82,	0.255,	4.274},
			[7] = 	{-0.82,	0.255,	-4.274},
			[8] = 	{-0.267,	0.054,	3.293},
			[9] = 	{-0.267,	0.054,	-3.293},
			[10] = 	{-0.267,	0.054,	3.293},
			[11] = 	{-0.267,	0.054,	-3.293},
		}, -- end of fires_pos
		
		chaff_flare_dispenser = 
		{
			[1] = 
			{
				dir = 	{0,	-1,	0},
				pos = 	{1.158,	-1.77,	-0.967},
			}, -- end of [1]
			[2] = 
			{
				dir = 	{0,	-1,	0},
				pos = 	{1.158,	-1.77,	0.967},
			}, -- end of [2]
		}, -- end of chaff_flare_dispenser


       -- Countermeasures
passivCounterm = {
CMDS_Edit = true,
SingleChargeTotal = 240,
chaff = {default = 120, increment = 30, chargeSz = 1},
flare = {default = 60, increment = 30, chargeSz = 2}
 },
	
        CanopyGeometry = {
            azimuth = {-145.0, 145.0},
            elevation = {-50.0, 90.0}
        },

Sensors = {
RADAR = "AN/APS-138",
RWR = "Abstract RWR"
},
Countermeasures = {
ECM = "AN/ALQ-135"--f15
},
	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 },
			{ id = 'radar',  	label = _('RADAR'), 	enable = false, hh = 0, mm = 0, mmint = 1, prob = 100 },
--			{ id = 'eos',  		label = _('EOS'), 		enable = false, hh = 0, mm = 0, mmint = 1, prob = 100 },
--			{ id = 'helmet',  	label = _('HELMET'), 	enable = false, hh = 0, mm = 0, mmint = 1, prob = 100 },
			{ id = 'mlws',  	label = _('MLWS'), 		enable = false, hh = 0, mm = 0, mmint = 1, prob = 100 },
			{ id = 'rws',  		label = _('RWS'), 		enable = false, hh = 0, mm = 0, mmint = 1, prob = 100 },
			{ id = 'ecm',   	label = _('ECM'), 		enable = false, hh = 0, mm = 0, mmint = 1, prob = 100 },
			{ id = 'hud',  		label = _('HUD'), 		enable = false, hh = 0, mm = 0, mmint = 1, prob = 100 },
			{ id = 'mfd',  		label = _('MFD'), 		enable = false, hh = 0, mm = 0, mmint = 1, prob = 100 },		
	},
	
	HumanRadio = {
		frequency = 127.5,  -- Radio Freq
		editable = true,
		minFrequency = 100.000,
		maxFrequency = 156.000,
		modulation = MODULATION_AM
	},

Guns = {gun_mount("M_61", { count = 0 },{muzzle_pos = {5.00000, 0.250000, 0.000000}})--
},


	Pylons =     {

		pylon(1, 0, 0, 0, 0,
            {
                FiZ = 0,--Winkel
				FiX = 0,--Drehung
            },
            {
                --
            }
        ),
},
	
Tasks = {
      aircraft_task(CAP),
     	aircraft_task(Escort),
      aircraft_task(FighterSweep),
		aircraft_task(Intercept),
		aircraft_task(Reconnaissance),
    	aircraft_task(GroundAttack),
     	aircraft_task(CAS),
        aircraft_task(AFAC),
	    aircraft_task(RunwayAttack),
    	aircraft_task(AntishipStrike),
		aircraft_task(PinpointStrike),
		aircraft_task(SEAD),
    },	
	DefaultTask = aircraft_task(GroundAttack),	

	SFM_Data = {     --E3
	aerodynamics = 
		{
			Cy0	=	0,
			Mzalfa	=	4.355,
			Mzalfadt	=	0.8,
			kjx	=	2.75,
			kjz	=	0.00125,
			Czbe	=	-0.016,
			cx_gear	=	0.015,
			cx_flap	=	0.05,
			cy_flap	=	1,
			cx_brk	=	0.06,
			table_data = 
			{
				[1] = 	{0,	0.022,	0.117,	0.0397,	1e-006,	0.5,	30,	1.2},
				[2] = 	{0.1,	0.022,	0.117,	0.0397,	1e-006,	1,	30,	1.2},
				[3] = 	{0.2,	0.022,	0.117,	0.0397,	1e-006,	1.5,	30,	1.2},
				[4] = 	{0.3,	0.022,	0.117,	0.0397,	1e-006,	2,	30,	1.2},
				[5] = 	{0.4,	0.022,	0.117,	0.0397,	1e-006,	2.5,	30,	1.2},
				[6] = 	{0.5,	0.022,	0.117,	0.0397,	1e-006,	3,	30,	1.2},
				[7] = 	{0.6,	0.022,	0.117,	0,	0.32,	3.5,	30,	1.2},
				[8] = 	{0.7,	0.025,	0.117,	0.049,	0.9,	3.5,	28.666666666667,	1.18},
				[9] = 	{0.8,	0.034,	0.117,	0.117,	1,	3.5,	27.333333333333,	1.16},
				[10] = 	{1.05,	0.04775,	0.117,	0.186375,	0.48125,	3.5,	24,	1.11},
				[11] = 	{1.1,	0.0505,	0.117,	0.20025,	0.3775,	3.15,	18,	1.1},
				[12] = 	{1.2,	0.056,	0.117,	0.228,	0.17,	2.45,	17,	1.05},
				[13] = 	{1.3,	0.056,	0.117,	0.228,	0.17,	1.75,	16,	1},
				[14] = 	{1.5,	0.056,	0.117,	0.228,	0.17,	1.5,	13,	0.9},
				[15] = 	{1.7,	0.056,	0.117,	0.228,	0.17,	0.9,	12,	0.7},
				[16] = 	{2.2,	0.056,	0.117,	0.228,	0.17,	0.7,	9,	0.4},
				[17] = 	{3.9,	0.056,	0.117,	0.228,	0.17,	0.7,	9,	0.4},
			}, -- end of table_data
		}, -- end of aerodynamics
		engine = 
		{
			Nmg		=	65,
			MinRUD	=	0,
			MaxRUD	=	1,
			MaksRUD	=	1,
			ForsRUD	=	1,
			-- type	=	"TurboProp", 	--MQ-9 Reaper
			typeng	=	3,
			Nominal_Fan_RPM = 1396,		-- Source: https://www.smartcockpit.com/docs/Saab_340B-Powerplant.pdf
			Nominal_RPM = 22196,		-- Source: https://www.smartcockpit.com/docs/Saab_340B-Powerplant.pdf
			Startup_Prework = 20,
			hMaxEng	=	19,
			dcx_eng	=	0.0144,
			cefor 	= 0.37,
			cemax 	= 0.37,
			dpdh_m	=	6600,
			dpdh_f	=	13200,
			table_data = 
			{
				[1] = 	{0.0,	37828.8},
				[2] = 	{0.1,	37200.5},
				[3] = 	{0.2,	30990.0},
				[4] = 	{0.3,	26040.4},
				[5] = 	{0.4,	21962.6},
				[6] = 	{0.5,	17989.3},
				[7] = 	{0.6,	14665.3},
				[8] = 	{0.7,	12198.3},
				[9] = 	{0.8,	10395.6},
				[10] = 	{0.9,	8278.6},
			}, -- end of table_data
		}, -- end of engine
	},


	--damage , index meaning see in  Scripts\Aircrafts\_Common\Damage.lua
	Damage = {
	[0] = {critical_damage = 5, args = {82}},
	[3] = {critical_damage = 10, args = {65}},
	[8] = {critical_damage = 10},
	[11] = {critical_damage = 3},
	[12] = {critical_damage = 3},
	[15] = {critical_damage = 10},
	[16] = {critical_damage = 10},
	[17] = {critical_damage = 3},
	[18] = {critical_damage = 3},
	[25] = {critical_damage = 5, args = {53}},
	[26] = {critical_damage = 5, args = {54}},
	[35] = {critical_damage = 10, args = {67}, deps_cells = {25, 37}},
	[36] = {critical_damage = 10, args = {68}, deps_cells = {26, 38}},
	[37] = {critical_damage = 4, args = {55}},
	[38] = {critical_damage = 4, args = {56}},
	[43] = {critical_damage = 4, args = {61}, deps_cells = {53}},
	[44] = {critical_damage = 4, args = {62}, deps_cells = {54}},
	[47] = {critical_damage = 5, args = {63}, deps_cells = {51}},
	[48] = {critical_damage = 5, args = {64}, deps_cells = {52}},
	[51] = {critical_damage = 2, args = {59}},
	[52] = {critical_damage = 2, args = {60}},
	[53] = {critical_damage = 2, args = {57}},
	[54] = {critical_damage = 2, args = {58}},
	[55] = {critical_damage = 15, args = {81}},
	},
	
	DamageParts = 
	{  
		[1] = "E-2C-OBLOMOK-WING-R", -- wing R
		[2] = "E-2C-OBLOMOK-WING-L", -- wing L
--		[3] = "kc-135-oblomok-nose", -- nose
--		[4] = "kc-135-oblomok-tail", -- tail
--		[5] = "kc-135-oblomok-tail-l", -- tail
	},
	
	lights_data = {
	typename = "collection",
	lights = {
    [1] = { typename = "collection",
						lights = {-- Left Anticollision Light
								  {typename = "natostrobelight",
								   connector = "WHITE_BEACON L",
								   argument_1 = 195,
								   period = 1.2,
								   phase_shift = 0
								  },
								  -- Right Anticollision Light
								  {typename = "natostrobelight",
								   connector = "WHITE_BEACON R",
								   argument_1 = 196,
								   period = 1.2,
								   phase_shift = 0
								  },
								  -- Tail Anticollision Light
								  {typename = "natostrobelight",
								   connector = "BANO_0_BACK",
								   argument_1 = 192,
								   period = 1.2,
								   phase_shift = 0
								  }
								 }
									  },
	[2] = { typename = "collection",
							lights = {-- Landing light
									  {typename = "spotlight",
									   connector = "MAIN_SPOT_PTR_02",
									   argument = 209,
									   dir_correction = {elevation = math.rad(-1)}
									  },
									  {-- Landing/Taxi light
									   typename = "spotlight",
									   connector = "MAIN_SPOT_PTR_01",
									   argument = 208,
									   dir_correction = {elevation = math.rad(3)}
									  }
									 }
						},
    [3]	= {	typename = "collection",
								lights = {-- Left Position Light (red)
								{typename = "omnilight",
								 connector = "BANO_1",
								 color = {0.99, 0.11, 0.3},
								 pos_correction  = {0.1, 0, -0.2},
								 argument  = 190
								},
								 -- Right Position Light (green)
								{typename = "omnilight",
								connector = "BANO_2",
								color = {0, 0.894, 0.6},
								pos_correction = {0.1, 0, 0.2},
								argument  = 191
								},
								-- Tail Position Light (white)
								{typename = "omnilight",
								connector = "BANO_0",
								color = {1, 1, 1},
								pos_correction  = {0, 0, 0},
								argument  = 192
								}}
							},
--[4] = { typename = "collection", -- white strobe upper
--	        lights = {
--				     {typename = "natostrobelight",connector = "WHITE_TOP",argument_1 = 999,period = 1.0,color = {0.8, 0.8, 1.0},phase_shift = 0.0},
--				     {typename = "natostrobelight",connector = "WHITE_TOP",argument_1 = 998,period = 1.0,color = {0.8, 0.8, 1.0},phase_shift = 0.5},
--			 }
--		},
	[5]	= {typename = "collection",
			lights = {
						{typename = "collection",
						lights = {{
								-- Right Nacelle Floodlight
								typename = "spotlight",
								position  = {0.5, 1.2, 0},
								color = {1.0, 1.0, 1.0},
								intensity_max = 0.0,
								angle_max = 0.45,
								direction = {azimuth = math.rad(150), elevation = math.rad(5)},
								dont_change_color = false,
								angle_change_rate = 0
							   },
							   {
								-- Left Nacelle Floodlight
								typename = "spotlight",
								position  = {0.5, 1.2, 0},
								color = {1.0, 1.0, 1.0},
								intensity_max = 0.0,
								angle_max = 0.45,
								direction = {azimuth = math.rad(-150), elevation = math.rad(5)},
								dont_change_color = false,
								angle_change_rate = 0
							   },
							   {typename  = "argumentlight", argument = 212},
						},
					},
					{typename = "collection",
						lights = {{
								-- Left Nose Floodlight
								typename  = "spotlight",
								position  = {0, -0.3, -5.80},
								color = {1.0, 1.0, 1.0},
								intensity_max = 0.0, angle_max = 0.45,
								direction = {azimuth = math.rad(45)},
								argument = 211,
								dont_change_color = false,
								angle_change_rate = 0
							   },
							   {
								-- Right Nose Floodlight
								typename = "spotlight",
								position  = {0, -0.3, 5.80},
								color = {1.0, 1.0, 1.0},
								intensity_max = 0.0,
								angle_max = 0.45,
								direction = {azimuth = math.rad(-45)},
								argument = 210,
								dont_change_color = false,
								angle_change_rate = 0
							   }
						}
					},
					-- UARRSI light
					{
						typename = "omnilight", position  = {6.5, 0.4, 0}, color = {6, 6, 2}
					}
				  },
			}
		}
	},
}

add_aircraft(E1B)
