From e08dff4f6b3ba782adc1c4b520ecc7ae387b2e10 Mon Sep 17 00:00:00 2001 From: He-Man Date: Wed, 31 Aug 2016 17:33:37 +0200 Subject: [PATCH] Update EPOCH_load_vehicles.sqf --- .../compile/epoch_vehicle/EPOCH_load_vehicles.sqf | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/Sources/epoch_server/compile/epoch_vehicle/EPOCH_load_vehicles.sqf b/Sources/epoch_server/compile/epoch_vehicle/EPOCH_load_vehicles.sqf index d23544cd..8603cbc5 100644 --- a/Sources/epoch_server/compile/epoch_vehicle/EPOCH_load_vehicles.sqf +++ b/Sources/epoch_server/compile/epoch_vehicle/EPOCH_load_vehicles.sqf @@ -24,6 +24,8 @@ _vehicleDamages = []; _serverSettingsConfig = configFile >> "CfgEpochServer"; _simulationHandler = [_serverSettingsConfig, "simulationHandlerOld", false] call EPOCH_fnc_returnConfigEntry; +_removeweapons = [_serverSettingsConfig, "removevehweapons", []] call EPOCH_fnc_returnConfigEntry; +_removemagazinesturret = [_serverSettingsConfig, "removevehmagazinesturret", []] call EPOCH_fnc_returnConfigEntry; for "_i" from 1 to _maxVehicleLimit do { _vehicleSlotIndex = EPOCH_VehicleSlots pushBack str(_i); @@ -109,6 +111,18 @@ for "_i" from 1 to _maxVehicleLimit do { clearMagazineCargoGlobal _vehicle; clearBackpackCargoGlobal _vehicle; clearItemCargoGlobal _vehicle; + + if !(_removeweapons isequalto []) then { + { + _vehObj removeWeaponGlobal _x; + } foreach _removeweapons; + }; + if !(_removemagazinesturret isequalto []) then { + { + _vehObj removeMagazinesTurret _x; + } foreach _removemagazinesturret; + }; + { _objType = _forEachIndex; _objTypes = _x;