Skip to content

Commit

Permalink
Surgery - Add settings for REBOA / Pericardial Tap / Ultrasound (#577)
Browse files Browse the repository at this point in the history
**When merged this pull request will:**
- add location, med level. and treatment time settings to REBOA,
pericardial tap, and ultrasound

### IMPORTANT

- [Development Guidelines](https://ace3.acemod.org/wiki/development/)
are read, understood and applied.
- Title of this PR uses our standard template `Component -
Add|Fix|Improve|Change|Make|Remove {changes}`.

---------

Co-authored-by: mazinskihenry <[email protected]>
  • Loading branch information
Cplhardcore and mazinskihenry authored Aug 8, 2024
1 parent b2fdb97 commit ea69902
Show file tree
Hide file tree
Showing 3 changed files with 138 additions and 22 deletions.
30 changes: 15 additions & 15 deletions addons/surgery/ACE_Medical_Treatment_Actions.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -121,11 +121,11 @@ class ACE_Medical_Treatment_Actions {
displayName = CSTRING(Ultra_Use);
displayNameProgress = CSTRING(Ultra_Action);
category = "surgery";
treatmentLocations = QGVAR(surgicalLocation);
treatmentLocations = QGVAR(ultrasoundLocation);
allowedSelections[] = {"Body"};
allowSelfTreatment = 0;
medicRequired = QGVAR(surgicalAction_MedLevel);
treatmentTime = QGVAR(intermediateTime);
medicRequired = QGVAR(ultrasoundAction_MedLevel);
treatmentTime = QGVAR(ultrasoundTime);
items[] = {"kat_ultrasound"};
condition = "";
consumeItem = 0;
Expand All @@ -135,11 +135,11 @@ class ACE_Medical_Treatment_Actions {
displayName = CSTRING(Reboa_Use);
displayNameProgress = CSTRING(Reboa_Action);
category = "surgery";
treatmentLocations = QGVAR(surgicalLocation);
treatmentLocations = QGVAR(reboaLocation);
allowedSelections[] = {"LeftLeg", "RightLeg"};
allowSelfTreatment = 0;
medicRequired = QGVAR(surgicalAction_MedLevel);
treatmentTime = QGVAR(intermediateTime);
medicRequired = QGVAR(reboa_MedLevel);
treatmentTime = QGVAR(reboaTime);
items[] = {"kat_reboa"};
condition = QUOTE((_patient getVariable [ARR_2(QQGVAR(imaging),false)]) && (!(_patient getVariable [ARR_2(QQGVAR(reboa),false)])));
consumeItem = 1;
Expand All @@ -149,11 +149,11 @@ class ACE_Medical_Treatment_Actions {
displayName = CSTRING(Reboa_Deep_Use);
displayNameProgress = CSTRING(Reboa_Deep_Action);
category = "surgery";
treatmentLocations = QGVAR(surgicalLocation);
treatmentLocations = QGVAR(reboaLocation);
allowedSelections[] = {"LeftLeg", "RightLeg"};
allowSelfTreatment = 0;
medicRequired = QGVAR(surgicalAction_MedLevel);
treatmentTime = QGVAR(intermediateTime);
medicRequired = QGVAR(reboa_MedLevel);
treatmentTime = QGVAR(reboaTime);
items[] = {"kat_ultrasound"};
condition = QUOTE(_patient getVariable [ARR_2(QQGVAR(reboa),false)]);
consumeItem = 0;
Expand All @@ -163,11 +163,11 @@ class ACE_Medical_Treatment_Actions {
displayName = CSTRING(Reboa_Remove_Use);
displayNameProgress = CSTRING(Reboa_Remove_Action);
category = "surgery";
treatmentLocations = QGVAR(reboaTime);
treatmentLocations = QGVAR(reboaLocation);
allowedSelections[] = {"LeftLeg", "RightLeg"};
allowSelfTreatment = 0;
medicRequired = QGVAR(surgicalAction_MedLevel);
treatmentTime = QGVAR(intermediateTime);
medicRequired = QGVAR(reboa_MedLevel);
treatmentTime = QGVAR(reboaTime);
items[] = {"kat_ultrasound"};
condition = QUOTE(_patient getVariable [ARR_2(QQGVAR(reboa),false)]);
consumeItem = 0;
Expand All @@ -177,11 +177,11 @@ class ACE_Medical_Treatment_Actions {
displayName = CSTRING(Pericardial_Tap_Use);
displayNameProgress = CSTRING(Pericardial_Tap_Action);
category = "surgery";
treatmentLocations = QGVAR(surgicalLocation);
treatmentLocations = QGVAR(pericardialtapLocation);
allowedSelections[] = {"Body"};
allowSelfTreatment = 0;
medicRequired = QGVAR(surgicalAction_MedLevel);
treatmentTime = QGVAR(intermediateTime);
medicRequired = QGVAR(pericardialtapAction_MedLevel);
treatmentTime = QGVAR(pericardialtapTime);
items[] = {"kat_ultrasound"};
condition = QUOTE(_patient getVariable [ARR_2(QQGVAR(imaging),false)]);
consumeItem = 0;
Expand Down
94 changes: 87 additions & 7 deletions addons/surgery/XEH_preInit.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,24 @@ PREP_RECOMPILE_END;
true
] call CBA_Settings_fnc_init;

// Sets time to apply NPWT dressing
[
QGVAR(npwt_MedLevel),
"LIST",
LLSTRING(NPWT_ACTION_MEDLEVEL),
[CBA_SETTINGS_CAT, LSTRING(SubCategory_NPWT)],
[[0, 1, 2], ["STR_ACE_Medical_Treatment_Anyone", "STR_ACE_Medical_Treatment_Medics", "STR_ACE_Medical_Treatment_Doctors"], 2],
true
] call CBA_Settings_fnc_init;

[
QGVAR(npwtLocation),
"LIST",
LLSTRING(NPWT_LOCATION),
[CBA_SETTINGS_CAT, LSTRING(SubCategory_NPWT)],
[[0,1,2,3],["STR_ACE_Common_Anywhere", "STR_ACE_Common_Vehicle", "STR_ACE_Medical_Treatment_MedicalFacilities", "STR_ACE_Medical_Treatment_VehiclesAndFacilities"],3],
true
] call CBA_Settings_fnc_init;

[
QGVAR(npwtTime),
"SLIDER",
Expand All @@ -176,21 +193,84 @@ PREP_RECOMPILE_END;
] call CBA_Settings_fnc_init;

[
QGVAR(npwtLocation),
QGVAR(reboa_MedLevel),
"LIST",
LLSTRING(NPWT_LOCATION),
[CBA_SETTINGS_CAT, LSTRING(SubCategory_NPWT)],
LLSTRING(REBOA_ACTION_MEDLEVEL),
[CBA_SETTINGS_CAT, LSTRING(SubCategory_SurgicalActions)],
[[0, 1, 2], ["STR_ACE_Medical_Treatment_Anyone", "STR_ACE_Medical_Treatment_Medics", "STR_ACE_Medical_Treatment_Doctors"], 2],
true
] call CBA_Settings_fnc_init;

[
QGVAR(reboaLocation),
"LIST",
LLSTRING(REBOA_LOCATION),
[CBA_SETTINGS_CAT, LSTRING(SubCategory_SurgicalActions)],
[[0,1,2,3],["STR_ACE_Common_Anywhere", "STR_ACE_Common_Vehicle", "STR_ACE_Medical_Treatment_MedicalFacilities", "STR_ACE_Medical_Treatment_VehiclesAndFacilities"],3],
true
] call CBA_Settings_fnc_init;

[
QGVAR(npwtMedLevel),
QGVAR(reboaTime),
"SLIDER",
[LLSTRING(REBOA_TIMER), LLSTRING(REBOA_TIMER_DESC)],
[CBA_SETTINGS_CAT, LSTRING(SubCategory_SurgicalActions)],
[0,100,8,0],
true
] call CBA_Settings_fnc_init;

[
QGVAR(ultrasound_MedLevel),
"LIST",
LLSTRING(NPWT_ACTION_MEDLEVEL),
[CBA_SETTINGS_CAT, LSTRING(SubCategory_NPWT)],
LLSTRING(ULTRASOUND_ACTION_MEDLEVEL),
[CBA_SETTINGS_CAT, LSTRING(SubCategory_SurgicalActions)],
[[0, 1, 2], ["STR_ACE_Medical_Treatment_Anyone", "STR_ACE_Medical_Treatment_Medics", "STR_ACE_Medical_Treatment_Doctors"], 2],
true
] call CBA_Settings_fnc_init;

[
QGVAR(ultrasoundLocation),
"LIST",
LLSTRING(ULTRASOUND_LOCATION),
[CBA_SETTINGS_CAT, LSTRING(SubCategory_SurgicalActions)],
[[0,1,2,3],["STR_ACE_Common_Anywhere", "STR_ACE_Common_Vehicle", "STR_ACE_Medical_Treatment_MedicalFacilities", "STR_ACE_Medical_Treatment_VehiclesAndFacilities"],3],
true
] call CBA_Settings_fnc_init;

[
QGVAR(ultrasoundTime),
"SLIDER",
[LLSTRING(ULTRASOUND_TIMER), LLSTRING(ULTRASOUND_TIMER_DESC)],
[CBA_SETTINGS_CAT, LSTRING(SubCategory_SurgicalActions)],
[0,100,8,0],
true
] call CBA_Settings_fnc_init;

[
QGVAR(pericardialtap_MedLevel),
"LIST",
LLSTRING(PERICARDIALTAP_ACTION_MEDLEVEL),
[CBA_SETTINGS_CAT, LSTRING(SubCategory_SurgicalActions)],
[[0, 1, 2], ["STR_ACE_Medical_Treatment_Anyone", "STR_ACE_Medical_Treatment_Medics", "STR_ACE_Medical_Treatment_Doctors"], 2],
true
] call CBA_Settings_fnc_init;

[
QGVAR(pericardialtapLocation),
"LIST",
LLSTRING(PERICARDIALTAP_LOCATION),
[CBA_SETTINGS_CAT, LSTRING(SubCategory_SurgicalActions)],
[[0,1,2,3],["STR_ACE_Common_Anywhere", "STR_ACE_Common_Vehicle", "STR_ACE_Medical_Treatment_MedicalFacilities", "STR_ACE_Medical_Treatment_VehiclesAndFacilities"],3],
true
] call CBA_Settings_fnc_init;

[
QGVAR(pericardialtapTime),
"SLIDER",
[LLSTRING(PERICARDIALTAP_TIMER), LLSTRING(PERICARDIALTAP_TIMER_DESC)],
[CBA_SETTINGS_CAT, LSTRING(SubCategory_SurgicalActions)],
[0,100,8,0],
true
] call CBA_Settings_fnc_init;

ADDON = true;
36 changes: 36 additions & 0 deletions addons/surgery/stringtable.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1106,6 +1106,42 @@
<Finnish>Salli leikkaus</Finnish>
<Russian>Разрешить хирургическое вмешательство</Russian>
</Key>
<Key ID="STR_KAT_Surgery_REBOA_ACTION_MEDLEVEL">
<English>Allow Reboa</English>
</Key>
<Key ID="STR_KAT_Surgery_REBOA_LOCATION">
<English>Locations for REBOA</English>
</Key>
<Key ID="STR_KAT_Surgery_REBOA_TIMER">
<English>Time to perform REBOA actions</English>
</Key>
<Key ID="STR_KAT_Surgery_REBOA_TIMER_DESC">
<English>Sets how long it takes to perform REBOA actions (Placing, advancing, Removing)</English>
</Key>
<Key ID="STR_KAT_Surgery_ULTRASOUND_ACTION_MEDLEVEL">
<English>Allow Ultrasound</English>
</Key>
<Key ID="STR_KAT_Surgery_ULTRASOUND_LOCATION">
<English>Locations for Ultrasound</English>
</Key>
<Key ID="STR_KAT_Surgery_ULTRASOUND_TIMER">
<English>Time to perform Ultrasound actions</English>
</Key>
<Key ID="STR_KAT_Surgery_ULTRASOUND_TIMER_DESC">
<English>Sets how long it takes to perform an ultrasound exam</English>
</Key>
<Key ID="STR_KAT_Surgery_PERICARDIALTAP_ACTION_MEDLEVEL">
<English>Allow Pericardial Tap</English>
</Key>
<Key ID="STR_KAT_Surgery_PERICARDIALTAP_LOCATION">
<English>Locations for Pericardial Tap</English>
</Key>
<Key ID="STR_KAT_Surgery_PERICARDIALTAP_TIMER">
<English>Time to perform Pericardial Tap</English>
</Key>
<Key ID="STR_KAT_Surgery_PERICARDIALTAP_TIMER_DESC">
<English>Sets how long it takes to perform a pericardial tap</English>
</Key>
<Key ID="STR_KAT_Surgery_BREATH_CHECK_MEDLEVEL">
<English>Allow Breath Check</English>
<Chinesesimp>呼吸检查所需的医疗水平</Chinesesimp>
Expand Down

0 comments on commit ea69902

Please sign in to comment.