KoffeinFlummi / AGM

Authentic Gameplay Modification for A3 | THIS PROJECT IS NO LONGER BEING WORKED ON. ALL ISSUES AND PULL REQUESTS WILL BE IGNORED.
Other
125 stars 84 forks source link

Have AI treat itself or not depending on current behaviour #1931

Open nicolasbadano opened 9 years ago

nicolasbadano commented 9 years ago

@KGBCartman, on https://github.com/KoffeinFlummi/AGM/issues/1904#issuecomment-69205355

They take one hit and instead of shooting back, they just take a knee and start the medical animation. Maybe it would be a good idea, to combine this with the combat mode, if this is possible.

behaviour: https://community.bistudio.com/wiki/behaviour

Returns the current state of the unit: "CARELESS", "SAFE", "AWARE", "COMBAT" and "STEALTH".

Maybe not trigger heals on "COMBAT" behaviour or only do under certain conditions (e.g. damage > X, is medic, etc)

BaerMitUmlaut commented 9 years ago

Behavior doesn't change until minutes after the last enemy was seen. How about you let the AI search for cover and treat itself there? Not sure how since findCover apparently doesn't work.

nicolasbadano commented 9 years ago

Behavior doesn't change until minutes after the last enemy was seen.

I suspected as much.

How about you let the AI search for cover and treat itself there?

I think that AGM should minimize AI scripting for the moment. There are a couple of great AI frameworks in Arma 3 that might malfuction if we start giving AI to many (posibly conflicting) commands.


An alternative to behaviour may be to check the nearTargets array and only trigger heals if there are no known enemies nearby (400m ?)

BaerMitUmlaut commented 9 years ago

NearTargets might be wallhack-ish in a mission where the AI gets injured but doesn't actually see the enemies that are nearby (mines, mortars, explosive charges, etc). How about: _unit knowsAbout (side _player) < 3.5 Which value would be good has to be tweaked of course. If the unit sees no more enemies, the number decreases automatically, it's quicker than checking the behavior but not instant (unless the enemy is far away or not very visible to the unit).