/* File : fn_updateGangContainers.sqf Author: NiiRoZz Description: Update inventory "i" in container */ private _container = [_this,0,objNull,[objNull]] call BIS_fnc_param; if (isNull _container) exitWith {}; private _containerID = switch (_container) do { case con_b: {1}; case con_d: {2}; case con_a: {3}; case con_e: {4}; case con_h: {5}; default {-1}; }; if (_containerID isEqualTo -1) exitWith {}; private _vehItems = getItemCargo _container; private _vehMags = getMagazineCargo _container; private _vehWeapons = getWeaponCargo _container; private _vehBackpacks = getBackpackCargo _container; private _cargo = [_vehItems,_vehMags,_vehWeapons,_vehBackpacks]; _cargo = [_cargo] call DB_fnc_mresArray; private _query = format ["UPDATE gangcontainers SET gear='%1' WHERE id='%2'",_cargo,_containerID]; [_query,1] call DB_fnc_asyncCall;