Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge #1

Merged
merged 5 commits into from
Dec 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions addons/common/stringtable.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1795,9 +1795,11 @@
</Key>
<Key ID="STR_ACE_Common_magneticDeclination">
<English>Realistic Compass Declination</English>
<French>Déclinaison réaliste de la boussole</French>
</Key>
<Key ID="STR_ACE_Common_magneticDeclinationooltip">
<English>Compass will point to magnetic north</English>
<French>La boussole indique le nord magnétique</French>
</Key>
<Key ID="STR_ACE_Common_playerOnly">
<English>Players only</English>
Expand Down
3 changes: 1 addition & 2 deletions addons/compat_sog/ACE_Medical_Injuries.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ class ACE_Medical_Injuries {
};
class GVAR(explosive_incendiary): explosive {
class woundHandlers: woundHandlers {
// TODO use function name after bug with the woundHandlers config caching is fixed
ADDON = QUOTE({call FUNC(woundsHandlerIncendiary)});
ADDON = QFUNC(woundsHandlerIncendiary);
};
};
};
Expand Down
3 changes: 1 addition & 2 deletions addons/compat_spe/ACE_Medical_Injuries.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ class ACE_Medical_Injuries {
};
class GVAR(explosive_incendiary): explosive {
class woundHandlers: woundHandlers {
// TODO use function name after bug with the woundHandlers config caching is fixed
ADDON = QUOTE({call FUNC(woundsHandlerIncendiary)});
ADDON = QFUNC(woundsHandlerIncendiary);
};
};
};
Expand Down
2 changes: 2 additions & 0 deletions addons/field_rations/stringtable.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1286,11 +1286,13 @@
<English>If enabled, hunger and thirst will continue to increase while the Zeus interface is open.</English>
<Japanese>有効化すると、空腹と渇きはZeusインタフェイスを開いている間も継続して進行します。</Japanese>
<Korean>활성화 시 제우스 인터페이스가 열려 있는 동안 허기와 갈증이 계속 증가합니다.</Korean>
<French>Si cette option est activée, la faim et la soif continueront d'augmenter tant que l'interface Zeus sera ouverte.</French>
</Key>
<Key ID="STR_ACE_Field_Rations_ZeusUpdates_DisplayName">
<English>Update Hunger and Thirst in Zeus</English>
<Japanese>Zeus時に空腹と渇きを進行させる</Japanese>
<Korean>제우스의 허기와 갈증 업데이트</Korean>
<French>Mise à jour Faim et soif dans Zeus</French>
</Key>
</Package>
</Project>
2 changes: 2 additions & 0 deletions addons/hearing/stringtable.xml
Original file line number Diff line number Diff line change
Expand Up @@ -319,12 +319,14 @@
<Russian>Изменяет степень глухоты, вызываемой взрывами.\nУстановка значения 0 отключает повреждение слуха при взрыве.</Russian>
<Korean>폭발로 인한 청력 상실 정도를 변경합니다.\n0으로 설정하면 폭발에도 청력을 온전히 유지할 수 있습니다.</Korean>
<Japanese>爆発による聴力低下の程度を変更します。\n0に設定することで爆発による聴力低下を無効化できます。</Japanese>
<French>Modifie le degré de surdité causé par les explosions.\nLa valeur 0 désactive les dégâts auditifs causés par les explosions.</French>
</Key>
<Key ID="STR_ACE_Hearing_explosionDeafnessCoefficient_DisplayName">
<English>Explosion Deafness Coefficient</English>
<Russian>Коэффициент оглушения при взрыве</Russian>
<Korean>폭발 난청 계수</Korean>
<Japanese>爆発による難聴発生係数</Japanese>
<French>Coefficient de surdité à l'explosion</French>
</Key>
<Key ID="STR_ACE_Hearing_heavyWeaponUnits">
<English>Only units with heavy weapons</English>
Expand Down
3 changes: 3 additions & 0 deletions addons/interaction/stringtable.xml
Original file line number Diff line number Diff line change
Expand Up @@ -854,18 +854,21 @@
<German>Granate geben</German>
<Japanese>手榴弾を渡す</Japanese>
<Korean>수류탄 건네주기</Korean>
<French>Donner une grenade</French>
</Key>
<Key ID="STR_ACE_Interaction_PassThrowableHint">
<English>%1 passed you %2.</English>
<German>%1 hat dir %2 gegeben.</German>
<Japanese>%1 は あなたに %2 を渡した。</Japanese>
<Korean>%1 님이 %2을(를) 건네주었습니다.</Korean>
<French>%1 vous a donné %2</French>
</Key>
<Key ID="STR_ACE_Interaction_PassThrowableSetting">
<English>Show "pass grenade" interaction</English>
<German>Zeige "Granate geben" Interaktion</German>
<Japanese>"手榴弾を渡す"をインタラクションに表示</Japanese>
<Korean>"수류탄 건네주기" 상호작용 표시</Korean>
<French>Afficher l'interaction « Donner une grenade »</French>
</Key>
<Key ID="STR_ACE_Interaction_Passengers">
<English>Passengers</English>
Expand Down
3 changes: 3 additions & 0 deletions addons/medical/XEH_PREP.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,8 @@ PREP(addDamageToUnit);
PREP(adjustPainLevel);
PREP(deserializeState);
PREP(fullHeal);
PREP(getBandagedWounds);
PREP(getOpenWounds);
PREP(getStitchedWounds);
PREP(serializeState);
PREP(setUnconscious);
51 changes: 51 additions & 0 deletions addons/medical/functions/fnc_getBandagedWounds.sqf
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
#include "..\script_component.hpp"
/*
* Author: LinkIsGrim
* Returns a copy of unit's bandaged wounds on a body part.
*
* Arguments:
* 0: Unit <OBJECT>
* 1: Body Part <STRING>
*
* Return Value:
* Wounds <ARRAY of ARRAY>:
* 0: Wound Class ID <NUMBER>
* 1: Wound Bandaged Amount <NUMBER>
* 2: Wound Bleeding Coef <NUMBER>
* 3: Wound Damage <NUMBER>
*
* Example:
* [player, "head"] call ace_medical_fnc_getBandagedWounds
*
* Public: Yes
*/

params [["_unit", objNull, [objNull]], ["_bodyPart", "", [""]]];

if (isNull _unit) exitWith {
ERROR("getBandagedWounds - null unit");

[]
};

if !(_unit isKindOf "CAManBase") exitWith {
ERROR_2("getBandagedWounds - unit %1 is not child of CAManBase - type %2",_unit,typeOf _unit);

[]
};

_bodyPart = toLowerANSI _bodyPart;

if !(_bodyPart in ALL_BODY_PARTS) exitWith {
ERROR_2("getBandagedWounds - invalid body part %1, expected one of %2",_bodyPart,ALL_BODY_PARTS);

[]
};

private _bandagedWounds = [];

{
_bandagedWounds pushBack +_x; // manual deep copy so modification doesn't affect unit state
} forEach (GET_OPEN_WOUNDS(_patient) getOrDefault [_bodyPart, []]);

_bandagedWounds
54 changes: 54 additions & 0 deletions addons/medical/functions/fnc_getOpenWounds.sqf
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
#include "..\script_component.hpp"
/*
* Author: LinkIsGrim
* Returns a copy of unit's open wounds on a body part.
*
* Arguments:
* 0: Unit <OBJECT>
* 1: Body Part <STRING>
*
* Return Value:
* Wounds <ARRAY of ARRAY>:
* 0: Wound Class ID <NUMBER>
* 1: Wound Open Amount <NUMBER>
* 2: Wound Bleeding Coef <NUMBER>
* 3: Wound Damage <NUMBER>
*
* Example:
* [player, "head"] call ace_medical_fnc_getOpenWounds
*
* Public: Yes
*/

params [["_unit", objNull, [objNull]], ["_bodyPart", "", [""]]];

if (isNull _unit) exitWith {
ERROR("getOpenWounds - null unit");

[]
};

if !(_unit isKindOf "CAManBase") exitWith {
ERROR_2("getOpenWounds - unit %1 is not child of CAManBase - type %2",_unit,typeOf _unit);

[]
};

_bodyPart = toLowerANSI _bodyPart;

if !(_bodyPart in ALL_BODY_PARTS) exitWith {
ERROR_2("getOpenWounds - invalid body part %1, expected one of %2",_bodyPart,ALL_BODY_PARTS);

[]
};

private _openWounds = [];

{
_x params ["", "_xAmount"];
if (_xAmount > 0) then { // bandaged wounds are open wounds with count 0, skip those
_openWounds pushBack +_x; // manual deep copy so modification doesn't affect unit state
};
} forEach (GET_OPEN_WOUNDS(_patient) getOrDefault [_bodyPart, []]);

_openWounds
51 changes: 51 additions & 0 deletions addons/medical/functions/fnc_getStitchedWounds.sqf
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
#include "..\script_component.hpp"
/*
* Author: LinkIsGrim
* Returns a copy of unit's stitched wounds on a body part.
*
* Arguments:
* 0: Unit <OBJECT>
* 1: Body Part <STRING>
*
* Return Value:
* Wounds <ARRAY of ARRAY>:
* 0: Wound Class ID <NUMBER>
* 1: Wound Stitched Amount <NUMBER>
* 2: Wound Bleeding Coef <NUMBER>
* 3: Wound Damage <NUMBER>
*
* Example:
* [player, "head"] call ace_medical_fnc_getStitchedWounds
*
* Public: Yes
*/

params [["_unit", objNull, [objNull]], ["_bodyPart", "", [""]]];

if (isNull _unit) exitWith {
ERROR("getStitchedWounds - null unit");

[]
};

if !(_unit isKindOf "CAManBase") exitWith {
ERROR_2("getStitchedWounds - unit %1 is not child of CAManBase - type %2",_unit,typeOf _unit);

[]
};

_bodyPart = toLowerANSI _bodyPart;

if !(_bodyPart in ALL_BODY_PARTS) exitWith {
ERROR_2("getStitchedWounds - invalid body part %1, expected one of %2",_bodyPart,ALL_BODY_PARTS);

[]
};

private _stitchedWounds = [];

{
_stitchedWounds pushBack +_x; // manual deep copy so modification doesn't affect unit state
} forEach (GET_STITCHED_WOUNDS(_patient) getOrDefault [_bodyPart, []]);

_stitchedWounds
13 changes: 13 additions & 0 deletions addons/medical_treatment/stringtable.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3083,12 +3083,14 @@
<Russian>Контролирует, где можно использовать Аденозин.</Russian>
<Japanese>アデノシンが使える場所を制御します。</Japanese>
<Korean>아데노신을 사용할 수 있는 장소를 정합니다.</Korean>
<French>Contrôle où l'Adénosine peut être utilisée.</French>
</Key>
<Key ID="STR_ACE_Medical_Treatment_LocationAdenosine_DisplayName">
<English>Locations Adenosine</English>
<Russian>Места использования Аденозина</Russian>
<Japanese>アデノシンの使用可能な場所</Japanese>
<Korean>아데노신 사용 장소</Korean>
<French>Lieux d'utilisation de l'adénosine</French>
</Key>
<Key ID="STR_ACE_Medical_Treatment_LocationEpinephrine_Description">
<English>Controls where epinephrine can be used.</English>
Expand Down Expand Up @@ -3153,12 +3155,14 @@
<Russian>Контролирует, где можно использовать Морфин.</Russian>
<Japanese>モルヒネが使える場所を制御します。</Japanese>
<Korean>모르핀을 사용할 수 있는 장소를 정합니다.</Korean>
<French>Contrôle où la morphine peut être utilisée.</French>
</Key>
<Key ID="STR_ACE_Medical_Treatment_LocationMorphine_DisplayName">
<English>Locations Morphine</English>
<Russian>Места использования Морфина</Russian>
<Japanese>モルヒネの使用可能な場所</Japanese>
<Korean>모르핀 사용 장소</Korean>
<French>Lieux d'utilisation de la morphine</French>
</Key>
<Key ID="STR_ACE_Medical_Treatment_LocationPAK_Description">
<English>Controls where a PAK can be used.</English>
Expand Down Expand Up @@ -3198,12 +3202,14 @@
<Russian>Контролирует, где можно использовать шины.</Russian>
<Japanese>添え木が使える場所を制御します。</Japanese>
<Korean>부목을 사용할 수 있는 장소를 정합니다.</Korean>
<French>Contrôle l'endroit où les attelles peuvent être utilisées.</French>
</Key>
<Key ID="STR_ACE_Medical_Treatment_LocationSplint_DisplayName">
<English>Locations Splint</English>
<Russian>Места наложения шины</Russian>
<Japanese>添え木の使用可能な場所</Japanese>
<Korean>부목 사용 장소</Korean>
<French>Emplacement des attelles</French>
</Key>
<Key ID="STR_ACE_Medical_Treatment_LocationSurgicalKit_Description">
<English>Controls where a surgical kit can be used.</English>
Expand Down Expand Up @@ -3289,12 +3295,14 @@
<Russian>Уровень подготовки, необходимый для использования Аденозина</Russian>
<Japanese>アデノシンの使用に必要な医療スキルのレベルを設定します。</Japanese>
<Korean>아데노신을 사용하는데 필요한 등급을 정합니다.</Korean>
<French>Niveau de formation requis pour utiliser l'Adénosine.</French>
</Key>
<Key ID="STR_ACE_Medical_Treatment_MedicAdenosine_DisplayName">
<English>Allow Adenosine</English>
<Russian>Доступ к Аденозину</Russian>
<Japanese>アデノシンの許可</Japanese>
<Korean>아데노신 사용 허가</Korean>
<French>Autoriser l'adénosine</French>
</Key>
<Key ID="STR_ACE_Medical_Treatment_MedicEpinephrine_Description">
<English>Training level required to use epinephrine.</English>
Expand Down Expand Up @@ -3363,12 +3371,14 @@
<Russian>Уровень подготовки, необходимый для использования Морфина.</Russian>
<Japanese>モルヒネの使用に必要な医療スキルのレベルを設定します。</Japanese>
<Korean>모르핀을 사용하는데 필요한 등급을 정합니다.</Korean>
<French>Niveau de formation requis pour l'utilisation de la morphine.</French>
</Key>
<Key ID="STR_ACE_Medical_Treatment_MedicMorphine_DisplayName">
<English>Allow Morphine</English>
<Russian>Доступ к Морфину</Russian>
<Japanese>モルヒネの許可</Japanese>
<Korean>모르핀 사용 허가</Korean>
<French>Autoriser la morphine</French>
</Key>
<Key ID="STR_ACE_Medical_Treatment_MedicPAK_Description">
<English>Training level required to use a PAK.</English>
Expand Down Expand Up @@ -3408,12 +3418,14 @@
<Russian>Уровень подготовки, необходимый для использования шины.</Russian>
<Japanese>添え木の使用に必要な医療スキルのレベルを設定します。</Japanese>
<Korean>부목을 사용하는데 필요한 등급을 정합니다.</Korean>
<French>Niveau de formation requis pour l'utilisation de l'attelle.</French>
</Key>
<Key ID="STR_ACE_Medical_Treatment_MedicSplint_DisplayName">
<English>Allow Splint</English>
<Russian>Доступ к наложению шины</Russian>
<Japanese>添え木の許可</Japanese>
<Korean>부목 사용 허가</Korean>
<French>Accès aux attelles</French>
</Key>
<Key ID="STR_ACE_Medical_Treatment_MedicSurgicalKit_Description">
<English>Training level required to use a surgical kit.</English>
Expand Down Expand Up @@ -3590,6 +3602,7 @@
<Russian>Числовое значение пульса</Russian>
<Japanese>脈拍の数値化</Japanese>
<Korean>맥박 수치</Korean>
<French>Pouls numérique</French>
</Key>
<Key ID="STR_ACE_Medical_Treatment_Packing_Bandage_Desc_Short">
<English>Used to pack medium to large wounds and stem the bleeding</English>
Expand Down
Loading