Jump to content
Sign in to follow this  
dnk

Stupid AI Tricks

Recommended Posts

Let's also note that the current AI scripting likely (but hardly confirmedly) is behind a large part of the performance issues players are having relating to "underutilization" (though there are other reasons as well, this seems to be the prime culprit). This really should be the #1 focus of the devs overall, not just fixing the glaring issues with realism ("bugs" here, lack of suppression, poor SA) but the performance as well (whatever's holding up the CPU's advancing of the simulation).

---------- Post added at 09:24 PM ---------- Previous post was at 09:06 PM ----------

UPDATE

Fixed: AI no longer fires on targets it does not see (but which are reported by other group members)

Someone want to check that? I'm off to bed soon.

Share this post


Link to post
Share on other sites
I think in most dev blogs the only AI changes they mentioned was the looking for wall position for cover was lessened, but all the way though Ive never really seen anything BI's end mentioning AI specific changes in these area.

I dont have Alpha but seeing as confirmation is coming from Fabrizio_T (AI Fiddler 101 :)) then its a shame things still seem to be Arma2 vanilla requiring the usual suspect mods to be ported over to get it better.

I have a question, when you get your team to form up while walking, do you still have it that the AI will lag behind or start going too far forward, so you have to stop still for them to realise, then they stop and back step into formation?

From what i can see ArmA3 AI is just ArmA2 AI, marginally improved via config fixes and tweaks.

The fact that my own ArmA2 AI mods run almost flawlessly in ArmA3 alpha (they rely on both .sqf scripting, scripted .fsm and core .fsm hooking ) sounds like a confirmation that base AI is almost the same.

Some things i've noticed:

* Enemy detection distance has improved, which is good.

* AI units sometimes enter buildings when "scared", then sit there. Mixed bag.

* AI Situational awareness is bad in CQB. Worse than ArmA2.

* AI groups have further problems in complying to their tasks / reaching next waypoints once engaged in combat.

Edited by fabrizio_T

Share this post


Link to post
Share on other sites
From what i can see ArmA3 AI is just ArmA2 AI, marginally improved via config fixes and tweaks.

Enemy detection distance has improved.

AI units now enter buildings when "scared", then sit there.

AI Situational awareness is worse in CQB.

The fact that my own ArmA2 AI mods run almost flawlessly in ArmA3 alpha (they rely on some core AI .fsm hooking ) sounds like a confirmation AI is almost the same.

Yep i got the same feeling actually. I'd be very interested in hearing someone from the A3 team unveil what are their plans considering AI.

Share this post


Link to post
Share on other sites
I have to agree that the AI needs to be the number 1 priority. It's always been the oxymoron of the arma franchise, meaning that it's always been one of the game's strong points AND it's weakest link. It seems lately that whenever BIS put out a patch for AI, however, their aiming accuracy and spotting keep improving (now to the point where it needs to be pulled back alot as default) but they don't seem to be much if any smarter than from years ago. That may not be technically correct, but I can't help but feel that is the way it seems from the "naked eye" of an average gamer.

They still don't follow orders while in Danger Mode, they still have major issues following/keeping up with you, it still takes twice as long to let them drive you around as compared to just driving yourself...these are a few of the very basics you need the AI to do very well in a game like this, but after many years still do not.

There are 3 things that BIS branded themselves upon: Huge landscapes, Dynamic AI, Plethora of drive-able vehicles. It is the combination of these 3 things that to this very day have set BIS and the Arma franchise apart from every other game...and it is also why they have attracted so many talented modders which are responsible for the game still being alive, well and even more popular 12 years after its initial inception.

While BIS has obviously been working hard on visuals and sound (which is VERY important of course) I think it's long overdue that they invest alot back into their AI. I see their AI as part of who and what they are about, it is part of their branding and needs serious consideration if it is to remain that way.

I'd like to point out that those issues actually wasn't that present in Operation Flashpoint. Soliders more consistently followed orders, they had less problems sticking to formation (unless sprinting), and they where much better drivers. I remember the tank missions in OFP, where your fellow tanks actually did drive in proper formation as long as you didn't use e speed. They also followed issued target commands much more effectively.

When I first picked up ARMA 1, I did get fed up with it pretty fast, and the reason was that the AI didn't lissen to what I told them. I mainly got the game for single player, and thus it ruined the game completely for me. It's been quite a while since OFP came out, but I still prefer it to ARMA 1. The same thing was true with ARMA II, when you told your team mates to hold fire in OFP, they held their fire. Not so in the games that came after.

The reason I guess is that OFP AI was much more based on scripts and was more rigid. I also have a feeling that it was more based around commander AI. The commander of a group made decitions, the others followed orders. While not perfect, I would say I prefer this way of doing AI than having every single AI thinking for them selves. Play any mission in Harvest red, and you'll notice that 2 of your teammates will constantly stop, take out their binos and look around before continuing to follow. Often, they do this in open ground. I just played through Harvest Red with current patches, and they still do this. It makes no sense at all.

I honestly do think the AI would benefit from being more commander oriented, following orders. The orders available to commanders could include more sub rutines, so that the AI would for instance bound, run as hell or hold fire when told to... But not being able to decide that for them selves.

I hate to fall back with an AI squad. They constantly turn around to cover eachother, even when the mission requires swift action and getting away quickly. There is currently no way of getting the AI to bugg out, and it is very frustrating.

Share this post


Link to post
Share on other sites

AI Pathfinding Causing Huge Performance Problems?

Cross posted from this thread:

http://forums.bistudio.com/showthread.php?147533-Low-CPU-utilization-amp-Low-FPS&p=2365202&viewfull=1#post2365202

Not definitively, but this is looking very likely.

My rig:

i5 3350P 3.3GHz x4 6M L2

GTS 250 1GB (POS GPU)

OCZ 2x2GB 1066 CL7 DC

WD 1TB 7200RPM (new)

Win7 64-bit

1600x900

Note that this should be highly GPU-bound, as the CPU is fairly decent for A3's needs, but the GPU sucks even on A2. The rest of the system is up to spec, with moderate RAM latency, and as much RAM as the game can handle, plus a moderate speed HDD with plenty of space and a newer 64-bit OS.

Test scenario 1:

40v40 AI, ungrouped, unarmed

each start and are given a waypoint in open country

all begin moving to waypoints without seeing opposing forces

Results:

GPU usage quickly raises to 99%, FPS steady in upper 30s, CPU usage between 40-50%

http://i482.photobucket.com/albums/rr181/davidk594/openground_zps6a7a7ade.jpg (107 kB)

Test Scenario 2:

40v40 AI, ungrouped, unarmed

each start and are given a waypoint in Agia Marina

all begin moving to waypoints without seeing opposing forces until late in test run

Results:

A very stable version of the poor performance seen in combat. AI seen bunching up on edge of a bridge and doing other stupid things.

GPU usage around 70%, as in prior combat scenarios I've done (see earlier in thread)

CPU usage more erratic, yet higher overall

FPS around 24 throughout (very similar to that seen in combat)

citystreets_zps8bb05989.jpg

Test Scenario 3:

From last week - using it for comparison

Similar amount AI in combat situation in Agia Marina, typical squads used with basic "Seek and Destroy" WPs

Longer than above 2

Results:

Obviously, was a bit more complicated, and I've already discussed it in full before - note that these are moving averages and not raw data in the picture

FPS around 24 throughout, GPU around 70%, CPU usage higher than Scenario 1 but similar to Scenario 2.

Chart-80AI_zpsda2a50f8.jpg

Conclusions:

Pretty much looks like AI pathfinding is a culprit. When in open ground, it isn't such an issue, especially for a single WP, but when the terrain gets more complex, it is clearly both causing seriously reduced performance and GPU underutilization.

The big question remains: why is this causing such a reduction in simulation speed without fully utilizing the CPU. Why is pathfinding forcing the CPU to regularly sit around and "wait" for information/threads to complete? Is it a simple matter of all AI routines being on one thread? But then why isn't at least that one core getting heavily used? All cores are roughly equal at ~50% use in my tests.

FEEDBACK TICKET

Edited by DNK

Share this post


Link to post
Share on other sites
Hi, one question about the AI on the ArmA3 Alpha... do the AI squad mates enter in formation facing the direction that theye were created?, instead form up in the told formation facing the direction that the Squad/Team Leader is facing?.

On the ArmA2, that mission where you had to try to leave the island in time... if you's ordered your AI mates to enter into Line formation... as they were created looking West, for get that formation shape looking South... you had to order 'em to enter into Column formation. Still the same on the ArmA3 Alpha?. Let's C ya

what would improve the ai in those lines is if they were less robotic and had the ability to look around independent of the direction their squad leader is looking or moving. in general, the ai needs to look around more often, and quickly, especially in combat or aware mode. and not only their heads need to rotate, but their body as well to provide proper rear security. right now if you place a guy in the editor watching one direction, he'll watch that direction forever. where's the autonomy?

you want an ai that isn't just a blank slate that requires you to micromanage everything it does. an ideal ai should do certain things naturally, and the commands will then modify or override their behavior in appropriate ways.

and i don't know about you, but i have never seen the ai move backwards on their own. i mean if you order a squad member to watch direction, then order him to move away from it, he'll have to turn around. it would be great if the direction command modified these movements and tactics. for example: commands>danger>watch direction east>move west, would cause the subject to look east while walking backwards towards the west.

Edited by seamusgod

Share this post


Link to post
Share on other sites

Very very well written guys.

There were tons of tickets in the old Arma2 Bug Tracker over at Dev-Heaven regardings this, definitely worth porting over to the new Arma3 bugtracker.

In tickets like "Self-caring for AI", SUMA himself IIRC once stated that its not easy possible to do it, it made the impression to me as if they have either no idea what we were suggesting, nor does it seems the Devs would the play often with/against AI, or they find the AI "sufficient" enough. Thats why i always suggested that we should be able to see and script a CORE AI, be able to overwrite the ArmA3 AI, because i believe we have some pretty darn smart guys here in our community that can do way better than BIS and script a AI that is design by means of logic and real world military tactics.

This is what ArmA is so desperately missing. I couldnt care less about new graphic improvements if only the AI were at least 10% more real-life like.

Share this post


Link to post
Share on other sites

AI for me, is by far the most important element in the game. It takes many, many hours to get the right ai, intelligent ai, for your game play. The main mod makers that I prefer for ai are gone from the community, but I’m really hoping there may be some new modders out there that may take up the challenge to give us great ai in Arma 3.

BIS needs to be straight here, own up and say that they are stuck where ai is concerned, possibly even not that bothered. Just give whatever is needed to let mod makers do what has been done before, so certainly its possible. The game needs great ai, or its dead in terms of SP or many smaller groups that play against ai on a regular basis.

Share this post


Link to post
Share on other sites

Yes but there are so many little tweaks that mod makers have shown they are possible with just scripting and enhance the overall feeling tremendous. For instance:

- Situational awareness or where the AI dudes are looking when standing still or moving

- stay at least crouched when advancing or fighting and stop that constant stance change every few seconds

- return fire as default setting

- etc etc etc

Share this post


Link to post
Share on other sites

One of the problems is that the AI can be very inconsistent. One moment, they'll run away from the town you're in to expose their backs to you as they run up a hill. The next, you're clearing out houses looking for any resistance left, and immediately get shot as you open the door by an OpFor survivor who has barricaded himself inside and covered the only entrance. It's really hit or miss.

Share this post


Link to post
Share on other sites
From what i can see ArmA3 AI is just ArmA2 AI, marginally improved via config fixes and tweaks.

The fact that my own ArmA2 AI mods run almost flawlessly in ArmA3 alpha (they rely on both .sqf scripting, scripted .fsm and core .fsm hooking ) sounds like a confirmation that base AI is almost the same.

Some things i've noticed:

* Enemy detection distance has improved, which is good.

* AI units sometimes enter buildings when "scared", then sit there. Mixed bag.

* AI Situational awareness is bad in CQB. Worse than ArmA2.

* AI groups have further problems in complying to their tasks / reaching next waypoints once engaged in combat.

Thanks, nice report back mate.

Well I guess it might be a worse situation if changes were allot for mods, so to mod the crap out of it again looks like the done thing and Alpha is open enough to get the mod base done for release. Then again we still have a beta and release and post patches to see anything updated.

DNK thats a great post. It seems odd when in Arma3 videos BI staff mentioned the lessening of pathfinding for AI as 2 seemed to "overlook" the map for positioning points. I would have thought this might have a been less.

Edited by mrcash2009

Share this post


Link to post
Share on other sites

My guys keep standing with their binoculars just sorta looking into hills and stuff, chillin'. Chilly.

I wish the AI was more like Ghost Recon 1, that game has some AI!

When an enemy is shot at they drop or take cover as first priority then either shoot back or they find a perfect blind spot where there's some sort of bush or other obstacle in a direct line between you and them and then they approach you.

Suddenly an ai can pop out of a bush right in front of you without you expecting it when you've been still for a while because they've been approaching you in a direct line behind some obstacle in your vision.

I also really like being smartly outflanked in video games. Always impresses me. ARMA3 AI can do it decently... if you lie still for too long in Showcase 1 suddenly you'll have a group of enemies running up your sides.

Edited by Sneakson

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×