Jump to content

Recommended Posts

Hi Guys,


Im developing a mission that requires the use of many modules, such being modules for zeus sectors and setting their capture state etc.


The issue i have is that i have run out of groups to use, modules cannot be grouped and if i attempt to group them to a unit that has no probability of presence, it removes their positioning and makes them stop functioning.


Is there any resolution to this?


Below is an image of the setup.
What i am trying to achieve and have achieved is;

A visible area on the map that changes color when captured by a faction [bLUFOR, OPFOR, INDEPENDENT]

An area that becomes editable inside after capture to the capturing side.

Extra points to be given to thats side after capture.

The above requires very few modules/triggers etc however, it becomes large when it is setup below to allow for it to switch back and forth as it is captured and recaptured.




Share this post

Link to post
Share on other sites

There may be, however, im unsure if the full process is scriptable, I know its possible to set the zone to change states easily with scripts however, adding points and setting it as an editable zone via Zeus im not aware of how to do.

Share this post

Link to post
Share on other sites

The module framework already handles some of this for you by grouping modules by their category type e.g all Multiplayer modules are grouped together, all Zeus modules are grouped together etc etc.

You can see this by opening the debugConsole and typing units bis_fnc_initModules_# where # is the category type. e.g

Typing units bis_fnc_initModules_multiplayer will show all your respawnPositions, sectors, sector dummies and vehicleRespawn modules.


What is not grouped for you are gamelogics, if you were to name all your sidelogics, locationAreas and unlocks and then query their groups from the debugconsole you will find they are all in their own separate groups.

One fix maybe to find all logics that are not a module (have no category) and lump them all into the bis_functions_mainscope which is the equivalent of the old logic you used to have to place in previous Arma titles for any thing to work but is now automatically placed for you.

Something like...

if !( isServer ) exitWith {};

waitUntil {!isNil "bis_fnc_init"};

_mapSize = ( getNumber( configFile >> "CfgWorlds" >> worldName >> "mapSize" ) / 2 );

_mapRadius = _mapSize * 1.4142;
_mapcenter = [ _mapSize, _mapSize ];

_allLogics = _mapcenter nearEntities [ "Logic", _mapRadius ];
_logicMain = group ( missionNamespace getVariable ["bis_functions_mainscope",objNull] );
if ( isNull _logicMain ) then {
    _logicMain = createGroup sideLogic;

    if !( isText( configFile >> "cfgvehicles" >> typeOf _x >> "category" ) ) then {
        _group = group _x;
        [ _x ] joinSilent _logicMain;
        if ( count units _group isEqualTo 0 ) then {
            deleteGroup _group;
}forEach _allLogics;
Would need experimenting with to make sure it does not break stuff.



To be honest now that you have got to this level of chaining stuff you would likely be better served working out how to script you additional behaviour. For instance side changes on sector modules can be handled by listening for the "ownerChanged" scripted eventhandler and would negate having all the unlocks and zeus editing areas and points that can be added via script. Even spawning your sector modules via script could be a valid solution and can save having to have all the extra sideLogics and locationAreas.

  • Like 1

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