Board index FlightGear Support

Howto wingman?

All general support: help on flying, installation, hardware, getting online etc. There are lots of users and developers to help you out.
Forum rules
In order to help you, we need to know a lot of information. Make sure to include answers to at least the following questions in your initial post.

- what OS (Windows Xp/Vista, Mac etc.) are you running?
- what FlightGear version do you use?
- what graphics card do you have?
- does the problem occur with any aircraft, at any airport?
- where did you download your aircraft/scenery from?
- is there any output printed to the console (black window)?
- copy&paste your commandline (tick the "Show commandline box on the last page of FGRun or the "Others" section on the Mac launcher).

Please report any bugs not specific to an aircraft on the issue tracker.
To run FlightGear on old computers with bad OpenGL support, please take a look at this wiki article.

Note: If you did not get a reponse, even after 7 days, you may want to check out the FlightGear mailing lists to ask your question there.

Howto wingman?

Postby F22-killed-you » Sun Nov 08, 2009 3:07 pm

Hey, could someone please tell me how to, make the wingman scenario work and how to make it into an f15c3d?

Thanks,
Swindel

ps: i have checked the Wiki, i didn't find anything, i might be too stupid :| :wink:
Google it!
Results 1 - 10 of about 351,000 for MSFS. (0.41 seconds)
Results 1 - 10 of about 6,480,000 for FlightGear. (0.07 seconds)
Results 1 - 10 of about 137,000 for Flightprosim. (0.31 seconds)
User avatar
F22-killed-you
 
Posts: 608
Joined: Sat Aug 30, 2008 8:17 am
Location: Earth

Re: Howto wingman?

Postby Farmboy » Tue Nov 10, 2009 4:45 am

- You need to copy the data folder for the aircraft you are going to use, and place the copy (with the same name) in the ai/aircraft folder. (The current ai/aircraft folder has a number of aircraft, but only what comes with FG originally) Mine looks like this. As you can see, I deleted all the files in the B-17F folder except "Models", for that is the only data used for formation. You don't need to do this, I just did it to keep the application size down in total.
Picture 16.png


- Then you need to create additional ai wingman_demo scenario files, that are aircraft specific.

- Look again at the file list in the ai folder, and you'll see wingman_demo_B17.xml, along with my other wingman demo aircraft files.
wingman_demo_:aircraft: provides one wingman to fly as a pair.
wingman2_demo_:aircraft: adds 2 additional wingman to fly a diamond pattern.
- You can choose to either either one, or both. (You need both for the diamond pattern)

Here is the text version of that file:
Note : I have not changed any text from Vivian's original, only the paths. Hence you'll see the reference to the Buccaneer.
____________

<?xml version="1.0"?>

<PropertyList>

<scenario>

<description>

Pair - non-tactical

This scenario formates 1 Buccaneer to the
parent ac at the position designated by
the x,y,z ofsets. It is automatically
included with the Bucaneer(wingman).

Note:

1. Setting life = -1 indicates that this ballistic object will
not die
4. Yaw offset should not be used for now

Vivian Meazza
</description>

<entry>
<name>Wingman-Port</name>
<type>wingman</type>
<!--<model>AI/Aircraft/B-17F/Models/B-17F.xml</model>-->
<model>AI/Aircraft/B-17F/Models/B-17F.xml</model>
<!--<model>Aircraft/B-17F/Models/B-17F.xml</model>-->
<trigger>controls/armament/station[1]/jettison-all</trigger>
<speed>0</speed>
<life>-1</life>
<repeat>false</repeat>
<count>1</count>
<x-offset>-100</x-offset>
<y-offset>-100</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>
</entry>


</scenario>

</PropertyList>
________________


Here is wingman2_demo in text -

_________________

<?xml version="1.0"?>

<PropertyList>

<scenario>

<description>

Diamond 4 - Non-tactical formation

This scenario formates 2 Buccaneers to the
parent ac at the position designated by
the x,y,z ofsets.

Use in conjunction with wingman.demo to give a Diamond 4

Note:

1. Setting life = -1 indicates that this
ballistic object will not die
2. The default value for aero-stabilzed
is false, so this must be explictly set.
3. Yaw offset should not be used for now

Vivian Meazza
</description>

<entry>
<name>Wingman-Stbd</name>
<type>wingman</type>
<model>AI/Aircraft/B-17F/Models/B-17F.xml</model>
<life>-1</life>
<repeat>false</repeat>
<count>1</count>
<x-offset>-75</x-offset>
<y-offset>75</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>
</entry>

<entry>
<name>Wingman-Centre</name>
<type>wingman</type>
<model>AI/Aircraft/B-17F/Models/B-17F.xml</model>
<life>-1</life>
<repeat>false</repeat>
<count>1</count>
<x-offset>-150</x-offset>
<y-offset>0</y-offset>
<z-offset>0</z-offset>
<ground-offset>1.5</ground-offset>
<yaw-offset>0</yaw-offset>
<pitch-offset>0</pitch-offset>
<roll-offset>0</roll-offset>
<formate>true</formate>
</entry>

</scenario>

</PropertyList>
______________________

- Once these files are created and in place, you simply need to add what I call ai command lines. (Since I have no idea what to call them)
I use a launcher, and in my "command-line options" I add these commands.
--ai-scenario=wingman_demo_B17 --ai-scenario=wingman2_demo_B17

- Use wingman_demo for a pair, or both wingman and wingman2 for the diamond pattern.
Change these for use with other aircraft.

--ai-scenario=wingman_demo_F4 --ai-scenario=wingman2_demo_F4
--ai-scenario=wingman_demo_T2 --ai-scenario=wingman2_demo_T2

etc....
Horsepower is just an illusion. Torque is the true answer.
User avatar
Farmboy
 
Posts: 436
Joined: Wed Jan 14, 2009 10:10 pm
Location: NorthEast New York State, and the rest of New England....

Re: Howto wingman?

Postby F22-killed-you » Tue Nov 10, 2009 6:39 am

Thanks! I will definately try that! :wink:

Swindel
Google it!
Results 1 - 10 of about 351,000 for MSFS. (0.41 seconds)
Results 1 - 10 of about 6,480,000 for FlightGear. (0.07 seconds)
Results 1 - 10 of about 137,000 for Flightprosim. (0.31 seconds)
User avatar
F22-killed-you
 
Posts: 608
Joined: Sat Aug 30, 2008 8:17 am
Location: Earth

Re: Howto wingman?

Postby Farmboy » Fri Dec 04, 2009 3:52 pm

Okay, so after posting what worked for me in FG 1.9.x...... I just tried it in CVS and it's loading the demo, but not displaying the model. (Tat's 9/07/09 release) Anyone know if it is a CVS difference in the language or parameters?

Thanks,
Peter
Horsepower is just an illusion. Torque is the true answer.
User avatar
Farmboy
 
Posts: 436
Joined: Wed Jan 14, 2009 10:10 pm
Location: NorthEast New York State, and the rest of New England....

Re: Howto wingman?

Postby hellcat » Wed Jan 20, 2010 1:43 am

Like this?:
Image
Last edited by hellcat on Thu Jan 21, 2010 5:23 am, edited 1 time in total.
Current Project: Yorktown Class, Essex Class, Light & Escort carrier package
Recent Release: X-Wing (Test)
http://hhfgfs.weebly.com/index.html
User avatar
hellcat
 
Posts: 97
Joined: Thu Nov 26, 2009 6:53 am
Location: Aiea, Hawaii
Callsign: hellcat

Re: Howto wingman?

Postby BrianVanSpeybroeck » Wed Jan 20, 2010 2:06 pm

Like what? Like this: http://www.youtube.com/watch?v=Q7Rf_rChuwo

I played with it for a couple hours...it's pretty much self explainatory. Take a good look at the code in the Wingman demo and it's pretty easy to do without trying too hard. :D

Brian
Done!
BrianVanSpeybroeck
 
Posts: 498
Joined: Tue Dec 02, 2008 12:36 pm

Re: Howto wingman?

Postby swampthing » Thu Dec 19, 2019 1:15 pm

To bring a very old post back to life. Is there a way to make wingmen change liveries, have engine some and tip trail effects etc. I have some but they are just dead flying planes. They follow me around but yo have to get the screenshot just right or it looks bad only having one old smokey engine and the rest do not. Really the only purpose I think for them is to take some nice screen shots. I'm still just as lonely. So far none have talked back to me. 8)
www.opredflag.com
I have sworn upon the altar of God, eternal hostility against every form of tyranny over the mind of man. -Thomas Jefferson-
swampthing
 
Posts: 593
Joined: Wed Oct 28, 2015 4:10 am
Location: Missouri
Callsign: swamp
Version: 2018.2
OS: multiple

Re: Howto wingman?

Postby enrogue » Thu Dec 19, 2019 11:14 pm

There is/was a multiple wingman scenario for the MiG-21bis in the AI directory that I did (it's still here - https://github.com/l0k1/MiG-21bis/tree/master/AI ) - it did do multiple liveries at least but not much else as I didn't get around to it

It ties in with the wingman model here https://github.com/l0k1/MiG-21bis/blob/ ... ingman.xml
User avatar
enrogue
 
Posts: 246
Joined: Mon May 19, 2014 6:40 pm
Location: London (UK)
Callsign: enrogue
OS: Ubuntu, macOS

Re: Howto wingman?

Postby swampthing » Fri Dec 20, 2019 10:16 am

@enrogue that looks very similar to the route I took but my liveries do not change. I simply gutted the 3D interior from the model.xml for the sake of FPS and saved as a new name. https://github.com/swampmo/Jaguar/blob/ ... ingman.xml
www.opredflag.com
I have sworn upon the altar of God, eternal hostility against every form of tyranny over the mind of man. -Thomas Jefferson-
swampthing
 
Posts: 593
Joined: Wed Oct 28, 2015 4:10 am
Location: Missouri
Callsign: swamp
Version: 2018.2
OS: multiple

Re: Howto wingman?

Postby enrogue » Fri Dec 20, 2019 3:57 pm

@swamp

this is the variant code you want (it's at the end of the nasal load section)

Code: Select all
   var variant_node = root.getNode("sim/model/variant", 1);
   var name_node = root.getNode("name", 1);
   print("value of name: ", name_node.getValue());
   var variant = nil;
   var loopid = 0;
   var loop = func(id) {

      id == loopid or return;

      if(name_node.getValue()== "Red-Leader"){
         variant_node.setValue("CCCP");
      }elsif(name_node.getValue()== "Red-1"){
         variant_node.setValue("Soviet");
      }elsif(name_node.getValue()== "Red-2"){
         variant_node.setValue("USSR");
      }elsif(name_node.getValue()== "Red-3"){
         variant_node.setValue("MiG-21-93");
      }

      var v = variant_node.getValue();

      if (v != nil ) {
         variant = v;
         v = "Aircraft/MiG-21bis/Models/Liveries/" ~ variant ~ ".xml";
         fgcommand("loadxml", props.Node.new({ filename: v, targetnode: root.getPath() }));
      }
   }

   loop(loopid);


It ties to the <name> given to the AI entry in the AI xml:

Code: Select all
      <entry>
         <name>Red-3</name>
         <callsign>Red-3</callsign>
         <type>wingman</type>
         <model>Aircraft/MiG-21bis/Models/MiG-21bis-Wingman.xml</model>
         <x-offset>-35</x-offset>
         <y-offset>-63</y-offset>
         <z-offset>0</z-offset>
         <formate>true</formate>
         <max-speed-kts>500</max-speed-kts>
         <coefficients>
            <heading>5.0</heading>
            <pitch>4.0</pitch>
            <bank>4.0</bank>
            <speed>2.5</speed>
         </coefficients>
      </entry>


variant has to be a part of the path name (without the .xml)
User avatar
enrogue
 
Posts: 246
Joined: Mon May 19, 2014 6:40 pm
Location: London (UK)
Callsign: enrogue
OS: Ubuntu, macOS

Re: Howto wingman?

Postby swampthing » Fri Dec 20, 2019 9:22 pm

I'll try it out. Thanks.
www.opredflag.com
I have sworn upon the altar of God, eternal hostility against every form of tyranny over the mind of man. -Thomas Jefferson-
swampthing
 
Posts: 593
Joined: Wed Oct 28, 2015 4:10 am
Location: Missouri
Callsign: swamp
Version: 2018.2
OS: multiple

Re: Howto wingman?

Postby Valafenn » Fri Jul 31, 2020 11:55 am

Hello,

Many thanks for all expalnations it works !!!
V box formation, in a 3x 3 x 3 box flight over KLAX (486 planes)
Image
edit
i'm not sure that image work, anyway, you can see the picture here https://drive.google.com/file/d/1a8x-BO ... sp=sharing
Valafenn
 
Posts: 17
Joined: Sat May 26, 2018 6:23 am


Return to Support

Who is online

Users browsing this forum: No registered users and 1 guest