ACE3/addons/dragging/functions/fnc_canRun_carry.sqf
Grim e5dc124fe8
Dragging - Add additional weight checks on inventory modification (#9225)
* Allow run when carrying light-weight objects

* Use global var instead of macro

* add weight check, improve getWeight & conditions

* changes from review

* changes from review - postInit

* add param to ignore PhysX mass

* add settings

* BI issue tracker in comment

* change defaults, remove overweight setting

* remove public variable

* setting name changes

* updating case in statusEffect_addType

* move to XEH

* derp

* Add some extra checks for closed events

* Update XEH_postInit.sqf

* conditions

---------

Co-authored-by: Dystopian <sddex@ya.ru>
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2023-07-22 06:30:40 +03:00

21 lines
387 B
Plaintext

#include "script_component.hpp"
/*
* Author: LinkIsGrim
* Check if weight can be carried while running
*
* Arguments:
* 0: Weight <NUMBER>
*
* Return Value:
* Can the weight be carried while running? <BOOL>
*
* Example:
* [500] call ace_dragging_fnc_canRun_carry
*
* Public: No
*/
params ["_weight"];
GVAR(allowRunWithLightweight) && {_weight <= GVAR(maxWeightCarryRun)}