Howto:Add wingmen

From FlightGear wiki
Jump to navigation Jump to search
B-29s dropping their load.

Military aircraft are rarley seen singly: they usually operate nowadays in pairs or larger formations. The pair is the basic building-block, but historically the "vic" of 3 was also used, until it was realised that this was tactically inflexible, and the pair was adopted instead. [[1]]

AIWingman is the method in FlightGear whereby one or more aircraft can be added to the main model to build up formations.

This howto will explain how to add wingmen to your model

Step 1: creating the wingman

First, you need to create a file with the extension .xml containg at least one <entry> tag with a <scenario> tag. This file can have any name you like, but MUST go into the directory AI with all the eixting scenarios. Here is an example taken from the AI/wingman_b29_demo.xml:

 <scenario>
   <entry>
     <name>Wingman-Port</name>
     <type>wingman</type>
     <model>AI/Aircraft/b29/Models/b29-wingman.xml</model>
     <speed>0</speed>
     <life>-1</life>
     <repeat>false</repeat>
     <count>1</count>
     <x-offset>-500</x-offset>
     <y-offset>-500</y-offset>  
     <z-offset>0</z-offset>
     <yaw-offset>0</yaw-offset>
     <pitch-offset>0</pitch-offset>
     <roll-offset>0</roll-offset>
     <formate>true</formate>  
     <submodels>
       <path type="string">/Aircraft/b29/b29-submodels.xml</path>
       <serviceable type="bool">true</serviceable>
     </submodels>
     <coefficients>
       <heading>5.0</heading>
       <pitch>4.0</pitch>
       <bank>4.0</bank>			
       <speed>2.5</speed>
     </coefficients>
   </entry>
 </scenario>