Jump to content
Rydygier

HETMAN - Artificial Commander

For HAC users: What is the maximum number of simultaneously used by you Leaders?  

64 members have voted

  1. 1. For HAC users: What is the maximum number of simultaneously used by you Leaders?

    • Only one
      18
    • Two
      9
    • Three
      15
    • Four of them
      0
    • Five
      6
    • Six
      0
    • Seven
      12
    • All eight!
      1


Recommended Posts

Well. HAC leaves medics their generic behavior, so until this scirpt doesn't handle also medevac vehicles and focuses on medic units only, it can be great supplement to HAC without any incorporating, just try to use both simultaneously... If it handles also medevacs - there will be option in HAC to disabling chosen kind of support, so you always may replace HAC medevac or/and logistics support with another addon/script, that is more suitable to you. Situation is similar for SLX - should work smooth & fine with HAC, I hope.

I can't try this script by Demonized, beacuse: "OA required as discovered by a Arma 2 only user."

Edited by Rydygier

Share this post


Link to post
Share on other sites

Time for another alpha tests.

HAC 1.1 alpha 2

I invite interested. General rules as previously:

http://forums.bistudio.com/showpost.php?p=2084480&postcount=218

What's new:

1. HAC takes into account more indicators when assessing whether the group is suitable for combat. Among other things, the current casualties and health status members;

2. A little fixes in the code, removed some bugs, some fixes in cargo handling system;

3. Optional reset on request;

4. An optional choice of control only ground or air transport units;

5. Current mode of control, over whole allied forces, is now optional. You can also select a mode of control over only specified units. Former "excluded" array works only with "control over all" mode;

There are three ways of determining units that are subject to the control of HAC in selective mode: using synchronization leaderHQ unit with selected team leaders, by naming of chosen team leaders "Ryd(B)" + number (1-100 default, the maximum number can be changed for example "Ryd10" or, for B side, "RydB35"), or by placing a group name in the "included" array. There is also a reversal, new "excluded" array, which works with all modes and should contain names of groups, no teamleaders names;

6. Handling of medical and logistical support. HAC will periodically checking whether any of units requires support and if necessary will send in the relevant area adequate number of support vehicles. However will not send a vehicle if he knows about enemy located within 500m from unit in need of assistance or if known enemy is too close to support units route (halfway point between support unit and target area).

Each of types of support (fuel, ammo, repair and medic) can be optionally disabled. Optionally, you can also enable extended support. In this case, support units receive SUPPORT waypoint type, which means that it may be called upon by units in need of assistance in any location on the map. In normal mode, are noticed by units in need of support up to 500 meters. Support units do not return to the starting point, but instead will stay, where they were sent, forming a kind of temporary support field base. During tests should remember that a vehicle, which is set at the beginning ammo level 0 (this setvehicleammo 0) does not "see" a small amount of ammunition (in Arma 2 1.10). Generally, units looking for support in the following circumstances (Arma2 1.10 settings, not HAC):

- fuel: when amount <= 0.1,

- ammo: < 0.2,

- repair: damage > 0.5,

- medic not tested, maybe damage > 0.1.

Priority is given to units seriously injured / damaged and those that can not move or stand. HAC makes sure not to send two support units of the same type too close together. Minimum distance, depending on the situation varies from 125 to 400 meters.

New config variables (default in quotes), as always RydHQB_ for B side:

RydHQ_ResetOnDemand (false) - if true HAC will reset some of its variables not cyclically (default each 10 minutes), but only on demand;

RydHQ_ResetNow (false) - if true and "ROD" mode is on, reset occurs and this variable is auto-reseted back to "false";

RydHQ_NoAirCargo (false) - if true, air cargo units will not be used;

RydHQ_NoLandCargo (false) - as above, for land cargo units;

RydHQ_SubAll (true) - default control mode - if true, all allied groups on the map will be controlled by HAC (minus "excluded" in old or new way);

RydHQ_SubSynchro (false) - when "all" control mode is false, and this is true, controlled by HAC will be groups, whose leaders will be synchronized with leaderHQ unit (not exclusive relative to other methods of choosing);

RydHQ_SubNamed (false) - when "all" control mode is false, and this is true, controlled by HAC will be groups, whose leaders are properly named (see above, not exclusive relative to other methods of choosing);

RydHQ_Included ([]) - when "all" control mode is false, controlled by HAC will be groups, whose name are included in this array (not exclusive relative to other methods of choosing);

RydHQ_ExcludedG ([]) - New exclusion method as above, but on the contrary, works also in "all" control mode;

RydHQ_NameLimit (100) - maximum number used in "subNamed" method;

RydHQ_ReSynchro (true) - if true, with "SubSynchro", HAC will re-synchronize with leaderHQ groups, which lost their teamleader;

RydHQ_SMed (true) - if true, medical support handling is on;

RydHQ_SFuel (true) - if true, fuel support handling is on;

RydHQ_SAmmo (true) - if true, ammo support handling is on;

RydHQ_SRep (true) - if true, repair support handling is on;

RydHQ_SupportWP (false) - if true, support is extended by SUPPORT waypoints for support units (see above).

I hope, did not forgot about something important...

Have a nice testing :)

Edited by Rydygier

Share this post


Link to post
Share on other sites
Something like that I want to do. Now this "somewhere" point I set currently near one of the units without ammunition/wounded/without fuel/damaged to make sure that HAC does not send support to a place where it is unnecessary. This support unit will stay there until it will be sent to another unit need of support. I take into account also, that would not send more than one support unit in the same area (currently up to one support of given kind in 125-250 meters radius, but it will be probably more extended) and if there are some known enemies in area (in 500 meters radius from target point and same radius from a halfway point to avoid passing a nearby enemy), support will not be sent. Of course I can simply deploy support trucks evenly behind front line too.

You can combine these methods. Normally HAC would set up "resupply base" (ammo, repair, fuel, medic) at the point where reserve forces are gathering. If HAC has more then one support vehicle of type (eg. 2xAmmo) HAC will send extra vehicles to units that need support in the field, while keeping at least one of each type at resupply base.

I did some testing: I gave orders to ambulance and ammo, repair, fuel trucks to move to point. Waypoint had disableAI "move" and once they all arrived they formed very neat resupply point. I had damaged tank drive by and the moment they got into 500m of resupply base commander ordered using support vehicles. Since support had move disabled it was very fast and neat resupply and repair. The only thing you may want to add to resupply vehicles is command to turn off the engines, AI keeps it running for some reason.

While testing this I got another idea: Rotation of forces. The idea is that HAC would rotate its forces so all units will have chance to see some action AND have chance to resupply, heal and rest.

It could look like this:

*HAC has 2 infantry units: squad A and B + some other units

*from start squad A is sent to capture town and squad B is ordered to guard its starting position

*enemy in town is destroyed, HAC orders squad A to guard its position sending squad B for next objective

*once next objective is captured HAC orders squad A to move and B to guard and so on

*if squad A spend several cycles in combat HAC may order squad B to move to squad A position

*once squad B arrives, squad A is ordered to pull out and move to resupply point

This behavior should be dependant on HAC presonality.

Share this post


Link to post
Share on other sites
Time for another alpha tests.

<snip>

I hope, did not forgot about something important...

Have a nice testing :)

Wow! That is a big list of major changes :bounce3:

Long work day ahead, but looking forward to getting to grips with this tonight.

BR

Orcinus

---------- Post added at 07:04 AM ---------- Previous post was at 06:49 AM ----------

Well. HAC leaves medics their generic behavior, so until this scirpt doesn't handle also medevac vehicles and focuses on medic units only, it can be great supplement to HAC without any incorporating, just try to use both simultaneously... If it handles also medevacs - there will be option in HAC to disabling chosen kind of support, so you always may replace HAC medevac or/and logistics support with another addon/script, that is more suitable to you. Situation is similar for SLX - should work smooth & fine with HAC, I hope.

From your HAC1.1 alpha2 release post, you'd already written scripts implementing the support functions - really impressive :)

Automedic is great for the player's team because you don't have to spend any time on giving the medic orders (which can be a PITA given the menu 6 problems). Will let you know how it works.

SLX is also a great addon - animations, taking prisoners, etc. - but has issues on some missions that are heavily scripted. Will test that as well, but likely not until at least the weekend.

I can't try this script by Demonized, beacuse: "OA required as discovered by a Arma 2 only user."

Oops - I forgot that (duh - I was the A2 user...)

BR

Orcinus

Share this post


Link to post
Share on other sites

Very nice update update Rydygier. Looking forward to giving this a go.

Share this post


Link to post
Share on other sites

Fantastic sounding mod you got here.

Just a curiosity, could I per say, place a bunch of squads with the init Code:

(group this) enableAttack false and still have them commanded by the artificial commander?

Share this post


Link to post
Share on other sites

@Taro8

There is good time to try your ideas (thanks!), because soon I will think about better defense and reserve handling.

In my game version I noticed, however, that effectiveness of any attempt of withdrawal groups currently engaged in combat is poor, while often cause serious losses. Thus, such a rotation changes would occur when there is no enemy near group.

I hope, did not forgot about something important...

Not important, but... There is also some small joke implemented. Fully randomized (every cycle) choosing, which commander will control given group, regardless of its side or fraction. Have not tested this, I do not know whether, or how it works, the effect probably is weird and not very useful, but can be funny.

RydHQ_SubZero (false) - if true this mode is on. Randomized will be all groups on map groupsselected by SubSynchro, SubNamed and Included array. Works for both sides, so there is no RHQB_ equivalent.

EDIT: also there are new RHQ arrays for non-generic support vehicles: RHQ_Med, RHQ_Fuel, RHQ_Ammo, RHQ_Rep.

Fantastic sounding mod you got here.

Just a curiosity, could I per say, place a bunch of squads with the init Code:

(group this) enableAttack false and still have them commanded by the artificial commander?

HAC should manage the army, as usual, by setting waypoints to groups, while sent groups will not do this, what required enabled "attack" AI.

Edited by Rydygier

Share this post


Link to post
Share on other sites

Sorry I'm not sure if I completely understand what your saying, the commander will issue the waypoints and the ai will then engage as per the

(group this) enableAttack false mode?

Share this post


Link to post
Share on other sites

HAC will issue waypoints, and groups should follow, but groups will not engage spotted enemy (team leader will not issue attack order, but maybe they will defend and shoot back? Didn't test this "enableAttack" command yet), because "attack" is disabled. Sorry for my poor language, sometimes is hard to understand. :)

EDIT: oh, you mean this command: http://community.bistudio.com/wiki/enableAttack

---------- Post added at 11:54 ---------- Previous post was at 11:39 ----------

From your HAC1.1 alpha2 release post, you'd already written scripts implementing the support functions

According to the plan... but as regards the medical support - control of HAC includes only medevac/ambulance vehicles. HAC by assumption tries not to interfere with AI of team and unit level, so it will not maintain control over individual medics. Therefore, this script by Demonized might be an excellent addition, when running simultaneously with HAC. OA owners can try this out.

Edited by Rydygier

Share this post


Link to post
Share on other sites
In my game version I noticed, however, that effectiveness of any attempt of withdrawal groups currently engaged in combat is poor, while often cause serious losses. Thus, such a rotation changes would occur when there is no enemy near group.

In CO AI is automatically kicked into "danger" mode whenever thy are attacked. I noticed that it keeps up even if they are ordered into different mode. AI keeps danger mode till they decide its clear. They keep covering until then.

If all fails just drop bunch of smoke rounds on group position.

Edited by Taro8

Share this post


Link to post
Share on other sites

Excellent work with this scripts Rydygier. It certainly adds more depth to the AI then simply using guard wp and "guarded by opfor" triggers. Perfect for large scale SP missions.

Any plans for adding AI artillery support?

Share this post


Link to post
Share on other sites
Any plans for adding AI artillery support?

:)

Fire At Will

FAW should work fine with HAC, I took into account specificity of FAW when I was writing HAC scripts. In HAC 1.1 alpha2 is now a small problem, because reammo truck will be always send to battery under FAW control (FAW at the beginning deprives batteries their ammo to replace it with chosen type in the desired quantity, so there is moment, when batteries are without ammo, and this triggers sending of reammo truck), unless close to given battery will be set another reammo vehicle, but already this issue was taken into account, so in the next test version will be an option of choosing groups that should not be supported by a given type of support vehicles.

Edited by Rydygier

Share this post


Link to post
Share on other sites
Any plans for adding AI artillery support?

In regards to ai arty, you can use the fire at will addon also by rydygier.

Find it here.

Share this post


Link to post
Share on other sites
:)

Fire At Will

FAW should work fine with HAC, I took into account specificity of FAW when I was writing HAC scripts. In HAC 1.1 alpha2 is now a small problem, because reammo truck will be always send to battery under FAW control (FAW at the beginning deprives batteries their ammo to replace it with chosen type in the desired quantity, so there is moment, when batteries are without ammo, and this triggers sending of reammo truck), unless close to given battery will be set another reammo vehicle, but already this issue was taken into account, so in the next test version will be an option of choosing groups that should not be supported by a given type of support vehicles.

This is simply brilliant! I will certainly try this. Thanks man!

Share this post


Link to post
Share on other sites
Fantastic sounding mod you got here.

Just a curiosity, could I per say, place a bunch of squads with the init Code:

(group this) enableAttack false and still have them commanded by the artificial commander?

Short answer: works straight out of the box with this command, no worries

Share this post


Link to post
Share on other sites
Short answer: works straight out of the box with this command, no worries

I agree - however I'm still not entirely sure that the command is still active after HAC takes over the group. Also, there's the issue pointed out by Igneuos01 in the thread I cited before

http://forums.bistudio.com/showthread.php?t=128833

that the type of the last waypoint has a significant impact on (especially) the AI group leader's behaviour.

I haven't had time to test it properly yet. Have you tried playing as a grunt in different groups to see if the leader behaves sensibly in general yet without sending single units hundreds of metres away with Engage orders? - what I call 'triple S' tasks.

BR

Orcinus

---------- Post added at 06:36 PM ---------- Previous post was at 06:35 PM ----------

This is simply brilliant! I will certainly try this. Thanks man!

I ran a very quick-and-dirty test & it worked great :)

BR

Orcinus

---------- Post added at 07:52 PM ---------- Previous post was at 06:36 PM ----------

:) Yes, defense perimeter has leght of about 1000 meters in HAC. Utes is in fact to small for HETMAN.

Hmm - if the commander has a relatively small number of groups at his disposal, that could make him very vulnerable to an incursion by an enemy group (or even a single unit, especially a sniper) that has by chance advanced through a gap undetected.

The diameter of the defensive perimeter should optimally be related to the qualities (number, & type, of groups) of the forces available, if possible.

And without HAC this effect does not occur?

I just ran some tests - it occurs in vanilla CO & vanilla A2 (plus latest beta OA) with no mods or addons. I've raised it in the beta thread.

Excellent question, thank you :)

BR

Orcinus

Added 12 Jan: retested team switch issue after complete machine reboot (updating system files) & problem with team switch no longer there in vanilla OA or OA wih HAC.

Must have been some temporary glitch.

Edited by Orcinus
Updated information

Share this post


Link to post
Share on other sites
Hmm - if the commander has a relatively small number of groups at his disposal, that could make him very vulnerable to an incursion by an enemy group (or even a single unit, especially a sniper) that has by chance advanced through a gap undetected.

The diameter of the defensive perimeter should optimally be related to the qualities (number, & type, of groups) of the forces available, if possible.

You are right. Soon defensive behaviour should be improved. For now I'm dealing with idle/reserve routines.

Share this post


Link to post
Share on other sites
You are right. Soon defensive behaviour should be improved. For now I'm dealing with idle/reserve routines.

No worries, I'm not nagging you :)

More than enough to test at the moment with the latest alpha, especially as I've just started setting up one mid- and one large-sized work projects; which is going to make me very busy for the next couple of weeks :(

BR

Orcinus

PS: on another point, Automedic is designed to work on medics in the player's team, where the player is commander.

Share this post


Link to post
Share on other sites

Dont forget about chance patrols for idle groups, gives them something to do.

Share this post


Link to post
Share on other sites

Interesting coincidence, I just now implement these patrols for non-motorized groups. :)

Share this post


Link to post
Share on other sites

I tried testing pulling out AI squad from under fire, but for some reason they didnt receive order to move.

However I noticed and odd and rather dangerous thing: trucks ordered to drop off troops and move away have very odd tendency to run over soldiers that just disembarked it. This can be easily countered by putting timeout giving soldiers time to clear from the way of truck.

Share this post


Link to post
Share on other sites

Well. Adding 15 second of delay after cargo unloading is not a problem. Thanks for info. Does this problem can also occur when truck is in the same group, as carried troops? In that case it would be a little more work.

Share this post


Link to post
Share on other sites
Well. Adding 15 second of delay after cargo unloading is not a problem. Thanks for info. Does this problem can also occur when truck is in the same group, as carried troops? In that case it would be a little more work.

Answer to your second point is "yes".

It isn't any fault of HAC, it's a known issue. I played an SP campaign recently where repeatedly, Strykers unloaded troops then ran over some of them. There are several tickets and multiple threads concerning AI driving problems; I've whinged in a couple of them myself :mad:

The global (?) workaround you suggest sounds fine. However, it isn't only vehicles connected in any way with a group of footsoldiers that may run them over, passing vehicles of any sort will frequently hit them - just as they'll crash into other vehicles, buildings & so on.

Seems to be worse from 1.60 onwards, & Sakudrive doesn't work since the last patch. Don't put any effort into more than setting a delay after unloading.

BR

Orcinus

Share this post


Link to post
Share on other sites

Hmm. Then unfortunately I can't help more indeed. I confirm that, I also have such problems. Today, during a test, I saw an ambulance killed in this way a soldier. And this supposed to be a medical service... I hoped that in later versions of game is better, but it looks like that is the same, if not worse. I personally think, that if currently used drivers AI can not be better balanced, they should in next versions of Arma write entirely new from scratch, perhaps based on a different concept, as far as possible. I suppose it's harder than it seems. But I know far too little to teach anyone, so enough complaining, I better go back to tracking bugs in HAC. :)

Share this post


Link to post
Share on other sites

Rydygier I tried using your script on other maps but can't seem to get it working properly. At first I thought I could add my own armies and this script with initialize the units automatically. Turns out it didn't work that way. Then I just copied the units from your Utes mission into Shapur (BAF), saved the mission and copied all the files. Everything started out fine but then I noticed the AI didn't place anything but recon markers and some 10 minutes later the whole game bogged down into a 1 - 2 fps slideshow scenario :crazy: What did I miss? The concept of a more capable AI commander is very interesting. I bet it works better if the missions is set up properly.

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

×