Fulqrum Publishing Home   |   Register   |   Today Posts   |   Members   |   UserCP   |   Calendar   |   Search   |   FAQ

Go Back   Official Fulqrum Publishing forum > Fulqrum Publishing > IL-2 Sturmovik: Cliffs of Dover

IL-2 Sturmovik: Cliffs of Dover Latest instalment in the acclaimed IL-2 Sturmovik series from award-winning developer Maddox Games.

Reply
 
Thread Tools Display Modes
  #1  
Old 09-09-2011, 05:21 PM
adonys adonys is offline
Approved Member
 
Join Date: Apr 2010
Posts: 850
Default

That's exactly what we should ask for: MG to open AI over-coding in an additional dll.

Maybe then the buddye and his mates from WoV BoB 2 could help with it, or anyone else with spare time and interest.
Reply With Quote
  #2  
Old 09-09-2011, 06:12 PM
buddye buddye is offline
Approved Member
 
Join Date: May 2011
Location: South East Texas
Posts: 46
Default

I am not sure if a commercial game developer would feel comfortable releasing his product (his source code). His source is his future with respect to new products which he plans to use as a baseline for future products. A flight sim developer must sell a string of products base on his engine to make any real money these days (you do not develop a new engine for only one product).

The COD manager might be willing to assign a programmer to work with a committed team of AI testers who would test, offer suggestions, analysis, and refinements. All parties would need to understand that the project would be long term (multi-year) with updates maybe every 6 months. A new priviate forum could be used to coordinate the work (the BOBII approach).

I do not want to bore you guys with BOBII but for those interested in AI (and I understand that some players are only into MP), I will offer a document. I offer the document to show an overview of BOBII AI's the scope and complexity. Please skip it if not interested and am sorry for boring anyone.

Overview of the BOBII AI Performance and Design

The redesign of the AI Maneuver Selection

The redesign of the AI maneuver Selection Criteria was driven by the need to become more deterministic and less random in selecting AI maneuvers. I felt the need to move in this direction to improve the AI offence and defense so the AI selection software had more control. Of course there is a big danger in this strategy. We do not want BOBII to become repeatable. This will become a fine line to follow in the future and I will need both our testers and customers help and feedback.

Here is a summary of the new selection criteria design:

1. Altitude (how much altitude and rate of change)
2. Speed (how much speed, and rate of change)
3. Position of A/C to each other (none to tail, tail to tail, nose to beam, tail to beam or left, right, front, back)

To implement the new selection criteria I built a 3 X 6 matrix (a truth table) and many new programs. For each A/C (the unfriendly and the AI or the player), I designed programs to look at Altitude, Speed, and position and to first try and select the best maneuver option (aggressive or defense) based on AI skill level.

Altitude and speed can also be thought of as “energy” as altitude can be turned into speed.

The new design uses the A/C’s current position but I am thinking about implementing the A/C’s “lead” position (his future position which would be a small delta in the future).

Anyway, this new design is a long term work BOBII AI strategy (work in progress) that I can work on as I have new ideas for the AI from our testers and customers. It should position the BOBII AI design for future improvements by using more deterministic rather than random selection criteria. The goal is very simple "to improve the AI performance" and keep BOBII the best off line AI.

My gut feel based on my experience and testing is that the AI is now stronger at selecting the best/correct maneuver, avoiding bad positions (like low altitude), better at avoiding low energy, and in general a bit stronger fighter and defender. Of course, the Player will always “win” with experience/practice but if we give the player a better fight (scrap), I personally consider that real progress.

BTW, I also gave the Terminator AI a bit of boost in performance and tune-up so you might want to try it out. With the boost in Terminator performance, he was getting “cocky” so I implemented a spinout feature. The Terminator flies so close to the edge now that he has a tendency to “spinout”. This is when you can get him.

I also implemented a new AI feature called “Flying Factor (FF)”. This is the knowledge of the AI pilot to fly a given maneuver (experience) and how well the AI pilot will actually fly the given maneuver (skill). The FF is based on the Skill Level (customer selected in Instant Action Missions and software assigned in the Campaign). The Terminator AI is assigned a Skill Level of Hero2 (the highest in the game) so that is where he gets his boost in performance (edge).

AI Maneuver Selection is KEY

First, the BOBII AI has a special case for selection called “Evasive maneuver selection”. The Evasive maneuver is required when an AI is shot at (either a hit or near miss). The AI will select a defensive maneuver based on the criteria/data for both Player and enemy AI (speed, altitude, and the position of the targeting AI and the AI being targeted with respect to each other).

The first key decision to be made is to select either an aggressive or defensive maneuver. This is a complex decision based on the available information on both the Player and the Enemy AI or the friendly AI and the enemy AI. The data considered for both Player and enemy is speed, altitude, and the position of the targeting AI and the AI being targeted with respect to each other.

After selecting either an aggressive or defensive, then a random approach is used to select a category (choose good, choose bad, or choose “neither” good nor bad maneuver).

Maneuvers are then divided into three parts Climb, Horizontal, and dive for each of our categories (choose good, choose bad, and choose neither good nor bad maneuver).

The individual maneuver selection is then based on speed, altitude, and position of both the player and the enemy AI.

In BOBII we have over 80 complex maneuvers for selection (both the aggressive and defensive maneuvers) for the fighters (Spit,Hurri,109.110) and over 50 simple maneuvers for selection for the JU87 and Defiant. The following are BOBII’s complex maneuvers (each maneuver is a significant program for completing the assigned maneuver):

MANOEUVRE_SELECT
MANOEUVRE_LOOKROUND
MANOEUVRE_WELDEDWINGMAN
MANOEUVRE_BAILOUT
MANOEUVRE_TOPCOVER
MANOEUVRE_FORCETOPCOVER
MANOEUVRE_LINEABREAST
MANOEUVRE_PINCER
MANOEUVRE_MULTIWAVE
MANOEUVRE_DIVEANDZOOM
MANOEUVRE_INSIDELOOP
MANOEUVRE_LAGPURSUIT
MANOEUVRE_SPLITMANOEUVRE
MANOEUVRE_HEADON
MANOEUVRE_LINEASTERN
MANOEUVRE_VICATTACK
MANOEUVRE_BARRELROLLATTACK
MANOEUVRE_SCISSORS
MANOEUVRE_MILDSCISSORS
MANOEUVRE_TURNINGFIGHT
MANOEUVRE_SPLITS
MANOEUVRE_ZOOMANDDROP
MANOEUVRE_STRAIGHTANDLEVEL
MANOEUVRE_SPINOUT
MANOEUVRE_DIVEFORHOME
MANOEUVRE_GOHOME
MANOEUVRE_MAKEFORFRIENDLY
MANOEUVRE_MOVEAWAY
MANOEUVRE_QUICKROLL
MANOEUVRE_IMMELMANNTURN
MANOEUVRE_IMMELMANN
MANOEUVRE_STAYWITHPREY
MANOEUVRE_CLIMBFORHOME
MANOEUVRE_STRAIGHTDIVE
MANOEUVRE_OUTSIDELOOP
MANOEUVRE_SHOOTTOFRIGHTEN
MANOEUVRE_SHOOTTOOEARLY
MANOEUVRE_GAINHEIGHT
MANOEUVRE_LAGROLL
MANOEUVRE_EXTENSION
MANOEUVRE_DIVINGROLL
MANOEUVRE_REVERSETURN
MANOEUVRE_SELFASBAIT
MANOEUVRE_JINK
MANOEUVRE_BREAKTURN
MANOEUVRE_LAZYTURN
MANOEUVRE_BREAKLOW
MANOEUVRE_BREAKHIGH
MANOEUVRE_BREAK90
MANOEUVRE_BREAK180
MANOEUVRE_HIGBARRELROLL
MANOEUVRE_PANICTURN
MANOEUVRE_TURNANDRUN
MANOEUVRE_LOWALT
MANOEUVRE_ZOOM
MANOEUVRE_INTERCEPTHIGH
MANOEUVRE_INTERCEPTLOW
MANOEUVRE_GAINSPEED
MANOEUVRE_HEADONATTACK
MANOEUVRE_LUFBERRY
MANOEUVRE_STEEPDIVE
MANOEUVRE_UPANDUNDER
MANOEUVRE_STALLTURN
MANOEUVRE_SLASHINGATTACK
MANOEUVRE_CLIMBTURN
MANOEUVRE_ROLL360
MANOEUVRE_STRAFFE
MANOEUVRE_TRANSITION
MANOEUVRE_PEELOFF
MANOEUVRE_SNAPSHOT
MANOEUVRE_STAYONTAIL
MANOEUVRE_FLYTHROUGHCLOUD
MANOEUVRE_REGROUP
MANOEUVRE_DISENGAGED
MANOEUVRE_SPINRECOVERY
MANOEUVRE_COLLIDE
MANOEUVRE_LAST
MANOEUVRE_ALIGNMENT
MANOEUVRE_DROPANDZOOM
MANOEUVRE_COLLISIONAVOIDANCE
MANOEUVRE_TURNTOHDGANDPITCH
MANOEUVRE_SCREWYOUGUYSIMGOINGHOME

The AI Performance Criteria/Dependencies

Skill Level

The AI performance is dependent on AI Skill Level (which is customer selected in Instant Action and SW assigned in the campaign). BOBII AI do make mistakes (spin, crash, dumb maneuvers, bad judgment, shoot late , shoot bad, etc) which is after all very human.

The skill level of the AI is key in making decisions on about everything with respect to AI performance like (1) how well the AI fly, shoot, shoot fast, slow, accuracy, or not shoot, (2) how well the AI fly, what maneuvers are selected, and how well the AI will fly the chosen maneuver.

Random Numbers (Luck of the draw)

The BOBII AI A/C is also dependent on luck (specifically on random numbers). Random number decisions are coded through out the AI code. BOBII’s random approach keeps BOBII from doing the same thing each time. Even something as simple as the direction to start a maneuver (left or right), I will use a random number to decide (why hard code something when you can use a random number).


For example, most BOBII vertical maneuvers use a random number to assign a length of time to for a specific vertical maneuver (Like Zoom). The AI pilot will sometimes cut off early, or late, or somewhere in the middle. If early the maneuver may carry too much speed and if late the AI may slow down so much that control is lost (very human).

The bottom line is that the customer will always see a somewhat different maneuver (very good, good, not so good, and loss of control) both because of the random implementation and the different physic’s parameters (speed, roll, heading, pitch, and overall energy) going into each maneuver.

The very real downside of random numbers is it is very hard to test (not repeatable) and the processing power used.

Conditions

The conditions for each maneuver are always different (energy, speed, altitude, skill, damage, and enemy position). This also changes how the maneuver is performed. A damaged AI will not fly as well as an undamaged AI.
Reply With Quote
  #3  
Old 09-09-2011, 06:24 PM
adonys adonys is offline
Approved Member
 
Join Date: Apr 2010
Posts: 850
Default

I wasn't saying about them giving the code away, but just provide an AI SDK or a script mechanism similar with the one for missions in order to overwrite AI functions.
Reply With Quote
  #4  
Old 09-09-2011, 06:49 PM
nearmiss nearmiss is offline
Global Moderator
 
Join Date: Dec 2007
Posts: 1,687
Default

I'm going to sticky this thread for a few days. Give it some time for response from other members that are very interested in this topic.

Last edited by nearmiss; 09-09-2011 at 08:23 PM.
Reply With Quote
  #5  
Old 09-09-2011, 08:20 PM
baronWastelan baronWastelan is offline
Approved Member
 
Join Date: Mar 2010
Location: the future home of Starfleet Academy
Posts: 628
Default

Quote:
Originally Posted by nearmiss View Post
I'm going to sticky this thread for a few days. Give it some time for response from other members that a very interested in this topic.
GREAT idea thanks!
Reply With Quote
  #6  
Old 09-09-2011, 06:55 PM
Les Les is offline
Approved Member
 
Join Date: Feb 2009
Posts: 566
Default

Interesting insights Buddye, thanks for that.

It looks to me, as someone who has no idea of how these things really work, that you have a set of potential manouvres that are triggered by where the planes are in relation to each other and what their individual state is (damage, speed, skill level etc.) With variations in how well the manouvres are carried out also based on the planes individual state, but with some randomness thrown in as well.

In laymans terms, that would mean the more of those manouvre routines you have, and the more often the game re-calculates which routine is required under the changing circumstances, the better.

What a nightmare lol

And by that I mean, where do you set the point at which the game still remains playable and all your computing power doesn't get chewed up by calculating what the AI should do?

It's always got to be a compromise.

But even so, it's hard to accept that some of the behaviour we see in Cliffs Of Dover is the unavoidable result of making compromises to work within those fundamental computational limits.

It could be done better, right? There are ways to make the AI conform to at least a basic set of player expectations aren't there? And if those expectations were conveyed to the developers they wouldn't be too difficult to meet, would they? Just asking for your opinion based on your understanding of what's involved and what you've seen of Cliffs Of Dover in it's current state. I know you've already said the AI could be worked on endlessly and that the developers couldn't afford to do that, just wondering how far you think they might be able to get.

Last edited by Les; 09-09-2011 at 07:05 PM.
Reply With Quote
  #7  
Old 09-09-2011, 08:42 PM
buddye buddye is offline
Approved Member
 
Join Date: May 2011
Location: South East Texas
Posts: 46
Default

Quote:
Originally Posted by Les View Post

It looks to me, as someone who has no idea of how these things really work, that you have a set of potential manouvres that are triggered by where the planes are in relation to each other and what their individual state is (damage, speed, skill level etc.) With variations in how well the manouvres are carried out also based on the planes individual state, but with some randomness thrown in as well.
I think you understand the Overview of BOBII AI performance and design.

Quote:
Originally Posted by Les View Post
In laymans terms, that would mean the more of those manouvre routines you have, and the more often the game re-calculates which routine is required under the changing circumstances, the better.

What a nightmare lol
Actually, the processor requirements for the AI are very low as compaired to GFX, weather , water, and landscape which run every 40 MS or faster. Remember, it takes seconds to complete a maneuver (range of 3 to 15 seconds on average but some maneuvers take longer (some of the aggressive maneuvers). As an example, a break low maneuver takes 7 seconds. Seconds are easy for a modern PC.

Quote:
Originally Posted by Les View Post

It could be done better, right? There are ways to make the AI conform to at least a basic set of player expectations aren't there? And if those expectations were conveyed to the developers they wouldn't be too difficult to meet, would they? Just asking for your opinion based on your understanding of what's involved and what you've seen of Cliffs Of Dover in it's current state. I know you've already said the AI could be worked on endlessly and that the developers couldn't afford to do that, just wondering how far you think they might be able to get.
The COD developers are good. They can fix anything they want. Yes, they can make significant improvements to the COD AI. Right now I think it is a question of priority as they have a very long work list with higher priorities. My hope and I think some of you agree is that the Developers will agree and give higher priority to the AI performance.

Last edited by buddye; 09-09-2011 at 08:46 PM.
Reply With Quote
  #8  
Old 09-09-2011, 08:57 PM
jimbop jimbop is offline
Approved Member
 
Join Date: Jan 2011
Location: Australia
Posts: 1,064
Default

How difficult might it be to remove the flaws which make it obvious that the plane is flown by AI? E.g. the dithering you see when they can't decide which way to break.

It seems to me that there are two levels of AI improvement for CoD: the first would be to remove these aspects which really break immersion because you instantly realise that the plane is AI-flown. The second would be to turn an AI plane into a tactically strong opponent.

I hope we get some dev involvement in this thread in particular. I think CoD is heading in the right direction, especially after the last patch, but there seems to be a lot of community expertise that could be tapped. Thanks for sharing the document, buddye.
Reply With Quote
  #9  
Old 09-11-2011, 06:11 PM
Apollo11 Apollo11 is offline
Approved Member
 
Join Date: Jul 2010
Posts: 6
Default

Hi all,

Quote:
Originally Posted by buddye View Post

I do not want to bore you guys with BOBII but for those interested in AI (and I understand that some players are only into MP), I will offer a document. I offer the document to show an overview of BOBII AI's the scope and complexity.
Many thanks for this!

BTW, I remember how we tweaked the AI for F4 RPG 10+ years ago using similar techniques...


Leo "Apollo11"
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 01:26 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 2007 Fulqrum Publishing. All rights reserved.