Backpacks - Code cleanup (#9409)

backpacks
This commit is contained in:
Grim 2023-09-24 00:13:33 -04:00 committed by GitHub
parent 0d9bcdd708
commit bf6dc5a7a1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 5 deletions

View File

@ -1,3 +1,3 @@
#include "script_component.hpp"
["ace_backpackOpened", {_this call FUNC(backpackOpened)}] call CBA_fnc_addEventHandler;
["ace_backpackOpened", LINKFUNC(backpackOpened)] call CBA_fnc_addEventHandler;

View File

@ -17,10 +17,10 @@
params [["_backpack", objNull, [objNull, ""]]];
private _config = if (_backpack isEqualType objNull) then {
configOf _backpack
} else {
configFile >> "CfgVehicles" >> _backpack
if (_backpack isEqualType objNull) exitWith {
maxLoad _backpack > 0
};
private _config = configFile >> "CfgVehicles" >> _backpack;
getText (_config >> "vehicleClass") == "backpacks" && {getNumber (_config >> "maximumLoad") > 0} // return