Author Topic: Custom AI profile and AI classes for you  (Read 29033 times)

0 Members and 1 Guest are viewing this topic.

Offline Fury

  • The Curmudgeon
  • 213
Custom AI profile and AI classes for you
This mod has been discontinued and replaced by Blue Planet: Age of Aquarius 3.6.12 Feature Pack.


I created new AI profile and six custom AI classes for Blue Planet: War in Heaven. You can now try it out and give feedback to further improve it.
NEW! Now works as a launcher selectable mod and all but training missions of FS2 campaign have been modified to use custom AI. Enjoy!
Download custom AI

If you used older versions of this mod and extracted contents to FreeSpace2\mediavps\data, don't forget to delete following files from mediavps:
notes.txt, AI - Apocalypse.fs2, AI - But Hate the Traitor.fs2, AI - Into the Lions Den.fs2, ai.tbl, ai_profiles.tbl and turrets-obt.tbm.

Readme.txt
Quote
ai.tbl contains six custom AI classes: Rookie, Veteran, Elite, Wingman Rookie, Wingman Veteran and Wingman Elite.
ai.tbl contains most settings that affect behavior of AI pilots and overrides any values in ai_profiles.tbl.

First three are "normal" AI classes intended to replace retail AI classes for fighter and bomber class ships. I advise against using these AI classes in capital ships unless you know what you're doing.
Wingmen classes are special classes designed to not scale with difficulty level, meaning their performance should be consistent regardless of selected difficulty level.

ai_profiles.tbl contains global AI settings that are used by all AI classes, including retail ones. Most, but not all gameplay affecting changes affect turrets.

turrets-obt.tbm contains a flag to enable turrets on fighters and bombers to pick targets on their own instead of firing at pilot's current target, like capital ships do.
This table is completely optional and can be skipped if you don't like independent fighter/bomber turrets.

These tables do not have any effect on missions that do not make use of this AI profile and/or these six custom AI classes.
You need to edit existing mission(s) to use this custom AI, or create your own. Exception to this is turrets-obt.tbm, which is always in effect if it is in tables folder.

Included are all but training missions from Mediavps 3.6.10 patch that have been edited to make use of custom AI profile and AI classes.
This custom AI was not created for retail campaign mission balance in mind, these missions are only there to show how this AI performs in various situations.
To play these missions without issues, you need the latest mediavps, including patch.
http://www.hard-light.net/forums/index.php?topic=65038.0

Last but not least, to use these tables you need 3.6.11 nightly build 5641 or newer, older builds or 3.6.10 won't work.
While not required, it is highly recommended to use 3.6.11 nightly build 5720 or newer to get fixed countermeasures.
http://www.hard-light.net/forums/index.php?board=173.0

The easiest way to try this AI mod, is to extract contents of this zip-file to your FreeSpace2 folder, then select CustomAI as your mod in launcher.
When you have this selected as mod, missions containing in the zip-file replaces those in retail or mediavps and you can see custom AI in action.

Optional semi-newtonian flight model with gliding now available to retail FS2 ships. This should be used together with custom AI for AI to make proper use of it. Based on SushiGlide mod by Sushi. To use gliding, please see control config in-game. To install, install custom AI mod first and then extract contents of this mod to FreeSpace2\CustomAI\data.
Download semi-newtonian flight mod

If you had previously extracted contents of this mod to FreeSpace2\mediavps\data, don't forget to delete following files from mediavps:
newtonian-shp.tbm and velindc-sct.tbm.

Above download links are always the latest. Trouble opening 7z-files? Get 7-zip.
« Last Edit: February 21, 2010, 07:06:23 am by Fury »

 
Re: Custom AI profile and AI classes for you
Having done some testing on this initially, I have to say that it makes playing the game seem more fun.
The AI is more 'alive', it's motions more fluid and it doesn't deadlock in on a target regardless of what ever else is going on, at least not that I noticed.

The AI is more evasive and less offensive, it's a much more exciting way to go about playing with them, makes it seem much more like a proper furball you might see in a sci-fi movie than just a duking fight between ships in a game.

I've said this and other people have confirmed it so I'll say it again;
I personally find this AI slightly easier than SCP AI - However, it may be more difficult to other people (evasive flying is just target practise for me), there is a marked difference in the behaviour and personally it's very much for the better, consider it for your mods if you have a lot of fighter action (I haven't tested bomber changes yet).
Also, ships that use glide handle (AI wise) significantly better with these tables.
"Neutrality means that you don't really care, cuz the struggle goes on even when you're not there: Blind and unaware."

"We still believe in all the things that we stood by before,
and after everything we've seen here maybe even more.
I know we're not the only ones, and we were not the first,
and unapologetically we'll stand behind each word."

 

Offline General Battuta

  • Poe's Law In Action
  • 214
  • i wonder when my postcount will exceed my iq
Re: Custom AI profile and AI classes for you
Hooray!

Feel free to grab the War in Heaven AI stuff and use it for your own mods. Rising tide lifts all boats and whatnot.

 

Offline Sushi

  • Art Critic
  • 211
Re: Custom AI profile and AI classes for you
Hooray indeed. :)

Fury, I probably should have mentioned this when you were showing me these over PM, but I'll put it here since it's generally useful information that applies generally. Sorry I forgot about it.

You have to be careful with the Friendly/Hostile AI Fire Delay Scale parameters. If they're less than one, the AI can actually fire faster than is technically allowed by the ship (faster than the player). In some cases, this may be the effect you want, but it's something you definitely want to be aware of: setting those lower than 1 means the AI will "cheat" and fire faster than it should be able to.


 

Offline General Battuta

  • Poe's Law In Action
  • 214
  • i wonder when my postcount will exceed my iq
Re: Custom AI profile and AI classes for you
That could be useful.  :nervous:

 

Offline Fury

  • The Curmudgeon
  • 213
Re: Custom AI profile and AI classes for you
If they're less than one
Oops, chalk that up for my misinterpretation. Will fix it to next AI update.

 

Offline Fury

  • The Curmudgeon
  • 213
Re: Custom AI profile and AI classes for you
New edition now linked to in the first post. QuantumDelta says it's better than the first one, so hopefully you will have similar experience. It also now includes three missions from FS2 campaign to make use of new AI.

Edit: Don't forget to read notes.txt in the zip-file if you haven't already.

Edit 2: Comments would be much appreciated, it'd help to tweak this AI further. :)
« Last Edit: November 08, 2009, 11:09:46 am by Fury »

 

Offline MatthTheGeek

  • Captain Obvious
  • 212
  • Frenchie McFrenchface
Re: Custom AI profile and AI classes for you
Quote
You have to be careful with the Friendly/Hostile AI Fire Delay Scale parameters. If they're less than one, the AI can actually fire faster than is technically allowed by the ship (faster than the player). In some cases, this may be the effect you want, but it's something you definitely want to be aware of: setting those lower than 1 means the AI will "cheat" and fire faster than it should be able to.
That explains why a couple of Nephilim was able to screw up my herc with their tiny turrets :p
People are stupid, therefore anything popular is at best suspicious.

Mod management tools     -     Wiki stuff!     -     Help us help you

666maslo666: Releasing a finished product is not a good thing! It is a modern fad.

SpardaSon21: it seems like you exist in a permanent state of half-joking misanthropy

Axem: when you put it like that, i sound like an insane person

bigchunk1: it's not retarded it's american!
bigchunk1: ...

batwota: steele's maneuvering for the coup de gras
MatthTheGeek: you mispelled grâce
Awaesaar: grace
batwota: oh right :P
Darius: ah!
Darius: yes, i like that
MatthTheGeek: the way you just spelled it it means fat
Awaesaar: +accent I forgot how to keyboard
MatthTheGeek: or grease
Darius: the killing fat!
Axem: jabba does the coup de gras
MatthTheGeek: XD
Axem: bring me solo and a cookie

 

Offline Fury

  • The Curmudgeon
  • 213
Re: Custom AI profile and AI classes for you
As I wrote in notes.txt that was included in the zip-file, I recommend keep using retail AI classes in turrets rather than these custom classes. The custom classes are for pilots, not turrets. In missions I included with ai_v2.zip, turrets still use retail AI classes unless you have changed them manually. In the first AI edition I did not include any missions, so you probably had changed them yourself, assuming they in fact used custom classes.
« Last Edit: November 08, 2009, 12:58:50 pm by Fury »

 

Offline Dragon

  • Citation needed
  • 212
  • The sky is the limit.
Re: Custom AI profile and AI classes for you
Maybe it was a custom mission that used this profile.
IIRC turrets inherit ship's AI class unless stated otherwise, so it's an easy thing to oversight.

 

Offline Sushi

  • Art Critic
  • 211
Re: Custom AI profile and AI classes for you
Maybe it was a custom mission that used this profile.
IIRC turrets inherit ship's AI class unless stated otherwise, so it's an easy thing to oversight.

Yeah, and even IF stated otherwise, as far as I can tell by looking at the code. :/ Turret/subsystem AI classes don't appear to do anything based on what I see in the code, although I thought I remember someone saying they COULD see a difference. I dunno.

 

Offline General Battuta

  • Poe's Law In Action
  • 214
  • i wonder when my postcount will exceed my iq
Re: Custom AI profile and AI classes for you
Isn't there a ROF difference? It might've been a placebo thing, but I could've sworn I observed such a difference, at least in flak turrets.

 

Offline Fury

  • The Curmudgeon
  • 213
Re: Custom AI profile and AI classes for you
IIRC turrets inherit ship's AI class unless stated otherwise, so it's an easy thing to oversight.
Changing pilot AI does not affect turret AI and vice versa.

 

Offline MatthTheGeek

  • Captain Obvious
  • 212
  • Frenchie McFrenchface
Re: Custom AI profile and AI classes for you
My mistake was to change the AI class for fighters and bombers in the ship table. There turrets inherits the AI class. What I should have done is modifying the pilot class manually in each mission for bombers.
People are stupid, therefore anything popular is at best suspicious.

Mod management tools     -     Wiki stuff!     -     Help us help you

666maslo666: Releasing a finished product is not a good thing! It is a modern fad.

SpardaSon21: it seems like you exist in a permanent state of half-joking misanthropy

Axem: when you put it like that, i sound like an insane person

bigchunk1: it's not retarded it's american!
bigchunk1: ...

batwota: steele's maneuvering for the coup de gras
MatthTheGeek: you mispelled grâce
Awaesaar: grace
batwota: oh right :P
Darius: ah!
Darius: yes, i like that
MatthTheGeek: the way you just spelled it it means fat
Awaesaar: +accent I forgot how to keyboard
MatthTheGeek: or grease
Darius: the killing fat!
Axem: jabba does the coup de gras
MatthTheGeek: XD
Axem: bring me solo and a cookie

 

Offline Sushi

  • Art Critic
  • 211
Re: Custom AI profile and AI classes for you
Isn't there a ROF difference? It might've been a placebo thing, but I could've sworn I observed such a difference, at least in flak turrets.

All I know is that I've looked at the code several times to see where the turret AI class set in FRED affects anything at all, and I consistently came up with nothing. A rigorous experiment to determine The Truth is on my TODO list: probably having one ship with two otherwise identical laser turrets with different AI classes set should be enough.
I brought this up also on SCP Internal: http://www.hard-light.net/forums/index.php?topic=65611.msg1309366#msg1309366

 

Offline Fury

  • The Curmudgeon
  • 213
Re: Custom AI profile and AI classes for you
My mistake was to change the AI class for fighters and bombers in the ship table. There turrets inherits the AI class. What I should have done is modifying the pilot class manually in each mission for bombers.
Indeed. But that hints at two things as far as turrets are concerned.
1) Turrets do use $Friendly AI Fire Delay Scale and $Hostile AI Fire Delay Scale flags set in AI class.
2) Class index may not affect turret ROF as $Autoscale by AI Class Index was off.

 

Offline Fury

  • The Curmudgeon
  • 213
Re: Custom AI profile and AI classes for you
FUBAR discovered an annoying bug in ai.tbl.
Quote
12:34:55   <Fury`>: FUBAR
12:34:59   <FUBAR>: yea
12:35:09   <Fury`>: what's this about ai.tbl going bonkers when adding more than 10 classes?
12:37:33   <FUBAR>: From what I can tell the game allocates memory for 10 classes.  If you use more it adds them in blocks of 10.  Something is happening and the 11th entry causes weapons to start firing from out of range.  It seems to get worse the farther down the table you go.  So while entry 11 fires missiles with a range for 1600 at 2800 entry 21 might fire them at 3600 and entry 41 just fires at any range.
12:38:03   <FUBAR>: Guessing this is why the Minbari fighters always fired out of range as well as they are in the second group of 10.
12:38:53   <Fury`>: oh ffs
12:39:41   <Flaming_Sword>: ...
12:39:44   <Fury`>: this is serious bug
12:39:50   <Fury`>: is Sushi aware?
12:39:55   <FUBAR>: yes and no
12:40:24   <FUBAR>: yes it's serious and no Sushi doesn't know.  I think this predates Sushi's chagnes though but need to do some testing for that.
12:40:31   <Fury`>: are only secondaries affected or is there other weird behavior?
12:40:57   <FUBAR>: Primaries as well but not to the same extent. 
12:41:09   <FUBAR>: Not sure on other behavior
12:41:30   <Fury`>: so THAT'S why battuta always complaina AI firing beyond their weapons range
12:41:47   <FUBAR>: possibly

In my tables posted in this topic, this bug would affect Wingmen AI classes. But apparently classes from Coward to Elite are safe.

 

Offline Spoon

  • 212
  • ヾ(´︶`♡)ノ
Re: Custom AI profile and AI classes for you
So I was messing around with these ai changes and was wondering about 'Chance AI Has to Fire Missiles at Player'. The wiki has nothing on that. Higher value means a higher chance the ai will fire missiles at the player?
Urutorahappī!!

[02:42] <@Axem> spoon somethings wrong
[02:42] <@Axem> critically wrong
[02:42] <@Axem> im happy with these missions now
[02:44] <@Axem> well
[02:44] <@Axem> with 2 of them

 

Offline Sushi

  • Art Critic
  • 211
Re: Custom AI profile and AI classes for you
So I was messing around with these ai changes and was wondering about 'Chance AI Has to Fire Missiles at Player'. The wiki has nothing on that. Higher value means a higher chance the ai will fire missiles at the player?

More or less, the number is the chance out of 7.

Bug Wanderer for more details, and see if you can get him to document it properly on the wiki. ;)

 

Offline Spoon

  • 212
  • ヾ(´︶`♡)ノ
Re: Custom AI profile and AI classes for you
That tells me enough, thanks  :)
Urutorahappī!!

[02:42] <@Axem> spoon somethings wrong
[02:42] <@Axem> critically wrong
[02:42] <@Axem> im happy with these missions now
[02:44] <@Axem> well
[02:44] <@Axem> with 2 of them