diff --git a/addons/cargo/functions/fnc_startLoadIn.sqf b/addons/cargo/functions/fnc_startLoadIn.sqf index 178d2fff25..938f5bd074 100644 --- a/addons/cargo/functions/fnc_startLoadIn.sqf +++ b/addons/cargo/functions/fnc_startLoadIn.sqf @@ -39,7 +39,7 @@ if ([_object, _vehicle] call FUNC(canLoadItemIn)) then { private _size = [_object] call FUNC(getSizeItem); [ - 5 * _size, + GVAR(loadTimeCoefficient) * 5 * _size, [_object, _vehicle], { [objNull, _this select 0 select 0, true] call EFUNC(common,claim); @@ -54,7 +54,7 @@ if ([_object, _vehicle] call FUNC(canLoadItemIn)) then { } else { private _displayName = getText (configFile >> "CfgVehicles" >> typeOf _object >> "displayName"); - [[LSTRING(LoadingFailed), _displayName], 3.0] call EFUNC(common,displayTextStructured); + [[LSTRING(LoadingFailed), _displayName], 3] call EFUNC(common,displayTextStructured); }; _return diff --git a/addons/cargo/functions/fnc_startUnload.sqf b/addons/cargo/functions/fnc_startUnload.sqf index eedf3b2efa..1d977f432c 100644 --- a/addons/cargo/functions/fnc_startUnload.sqf +++ b/addons/cargo/functions/fnc_startUnload.sqf @@ -70,7 +70,7 @@ if ([_item, GVAR(interactionVehicle), ACE_player] call FUNC(canUnloadItem)) then private _size = [_item] call FUNC(getSizeItem); [ - 5 * _size, + GVAR(loadTimeCoefficient) * 5 * _size, [_item, GVAR(interactionVehicle), ACE_player], {["ace_unloadCargo", _this select 0] call CBA_fnc_localEvent}, {}, @@ -82,5 +82,5 @@ if ([_item, GVAR(interactionVehicle), ACE_player] call FUNC(canUnloadItem)) then private _itemClass = if (_item isEqualType "") then {_item} else {typeOf _item}; private _displayName = getText (configFile >> "CfgVehicles" >> _itemClass >> "displayName"); - [[LSTRING(UnloadingFailed), _displayName], 3.0] call EFUNC(common,displayTextStructured); + [[LSTRING(UnloadingFailed), _displayName], 3] call EFUNC(common,displayTextStructured); }; diff --git a/addons/cargo/initSettings.sqf b/addons/cargo/initSettings.sqf index 3a9f70070a..c2c5483c46 100644 --- a/addons/cargo/initSettings.sqf +++ b/addons/cargo/initSettings.sqf @@ -1,19 +1,26 @@ -// CBA Settings [ADDON: ace_cargo]: - [ QGVAR(enable), "CHECKBOX", [LSTRING(ModuleSettings_enable), LSTRING(ModuleSettings_enable_Description)], - [localize ELSTRING(OptionsMenu,CategoryLogistics), localize LSTRING(openMenu)], - true, // default value - true, // isGlobal + [LELSTRING(OptionsMenu,CategoryLogistics), LLSTRING(openMenu)], + true, + true, {[QGVAR(enable), _this] call EFUNC(common,cbaSettings_settingChanged)} ] call CBA_settings_fnc_init; +[ + QGVAR(loadTimeCoefficient), "SLIDER", + [LSTRING(loadTimeCoefficient), LSTRING(loadTimeCoefficient_description)], + [LELSTRING(OptionsMenu,CategoryLogistics), LLSTRING(openMenu)], + [0, 3, 1, 1], + true, + {[QGVAR(loadTimeCoefficient), _this, true] call EFUNC(common,cbaSettings_settingChanged)} +] call CBA_settings_fnc_init; + [ QGVAR(paradropTimeCoefficent), "SLIDER", [LSTRING(paradropTimeCoefficent), LSTRING(paradropTimeCoefficent_description)], - [localize ELSTRING(OptionsMenu,CategoryLogistics), localize LSTRING(openMenu)], - [0,10,2.5,1], // [min, max, default value, trailing decimals (-1 for whole numbers only)] - true, // isGlobal - {[QGVAR(paradropTimeCoefficent), _this] call EFUNC(common,cbaSettings_settingChanged)} + [LELSTRING(OptionsMenu,CategoryLogistics), LLSTRING(openMenu)], + [0, 10, 2.5, 1], + true, + {[QGVAR(paradropTimeCoefficent), _this, true] call EFUNC(common,cbaSettings_settingChanged)} ] call CBA_settings_fnc_init; diff --git a/addons/cargo/stringtable.xml b/addons/cargo/stringtable.xml index 0bcd784d0d..534d255fdf 100644 --- a/addons/cargo/stringtable.xml +++ b/addons/cargo/stringtable.xml @@ -291,7 +291,7 @@ 此架飞机并无保持水平飞行 - Paradrop Time Coffecient + Paradrop Time Coefficient Türlast Zeitfaktor 空中投下までの時間係数 Coefficente Tempo Lancio Paracadute @@ -312,5 +312,11 @@ Modyfikator wskazujący jak dużo czasu potrzeba by zrzucić przedmiot na spadochronie. 화물을 공중 투하 하는데 얼마나 걸리는 시간 설정 + + Load Time Coefficient + + + Modifies how long it takes to load/unload items.\nTime, in seconds, is 5 times the size of the item multiplied by this value. +