Board index FlightGear Development New features

AI & MP Dogfighting now working! Bombable ships, aircraft...

Discussion and requests for new features. Please note that FlightGear developers are volunteers and may or may not be able to consider these requests.

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby Fahim Dalvi » Wed Aug 26, 2009 10:45 am

Wow! Thats Amazing!
User avatar
Fahim Dalvi
 
Posts: 1352
Joined: Sun Oct 14, 2007 2:08 pm
Location: Qatar
Callsign: Fahim
Version: 2020.3.11
OS: macOS

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby Student_Pilot_Noob » Wed Aug 26, 2009 9:25 pm

I suggest making a template directory structure and putting the files where they belong, that way all the user has to do is extract everything to the root directory of FlightGear and click YES when the warning that the folders already exist and that some files may be overwritten pops up.

Also, why don't the scenerios have descriptions? How do I actually use the scenerios?

As well, I don't understand what you mean by:

2. Aircraft files to FG/data/AI/Aircraft:

Copy the entire Fire-Particles directory to the FlightGear/data/AI/Aircraft. Do the same with all the aircraft subdirectories, including M1-Abrams, jeep-bombable, ferry-bombable, c172-bombable, A-10-bombable, etc.


Am I supposed to just add the folders to ai/aircraft or am I supposed to find the folder for the plane named in the folder and extract it inside the plane's AI folder.

Example: Place the CONTENTS of c172_bombable inside the c172 folder inside ai/aircraft, or just place c172_bombable inside ai/aircraft?
Student_Pilot_Noob
 
Posts: 82
Joined: Wed Aug 26, 2009 2:35 am

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby Fahim Dalvi » Thu Aug 27, 2009 8:26 am

Hi,

I Have Already Given him a similar Package, Hope he Uploads it soon!
User avatar
Fahim Dalvi
 
Posts: 1352
Joined: Sun Oct 14, 2007 2:08 pm
Location: Qatar
Callsign: Fahim
Version: 2020.3.11
OS: macOS

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby 2011futuremarine » Thu Aug 27, 2009 2:22 pm

The one with the sopwith camel looks fabulous...if there was only some way to enable it over mp :)
Aircraft: primarily military
User avatar
2011futuremarine
 
Posts: 969
Joined: Thu Jun 05, 2008 9:19 pm
Location: USA
Callsign: Dodger4

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby flug » Fri Aug 28, 2009 12:36 pm

Student_Pilot_Noob wrote:I suggest making a template directory structure and putting the files where they belong, that way all the user has to do is extract everything to the root directory of FlightGear and click YES when the warning that the folders already exist and that some files may be overwritten pops up.

Also, why don't the scenerios have descriptions? How do I actually use the scenerios?


They all have descriptions.

If all else fails, just open up those scenario XML files in a text editor & the description will be the first thing you see.

If anything, the problem is not "no description" but "WAY too much description".

You'll see when you look at one . . .
flug
 
Posts: 219
Joined: Wed Jun 17, 2009 2:06 am

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby flug » Fri Aug 28, 2009 12:38 pm

Student_Pilot_Noob wrote:As well, I don't understand what you mean by:

2. Aircraft files to FG/data/AI/Aircraft:

Copy the entire Fire-Particles directory to the FlightGear/data/AI/Aircraft. Do the same with all the aircraft subdirectories, including M1-Abrams, jeep-bombable, ferry-bombable, c172-bombable, A-10-bombable, etc.


Am I supposed to just add the folders to ai/aircraft or am I supposed to find the folder for the plane named in the folder and extract it inside the plane's AI folder.

Example: Place the CONTENTS of c172_bombable inside the c172 folder inside ai/aircraft, or just place c172_bombable inside ai/aircraft?


C172_bombable is a new aircraft, just like c172 is.

So just place the file inside ai/aircraft.

Sorry I haven't gotten the "easy install" file up yet--been too busy getting the Sopwith Camel dogfighting going . . . it's basically ready to go now.

(I hope . . . I thought that several days ago already.)
flug
 
Posts: 219
Joined: Wed Jun 17, 2009 2:06 am

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby Fahim Dalvi » Fri Aug 28, 2009 12:52 pm

Hi Flug,

I did PM you a link to an "easy-install" package, If you want I can send you the link again.

Regards,
Fahim
User avatar
Fahim Dalvi
 
Posts: 1352
Joined: Sun Oct 14, 2007 2:08 pm
Location: Qatar
Callsign: Fahim
Version: 2020.3.11
OS: macOS

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby flug » Tue Sep 01, 2009 9:09 am

OK, I've actually been working pretty hard on this over the past week. It's all been re-figured (multiple times, unfortunately for me) and now it is a really back to a pre-alpha state--I haven't even loaded in all the aircraft/scenarios to make sure they work.

Nevertheless the ones that work are really, really good.

I highly recommend the Marin County Sopwith Camel scenario and I know the San Francisco Bay Ferry Invasion works (use the A-10 aircraft).

Also dogfighting the Camels over MP is a real gas . . . it doesn't totally work (you can see the damage you are inflicting on the other person but you can't see the damage the other person is inflicting on you) but it works well enough to be a lot of fun. You just have to inform the other person via chat when you've shot them down . . .

I'll try to do testing & have all aircraft/scenarios working in a few days but in the meanwhile, if you're into the cutting edge:

http://brenthugh.com/flightgear/invasions3d.zip
Last edited by flug on Tue Sep 01, 2009 5:03 pm, edited 1 time in total.
flug
 
Posts: 219
Joined: Wed Jun 17, 2009 2:06 am

Note on dogfight with Sopwith Camel, new file

Postby flug » Tue Sep 01, 2009 9:33 am

A quick note about the new Pre-alpha release:

http://brenthugh.com/flightgear/invasions3d.zip

Note that by default it starts in "Easy Mode".

You can also select "Really Easy Mode".

If you select both, you get "Super-Duper Easy Mode".

All these modes (and other options) are selected via the "Bombable" menu.

What these do, in general, is make it both easy to hit targets and also make the damage accumulate faster.

I put these modes in place after chasing after Camels for over an hour (with the settings on a more realistic level) firing thousands of rounds, and never even getting one hit.

"This could be a little frustrating for beginners," I thought.

So I put in easy, really easy, and super-duper easy modes.

But far more interesting is what happens when you de-select the easy modes.

Based on some reading I've been doing, I feel like for the Sopwith Camels, anyway, this gives a very realistic sense of how difficult it was to shoot them down--or even get a single round into the opposing plane.

You really have to wait and be right on top of the other plane (wait til you see the whites of their eyes!) before firing and even then it likely will take multiple passes before you are really sure the other plane is disabled.

And if you try to take potshots at other planes from 500 or 1000 yards you'll find you never even land a single round. Wait until you're within 100 yards AND the other plane is directly in your sights. Then you MIGHT hit something.

Apparently a lot of novice aviators blew all their ammunition this way without ever getting anything but air--and you only have a few hundred rounds on board.

The aces, on the other hand, waited until they were close.

And the didn't give up just because they scored a hit on the other guy and he seemed to be crashing. (Lots of times this was a ruse.)

To really knock down another plane usually took several passes, shooting a lot of rounds at short range. The Red Baron described one instance where he put 500 rounds into another aircraft, following it over a period of time, to make sure it really went down.

Take a good look at this--because dogfighting with the Sopwith Camels in FlightGear, you'll need to know it:
Dicta Boelcke -- Rules of success in air combat, compiled by Hauptmann Oswald Boelcke.
flug
 
Posts: 219
Joined: Wed Jun 17, 2009 2:06 am

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby asdfasdf » Tue Sep 01, 2009 11:32 pm

Can you add the lines of code to make and object bombable to a regular aircraft to make them bombable?
asdfasdf
 
Posts: 161
Joined: Tue Aug 25, 2009 7:33 pm

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby flug » Wed Sep 02, 2009 2:23 am

asdfasdf wrote:Can you add the lines of code to make and object bombable to a regular aircraft to make them bombable?


Yes, I think so--I just haven't tried it so far because there is nothing else out there to shoot at the main aircraft so there is little reason to do so.

What I'm thinking about as a very simple solution to multi-player, is this:

1. Child AI aircraft detects hits nearby weapons hit. (Bombable already does this, thanks to the code put together by the guys who wrote the A-10 and M-1 tank.)

2. Child AI aircraft sends back the info about the hit to the parent aircraft. There are two tricks to this:

- Send the location of the hits ***relative to the child aircraft***. Then the parent aircraft, via a bombable subroutine most likely, draws the hits relative to itself and the whole "lag problem" is solved, at least as well as it can be until there actually is no more lag to deal with.

- In multiplayer, the parent aircraft can communicate with the child but the child can't send anything back to the parent. So either our programmers will have to add that capability to FG (multiplayer child aircraft send data back to the main aircraft0 or a bit of a workaround will have to be made.

3. Then the parent aircraft calculates its own damage value based on the location of the hit in relation to itself and the size of the armament. This is what bombable does already and what would transfer over directly to the main parent (ie, non-AI) aircraft.

4. Then the parent aircraft transmits the aircraft damage level & other parameters (on fire, smoking, etc.) to the child AI aircraft which then displays the same characteristics.

All that is fairly simple in principle but I don't have time to do it right now--I'll be lucky to get a semi-bug-free version out of what we have bitten off already.
flug
 
Posts: 219
Joined: Wed Jun 17, 2009 2:06 am

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby flug » Wed Sep 02, 2009 2:29 am

What I'm thinking about as a very simple solution to multi-player, is this:


By the way an even simpler version of the above would be to have the child aircraft send any damage level increases back to the main craft. Through bombable, the child craft is already detecting those hits and calculating a damage level.

Then the main craft would add to the damage level and/or do things like start smoking, lose control of the controls or engine power at a certain point.

Not total realism by any means but it would be very simple and starting from there could be refined as time goes on.

Damage value is just a single number so by passing one single number back from child to parent in MP you could get multiplayer dogfights working.
flug
 
Posts: 219
Joined: Wed Jun 17, 2009 2:06 am

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby flug » Wed Sep 02, 2009 2:52 am

By the way, the S.P.A.D. VII is a great choice for hunting the Sopwith Camels. The S.P.A.D is just a little faster than the Camels, making it a little easier to catch up with them.
Image (S.P.A.D VII is in the current CVS version.)
flug
 
Posts: 219
Joined: Wed Jun 17, 2009 2:06 am

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby AndersG » Wed Sep 02, 2009 3:49 pm

I think $FG_ROOT/Nasal/mp_broadcast.nas might cover your communication needs. If the attacker broadcasts a message containing callsign of target and hit details when a local hit is detected the target will receive this and can take appropriate action.
See Nasal/wildfire.nas for an example of how to use mp_broadcast.

The problem that what appears as a clear hit on the attacker's end may look like a clear miss on the target's side remains, however.

Cheers,

Anders
Callsign: SE-AG
Aircraft (uhm...): Submarine Scout, Zeppelin NT, ZF Navy free balloon, Nordstern, Hindenburg, Short Empire flying-boat, ZNP-K, North Sea class, MTB T21 class, U.S.S. Monitor, MFI-9B, Type UB I submarine, Gokstad ship, Renault FT.
AndersG
 
Posts: 2524
Joined: Wed Nov 29, 2006 10:20 am
Location: Göteborg, Sweden
Callsign: SE-AG
OS: Debian GNU Linux

Re: AI Dogfighting--new download w/bombable ships, aircraft, etc

Postby flug » Wed Sep 02, 2009 9:20 pm

AndersG wrote:I think $FG_ROOT/Nasal/mp_broadcast.nas might cover your communication needs. If the attacker broadcasts a message containing callsign of target and hit details when a local hit is detected the target will receive this and can take appropriate action.
See Nasal/wildfire.nas for an example of how to use mp_broadcast.


Aha, I was vaguely thinking of that also but having a very specific example will help a lot.

The problem that what appears as a clear hit on the attacker's end may look like a clear miss on the target's side remains, however.


Well, my (brilliant! brilliant!) solution is, simply don't show the shot itself , but only the impact. Then the person is left to guess where the shot came from.

I'm sort of joking about that but in reality, if lag is not **too** bad I'll bet it will work OK.

IRL you're not really aware of a bullet or bomb sort of slowly approaching you and getting closer then hitting. They (usually) move at such a high rate of speed that you're usually just aware of the impact, or maybe simultaneously the impact and sort of a streak leading to it.

So for instance, with a machine gun if you could show smoke from the weapon firing and then the impact points where it is hitting, that is at least 90% what you're aware of.

OTOH if lag is really bad you might have the impacts appearing in a different direction than where the gun is pointing . . . not necessarily good.

But again from the point of view of dogfighting, anyway, you really aren't trying to dodge a specific bullet, but rather you need to be aware generally that you are under fire so that you can generally take evasive action.

Knowing there are hits coming nearby is sufficient for that.

Anyway, it seems to me with a very simple way you might get 75% or 90% of a workable system going and so it's worth a try . . . getting the last 10% or 25% working really right will probably be 100X the work . . .
flug
 
Posts: 219
Joined: Wed Jun 17, 2009 2:06 am

PreviousNext

Return to New features

Who is online

Users browsing this forum: No registered users and 3 guests