mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Merge remote-tracking branch 'origin/medical-rewrite' into medical-rewrite
This commit is contained in:
commit
236d1f9669
@ -143,30 +143,6 @@ class ACE_Settings {
|
||||
typeName = "BOOL";
|
||||
value = 0;
|
||||
};
|
||||
class GVAR(allowLitterCreation) {
|
||||
category = CSTRING(Category_Medical);
|
||||
displayName = CSTRING(MedicalSettings_allowLitterCreation_DisplayName);
|
||||
description = CSTRING(MedicalSettings_allowLitterCreation_Description);
|
||||
typeName = "BOOL";
|
||||
value = 1;
|
||||
};
|
||||
class GVAR(litterSimulationDetail) {
|
||||
category = CSTRING(Category_Medical);
|
||||
displayName = CSTRING(litterSimulationDetail);
|
||||
description = CSTRING(litterSimulationDetail_Desc);
|
||||
typeName = "SCALAR";
|
||||
|
||||
value = 3;
|
||||
values[] = {"Off", "Low", "Medium", "High", "Ultra"};
|
||||
_values[] = { 0, 50, 100, 1000, 5000 };
|
||||
};
|
||||
class GVAR(litterCleanUpDelay) {
|
||||
category = CSTRING(Category_Medical);
|
||||
displayName = CSTRING(MedicalSettings_litterCleanUpDelay_DisplayName);
|
||||
description = CSTRING(MedicalSettings_litterCleanUpDelay_Description);
|
||||
typeName = "SCALAR";
|
||||
value = 0;
|
||||
};
|
||||
class GVAR(medicSetting_basicEpi) {
|
||||
category = CSTRING(Category_Medical);
|
||||
displayName = CSTRING(BasicMedicalSettings_medicSetting_basicEpi_DisplayName);
|
||||
|
@ -11,7 +11,6 @@ call FUNC(stateMachine);
|
||||
if (isServer) then {
|
||||
["ace_placedInBodyBag", FUNC(serverRemoveBody)] call CBA_fnc_addEventHandler;
|
||||
};
|
||||
[QGVAR(createLitterServer), FUNC(handleCreateLitter)] call CBA_fnc_addEventHandler;
|
||||
|
||||
["ace_unconscious", {
|
||||
params ["_unit", "_status"];
|
||||
|
@ -1,93 +0,0 @@
|
||||
/*
|
||||
* Author: Glowbal
|
||||
* Spawns litter for the treatment action on the ground around the target
|
||||
*
|
||||
* Arguments:
|
||||
* 0: The Caller <OBJECT>
|
||||
* 1: The target <OBJECT>
|
||||
* 2: The treatment Selection Name <STRING>
|
||||
* 3: The treatment classname <STRING>
|
||||
* 4: ?
|
||||
* 5: Users of Items <?>
|
||||
* 6: Blood Loss on selection (previously called _previousDamage) <NUMBER>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
|
||||
#include "script_component.hpp"
|
||||
|
||||
#define MIN_ENTRIES_LITTER_CONFIG 3
|
||||
|
||||
params ["_caller", "_target", "_selectionName", "_className", "", "_usersOfItems", "_bloodLossOnSelection"];
|
||||
TRACE_6("params",_caller,_target,_selectionName,_className,_usersOfItems,_bloodLossOnSelection);
|
||||
|
||||
//Ensures comptibilty with other possible medical treatment configs
|
||||
private _previousDamage = _bloodLossOnSelection;
|
||||
|
||||
if !(GVAR(allowLitterCreation)) exitwith {};
|
||||
if (vehicle _caller != _caller || {vehicle _target != _target}) exitwith {};
|
||||
|
||||
private _config = if (GVAR(level) >= 2) then {
|
||||
(configFile >> "ACE_Medical_Actions" >> "Advanced" >> _className);
|
||||
} else {
|
||||
(configFile >> "ACE_Medical_Actions" >> "Basic" >> _className)
|
||||
};
|
||||
if !(isClass _config) exitwith {TRACE_1("No action config", _className);};
|
||||
|
||||
if !(isArray (_config >> "litter")) exitwith {TRACE_1("No litter config", _className);};
|
||||
private _litter = getArray (_config >> "litter");
|
||||
|
||||
private _createLitter = {
|
||||
params ["_unit", "_litterClass"];
|
||||
// @TODO: handle carriers over water
|
||||
// For now, don't spawn litter if we are over water to avoid floating litter
|
||||
if (surfaceIsWater (getPos _unit)) exitWith { false };
|
||||
|
||||
private _position = getPosATL _unit;
|
||||
_position params ["_posX", "_posY", "_posZ"];
|
||||
_position = [_posX + (random 2) - 1, _posY + (random 2) - 1, _posZ];
|
||||
|
||||
private _direction = (random 360);
|
||||
|
||||
// Create the litter, and timeout the event based on the cleanup delay
|
||||
// The cleanup delay for events in MP is handled by the server side
|
||||
TRACE_3("Creating Litter on server",_litterClass,_position,_direction);
|
||||
[QGVAR(createLitterServer), [_litterClass, _position, _direction]] call CBA_fnc_serverEvent;
|
||||
|
||||
true
|
||||
};
|
||||
|
||||
private _createdLitter = [];
|
||||
{
|
||||
if (_x isEqualType []) then {
|
||||
if (count _x < MIN_ENTRIES_LITTER_CONFIG) exitwith {};
|
||||
|
||||
_x params ["_selection", "_litterCondition", "_litterOptions"];
|
||||
|
||||
if (toLower _selection in [toLower _selectionName, "all"]) then { // in is case sensitve. We can be forgiving here, so lets use toLower.
|
||||
|
||||
if (isnil _litterCondition) then {
|
||||
_litterCondition = if (_litterCondition != "") then {compile _litterCondition} else {{true}};
|
||||
} else {
|
||||
_litterCondition = missionNamespace getVariable _litterCondition;
|
||||
if (!(_litterCondition isEqualType {})) then {_litterCondition = {false}};
|
||||
};
|
||||
if !([_caller, _target, _selectionName, _className, _usersOfItems, _bloodLossOnSelection] call _litterCondition) exitwith {};
|
||||
|
||||
if (_litterOptions isEqualType []) then {
|
||||
// Loop through through the litter options and place the litter
|
||||
{
|
||||
if (_x isEqualType [] && {(count _x > 0)}) then {
|
||||
[_target, selectRandom _x] call _createLitter;
|
||||
};
|
||||
if (_x isEqualType "") then {
|
||||
[_target, _x] call _createLitter;
|
||||
};
|
||||
} foreach _litterOptions;
|
||||
};
|
||||
};
|
||||
};
|
||||
} foreach _litter;
|
@ -25,30 +25,6 @@
|
||||
<Czech>Žádné zranění na této části těla...</Czech>
|
||||
<Portuguese>Nenhum ferimento nesta parte do corpo...</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_litterSimulationDetail">
|
||||
<English>Litter Simulation Detail</English>
|
||||
<Polish>Detale zużytych medykamentów</Polish>
|
||||
<Spanish>Detalle de simulación de basura</Spanish>
|
||||
<Russian>Количество мусора от медицины</Russian>
|
||||
<Italian>Dettagli Simulazione Rifiuti</Italian>
|
||||
<French>Niveau de simulation des détritus</French>
|
||||
<German>Abfall-Detaillevel</German>
|
||||
<Hungarian>Hulladékszimuláció részletessége</Hungarian>
|
||||
<Portuguese>Detalhe da simulação de sujeira</Portuguese>
|
||||
<Czech>Počet zobrazených předmětů po použití zdravotnického materiálu</Czech>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_litterSimulationDetail_Desc">
|
||||
<English>Litter simulation detail level sets the number of litter items which will be locally spawned in the client. Excessive amounts in local areas could cause FPS lag, so this is a client only setting.</English>
|
||||
<Polish>Opcja ta ustawia liczbę zużytych medykamentów, jakie pojawiają się lokalnie wokół gracza. Ich zbyt duża ilość może spowodować spadki FPS, dlatego jest to ustawienie tylko po stronie klienta.</Polish>
|
||||
<Spanish>Detalle simulación de basura establece el número de artículos de basura que se generan a nivel local en el cliente. Las cantidades excesivas en áreas locales podrían causar caída de rendimiento, así que esto es un ajuste de cliente únicamente.</Spanish>
|
||||
<Russian>Устанавливает количество мусора, который появляется после использования мед. препаратов. Большое количество мусора может уменьшить производительность, поэтому данная настройка локальна для клиента.</Russian>
|
||||
<Italian>Il numero di rifiuti che verranno creati localmente. La creazione di troppi rifiuti in aree locali potrebbe causare lag e calo di FPS. Questo è un settaggio lato client.</Italian>
|
||||
<French>Le niveau de simulation des détritus règle la quantité de déchets qui vont être créés localement chez le client. Des quantitées excessive chez certains clients peuvent causer des chutes de FPS, c'est donc une option client uniquement.</French>
|
||||
<German>Die Einstellung für das Abfall-Detaillevel stellt die Menge des lokal angezeigten medizinischen Abfalls ein. Zuviel Abfall kann FPS-Einbrüche erzeugen, weswegen diese Einstellung nur clientseitig ist.</German>
|
||||
<Hungarian>A hulladékszimuláció részletessége megszabja a kliens által megjelenített hulladékobjektumok mennyiségét. Súlyos mennyiségek izolált területeken alacsony FPS-t okozhatnak, így ez egy kliensoldali beállítás.</Hungarian>
|
||||
<Portuguese>O nível de detalhe de sujeira determina o número de itens que irão aparecer no cliente. Quantidades excessivas em áreas locais podem aumentar o lag do FPS, então esta é uma opção somente para o cliente.</Portuguese>
|
||||
<Czech>Počet zobrazených předmětů po použití zdravotnického materiálu ovlivňuje počet objektů, které budou zobrazeny klientovi v místě použití zdravotnického materiálu. Vyšší množství objektů může způsobovat poklesy FPS a proto je toto nastavení čistě na klientovi.</Czech>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_Inject_Adenosine">
|
||||
<English>Inject Adenosine</English>
|
||||
<German>Adenosin injizieren</German>
|
||||
@ -2547,54 +2523,6 @@
|
||||
<Hungarian>Orvosok letiltása</Hungarian>
|
||||
<Italian>Disabilita medici</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_MedicalSettings_allowLitterCreation_DisplayName">
|
||||
<English>Enable Litter</English>
|
||||
<Russian>Включить мусор</Russian>
|
||||
<Polish>Aktywuj odpadki</Polish>
|
||||
<Spanish>Activar restos médicos</Spanish>
|
||||
<German>Abfälle aktivieren</German>
|
||||
<Czech>Povolit odpadky</Czech>
|
||||
<Portuguese>Ativar lixo médico</Portuguese>
|
||||
<French>Activer les détritus</French>
|
||||
<Hungarian>Szemét engedélyezése</Hungarian>
|
||||
<Italian>Abilita Barella</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_MedicalSettings_allowLitterCreation_Description">
|
||||
<English>Enable litter being created upon treatment</English>
|
||||
<Russian>Включить появление мусора после лечения</Russian>
|
||||
<Polish>Twórz odpadki medyczne podczas leczenia</Polish>
|
||||
<Spanish>Activar los restos médicos que se crean en el tratamiento</Spanish>
|
||||
<German>Aktiviere Abfälle, wenn eine Behandlung durchgeführt wurde</German>
|
||||
<Czech>Vytváří odpad zdravotnického materiálu pří léčení</Czech>
|
||||
<Portuguese>Ativar lixo ser criado após tratamento</Portuguese>
|
||||
<French>Activer la création de détrimus au début des traitements</French>
|
||||
<Hungarian>Engedélyezi a szemét keletkezését ellátáskor</Hungarian>
|
||||
<Italian>Abilita la creazione della barella dopo trattamento</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_MedicalSettings_litterCleanUpDelay_DisplayName">
|
||||
<English>Life time of litter objects</English>
|
||||
<Russian>Время удаления мусора</Russian>
|
||||
<Polish>Długość życia odpadków</Polish>
|
||||
<Spanish>Tiempo de vida de los restos médicos</Spanish>
|
||||
<German>Dauer des angezeigten Abfalls</German>
|
||||
<Czech>Životnost pro odpadky</Czech>
|
||||
<Portuguese>Tempo de vida dos objetos do lixo</Portuguese>
|
||||
<French>Durée d'affichage des détritus</French>
|
||||
<Hungarian>Szemétobjektumok élettartama</Hungarian>
|
||||
<Italian>Tempo di vita delle barelle</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_MedicalSettings_litterCleanUpDelay_Description">
|
||||
<English>How long should litter objects stay? In seconds. -1 is forever.</English>
|
||||
<Russian>Как долго мусор будет оставаться на земле? В секундах. -1 означает бесконечное время.</Russian>
|
||||
<Polish>Ile czasu musi upłynąć, aby odpadki zaczęły znikać? W sekundach. -1 dla nieskończoności.</Polish>
|
||||
<Spanish>¿Por cuánto tiempo deben permanecer los restos médicos? En segundos. -1 es para siempre.</Spanish>
|
||||
<German>Wie lange sollen Abfälle am Boden liegen (in Sekunden)? -1 ist für immer.</German>
|
||||
<Czech>Za jak dlouho začnou odpadky mizet? V sekundách. -1 navždy.</Czech>
|
||||
<Portuguese>Quanto tempo os objetos do lixo devem ficar? Em segundos. -1 é para sempre.</Portuguese>
|
||||
<French>Combien de temps doivent rester affiché les détritus? En secondes. -1 pour tout le temps</French>
|
||||
<Hungarian>Milyen sokáig legyenek jelen a szemétobjektumok (másodpercben)? A -1 végtelen időt jelent.</Hungarian>
|
||||
<Italian>Per quanto devono restare le barelle? In secondi. -1 è permanente</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_MedicalSettings_enableScreams_DisplayName">
|
||||
<English>Enable Screams</English>
|
||||
<Russian>Включить крики</Russian>
|
||||
|
26
addons/medical_treatment/ACE_Settings.hpp
Normal file
26
addons/medical_treatment/ACE_Settings.hpp
Normal file
@ -0,0 +1,26 @@
|
||||
class ACE_Settings {
|
||||
class EGVAR(medical,allowLitterCreation) {
|
||||
category = ECSTRING(medical,Category_Medical);
|
||||
displayName = CSTRING(allowLitterCreation);
|
||||
description = CSTRING(allowLitterCreation_Description);
|
||||
typeName = "BOOL";
|
||||
value = 1;
|
||||
};
|
||||
class EGVAR(medical,litterSimulationDetail) {
|
||||
category = ECSTRING(medical,Category_Medical);
|
||||
displayName = CSTRING(litterSimulationDetail);
|
||||
description = CSTRING(litterSimulationDetail_Description);
|
||||
typeName = "SCALAR";
|
||||
|
||||
value = 3;
|
||||
values[] = {"Off", "Low", "Medium", "High", "Ultra"};
|
||||
_values[] = { 0, 50, 100, 1000, 5000 };
|
||||
};
|
||||
class EGVAR(medical,litterCleanUpDelay) {
|
||||
category = ECSTRING(medical,Category_Medical);
|
||||
displayName = CSTRING(litterCleanUpDelay);
|
||||
description = CSTRING(litterCleanUpDelay_Description);
|
||||
typeName = "SCALAR";
|
||||
value = 0;
|
||||
};
|
||||
};
|
@ -1,3 +1,4 @@
|
||||
|
||||
PREP(actionCheckBloodPressure);
|
||||
PREP(actionCheckBloodPressureLocal);
|
||||
PREP(actionCheckPulse);
|
||||
@ -52,3 +53,8 @@ PREP(useItem);
|
||||
PREP(useItems);
|
||||
|
||||
PREP(checkItems);
|
||||
|
||||
// litter
|
||||
PREP(litterCreate);
|
||||
PREP(litterHandleCreate);
|
||||
PREP(litterCleanupLoop);
|
||||
|
@ -5,3 +5,7 @@
|
||||
params ["_unit"];
|
||||
_unit call FUNC(checkItems);
|
||||
}] call CBA_fnc_addEventHandler;
|
||||
|
||||
if (isServer) then {
|
||||
[QGVAR(createLitterServer), FUNC(litterHandleCreate)] call CBA_fnc_addEventHandler;
|
||||
};
|
||||
|
@ -17,3 +17,4 @@ class CfgPatches {
|
||||
#include "CfgEventHandlers.hpp"
|
||||
#include "ACE_Medical_Treatment.hpp"
|
||||
#include "ACE_Medical_Treatment_Actions.hpp"
|
||||
#include "ACE_Settings.hpp"
|
||||
|
@ -10,25 +10,28 @@
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
|
||||
#include "script_component.hpp"
|
||||
|
||||
{
|
||||
_x params ["_time", "_objects"];
|
||||
//Older elements are always at the begining of the array:
|
||||
if ((CBA_missionTime - _time) < GVAR(litterCleanUpDelay)) exitWith {};
|
||||
|
||||
// Older elements are always at the begining of the array
|
||||
if (CBA_missionTime - _time < GVAR(litterCleanUpDelay)) exitWith {};
|
||||
|
||||
TRACE_2("deleting",_time,_objects);
|
||||
{
|
||||
deleteVehicle _x;
|
||||
} forEach _objects;
|
||||
|
||||
GVAR(allCreatedLitter) set [_forEachIndex, objNull];
|
||||
} forEach GVAR(allCreatedLitter);
|
||||
|
||||
GVAR(allCreatedLitter) = GVAR(allCreatedLitter) - [objNull];
|
||||
|
||||
// If no more litter remaining, exit the loop
|
||||
// If no more litter remain, exit the loop
|
||||
if (GVAR(allCreatedLitter) isEqualTo []) exitWith {
|
||||
GVAR(litterPFHRunning) = false;
|
||||
};
|
||||
|
||||
// Schedule the loop to be executed again 30 sec later
|
||||
[DFUNC(litterCleanupLoop), [], 30] call CBA_fnc_waitAndExecute;
|
||||
[FUNC(litterCleanupLoop), [], 30] call CBA_fnc_waitAndExecute;
|
98
addons/medical_treatment/functions/fnc_litterCreate.sqf
Normal file
98
addons/medical_treatment/functions/fnc_litterCreate.sqf
Normal file
@ -0,0 +1,98 @@
|
||||
/*
|
||||
* Author: Glowbal
|
||||
* Spawns litter for the treatment action on the ground around the target
|
||||
*
|
||||
* Arguments:
|
||||
* 0: The Caller <OBJECT>
|
||||
* 1: The target <OBJECT>
|
||||
* 2: The treatment Selection Name <STRING>
|
||||
* 3: The treatment classname <STRING>
|
||||
* 4: ?
|
||||
* 5: Users of Items <?>
|
||||
* 6: Blood Loss on selection (previously called _previousDamage) <NUMBER>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
#define MIN_ENTRIES_LITTER_CONFIG 3
|
||||
|
||||
params ["_caller", "_target", "_selectionName", "_className", "", "_usersOfItems", "_bloodLossOnSelection"];
|
||||
TRACE_6("params",_caller,_target,_selectionName,_className,_usersOfItems,_bloodLossOnSelection);
|
||||
|
||||
// Ensures comptibilty with other possible medical treatment configs
|
||||
private _previousDamage = _bloodLossOnSelection;
|
||||
|
||||
// Exit if litter is disabled by setting
|
||||
if !(EGVAR(medical,allowLitterCreation)) exitWith {};
|
||||
|
||||
// Don't create litter if medic or patient are inside a vehicle
|
||||
if (vehicle _caller != _caller || {vehicle _target != _target}) exitWith {};
|
||||
|
||||
private _config = configFile >> "ACE_Medical_Treatment_Actions" >> ["Basic", "Advanced"] select (EGVAR(medical,level) >= 2) >> _className;
|
||||
if !(isClass _config) exitWith {TRACE_1("No action config",_className);};
|
||||
|
||||
if !(isArray (_config >> "litter")) exitWith {TRACE_1("No litter config",_className);};
|
||||
private _litter = getArray (_config >> "litter");
|
||||
|
||||
private _createLitter = {
|
||||
params ["_unit", "_litterClass"];
|
||||
|
||||
private _position = getPosASL _unit;
|
||||
|
||||
// @TODO: handle carriers over water
|
||||
// For now, don't spawn litter if we are over water to avoid floating litter
|
||||
if (surfaceIsWater _position) exitWith {false};
|
||||
|
||||
_position = _position vectorAdd [
|
||||
random 2 - 1,
|
||||
random 2 - 1,
|
||||
0
|
||||
];
|
||||
|
||||
private _direction = random 360;
|
||||
|
||||
// Create the litter, and timeout the event based on the cleanup delay
|
||||
// The cleanup delay for events in MP is handled by the server side
|
||||
TRACE_3("Creating Litter on server",_litterClass,_position,_direction);
|
||||
[QGVAR(createLitterServer), [_litterClass, _position, _direction]] call CBA_fnc_serverEvent;
|
||||
|
||||
true
|
||||
};
|
||||
|
||||
{
|
||||
if (count _x < MIN_ENTRIES_LITTER_CONFIG) then {
|
||||
WARNING(format [ARR_2("Wrong litter array: %1",_x)]);
|
||||
} else {
|
||||
_x params [
|
||||
["_selection", "", [""]],
|
||||
["_litterCondition", "", [""]],
|
||||
["_litterOptions", [], [[]]]
|
||||
];
|
||||
|
||||
if (toLower _selection in [toLower _selectionName, "all"]) then {
|
||||
if (_litterCondition isEqualTo "") then {
|
||||
_litterCondition = {true};
|
||||
} else {
|
||||
_litterCondition = compile _litterCondition;
|
||||
};
|
||||
|
||||
// existing configs seem to use carried over magic variables. we pass them as arguments (_this) anyway
|
||||
if !([_caller, _target, _selectionName, _className, _usersOfItems, _bloodLossOnSelection] call _litterCondition) exitWith {};
|
||||
|
||||
// Loop through through the litter options and place the litter
|
||||
{
|
||||
if (_x isEqualType "") then {
|
||||
[_target, _x] call _createLitter;
|
||||
};
|
||||
|
||||
if (_x isEqualType [] && {count _x > 0}) then {
|
||||
[_target, selectRandom _x] call _createLitter;
|
||||
};
|
||||
} foreach _litterOptions;
|
||||
};
|
||||
};
|
||||
} foreach _litter;
|
@ -24,22 +24,33 @@ if (isNil QGVAR(allCreatedLitter)) then {
|
||||
GVAR(litterPFHRunning) = false;
|
||||
};
|
||||
|
||||
private _p3dFile = getText (configFile >> "CfgVehicles" >> _litterClass >> "model");
|
||||
if (_p3dFile == "") exitWith {TRACE_2("no model",_litterClass,_p3dFile)};
|
||||
private _model = getText (configFile >> "CfgVehicles" >> _litterClass >> "model");
|
||||
if (_model == "") exitWith {TRACE_2("no model",_litterClass,_model)};
|
||||
|
||||
// createSimpleObject expects a path without the leading slash
|
||||
if ((_p3dFile select [0,1]) == "\") then {_p3dFile = _p3dFile select [1];};
|
||||
if (_model select [0,1] == "\") then {
|
||||
_model = _model select [1];
|
||||
};
|
||||
|
||||
private _litterObject = createSimpleObject [_p3dFile, [0,0,0]];
|
||||
private _litterObject = createSimpleObject [_model, [0,0,0]];
|
||||
TRACE_2("created",_litterClass,_litterObject);
|
||||
_litterObject setDir _direction;
|
||||
_litterObject setPosATL _position;
|
||||
// Move the litter next frame to get rid of HORRIBLE spacing, fixes #1112
|
||||
[{ params ["_object", "_pos"]; _object setPosATL _pos; }, [_litterObject, _position]] call CBA_fnc_execNextFrame;
|
||||
|
||||
private _maxLitterCount = getArray (configFile >> "ACE_Settings" >> QGVAR(litterSimulationDetail) >> "_values") select GVAR(litterSimulationDetail);
|
||||
if ((count GVAR(allCreatedLitter)) > _maxLitterCount) then {
|
||||
_litterObject setDir _direction;
|
||||
_litterObject setPosASL _position;
|
||||
|
||||
// Move the litter next frame to get rid of HORRIBLE spacing, fixes #1112
|
||||
[{
|
||||
params ["_object", "_position"];
|
||||
|
||||
_object setPosASL _position;
|
||||
}, [_litterObject, _position]] call CBA_fnc_execNextFrame;
|
||||
|
||||
private _maxLitterCount = getArray (configFile >> "ACE_Settings" >> QEGVAR(medical,litterSimulationDetail) >> "_values") select EGVAR(medical,litterSimulationDetail);
|
||||
|
||||
if (count GVAR(allCreatedLitter) > _maxLitterCount) then {
|
||||
// gank the first litter object, and spawn ours.
|
||||
private _oldLitter = GVAR(allCreatedLitter) deleteAt 0;
|
||||
|
||||
{
|
||||
deleteVehicle _x;
|
||||
} forEach (_oldLitter select 1);
|
||||
@ -47,7 +58,7 @@ if ((count GVAR(allCreatedLitter)) > _maxLitterCount) then {
|
||||
|
||||
GVAR(allCreatedLitter) pushBack [CBA_missionTime, [_litterObject]];
|
||||
|
||||
if(!GVAR(litterPFHRunning) && {GVAR(litterCleanUpDelay) > 0}) then {
|
||||
if (!GVAR(litterPFHRunning) && {GVAR(litterCleanUpDelay) > 0}) then {
|
||||
// Start the litter cleanup loop
|
||||
GVAR(litterPFHRunning) = true;
|
||||
call FUNC(litterCleanupLoop);
|
@ -81,7 +81,7 @@ TRACE_1("advanced",_bloodLossOnSelection);
|
||||
|
||||
_args call _callback;
|
||||
_args pushBack _bloodLossOnSelection;
|
||||
_args call FUNC(createLitter);
|
||||
_args call FUNC(litterCreate);
|
||||
|
||||
//If we're not already tracking vitals, start:
|
||||
if (!(_target getVariable [QGVAR(addedToUnitLoop),false])) then {
|
||||
|
@ -1,5 +1,77 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project name="ACE">
|
||||
<Package name="Medical_Treatment">
|
||||
<Key ID="STR_ACE_Medical_Treatment_allowLitterCreation">
|
||||
<English>Enable Litter</English>
|
||||
<Russian>Включить мусор</Russian>
|
||||
<Polish>Aktywuj odpadki</Polish>
|
||||
<Spanish>Activar restos médicos</Spanish>
|
||||
<German>Abfälle aktivieren</German>
|
||||
<Czech>Povolit odpadky</Czech>
|
||||
<Portuguese>Ativar lixo médico</Portuguese>
|
||||
<French>Activer les détritus</French>
|
||||
<Hungarian>Szemét engedélyezése</Hungarian>
|
||||
<Italian>Abilita Barella</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_Treatment_allowLitterCreation_Description">
|
||||
<English>Enable litter being created upon treatment</English>
|
||||
<Russian>Включить появление мусора после лечения</Russian>
|
||||
<Polish>Twórz odpadki medyczne podczas leczenia</Polish>
|
||||
<Spanish>Activar los restos médicos que se crean en el tratamiento</Spanish>
|
||||
<German>Aktiviere Abfälle, wenn eine Behandlung durchgeführt wurde</German>
|
||||
<Czech>Vytváří odpad zdravotnického materiálu pří léčení</Czech>
|
||||
<Portuguese>Ativar lixo ser criado após tratamento</Portuguese>
|
||||
<French>Activer la création de détrimus au début des traitements</French>
|
||||
<Hungarian>Engedélyezi a szemét keletkezését ellátáskor</Hungarian>
|
||||
<Italian>Abilita la creazione della barella dopo trattamento</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_Treatment_litterSimulationDetail">
|
||||
<English>Litter Simulation Detail</English>
|
||||
<Polish>Detale zużytych medykamentów</Polish>
|
||||
<Spanish>Detalle de simulación de basura</Spanish>
|
||||
<Russian>Количество мусора от медицины</Russian>
|
||||
<Italian>Dettagli Simulazione Rifiuti</Italian>
|
||||
<French>Niveau de simulation des détritus</French>
|
||||
<German>Abfall-Detaillevel</German>
|
||||
<Hungarian>Hulladékszimuláció részletessége</Hungarian>
|
||||
<Portuguese>Detalhe da simulação de sujeira</Portuguese>
|
||||
<Czech>Počet zobrazených předmětů po použití zdravotnického materiálu</Czech>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_Treatment_litterSimulationDetail_Description">
|
||||
<English>Litter simulation detail level sets the number of litter items which will be locally spawned in the client. Excessive amounts in local areas could cause FPS lag, so this is a client only setting.</English>
|
||||
<Polish>Opcja ta ustawia liczbę zużytych medykamentów, jakie pojawiają się lokalnie wokół gracza. Ich zbyt duża ilość może spowodować spadki FPS, dlatego jest to ustawienie tylko po stronie klienta.</Polish>
|
||||
<Spanish>Detalle simulación de basura establece el número de artículos de basura que se generan a nivel local en el cliente. Las cantidades excesivas en áreas locales podrían causar caída de rendimiento, así que esto es un ajuste de cliente únicamente.</Spanish>
|
||||
<Russian>Устанавливает количество мусора, который появляется после использования мед. препаратов. Большое количество мусора может уменьшить производительность, поэтому данная настройка локальна для клиента.</Russian>
|
||||
<Italian>Il numero di rifiuti che verranno creati localmente. La creazione di troppi rifiuti in aree locali potrebbe causare lag e calo di FPS. Questo è un settaggio lato client.</Italian>
|
||||
<French>Le niveau de simulation des détritus règle la quantité de déchets qui vont être créés localement chez le client. Des quantitées excessive chez certains clients peuvent causer des chutes de FPS, c'est donc une option client uniquement.</French>
|
||||
<German>Die Einstellung für das Abfall-Detaillevel stellt die Menge des lokal angezeigten medizinischen Abfalls ein. Zuviel Abfall kann FPS-Einbrüche erzeugen, weswegen diese Einstellung nur clientseitig ist.</German>
|
||||
<Hungarian>A hulladékszimuláció részletessége megszabja a kliens által megjelenített hulladékobjektumok mennyiségét. Súlyos mennyiségek izolált területeken alacsony FPS-t okozhatnak, így ez egy kliensoldali beállítás.</Hungarian>
|
||||
<Portuguese>O nível de detalhe de sujeira determina o número de itens que irão aparecer no cliente. Quantidades excessivas em áreas locais podem aumentar o lag do FPS, então esta é uma opção somente para o cliente.</Portuguese>
|
||||
<Czech>Počet zobrazených předmětů po použití zdravotnického materiálu ovlivňuje počet objektů, které budou zobrazeny klientovi v místě použití zdravotnického materiálu. Vyšší množství objektů může způsobovat poklesy FPS a proto je toto nastavení čistě na klientovi.</Czech>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_Treatment_litterCleanUpDelay">
|
||||
<English>Life time of litter objects</English>
|
||||
<Russian>Время удаления мусора</Russian>
|
||||
<Polish>Długość życia odpadków</Polish>
|
||||
<Spanish>Tiempo de vida de los restos médicos</Spanish>
|
||||
<German>Dauer des angezeigten Abfalls</German>
|
||||
<Czech>Životnost pro odpadky</Czech>
|
||||
<Portuguese>Tempo de vida dos objetos do lixo</Portuguese>
|
||||
<French>Durée d'affichage des détritus</French>
|
||||
<Hungarian>Szemétobjektumok élettartama</Hungarian>
|
||||
<Italian>Tempo di vita delle barelle</Italian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_Treatment_litterCleanUpDelay_Description">
|
||||
<English>How long should litter objects stay? In seconds. -1 is forever.</English>
|
||||
<Russian>Как долго мусор будет оставаться на земле? В секундах. -1 означает бесконечное время.</Russian>
|
||||
<Polish>Ile czasu musi upłynąć, aby odpadki zaczęły znikać? W sekundach. -1 dla nieskończoności.</Polish>
|
||||
<Spanish>¿Por cuánto tiempo deben permanecer los restos médicos? En segundos. -1 es para siempre.</Spanish>
|
||||
<German>Wie lange sollen Abfälle am Boden liegen (in Sekunden)? -1 ist für immer.</German>
|
||||
<Czech>Za jak dlouho začnou odpadky mizet? V sekundách. -1 navždy.</Czech>
|
||||
<Portuguese>Quanto tempo os objetos do lixo devem ficar? Em segundos. -1 é para sempre.</Portuguese>
|
||||
<French>Combien de temps doivent rester affiché les détritus? En secondes. -1 pour tout le temps</French>
|
||||
<Hungarian>Milyen sokáig legyenek jelen a szemétobjektumok (másodpercben)? A -1 végtelen időt jelent.</Hungarian>
|
||||
<Italian>Per quanto devono restare le barelle? In secondi. -1 è permanente</Italian>
|
||||
</Key>
|
||||
</Package>
|
||||
</Project>
|
||||
|
Loading…
Reference in New Issue
Block a user