Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
# Changelog for Zeus Additions 27.9.2025

1.6.11.0
- Fixed paradrop module not selecting units.
- Added "Assemble Static Weapon" context menu option that makes AI set up static weapons.
- Removed "ACE Drag Bodies" module, as Zeus Additions now requires ACE 3.18.0, ACE having added native body dragging.

# Changelog for Zeus Additions 9.2.2025

1.6.10.0
Expand All @@ -9,7 +16,7 @@
- Updated to use 2.18 commands.
- Raised limit for automatic parachute deployment from 100 m to 150 m.
- Updated to support ACE 3.18.0
- Fixed bug with VBIED where vehicle could blow up numerous time in rapid succession.
- Fixed bug with VBIED where vehicle could blow up numerous times in rapid succession.

# Changelog for Zeus Additions 6.5.2024

Expand Down Expand Up @@ -64,7 +71,7 @@
1.6.3.13
- Added support for 2.12.
- Changed "Remote Control (Switch Unit)" module method of going back into Zeus from pressing getting into the pause menu to pressing the Zeus interface keybind.
- Unconscious and create injuries module doesn't notify players anymore.
- Unconscious and create injuries modules don't notify players anymore.
- Fixed numerous bugs.

# Changelog for Zeus Additions 26.11.2022
Expand Down
9 changes: 6 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
<h2>Modules</h2>

* **ACE Drag and Carry:** Allows the Zeus to set object to be ACE draggable and carriable. The module can also set whether weight limits should be respected when trying to drag or carry the selected object.
* **ACE Drag Bodies:** Hidden if you have ACE 3.18.0 loaded, as it's part of ACE 3.18.0. Allows the Zeus to give players the option to drag corpses.
* **ACE Medical Injuries:** Allows the Zeus to create ACE Medical injuries on AI or players, either dead or alive. Also can create random wounds, taking a damage value and type you are able to set. Random damage can only be applied to a living unit.
* **ACE Medical Resupply:** Spawns an ACE medical resupply. If the module is placed on an object, it can put the resupply in the inventory of the object and clear out the inventory prior to that if wanted.
* **AI Crew Behaviour:** Can prevent AI from dismounting in combat and also when their vehicle is immobilized. Allows the Zeus to change if AI can turn out or not.
Expand Down Expand Up @@ -51,14 +50,18 @@ Inputs are arrays of strings.
* **Enable ACE Medical missing addon hint:** If enabled, it will hint if ACE Medical is missing.
* **Enable TFAR missing addon hint:** If enabled, it will hint if TFAR is missing.
* **Enable RHS missing addon hint:** If enabled, it will hint if RHS is missing.
* **Enable JIP features:** If enabled, it will add JIP functionality to the server, if the player is a curator.
* **Enable Building Destruction handling:** If enabled, it will make floating objects near a building upon destruction fall to the ground.
* **Enable Mission Object Counter:** This will only work if the player is a curator. If enabled, it will count what you have placed down as a curator. If disabled, it will remove the counter, but not reset it.

This mod also adds:
- the ability to drag dead corpses as Zeus. In order to do so, you must be in the map screen.
- gravity to objects that don't have gravity, when a building is destroyed. This must be enabled in the CBA settings.

<h2>CBA Keybinds</h2>

* **Deep Copy** (default: **Ctrl-Alt-C**): Identical as ZEN's Deep Copy, but additionally copies AI features (e.g. pathing, FSM, etc.).
* **Deep Paste** (default: **Ctrl-Alt-V**): Identical as ZEN's Deep Paste, but places units under the cursor instead.

<h2>How to - Spawn Ammo Resupply</h2>

* Select initial option in the first window. If you cancel in the first window, it will not open up the second one.
Expand All @@ -74,7 +77,7 @@ This mod also adds:
* "Control" + "shift" modifies the amount by 50.
* When you press ok, it will spawn the magazines.

<h2>JIP & Building destruction features</h2>
<h2>Building destruction feature</h2>

Only 1 client needs it to be enabled for it to be added to the server. If multiple clients have Zeus Additions and one or more have it turned on but the others not, the feature will still be enabled.

Expand Down
9 changes: 8 additions & 1 deletion README_steam.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
[h2]Modules[/h2]
[list]
[*] ACE Drag and Carry
[*] ACE Drag Bodies (hidden if you're using ACE 3.18.0 as it's now native to ACE)
[*] ACE Medical Injuries
[*] ACE Medical Resupply
[*] AI Crew Behaviour
Expand Down Expand Up @@ -52,6 +51,14 @@ This mod also adds:
[*] gravity to objects that don't have gravity, when a building is destroyed. This must be enabled in the CBA settings.
[/list]

[h2]CBA Keybinds[/h2]
[list]
[*] Deep Copy (default: [b]Ctrl-Alt-C[/b])
[*] Deep Paste (default: [b]Ctrl-Alt-V[/b])
[/list]

For more detailed information on the keybinds and what they do, click [url=https://github.com/johnb432/Zeus-Additions#readme]here[/url].

[h2]Links[/h2]
[list]
[*] [url=https://steamcommunity.com/sharedfiles/filedetails/?id=2387297579]Steam Workshop[/url]
Expand Down
12 changes: 10 additions & 2 deletions addons/main/CfgContext.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,14 @@ class zen_context_menu_actions {
statement = QUOTE([ARR_2(_objects,'enableAI')] call FUNC(pathingStatement));
};

class GVAR(assembleStaticWeapon) {
condition = QUOTE(true);
displayName = CSTRING(assembleStaticWeapon);
icon = "\A3\ui_f\data\map\vehicleicons\iconStaticMG_ca.paa";
insertChildren = QUOTE([_objects] call FUNC(assembleStaticWeaponActions));
priority = 50;
};

#if __has_include("\z\ace\addons\medical_gui\script_component.hpp")
class GVAR(openMedicalMenuContextMenu) {
condition = QUOTE(_hoveredEntity isEqualType objNull && {private _object = ([ARR_2(_hoveredEntity,effectiveCommander _hoveredEntity)] select (alive _hoveredEntity)); _object isKindOf 'CAManBase' && {[ARR_2(objNull,_object)] call ace_medical_gui_fnc_canOpenMenu}});
Expand All @@ -28,7 +36,7 @@ class zen_context_menu_actions {
#endif

class GVAR(selectParadropContextMenu) {
condition = QUOTE(private _object = objNull; (_objects select {alive _x}) findIf {_object = _x; [ARR_4('LandVehicle','Ship','CAManBase','Thing')] findIf {_object isKindOf _x} != -1} != -1);
condition = QUOTE((_objects select {alive _x}) findIf {private _object = _x; [ARR_4('LandVehicle','Ship','CAManBase','Thing')] findIf {_object isKindOf _x} != -1} != -1);
displayName = CSTRING(selectParadropContextMenu);
icon = ICON_PARADROP;
priority = 10;
Expand All @@ -41,7 +49,7 @@ class zen_context_menu_actions {
};

class GVAR(selectParadropVehiclesContextMenu) {
condition = QUOTE(private _object = objNull; (_objects select {alive _x}) findIf {_object = _x; [ARR_2('LandVehicle','Ship')] findIf {_object isKindOf _x} != -1} != -1);
condition = QUOTE((_objects select {alive _x}) findIf {private _object = _x; [ARR_2('LandVehicle','Ship')] findIf {_object isKindOf _x} != -1} != -1);
displayName = CSTRING(selectParadropVehiclesContextMenu);
icon = ICON_PARADROP;
statement = QUOTE([ARR_2(_objects,PARADROP_VEHICLES)] call FUNC(unitParadropContextMenu));
Expand Down
2 changes: 1 addition & 1 deletion addons/main/CfgVersioning.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ class CfgSettings {
class Versioning {
class PREFIX {
class Dependencies {
ACE[] = {"ace_main", {3, 16, 2}, QUOTE(isClass (configFile >> 'CfgPatches' >> 'ace_main'))};
ACE[] = {"ace_main", {3, 18, 0}, QUOTE(isClass (configFile >> 'CfgPatches' >> 'ace_main'))};
CBA[] = {"cba_main", {3, 16, 0}, "true"};
ZEN[] = {"zen_main", {1, 14, 0}, "true"};
};
Expand Down
2 changes: 2 additions & 0 deletions addons/main/XEH_PREP.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
PREP(assembleStaticWeapon);
PREP(assembleStaticWeaponActions);
PREP(compileSanitisedFunction);
PREP(getRole);
PREP(globalEventJIP);
Expand Down
7 changes: 2 additions & 5 deletions addons/main/XEH_postInit.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ if (isNil QGVAR(functionsSent)) then {

if (!hasInterface) exitWith {};

#include "initKeybinds.inc.sqf"

// Add mission counter only if player is curator; However, check every time the zeus interface is opened
["zen_curatorDisplayLoaded", {
// Wait until CBA settings have been initialised
Expand All @@ -24,11 +26,6 @@ if (!hasInterface) exitWith {};
if (GETMVAR("CBA_settings_ready",false)) then {
[QGVAR(buildingDestruction), getPlayerUID player, GVAR(enableBuildingDestructionHandling), QFUNC(handleBuildingDestruction)] call FUNC(changeReason);
};

// Add Drag Bodies module
if (!isNil "ace_dragging" && {getNumber (_cfgPatches >> "ace_main" >> "version") < 3.18}) then {
#include "modules\module_dragBodies.inc.sqf"
};
}] call CBA_fnc_addEventHandlerArgs;

// Add functionality
Expand Down
49 changes: 49 additions & 0 deletions addons/main/functions/fnc_assembleStaticWeapon.sqf
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
#include "..\script_component.hpp"
/*
* Author: johnb43
* Makes two units assemble a static weapon.
*
* Arguments:
* 0: Tripod unit and associated backpack <ARRAY>
* 1: Weapon unit and associated backpack <ARRAY>
*
* Return Value:
* None
*
* Example:
* [[player, backpackContainer player], [cursorObject, backpackContainer cursorObject]] call zeus_additions_main_fnc_assembleStaticWeapon;
*
* Public: No
*/

params ["_base", "_weapon"];
_base params ["_baseUnit", "_baseBackpack"];
_weapon params ["_weaponUnit"];

[[_baseUnit, _weaponUnit], {
params ["_successful", "_units", "_position", "_baseBackpack"];

if (!_successful) exitWith {};

_units doMove ASLToATL _position;

[{
params ["_args", "_pfhId"];
_args params ["_baseUnit", "_weaponUnit", "_baseBackpack"];

if (!alive _baseUnit || {!alive _weaponUnit} || {isNull _baseBackpack}) exitWith {
_pfhId call CBA_fnc_removePerFrameHandler;
};

if !(moveToCompleted _baseUnit || {moveToCompleted _weaponUnit}) exitWith {};

_pfhId call CBA_fnc_removePerFrameHandler;

// Drop base on ground
_baseUnit action ["PutBag"];

[{
(_this select 0) action ["Assemble", _this select 1];
}, [_weaponUnit, _baseBackpack], 1] call CBA_fnc_waitAndExecute;
}, 0, [_units select 0, _units select 1, _baseBackpack]] call CBA_fnc_addPerFrameHandler;
}, _baseBackpack, LSTRING(assembleStaticWeaponHere)] call zen_common_fnc_selectPosition;
67 changes: 67 additions & 0 deletions addons/main/functions/fnc_assembleStaticWeaponActions.sqf
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
#include "..\script_component.hpp"
/*
* Author: johnb43
* Returns children actions for assembling static weapons.
*
* Arguments:
* 0: Objects <OBJECT>
*
* Return Value:
* Actions <ARRAY>
*
* Example:
* [units cursorObject] call zeus_additions_main_fnc_assembleStaticWeaponActions;
*
* Public: No
*/

params ["_objects"];

// Get all backpacks that can be used to assemble a static weapon
private _unitBackpacks = [];

{
private _backpack = backpackContainer _x;

if (!isNull _backpack && {!isNull (configOf _backpack >> "assembleInfo")}) then {
_unitBackpacks pushBack [_x, backpackContainer _x];
};
} forEach (_objects select {alive _x && {_x isKindOf "CAManBase"}});

private _validPairs = [];

// Check if there are any other units that have valid backpacks
{
_x params ["_unit", "_backpack"];

private _backpackType = typeOf _backpack;

{
if (((getArray (configOf (_x select 1) >> "assembleInfo" >> "base")) findIf {_backpackType == _x}) != -1) then {
_validPairs pushBack [[_unit, _backpack], _x];
};
} forEach _unitBackpacks;
} forEach _unitBackpacks;

private _cfgVehicles = configFile >> "CfgVehicles";

_validPairs apply {
_x params ["", "_weapon"];

private _staticConfig = _cfgVehicles >> getText (configOf (_weapon select 1) >> "assembleInfo" >> "assembleTo");

[
[
hashValue (_weapon select 1),
getText (_staticConfig >> "displayName"),
getText (_staticConfig >> "picture"),
{
_args call FUNC(assembleStaticWeapon);
},
{true},
_x
] call zen_context_menu_fnc_createAction,
[],
0
]
} // return
2 changes: 1 addition & 1 deletion addons/main/functions/fnc_compileSanitisedFunction.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
* None
*
* Example:
* ["x\zeus_additions\addons\main\functions\fnc_compileSanitisedFunction.sqf", "zeus_additions_main_fnc_compileSanitisedFunction"] call zeus_additions_main_fnc_compileSanitisedFunction
* ["x\zeus_additions\addons\main\functions\fnc_compileSanitisedFunction.sqf", "zeus_additions_main_fnc_compileSanitisedFunction"] call zeus_additions_main_fnc_compileSanitisedFunction;
*
* Public: No
*/
Expand Down
2 changes: 1 addition & 1 deletion addons/main/functions/fnc_createInjuriesHandler.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* Example:
* [player,
* [[0, 4, false], [0, 0, false], [0, 0, false], [0, 0, false], [0, 0, false], [0, 0, false]],
* "Avulsion"] call zeus_additions_main_fnc_createInjuriesHandler
* "Avulsion"] call zeus_additions_main_fnc_createInjuriesHandler;
* --> 4 Minor avulsions to the Head
*
* Public: No
Expand Down
3 changes: 3 additions & 0 deletions addons/main/functions/fnc_garrisonBuilding.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@
* Return Value:
* None
*
* Example:
* [cursorObject, west, [], false, false, 0, 1, 2] call zeus_additions_main_fnc_garrisonBuilding
*
* Public: No
*/

Expand Down
4 changes: 2 additions & 2 deletions addons/main/functions/fnc_gui_createResupply.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ _ctrlListMagazines ctrlAddEventHandler ["KeyDown", {
"ace" callExtension ["clipboard:complete", []];
};
} else {
copyToClipboard _export
copyToClipboard _export;
};

true
Expand Down Expand Up @@ -192,7 +192,7 @@ _ctrlListSelected ctrlAddEventHandler ["KeyDown", {
"ace" callExtension ["clipboard:complete", []];
};
} else {
copyToClipboard _export
copyToClipboard _export;
};

true
Expand Down
2 changes: 1 addition & 1 deletion addons/main/functions/fnc_sanitiseFunction.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* Sanitised function <CODE> <STRING>
*
* Example:
* {nil} call zeus_additions_main_fnc_sanitiseFunction
* {nil} call zeus_additions_main_fnc_sanitiseFunction;
*
* Public: No
*/
Expand Down
2 changes: 1 addition & 1 deletion addons/main/functions/fnc_unitParadropContextMenu.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ if (_filterMode == PARADROP_MISC) exitWith {
[LSTRING(selectedParadropObjectsContextMenu), count _misc] call zen_common_fnc_showMessage;
};

private _units = _objects select {_x isKindOf "CAManBase" && {getNumber ((configOf _unit) >> "isPlayableLogic") == 0}};
private _units = _objects select {_x isKindOf "CAManBase" && {getNumber ((configOf _x) >> "isPlayableLogic") == 0}};

[LSTRING(paradropContextMenu), [
["TOOLBOX:YESNO", [LSTRING(paradropContextMenuIncludeGroup), LSTRING(paradropContextMenuIncludeGroupDesc)], false, true],
Expand Down
3 changes: 0 additions & 3 deletions addons/main/gui.hpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
class RscText;
class RscTextMulti;
class RscButton;
class RscStructuredText;
class RscButtonMenu;
class RscButtonMenuOK;
class RscButtonMenuCancel;
Expand Down Expand Up @@ -163,7 +161,6 @@ class ctrlButtonPictureKeepAspect;

class zen_common_RscLabel;
class zen_common_RscBackground;
class zen_common_RscEdit;
class zen_modules_RscSidesCombo;

class zen_common_RscDisplay {
Expand Down
Loading
Loading