INCON Scripts for ALiVE - Intel + AI teammate persistence

  1. 8 years ago
    Edited 8 years ago by incontinenetia

    INCON INTEL (alpha)

    Requires: CBA

    FEATURES

    • Made for ALiVE
    • Units drop intel when they are killed

    Dropped intel will:

    • Find ALiVE asym opcom installations
    • Track phone contacts on map (requires UAV terminal)
    • Track radio contacts on map (requires UAV terminal)
    • Tracking accuracy depends on the weather, overhead cover, range etc.

    INCON PERSISTENCE (alpha)

    Requires: CBA, ALiVE, iniDBI2

    FEATURES

    Provides persistence for non-playable AI teammates (in player group) between play sessions when ALiVE data is present using iniDBI2. Saves full unit information for up to 11 AI teammates and loads it when there is corresponding ALiVE persistent player information.

    See readme files for usage details.

    Special thanks to @davidoss, @dixon13 and @Spyderblack723 for being super helpful and for inspiring me start writing my own stuff.

    Download links:

    Incon Persistence
    Incon Intel

    Note: Incon Undercover has been released separately here:
    Incon Undercover

  2. In a mission I am trying to make I ended up accidentally getting carried away and producing something I thought a few people on here might also want to use.

    That's how it always happens, get used to it ;)

    inspiring me to stop freeloading and start writing my own stuff.

    Get off my virtual lawn

  3. @SpyderBlack723 Get off my virtual lawn

    Surely I've got some kind of squatters' rights by now?

  4. Edited 8 years ago by HeroesandvillainsOS

    @incontinenetia

    I'm having a hard time processing it all. It's blowing my mind.

    Can you provide an example for the types of missions you envision this being used for? Perhaps you'd play as an undercover Afghani infiltrating Taliban compounds killing HVT's and recruiting civs? Like that maybe?

    I see its BLUFOR only so we'd need to be on the BLU side, right?

    And it's not advised to use in SP then? The last line is confusing me. PVP or humans only?

    Anyway, if you could paint a picture and give me some hypothetical mission/story examples, that would help me out man.

  5. Yeah, anything like that. It basically allows a unit to dress as a civilian and go incognito, then recruit civilians and do whatever you want. Imagine yourself as the insurgent, asking people to join your cause and creating havoc.

    So, you could dress as a civilian and keep a suppressed rifle in your backpack, sneak into a sensitive area, find a decent hiding spot, kill a HVT... or just do some recon, or use your disguise to mount an ambush inside a place you couldn't ordinarily get without fighting your way through. Or you could act as a FAC / JTAC deep behind enemy lines, stuff like that.

    I recently recruited a whole load of dudes, ambushed an enemy patrol, stole their supplies and gave them to my new civilian team, then got them to hide their weapons, head to an enemy base and mount a diversion while I snuck in and blew up a load of vehicles.

    You could also have a BLUFOR FIA insurgency going on and play as one of them, only revealing yourself when you need to attack and blending back into the civilian population once your attack is over. Does that make sense?

    The BLUFOR limitation is just because this was designed with a specific scenario in mind and I haven't quite figured out a reliable way to integrate the reputation and recruitment system dynamically yet. I'll hopefully get round to changing that soon.

    SP / COOP is exactly what it is useful for.

  6. I think he's saying that it won't work outside of CO-OP, while in PvP scenarios. Most other players would pick up on it pretty easily.

    As far as envisioned scenarios?
    This is just begging for some Eastern Ukraine action. Black-Ops adventures against Russian backed Separatists, taking out HVT's, sabotaging assets, recruiting Civs to help against Little Green Men etc.

    I had a campaign planned using my ORBAT Pirates/Rebels that this would work wonders for. Small group of undercover or stealth operators is inserted into an Island chain that has been taken over by Pirates and instructed to dismantle their operations. BUT, overt military action cannot be undertaken because of regional backing by a major OpFor (CSAT/PLA etc).
    Hence a small, deniable team is sent in to blow stuff up and take down the cartel.

  7. ^^^^ Yup, @ski2060 pretty much nailed it.

    I've updated the first post with instructions to hopefully make the usage a bit clearer. BLUFOR only limitation will be the first thing I'll be looking at changing.

    Think of it as a bit like Spyder's detection module in terms of usage, but with a lightweight AI version too.

  8. Just caught the offending mistake, I meant PvE when I said PvP (sorry @HeroesandvillainsOS!). First post updated.

  9. Edited 8 years ago by HeroesandvillainsOS

    I get it now.

    While working on my main releases, me and another guy have been working on some new stuff while also discussing making something unique. I think this script will fit the bill nicely. :)

    One idea I've been kicking around for a while is a scenario where you play as Afghan (or other) local, hired secretly by a western nation to recon and disrupt insurgent activity, to recruit and win over the locals, and take back your country from the inside. I'm picturing a scenario where western forces can't exactly full scale invade due to government pressure, so the local would work in collaboration with some small, officially un-sanctioned western spec ops team, going remotely undercover and gaining access to areas that are off limits to the super powers. Then the spec ops team would go in occasionally and do surgical strikes with the info the local gathered.

    And the idea of recruiting a local militia on top of it is amazing so I think this mod is exactly what we need!

    Of course it's hard for me to figure out exactly how it I might make it work in practice. What's your mission like? Like, does he initially spawn in a house, or is the civ part of a military team and starts his assignment from a covert base somewhere?

    I'm also thinking about how this script might function with the ALiVE systems as a whole or if it would need more structured "missions" to utilize it's full power. I'm thinking it would go hand in hand with a counter insurgency or even a conventional I guess if you got creative.

    I'm looking forward to your mission buddy. I really want to see this in practice. Spookwarcom is one of my all-time favorite experiences and this could probably replicate something covert like that too, maybe if I hand-crafted a few tasks! So many ideas. You're killing me with this awesomeness. :)

  10. Friznit

    16 Oct 2016 Administrator

    Very cool!

  11. Cheers Friznit!

    @HeroesandvillainsOS  Of course it's hard for me to figure out exactly how it I might make it work in practice. What's your mission like? Like, does he initially spawn in a house, or is the civ part of a military team and starts his assignment from a covert base somewhere?

    It's entirely up to you but I've just got one undercover operative starting out at a little safehouse in the middle of nowhere. My mission is a weird mix of counterinsurgency and undercover / stealth work. Basically, trying to destroy a criminal network under the noses of a hostile occupation force (who are aiding the criminals), so this undercover script is one aspect of that. It's a very long mission that will require persistence, in theory you could play it for months, slowly whittling away at the enemy's resolve.

    I've also got a custom high value target system which doesn't rely on tasks and rewards so much as actions and consequences... i.e. nail the right dude and potentially kick off an internal power struggle as the criminal gang splits in two and fights each other.. or capture an enemy and take them to an interrogation cell to reveal installations and locations of potential targets. Then there's the new intel system I'm putting together which allows you to hack dropped phones / walkie talkies and track their contacts (will release standalone soon too once I've worked out some niggling localisation issues), plus stealth drones with ISR / strike capability.... the idea is to recreate some of the more sneaky stuff that goes on in the SF world in a fairly plausible way. Looking forward to releasing it but getting all the moving parts working together properly is quite a challenge!

    But yeah, really, just use your imagination I guess. As long as the unit is BLUFOR, you can dress him like an Afghan or a civilian or a mermaid or whatever and go from there. You could even just run the script on a normal unit and then halfway through the mission, that unit could find a safehouse, change into civilian clothes and as long as he isn't compromised already, you could complete a specific objective undercover, then go back to the safehouse and get back into your ninja suit and carry on. There's loads of ways of using it I reckon. I just need to figure out a way to make it work dynamically on units of all sides which shouldn't take too long.

  12. Edited 8 years ago by HeroesandvillainsOS

    @incontinenetia Cheers Friznit!

    It's entirely up to you but I've just got one undercover operative starting out at a little safehouse in the middle of nowhere. My mission is a weird mix of counterinsurgency and undercover / stealth work. Basically, trying to destroy a criminal network under the noses of a hostile occupation force (who are aiding the criminals), so this undercover script is one aspect of that. It's a very long mission that will require persistence, in theory you could play it for months, slowly whittling away at the enemy's resolve.

    I've also got a custom high value target system which doesn't rely on tasks and rewards so much as actions and consequences... i.e. nail the right dude and potentially kick off an internal power struggle as the criminal gang splits in two and fights each other.. or capture an enemy and take them to an interrogation cell to reveal installations and locations of potential targets. Then there's the new intel system I'm putting together which allows you to hack dropped phones / walkie talkies and track their contacts (will release standalone soon too once I've worked out some niggling localisation issues), plus stealth drones with ISR / strike capability.... the idea is to recreate some of the more sneaky stuff that goes on in the SF world in a fairly plausible way. Looking forward to releasing it but getting all the moving parts working together properly is quite a challenge!

    But yeah, really, just use your imagination I guess. As long as the unit is BLUFOR, you can dress him like an Afghan or a civilian or a mermaid or whatever and go from there. You could even just run the script on a normal unit and then halfway through the mission, that unit could find a safehouse, change into civilian clothes and as long as he isn't compromised already, you could complete a specific objective undercover, then go back to the safehouse and get back into your ninja suit and carry on. There's loads of ways of using it I reckon. I just need to figure out a way to make it work dynamically on units of all sides which shouldn't take too long.

    Do you plan on releasing both the custom HVT system and the Intel system?

    Yeah man this mission of yours seems so awesome! Please please share it when you're done!

  13. Yeah the intel system will go public soon definitely, HVTs are more mission specific so I don't know how well it will translate to other scenarios. I might try to put together something like Spyder's addons / spookwarcom maybe. I'll just have to see how well the conversion from mission specific to generic goes.

  14. Is there any way to add a list of all military uniforms from a particular Mod (RHS, US Vests, etc) without having to add each individual uniform classname to the UC.sqf ?

  15. Edited 8 years ago by SpyderBlack723

    @ski2060 Is there any way to add a list of all military uniforms from a particular Mod (RHS, US Vests, etc) without having to add each individual uniform classname to the UC.sqf ?

    For @incontinenetia

    // get faction gear
    // ["uniforms", ["BLU_F"]] call fnc
    
    _data params ["_gearType","_factions"];
    
    private _result = [];
    
    private _units = [];
    private _cfgVehicles = configFile >> "CfgVehicles";
    
    for "_i" from 0 to (count _cfgVehicles - 1) do {
        _entry = _cfgVehicles select _i;
        
        if (isclass _entry) then {
            if (
                (getNumber(_entry >> "scope") >= 2) &&
                {configname _entry isKindOf "Man"}
            ) then {
                _units pushback _entry;
            };
        };
    };
    
    switch (_gearType) do {
    
        case "headgear": {
            {
                _unit = _x;
                _linkedItems = getArray (_unit >> "linkedItems");
    
                {
                    _item = _x;
                    _configPath = configFile >> "CfgWeapons" >> _item;
                        if (isClass _configPath) then {
                            _itemInfo = getNumber (_configPath >> "ItemInfo" >> "Type");
    
                            switch (str _itemInfo) do {
                                case "605": {
                                    _result pushbackunique _item;
                                };
                            };
                        };
                } forEach _linkedItems;
            } forEach _units;
        };
    
        case "vests": {
            {
                _unit = _x;
                _linkedItems = getArray (_unit >> "linkedItems");
                {
                    _item = _x;
                    _configPath = configFile >> "CfgWeapons" >> _item;
                        if (isClass _configPath) then {
                            _itemInfo = getNumber (_configPath >> "ItemInfo" >> "Type");
    
                            switch (str _itemInfo) do {
                                case "701": {
                                    _result pushbackunique _item;
                                };
                            };
                        };
                } forEach _linkedItems;
            } forEach _units;
        };
    
        case "uniforms": {
            {
                _uniform = getText (_x >> "uniformClass");
                _result pushbackunique _uniform;
            } forEach _units;
        };
        
    };
    
    _result
  16. Thanks @SpyderBlack723! @ski2060, I'll try to get this in at some point in the very near future (hopefully by tomorrow). Any other requests while I'm working on it?

  17. Hi,

    I'm working on an Afghanistan-Style mission and giving the Opfor players more flexibility sounds great to me. Would mean IND (Project Opfor) against BLU (RHS).

  18. Hi @matze - working on it as I type. Just bear in mind that this script will only function correctly for units of one side at a time (so not BLUFOR and OPFOR / IND simultaneously).

  19. Sounds perfect! Thank you for your effort!

  20. Updated the script (same DL link as before) with a few requested changes:

    • Undercover units are no longer limited to BLUFOR
    • Trespassing zones can now be set up using triggers
    • Uniforms and vests automatically added from faction lists (ability to manually add still remains) - thanks to @SpyderBlack723 for the script
    • A few small tweaks and fixes here and there

    Keep throwing the ideas / feedback out there guys.

  21. 8 years ago
    Edited 8 years ago by SpyderBlack723

    Suggestions:

    Ability to define trespassing zones using markers, where an internal script/loop handles the checking as opposed to triggers. (inArea command is useful for this)
    Benefits: one loop instead of many

    A Github "release" if you know how or want to learn how to use it.

  22. Yup, great shout on both counts. Probably ought to get my head around GitHub sooner or later. Any ideas of a good way of getting whether a unit is in one of several marker areas without resorting to an enormous if condition? I couldn't see an obvious way when I was looking at vanilla solutions so maybe CBA has something useful.

  23. Actually what would be really cool to do is have some kind of tag in the marker name that autodetects any trespass markers. Now I know what I'm doing for my next weekend project..

  24. check out the inArea command

  25. Man, I really need to sit down with one of my mission makers and get this into some of our stuff. It really opens up some good Covert action ideas.

  26. Me too. It's tops on my list for my next project I just need to finish up my current project. Hopefully that's not discouraging Incontinenetia at all. I'm really looking forward to spending time with this.

  27. Edited 8 years ago by incontinenetia

    Good to hear it's hopefully going to be useful! Just keep in mind this is my first foray into scripting so things may change a bit as I learn more.. on the other hand, I put a lot of effort into optimising the detection scripts and think I've found a pretty speedy solution for that, which is the core of it.

    Intel will probably be in the next update too. Just have to get some final tests done.

    @SpyderBlack723, I had a look at the inArea command and can't see anything about checking an array of markers, is it able to do that? As in:

    _unit inArea ["marker1","marker2","marker3"]

    Away from my PC for a couple of days but will check it out in a bit more detail when I'm back.

    Edit: Or something like this:

    [_unit,_trespassMarkers] spawn {
    
        params [["_unit",objNull],["_trespassMarkers",[]]];
    
        sleep 2; 
    
        private _activeMarker = [];
    
        for "_i" from 0 to (count (_trespassMarkers - 1)) do {
    
            _entry = _trespassMarkers select _i;
    
            if (_unit inArea _entry) then {
                _activeMarker pushBack _entry;
            };
        };
    
        if (_activeMarker != []) then {
            _unit setVariable ["trespassingType2",true,true];
        } else {
            _unit setVariable ["trespassingType2",false,true];
        };
    
    
        !(_unit getVariable ["isUndercover",false])
    
    };
  28. Edited 8 years ago by SpyderBlack723
    _markers = [...];
    _unit = ...
    
    private _detected = false;
    {
        if (_unit inArea _x) exitWith {
            _detected = true; // exitWith can terminate forEach early
        };
    } foreach _markers;

    or if you're an optimization freak you could substitute count for foreach, which loops a little bit faster.

    _markers = [...];
    _unit = ...
    
    private _detected = false;
    {
        if (_unit inArea _x) exitWith {
            _detected = true; // exitWith can terminate forEach early
        };
    
        false
    } count _markers;
  29. Edited 8 years ago by incontinenetia

    Of course it's that simple! Not sure why I didn't think of that. Cheers again Spyder.

  30. So, usage question. I place everything INSIDE the Missionname.terrain folder inside my saved mission file correct?

    So all of that stuff (INCON, ds.store*, init.sqf and description.ext) go in there, and I modify the UCRsetup.sqf inside INCON to set my factions and such. Is that correct?

    And for any UC units, I place the appropriate init code from above into the group leaders init variable field?

    And this will work without Alive, correct? Trying to work on a black ops trainer mission that does not utilize ALiVE at this time.

  31. Edited 8 years ago by incontinenetia

    Hi @ski2060, give me a minute and I'll get the new version up. But yeah, that's pretty much it! The recruitment won't work with ALiVE so make sure you set up the options with that in mind.

    Edit: new version is up, mini changelog:

    - Changed from trespass triggers to markers - thanks to Spyderblack once again (include INC_tre in your marker name and the script will handle the rest)

    - Some general optimisations

  32. cool, just got it.

    Sooo.. tried it out and promptly got shot in the face by the IndFor I was trying to blend in with.

    I'll have to try it again and see if I got it all correct.

    Will it hurt anything if I put the init code into every playable slot, instead of just the group leader?

  33. Haha oh dear. Yeah, maybe give that a go.. is your group leader a player?

    Regarding getting shot, did you get close to the IND guy? Or spawn next to him? It takes a short while to initialise and the cover will only work at a certain distance.

    Otherwise, I'd check you have set up the uniforms properly maybe.

  34. Ok, distance was probably it. I was checking to see if they would just open fire on me, and I was pretty close via teleport.

    I'll test some more out tomorrow on my off day, and try longer distances.

    I was just using standard CIV_F clothing, no backpack, no vest etc.

    Oh.. do any backpacks set off the discovery? Or all backpacks exempt from discovery checks?
    being able to carry all my gear in a backpack, posing as a hiker or something would be great. Can get a vest and maybe a SMG/Long weapon in one of the big backpacks then :D

  35. Yeah that's correct, for now backpacks are excluded, trying to keep the number of checks down for performance. As long as you've defined CIV_F in the safe faction uniform list that should work. I'm open to suggestions on the distance checks, I put them in because otherwise with ACE, you can just walk up to enemy soldiers and plant explosive charges in the middle of them, which makes things less fun. I'll revisit this over time though.

  36. Now up on GitHub with an experimental Intel spawning script too.

  37. Can you (again) describe the intended use and features of the Intel script? And possibly how you personally use it with the Intel script?

  38. Yeah, it's basically just an updated version of the intel script that was posted on this forum a while back (you requested it I think!). So units drop intel items when they are killed.

    This time around they not only drop intel revealing locations of installations, but also drop phones and radios that you can hack into and track contacts on the map.

    Usage should be pretty self explanatory I guess?

  39. Nice! I'm really looking forward to experimenting with all this. I've been a bit busy with some other Arma projects lately but I can't wait!

  40. I assume the intel is for tracking Assymetrical actors? It wouldn't work in regards to any other type of force?

  41. Newer ›
 

or Sign Up to reply!