Arma 3
323 ratings
Drongo's Defensive AI
2
3
2
   
Award
Favorite
Favorited
Unfavorite
Data Type: Mod
Mod Type: Mechanics
File Size
Posted
Updated
66.037 KB
Jul 25, 2022 @ 4:02am
Jul 29, 2022 @ 5:39am
7 Change Notes ( view )

Subscribe to download
Drongo's Defensive AI

Description
This mod adds variety and unpredictability to AI defensive positions. Tested in SP and MP

DDAI makes defensive positions more challenging by garrisoning troops in structures (using LAMBS Danger), spawning and garrisoning bunkers, placing camo nets over vehicles and making the AI more reactive (with options to hold position, react to contact, launch counter-attacks, flee upon taking heavy casualties). Infantry units that do not garrison a bunker or structure will use LAMBS AI to patrol. Empty statics placed in the area may be crewed using LAMBS AI. The system also allows reserves to be specified and called.

Most of the mod features can be done by script if you wish to avoid dependencies.

There is a detailed README in the mod folder.

Check my profile for a link to my Discord.

Discord for my mods[discord.gg]
My Artillery/Cruise Missile/Loitering Munition mod
My Air Support mod
My Active Protection System mod

BASIC USE
Place a DDAI Defensive Area module at the center of the desired area
Select the desired values in the editor
(ATTACK ONLY) Place a marker at the position to attack and put the marker name in the "Attack marker name" field
(OPTIONAL) Using the Eden "Placement Radius" option on groups is a quick and easy way to randomize a mission

OPTIONS
  • Side
  • Posture (Defend, DefendFlexible, Counter, Guard, Attack)
  • Facing
  • Radius
  • Position to attack (Attack orders only)
  • Delay before attack (Attack orders only)
  • Delay before counter-attack (Counter orders only)
  • Distance from enemy before triggering counter attack (Counter orders only)
  • Counter attack composition (infantry, vehicles, both, random)
  • Camo scheme (green or brown)
  • Bunker chance (chance an ungarrisoned infantry squad will spawn a bunker to garrison)
  • Camo net chance (chance a vehicle will spawn a camo net)
  • Delete ungarrisoned men (true/false)
  • Delete empty statics (true/false)
  • Distance from other objects at which bunkers can spawn
  • Breakpoint before fleeing
  • Delay before start
  • Go codes required to start
  • Control over which bunker types are used

POSTURE TYPES
DEFEND: Groups stay in garrison, no extra WP
DEFENDFLEXIBLE: Groups stay in garrison with random exit conditions, vehicles may get guard WP
COUNTER: Groups will launch a counter attack once ground units are spotted and within range
GUARD: Groups stay in garrison with random exit conditions, all groups get guard WP
ATTACK: Groups will attack the target position

FLEEING
A random value between the two values provided will be generated. This is the percentage of men killed that will trigger allowFleeing 1 in all groups. To disable fleeing, put 0,0 in the field.

NOTES
Vehicles should be in groups of one
Mixed infantry/vehicle groups should have the leader in the vehicle
Air units will not be used by the system (use DAFS)
It is possible to extract the scripts and apply them at the mission level to avoid an addon dependency. This requires some basic scripting skills and I do not provide support for this approach.

EXCLUDING UNITS
_group setVariable["DDAIexclude",TRUE,TRUE];

For example, in a group's init field in the editor:
this setVariable["DDAIexclude",TRUE,TRUE];

Alternatively, sync a single unit from a group to the Exclude module.

GO CODES
Modules can be delayed from starting by putting a string or array of strings in the Go Code field. The module will not start until all of the listed go codes are in the server-side array ddaiGoCodes. For example:

[ddaiGocodes,"myGoCode_1"]remoteExec["pushBack",2];

RESERVES
Sync a single unit from each desired reserve group to a Reserves module and place the module at the location they should move to when called. The module must be within the radius of an Area module. Only the groups in that Area module can call those reserves. They will call reserves when one of the Area module groups detects land-based enemies within 1000m.

BUNKER TYPES
For more control over which types of bunkers will be spawned, place a Bunker Types module and sync it to the Area module.

CUSTOM BUNKER TYPES
Any object that isKindOf"Structure" can be used as a bunker (providing it has AI positions) .Sync the desired objects to the Defensive Area module and orient the front of the structure to the north. This will overwrite the vanilla bunker types.

KNOWN BUGS
Bunkers may sometimes clip with structures

THEFT OF MY WORK
My artillery mod was stolen, edited and re-released in violation of the license by BlackAlpha of tier1ops.eu. Here is a video showing my original work and his stolen edit:

https://www.youtube.com/watch?v=Oe7G6WwxQVU

Please share this video and let the community know that BlackAlpha and tier1ops.eu are thieves.

LICENSE
Arma Public License Share Alive (APL-SA)

CREDITS
Drongo: Concept and coding

CHANGELOG
0.12
Added: Custom bunker support
Fixed: Error with facing code

0.11
Added: Debug option
Added: Face out option for bunkers (all around defence)
Fixed: Reserves not moving when called
Improved: Bunker position finding
84 Comments
Drongo  [author] Aug 13, 2023 @ 4:18am 
I'm not sure, I haven't tried spearhead. There are methods in the readme to get non-vanilla bunkers working.
roflcake$ Aug 5, 2023 @ 12:26am 
does this work with spearhead? thanks for all your work! the command enhancement i think has some issues with spearhead but it's still the best one around. awesome stuff.
RESQUART May 25, 2023 @ 5:02am 
@Vostok918 Not only you my friend. Probably this mod or LAMBDA_Danger mod (this mod's dependency mod) causing the real problem.
RESQUART May 25, 2023 @ 5:00am 
Extreme performance issue. I have Rtx 3060 laptop GPU with 12700-H processor plus 32 GB DDR4 Ram but this mod OR MAYBE LAMBS_Danger mod idk causes HEAVY performance issue... My FPS drops to 30s and 40s
Drongo  [author] Apr 15, 2023 @ 3:51pm 
No, it doesn't.
tacticooldude1067 Apr 15, 2023 @ 3:15pm 
great work, does this not setup static weapons in the bunkers?
Drongo  [author] Dec 16, 2022 @ 2:38am 
Unfortunately no, it is all random. Maybe you could hand place groups and bunkers with probability of presence and exclude them from DDAI.
Crome Dec 15, 2022 @ 9:38am 
Very nice mod, is there a way to make DDAI exclude certain defensive positions or make it more likely that AI are positioned at other defensive positions?
Drongo  [author] Dec 5, 2022 @ 12:51pm 
I wouldn't have thought it could cause lag at all. Do you have other mods running?
Vostok918 Nov 29, 2022 @ 8:59am 
is it normal if i think this makes game lag af?
my computer can easily run an ai vs ai battle with 200 units, 400 groups on both sides if no mods are installed, but if i use this module framrate drops to 0.5 and 1 sec in game became 5 sec irl
i wonder if this mod do make game laggy or it's other thing's problem