Putting OPCOM to Bed on Empty Server

  1. 6 years ago

    So I have a Kunduz-based mission that utilizes an asymmetric OPCOM which starts on the east side of the map, and typically within a couple uninterrupted hours has started taking root on objectives to the west. It takes root and recruits, and recruits, and recruits...and if I leave the session up overnight, one returns to a sea of hostile patrols, practically evvvvverywherrrrre.


    But, in the interest of looking at ways of throttling the rate of their progress just a wee a bit, I came across mention in the wiki that a trigger could be sync'd to OPCOM that, when all conditions have been satisfied, would basically free up OPCOM to do its thing, but when that trigger was negated, the OPCOM would wrap-up its assigned objectives and wait. The wiki mentioned that this could be utilized to suspend OPCOM operations on an empty server, for instance...

    With my limited trigger experience all I could think of to do so far for such an effect was create a full-map trigger, set it to Anyone/Present with a "vehicle player in thisList;" conditional, and sync it to the OPCOM. However, this doesn't see to have any effect. I'm not sure if this is due to the nature of the asymmetric OPCOM or I'm just way off on the trigger execution.

    Has anyone had any success setting up a similar mechanism? Care to share basic setup? Do I need to maybe try unsyncing and just pause/unpause many modules with the trigger activation/deactivation settings?

    Thank you for your time,

    - Crap

  2. Solution...
    Create "initServer.sqf" in your mission directory...


    ["someId", "onPlayerConnected", {
    	if (({isPlayer _x} count playableUnits) > 0 || OPCOM_TOGGLE) then { ["ALIVE_MIL_OPCOM"] call ALiVE_fnc_unPauseModule; OPCOM_TOGGLE = false; };
    }] call BIS_fnc_addStackedEventHandler;
    ["someId", "onPlayerDisconnected", {
    	if ( ({isPlayer _x} count playableUnits) == 0 ) then { ["ALIVE_MIL_OPCOM"] call ALiVE_fnc_pauseModule; OPCOM_TOGGLE = true; };
    }] call BIS_fnc_addStackedEventHandler;
  3. Friznit

    15 Jun 2015 Administrator

    Nice. Remind me to add this to the wiki later!

  4. Outfreakin'standing dixon! Appreciate it.

    - D

  5. Edited 6 years ago by DaVidoSS

    What you exactly mind as "someId"? Player uid or what?

  6. Edited 6 years ago by SpyderBlack723

    Reference here regarding "someId"

    I don't think you need to manipulate it at all.

  7. As is, it still seems like my asymmetrical OPCOM goes buckwild with recruiting and seizing objectives while server is empty. Definitely a step in the right direction though, and seems very sound logically. Still playing with it and will notify with any changes if I see it working 100%.

    - D

  8. Deleted 6 years ago by SpyderBlack723
  9. Edited 6 years ago by thefinn

    I'm doing something similar here, I want to stop the opcoms of both sides until a cinematic finishes, then begin the silliness ;)

    Unfortunately it seems like the BLUFOR opcom has stopped but OPFOR is still attacking ?

    Edit: seems both sides are.

    I basically just put this in init.sqf:
    ["ALIVE_MIL_OPCOM","ALIVE_MIL_C2ISTAR"] call ALiVE_fnc_PauseModule;

    Would just like to place units, but everything else is off including C2ISTAR etc at the start of the mission.

    I know I saw a list of how to call these in scripts :\

    Edit: Seems there's a few listed under "script snippets" on the wiki. Wiki could likely do with a full list.

    This isn't working for me atm.

  10. Edited 6 years ago by SpyderBlack723

    Were you testing this in the editor or on a server, the pause module function only works on a server as far as I know.

    Edit: does work in SP now

  11. Ahh, Yes I was using co-op. Will have to get that server running today. ;)

  12. Hate to bump, but I'm still not seeing this working as I'd expect with the asymmetrical OPCOM... Would it be possible that another module, civilian-related perhaps, would have to be paused as well, as they seem to do some of the legwork for the asym commander?

    Best regards and thanks,

    - D

  13. Edited 6 years ago by Crapachi

    After some further testing utilizing dixon's snippet above, but pausing/unpausing the entire ALIVE_SYS_PROFILE, ALIVE_MIL_OPCOM, and ALIVE_AMB_CIV_POPULATION trifecta, everything seems to do what I was originally aiming to achieve. While an unchecked asymmetrical commander will still populate 5km x 5km Kunduz in short order, at least for sessions left on throughout the week we still stand a chance of holding ground against an enemy OPCOM that's not running rampant while the server is empty.

    Thanks again guys. ALiVE, and ALiVE community, is absolutely brilliant!

    - D

  14. Friznit

    3 Jul 2015 Administrator

    Pausing profiles is probably the most effective. Remember though that pausing OPCOM simlpy stops it issuing any new orders. Current orders will still play out until the objective has been secured, which may not happen for a while if Profiles can't move!

  15. I wonder if anyone can say how to do this in the INIT file in order to stop all orders until (perhaps) a mission intro had finished playing.

    Spyder and I had some issue with this earlier.

  16. highhead

    6 Jul 2015 Administrator

    oh yeah - confirmed, need to implement pausing in Asym OPCOM!

  17. @highhead are you saying that you are implementing a pausing in Asym OPCOM or do I need to write another script xD?

  18. 4 years ago
    Edited 4 years ago by CC_KRONUS

    sorry to resurrect this old thread, but that is the only one that the search has given as aprox to what I am looking for.

    here is the question:
    Is there any way to tell the assymetric forces to spawn and be operative only between x time and x time next day, then then despawn?

    I am working UNSUNG mod on a vietnam insurgency for my clan, and what I want is that at late afternoon, some of the peasants take their ak-47 from under the rug, put on their VC conical hat and go to do their stuff until daylight next day, when they know that if they don't go back to work the rice fields with their water buffalos, the US Air power will blow them to commy heaven, so at first light they vanish in thin air.

  19. You would have to write a script that pauses the OPCOM modules during the day then un-pauses at night.


  20. Thanks for the link but it has not solved my doubts. see, beyond copy-paste, I have a very limited knowledge of programming Arma3. Any help with an example to pause assymetric between say, 7AM to 7PM? Where should I run the script? in the init of the module or in init.sqf at root?


or Sign Up to reply!