mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Medical GUI - Reformat injury list to clarify global vs. limb-specific information (#9468)
* Reorder injury list to clarify global vs. local * Add non-issue entries and deemphasize with color * Give non-issue color to "No injuries..." entry * Hook up to string tables * move bleeding above blood volume lost --------- Co-authored-by: LinkIsGrim <salluci.lovi@gmail.com>
This commit is contained in:
parent
7b32cb76f8
commit
78bb0514d1
@ -20,6 +20,70 @@
|
||||
params ["_ctrl", "_target", "_selectionN"];
|
||||
|
||||
private _entries = [];
|
||||
private _nonissueColor = [1, 1, 1, 0.33];
|
||||
|
||||
// Indicate if unit is bleeding at all
|
||||
if (IS_BLEEDING(_target)) then {
|
||||
_entries pushBack [localize LSTRING(Status_Bleeding), [1, 0, 0, 1]];
|
||||
} else {
|
||||
_entries pushBack [localize LSTRING(Status_Nobleeding), _nonissueColor];
|
||||
};
|
||||
|
||||
if (GVAR(showBloodlossEntry)) then {
|
||||
// Give a qualitative description of the blood volume lost
|
||||
switch (GET_HEMORRHAGE(_target)) do {
|
||||
case 0: {
|
||||
_entries pushBack [localize LSTRING(Lost_Blood0), _nonissueColor];
|
||||
};
|
||||
case 1: {
|
||||
_entries pushBack [localize LSTRING(Lost_Blood1), [1, 1, 0, 1]];
|
||||
};
|
||||
case 2: {
|
||||
_entries pushBack [localize LSTRING(Lost_Blood2), [1, 0.67, 0, 1]];
|
||||
};
|
||||
case 3: {
|
||||
_entries pushBack [localize LSTRING(Lost_Blood3), [1, 0.33, 0, 1]];
|
||||
};
|
||||
case 4: {
|
||||
_entries pushBack [localize LSTRING(Lost_Blood4), [1, 0, 0, 1]];
|
||||
};
|
||||
};
|
||||
};
|
||||
// Show receiving IV volume remaining
|
||||
private _totalIvVolume = 0;
|
||||
{
|
||||
_x params ["_volumeRemaining"];
|
||||
_totalIvVolume = _totalIvVolume + _volumeRemaining;
|
||||
} forEach (_target getVariable [QEGVAR(medical,ivBags), []]);
|
||||
|
||||
if (_totalIvVolume >= 1) then {
|
||||
_entries pushBack [format [localize ELSTRING(medical_treatment,receivingIvVolume), floor _totalIvVolume], [1, 1, 1, 1]];
|
||||
} else {
|
||||
_entries pushBack [localize ELSTRING(medical_treatment,Status_NoIv), _nonissueColor];
|
||||
};
|
||||
|
||||
// Indicate the amount of pain the unit is in
|
||||
if (_target call EFUNC(common,isAwake)) then {
|
||||
private _pain = GET_PAIN_PERCEIVED(_target);
|
||||
if (_pain > 0) then {
|
||||
private _painText = switch (true) do {
|
||||
case (_pain > PAIN_UNCONSCIOUS): {
|
||||
ELSTRING(medical_treatment,Status_SeverePain);
|
||||
};
|
||||
case (_pain > (PAIN_UNCONSCIOUS / 5)): {
|
||||
ELSTRING(medical_treatment,Status_Pain);
|
||||
};
|
||||
default {
|
||||
ELSTRING(medical_treatment,Status_MildPain);
|
||||
};
|
||||
};
|
||||
_entries pushBack [localize _painText, [1, 1, 1, 1]];
|
||||
} else {
|
||||
_entries pushBack [localize ELSTRING(medical_treatment,Status_NoPain), _nonissueColor];
|
||||
};
|
||||
};
|
||||
|
||||
_entries pushBack ["", [1, 1, 1, 1]];
|
||||
|
||||
// Add selected body part name
|
||||
private _bodyPartName = [
|
||||
@ -70,29 +134,6 @@ if (GVAR(showDamageEntry)) then {
|
||||
};
|
||||
};
|
||||
|
||||
// Indicate if unit is bleeding at all
|
||||
if (IS_BLEEDING(_target)) then {
|
||||
_entries pushBack [localize LSTRING(Status_Bleeding), [1, 0, 0, 1]];
|
||||
};
|
||||
|
||||
if (GVAR(showBloodlossEntry)) then {
|
||||
// Give a qualitative description of the blood volume lost
|
||||
switch (GET_HEMORRHAGE(_target)) do {
|
||||
case 1: {
|
||||
_entries pushBack [localize LSTRING(Lost_Blood1), [1, 1, 0, 1]];
|
||||
};
|
||||
case 2: {
|
||||
_entries pushBack [localize LSTRING(Lost_Blood2), [1, 0.67, 0, 1]];
|
||||
};
|
||||
case 3: {
|
||||
_entries pushBack [localize LSTRING(Lost_Blood3), [1, 0.33, 0, 1]];
|
||||
};
|
||||
case 4: {
|
||||
_entries pushBack [localize LSTRING(Lost_Blood4), [1, 0, 0, 1]];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
// Indicate if a tourniquet is applied
|
||||
if (HAS_TOURNIQUET_APPLIED_ON(_target,_selectionN)) then {
|
||||
_entries pushBack [localize LSTRING(Status_Tourniquet_Applied), [0.77, 0.51, 0.08, 1]];
|
||||
@ -110,36 +151,6 @@ switch (GET_FRACTURES(_target) select _selectionN) do {
|
||||
};
|
||||
};
|
||||
|
||||
// Indicate the amount of pain the unit is in
|
||||
if (_target call EFUNC(common,isAwake)) then {
|
||||
private _pain = GET_PAIN_PERCEIVED(_target);
|
||||
if (_pain > 0) then {
|
||||
private _painText = switch (true) do {
|
||||
case (_pain > PAIN_UNCONSCIOUS): {
|
||||
ELSTRING(medical_treatment,Status_SeverePain);
|
||||
};
|
||||
case (_pain > (PAIN_UNCONSCIOUS / 5)): {
|
||||
ELSTRING(medical_treatment,Status_Pain);
|
||||
};
|
||||
default {
|
||||
ELSTRING(medical_treatment,Status_MildPain);
|
||||
};
|
||||
};
|
||||
_entries pushBack [localize _painText, [1, 1, 1, 1]];
|
||||
};
|
||||
};
|
||||
|
||||
// Show receiving IV volume remaining
|
||||
private _totalIvVolume = 0;
|
||||
{
|
||||
_x params ["_volumeRemaining"];
|
||||
_totalIvVolume = _totalIvVolume + _volumeRemaining;
|
||||
} forEach (_target getVariable [QEGVAR(medical,ivBags), []]);
|
||||
|
||||
if (_totalIvVolume >= 1) then {
|
||||
_entries pushBack [format [localize ELSTRING(medical_treatment,receivingIvVolume), floor _totalIvVolume], [1, 1, 1, 1]];
|
||||
};
|
||||
|
||||
// Add entries for open, bandaged, and stitched wounds
|
||||
private _woundEntries = [];
|
||||
|
||||
@ -174,7 +185,7 @@ private _fnc_processWounds = {
|
||||
|
||||
// Handle no wound entries
|
||||
if (_woundEntries isEqualTo []) then {
|
||||
_entries pushBack [localize ELSTRING(medical_treatment,NoInjuriesBodypart), [1, 1, 1, 1]];
|
||||
_entries pushBack [localize ELSTRING(medical_treatment,NoInjuriesBodypart), _nonissueColor];
|
||||
} else {
|
||||
_entries append _woundEntries;
|
||||
};
|
||||
|
@ -957,6 +957,9 @@
|
||||
<Chinese>出血中</Chinese>
|
||||
<Turkish>Kanama var</Turkish>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_GUI_STATUS_NOBLEEDING">
|
||||
<English>No bleeding</English>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_GUI_STATUS_PAIN">
|
||||
<English>in Pain</English>
|
||||
<German>hat Schmerzen</German>
|
||||
@ -1021,6 +1024,9 @@
|
||||
<German>Schiene angelegt</German>
|
||||
<Korean>부목 적용함</Korean>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_GUI_Lost_Blood0">
|
||||
<English>No blood loss</English>
|
||||
</Key>
|
||||
<!--Strings above match Blood2 but seem to differ in some languages, determine which is best to use-->
|
||||
<Key ID="STR_ACE_Medical_GUI_Lost_Blood1">
|
||||
<English>Lost some blood</English>
|
||||
|
@ -3417,6 +3417,9 @@
|
||||
<Chinese>呼吸極弱</Chinese>
|
||||
<Turkish>Neredeyse nefes almıyor</Turkish>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_Treatment_Status_NoPain">
|
||||
<English>No pain</English>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_Treatment_Status_MildPain">
|
||||
<English>In mild pain</English>
|
||||
<German>Hat leichte Schmerzen</German>
|
||||
@ -3496,6 +3499,9 @@
|
||||
<Chinesesimp>正在接受静脉注射 [%1毫升]</Chinesesimp>
|
||||
<Chinese>接收靜脈注射液中 [%1毫升]</Chinese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_Treatment_Status_NoIv">
|
||||
<English>No IV</English>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Medical_Treatment_Check_Bloodpressure">
|
||||
<English>Blood Pressure</English>
|
||||
<French>Tension artérielle</French>
|
||||
|
Loading…
Reference in New Issue
Block a user