<?xml version="1.0"?>
<!--Data from documents by schulgleiter.de and https://en.wikipedia.org/wiki/Elliotts_Primary_EoN-->

<airplane mass="265">
    <!--Glide number: 8-->
    
<!-- Approach configuration -->
<approach speed="30.55" aoa="5.2" glide-angle="7.5">
</approach>
<!--63 kts MAX-->
<!-- Cruise configuration -->
<cruise speed="55" alt="5000" glide-angle="7.125">
</cruise>

<!-- pilot's eyepoint -->
<cockpit x="2" y="0" z="0"/>

<fuselage ax="3.1557" ay="0.0" az="-0.7" bx="-2.33824" by="0.0" bz="-0.06042"
		  width="1" taper="0.28" midpoint="0.24" idrag="1" />

<wing x="1.10997" y="0.05" z="0.35758" taper="0.95" incidence="0" twist="-2.5"
	  length="5.2" chord="1.641" sweep="0" dihedral="0" >
	<stall aoa="12" width="12" peak="1.5"/>
		<flap0 start="0.512" end="0.9" lift="1.45" drag="1.3"/><!--
	<spoiler start="0.28" end="0.40" lift="-2" drag="45"/>-->
			<control-input axis="/controls/flight/aileron" control="FLAP0" split="true"/>
			<control-output control="FLAP0" side="left" prop="surface-positions/left-aileron-pos-norm"/>
			<control-output control="FLAP0" side="right" prop="surface-positions/right-aileron-pos-norm"/>
			<control-speed control="FLAP0" transition-time="0.2"/><!--
			<control-input axis="/controls/engines/engine/throttle" control="SPOILER"
			src0="0" src1="1.0"
			dst0="1.0" dst1="0"/>--><!--
	<control-output control="SPOILER" prop="/surface-positions/speedbrake-pos-norm"/>
	<control-speed  control="SPOILER" transition-time="0.5"/>-->
</wing>

<hstab x="-2.25045" y="0.0" z="0.237" taper="0.95" 
	   length="1.6" chord="0.992" sweep="0" incidence="0" effectiveness="1.8">
	<stall aoa="12" width="16" peak="1.5"/>
		<flap0 start="0.0" end="0.8" lift="1.4" drag="1.3"/>
			<control-input axis="/controls/flight/elevator" control="FLAP0"/>
			<control-input axis="/controls/flight/elevator-trim" control="FLAP0"/>
			<control-output control="FLAP0" prop="/surface-positions/elevator-pos-norm"/>
</hstab>

<vstab x="-2.726" y="0" z="-0.13381" taper="0.9" effectiveness="2.5"
	   length="1.1" chord="0.726" sweep="0">
	<stall aoa="15" width="14" peak="1.5"/>
		<flap0 start="0" end="1" lift="1.5" drag="1.35"/>
			<control-input axis="/controls/flight/rudder" square="true" control="FLAP0" invert="true"/>
			<control-input axis="/controls/flight/rudder-trim" control="FLAP0" invert="true"/>
			<control-output control="FLAP0" prop="/surface-positions/rudder-pos-norm" min="1" max="-1"/>
</vstab>


<!-- nose skid -->
<gear x="2.61709" y="0" z="-1.27664" skid="1" compression="0.1" spring="1" damp="2" 
   dfric="1.7" sfric ="1.7" >

</gear>

<!-- main skid (aft part of main skid)-->
<gear x="1.27" y="0" z="-1.3" skid="1" compression="0.1" spring="1" damp="1"
   dfric="0.7" sfric ="0.9">
</gear>

<!-- Tail Skid -->

<gear x="-2.31927" y="0" z="-0.41537" compression="0.1" dfric="1.5" sfric ="1.5" damp="2" skid="1">

</gear>

<!--right wing skid-->
<gear x="1.32932" y="-5.1" z="0.1" skid="1" compression="0.1" spring="0.9" sfric="1" dfric="1"/>

<!--lef wing skid-->
<gear x="1.32932" y="5.1" z="0.1"  skid="1" compression="0.1" spring="0.9" sfric="1" dfric="1"/>

<!--Assiting gears for ground movement-->
<gear x="1.32932" y="2" z="-1" compression=".1"
    spring="0.8" damp="1.2" sfric="0.8" dfric="0.7" skid="true">
  <control-input axis="/controls/gear/assist" control="EXTEND"/>
  <control-output control="EXTEND" prop="/gear/gear[5]/position-norm"/>
</gear>
<gear x="1.32932" y="-2" z="-1" compression=".1"
    spring="0.8" damp="1.2" sfric="0.8" dfric="0.7" skid="true">
  <control-input axis="/controls/gear/assist" control="EXTEND"/>
  <control-output control="EXTEND" prop="/gear/gear[6]/position-norm"/>
</gear>

<!-- pilot: MAX WEIGHT 90KG -->
<ballast x="2" y="0" z="-0.45" mass="170"/>

<!--Pushing/pulling the aircraft around:-->
<!--TURN, this is done by tearing the wings around-->
  <thruster x="1.32932" y="5.1" z="0.34379" vx="1" vy="-1" vz="0" thrust="100">
  <control-input axis="/controls/flight/rudder2" control="THROTTLE" src0="-1" src1="1" dst0="-1" dst1="1"/>
  </thruster>
  <thruster x="1.32932" y="-5.1" z="0.34379" vx="-1" vy="1" vz="0" thrust="100">
  <control-input axis="/controls/flight/rudder2" control="THROTTLE" src0="-1" src1="1" dst0="-1" dst1="1"/>
  </thruster>
  <!--Push/pull forward-->
  <thruster x="1.53551" y="0" z="-1.51963" vx="1" vy="0" vz="0" thrust="200">
  <control-input axis="/controls/throttle-2" control="THROTTLE"/>
  </thruster>
  <!--Push/pull backward-->
  <thruster x="1.53551" y="0" z="-1.51963" vx="-1" vy="0" vz="0" thrust="200">
      <control-input axis="/controls/throttle-reverse" control="THROTTLE"/>
  </thruster>
  <!--Hold the aircraft levelled (for takeoff-->
<!--  <thruster x="1.5"  y="10" z="0.1" vx="0" vy="1" vz="1" thrust="1">
  <control-input axis="/controls/flight/aileron2" control="THROTTLE" src0="-1" src1="-1" dst0="1" dst1="1"/>
  </thruster>
  <thruster x="1.5"  y="-10" z="0.1" vx="0" vy="1" vz="1" thrust="1">
  <control-input axis="/controls/flight/aileron2" control="THROTTLE" src0="-1" src1="1" dst0="1" dst1="-1"/>
  </thruster>-->
  
<!-- hitch -->

<hitch name="winch" x="3.2" y="0" z="-0.8">
	<tow length="51" weight-per-meter="0.1" elastic-constant="40000"  break-force="10000"/>
	<!-- 4.5mm steel wire-->
	<winch max-tow-length="1000" min-tow-length="1" initial-tow-length="1000" max-winch-speed="40" power="150" max-force="6000" />
	<control-input axis="/controls/winch/place" control="PLACEWINCH"/>
</hitch>

<hitch name="aerotow" x="3.2" y="0" z="-0.8" force-is-calculated-by-other="0">
	<tow length="60" weight-per-meter="0.035" elastic-constant="9000" break-force="10000" mp-auto-connect-period="0.0"/>
	<winch max-tow-length="1000" min-tow-length="60" initial-tow-length="60"/>
	<control-input axis="/controls/aerotow/find-aircraft" control="FINDAITOW"/>

</hitch>

</airplane>
