ACE3/docs/wiki/framework/trenches-framework.md
Filip Maciejewski 508e669e05
Trenches - Add modded Entrenching Tools support (#8999)
* Add support for other entrenching tools

* Docs

* Remove unused variable

* Check unit weapons for entrenching tool

`weapons` returns weapons in weapon slots and from all containers.

* Update addons/trenches/README.md

Co-authored-by: Jouni Järvinen <rautamiekka@users.noreply.github.com>

* Support for shovel Backpacks

* Update XEH_preStart.sqf

* Add Arsenal "Entrenching Tool" stat

Co-authored-by: Jouni Järvinen <rautamiekka@users.noreply.github.com>
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2022-09-05 00:21:29 +02:00

1.1 KiB

layout title description group order parent mod version
wiki Trenches Framework Explains how to set-up surface whitelisting and entrenching tools. framework 5 wiki ace
major minor patch
3 5 0

1. Config Values

1.1 Whitelisting surfaces for digging

Single surfaces can be whitelisted by adding ACE_canDig = 1 into CfgSurfaces.

class CfgSurfaces {
    class myAwesomeSurface {
        ACE_canDig = 1;
    };
};

1.2 Enabling entrenching tool features on an item or backpack

class CfgWeapons { // same config also works on backpacks (CfgVehicles)
    class yourBaseClass;
    class yourEntrenchingToolClass: yourBaseClass
        ace_trenches_entrenchingTool = 1;
    };
};

2. Scripting

2.1 Checking if unit has entrenching tool

ace_trenches_fnc_hasEntrenchingTool Used to check if unit has any entrenching capable tool.

 * Checks if unit has entrenching tool.
 *
 * Arguments:
 * 0: Unit <OBJECT>
 *
 * Return Value:
 * Has entrenching tool <BOOL>
 *
 * Example:
 * [bob] call ace_trenches_fnc_hasEntrenchingTool