diff --git a/addons/cargo/functions/fnc_loadItem.sqf b/addons/cargo/functions/fnc_loadItem.sqf index 1d59cc1e646..bb608ff9266 100644 --- a/addons/cargo/functions/fnc_loadItem.sqf +++ b/addons/cargo/functions/fnc_loadItem.sqf @@ -13,7 +13,7 @@ * Example: * [object, vehicle] call ace_cargo_fnc_loadItem * - * Public: No + * Public: Yes */ #include "script_component.hpp" diff --git a/addons/cargo/functions/fnc_unloadItem.sqf b/addons/cargo/functions/fnc_unloadItem.sqf index 47ff3ba36e9..20fde5d6311 100644 --- a/addons/cargo/functions/fnc_unloadItem.sqf +++ b/addons/cargo/functions/fnc_unloadItem.sqf @@ -5,14 +5,15 @@ * Arguments: * 0: Item * 1: Vehicle + * 2: Unloader (default: objNull) * * Return Value: - * Object unloaded + * Object was unloaded * * Example: * [object, vehicle] call ace_cargo_fnc_unloadItem * - * Public: No + * Public: Yes */ #include "script_component.hpp" diff --git a/docs/wiki/framework/cargo-framework.md b/docs/wiki/framework/cargo-framework.md index 03ddf4e757d..091969b91f7 100644 --- a/docs/wiki/framework/cargo-framework.md +++ b/docs/wiki/framework/cargo-framework.md @@ -46,20 +46,10 @@ class staticBananaLauncher { ### 2.1 Listenable -Event Name | Description | Passed Parameter(s) | Locality +Event Name | Passed Parameter(s) | Locality | Description ---------- | ----------- | ------------------- | -------- -`cargoLoaded` | Cargo has been loaded | ` [_item, _vehicle]` | Global -`cargoUnloaded` | Cargo has been unloaded | `[_item, _vehicle]` | Global -`cargoAddedByClass` | Cargo items have been added | `[_itemClass, _vehicle, _amount]` | Global - -### 2.2 Callable - -Event Name | Description | Passed Parameter(s) | Locality ----------- | ----------- | ------------------- | -------- -`LoadCargo` | Load object into vehicle. | `[_object, _vehicle, _showHint]` | Local -`UnloadCargo` | Unload object from vehicle. | `[_object, _vehicle]` | Local -`AddCargoByClass` | Adds a cargo item to the vehicle. | `[_itemClass, _vehicle, _amount, _showHint]` | Local - +`ace_cargoLoaded` | [_item, _vehicle] | Global | Cargo has been Loaded into vehicle +`ace_cargoUnloaded` | [_item, _vehicle] | Global | Cargo has been Unloaded from vehicle ## 3. Scripting @@ -70,3 +60,37 @@ To disable cargo for a mission object use: ```cpp this setVariable ["ace_cargo_size", -1]; ``` + +### 3.2 Add cargo to vehicle + +`ace_cargo_fnc_loadItem` (Also callable from cba event `ace_loadCargo`) +Note first arg can be a in-game object or a classname of an object type. + +```cpp + * Arguments: + * 0: Item + * 1: Vehicle + * + * Return Value: + * Object loaded + * + * Example: + * [object, vehicle] call ace_cargo_fnc_loadItem +``` + +### 3.3 Unload cargo from vehicle + +`ace_cargo_fnc_unloadItem` (Also callable from cba event `ace_unloadCargo`) + +```cpp + * Arguments: + * 0: Item + * 1: Vehicle + * 2: Unloader (default: objNull) + * + * Return Value: + * Object was unloaded + * + * Example: + * [object, vehicle] call ace_cargo_fnc_unloadItem +``` diff --git a/docs/wiki/framework/goggles-framework.md b/docs/wiki/framework/goggles-framework.md index 4261f0a5aba..1b9b27588bb 100644 --- a/docs/wiki/framework/goggles-framework.md +++ b/docs/wiki/framework/goggles-framework.md @@ -36,5 +36,5 @@ class CfgGlasses { Event Name | Description | Passed Parameter(s) | Locality ---------- | ----------- | ------------------- | -------- -`GlassesChanged` | Glasses Changed | `[_glassesClass]` | Local -`GlassesCracked` | Glasses Cracked | `[_unit]` | Local +`ace_glassesChanged` | Glasses Changed | `[_unit, _glassesClass]` | Local +`ace_glassesCracked` | Glasses Cracked | `[_unit]` | Local diff --git a/docs/wiki/framework/overpressure-framework.md b/docs/wiki/framework/overpressure-framework.md index 79fe46104f6..23d2080514f 100644 --- a/docs/wiki/framework/overpressure-framework.md +++ b/docs/wiki/framework/overpressure-framework.md @@ -47,4 +47,4 @@ class CfgWeapons { Event Name | Description | Passed Parameter(s) | Locality ---------- | ----------- | ------------------- | -------- -`overpressure` | Overpressure damage inflicted | `[_firer, _position, _direction, _weapon]` | Target +`ace_overpressure` | Overpressure damage inflicted | `[_firer, _posASL, _direction, _weapon, _magazine, _ammo]` | Target diff --git a/docs/wiki/framework/reloadlaunchers-framework.md b/docs/wiki/framework/reloadlaunchers-framework.md index f175b60639e..d055cc533c9 100644 --- a/docs/wiki/framework/reloadlaunchers-framework.md +++ b/docs/wiki/framework/reloadlaunchers-framework.md @@ -28,4 +28,4 @@ class CfgWeapons { Event Name | Description | Passed Parameter(s) | Locality ---------- | ----------- | ------------------- | -------- -`reloadLauncher` | Launcher reloaded | `[_unit, _target, _weapon, _magazine]` | Target +`ace_reloadlaunchers_reloadLauncher` | Launcher reloaded | `[_unit, _target, _weapon, _magazine]` | Target