ACE3/addons/common/functions/fnc_checkPBOs.sqf

39 lines
833 B
Plaintext
Raw Normal View History

/*
* Author: commy2
*
* Used to execute the checkPBOs module without placing the module. Don't use this together with the module.
*
* Argument:
* 0: Mode (Number)
* 0: Warn once
* 1: Warn permanently
* 2: Kick
* 1: Check all PBOs? (Boolean, optional default: "[]")
* 2: Whitelist (String, optinal default: false)
*
* Return value:
* None.
*/
2015-01-13 19:56:02 +00:00
#include "script_component.hpp"
2015-05-14 18:06:06 +00:00
private ["_logic"];
_this resize 3;
2015-05-14 18:06:06 +00:00
PARAMS_3(_mode,_checkAll,_whitelist);
if (isNil "_checkAll") then {
2015-05-09 14:06:44 +00:00
_checkAll = false;
};
if (isNil "_whitelist") then {
2015-05-09 14:06:44 +00:00
_whitelist = "[]";
};
_logic = "Logic" createVehicleLocal [0,0,0];
_logic setVariable ["Action", _mode];
_logic setVariable ["CheckAll", _checkAll];
_logic setVariable ["Whitelist", _whitelist];
2015-01-11 18:20:14 +00:00
[_logic, [], true] call FUNC(moduleCheckPBOs);
deleteVehicle _logic;