Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {
- {
- if (getPlayerUID _x != "" && isPlayer _x) then
- {
- _dir = getdir _x;
- _pos = getPosATL _x;
- _pos = [(_pos select 0)+2*sin(_dir),(_pos select 1)+2*cos(_dir),(_pos select 2)];
- [_dir,_pos] spawn {
- _dir = _this select 0;
- _pos = _this select 1;
- _b0x = 'Foodbox1' createVehicle _pos;
- _b0x setPosATL _pos;
- clearWeaponCargoGlobal _b0x;
- clearmagazinecargoGlobal _b0x;
- if (isNil "PV_b0x_wpnlist") then
- {
- PV_b0x_wpnlist = [];
- _CfgWeapons = configFile >> "CfgWeapons";
- for "_i" from 0 to (count _CfgWeapons)-1 do
- {
- _weapon = _CfgWeapons select _i;
- if (isClass _weapon) then
- {
- _wpn_type = configName(_weapon);
- _plx = toArray _wpn_type;
- _plx resize 7;
- _plx;
- _plx = toString _plx;
- if (((_plx != "ItemKey") || (_wpn_type == "ItemKeyKit")) && (_wpn_type != "MineE")) then
- {
- if (((getNumber (_weapon >> "scope") == 0) || (getNumber (_weapon >> "scope") == 2)) && (getText (_weapon >> "picture") != "")) then
- {
- PV_b0x_wpnlist = PV_b0x_wpnlist + [_wpn_type];
- };
- };
- };
- };
- uiSleep 2;
- };
- if (isNil "PV_b0x_maglist") then
- {
- PV_b0x_maglist = [];
- _CfgWeapons = configFile >> "CfgMagazines";
- for "_i" from 0 to (count _CfgWeapons)-1 do
- {
- _weapon = _CfgWeapons select _i;
- if (isClass _weapon) then
- {
- _wpn_type = configName(_weapon);
- if (((getNumber (_weapon >> "scope") == 0) || (getNumber (_weapon >> "scope") == 2)) && (getText (_weapon >> "picture") != "") && !(_wpn_type == "AngelCookies")) then
- {
- PV_b0x_maglist = PV_b0x_maglist + [_wpn_type];
- };
- };
- };
- uiSleep 2;
- };
- {_b0x addWeaponCargoGlobal [_x, 5];} forEach PV_b0x_wpnlist;
- {_b0x addMagazineCargoGlobal [_x, 20];} forEach PV_b0x_maglist;
- _b0x addBackpackCargoGlobal ["DZ_Backpack_EP1", 1];
- _b0x setVariable ['HBC',3,true];
- };
- };
- } forEach (crew _x);
- } forEach ([0,0,0] nearEntities ["AllVehicles", 10000000]);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement