fix handler cleanup and make deceased a dark gray
This commit is contained in:
@@ -35,13 +35,15 @@ milsim_client_medState3D_colors = [
|
|||||||
[0, 0.5, 0, 0.9], // TRIAGE_COLOR_MINIMAL
|
[0, 0.5, 0, 0.9], // TRIAGE_COLOR_MINIMAL
|
||||||
[1, 0.84, 0, 0.9], // TRIAGE_COLOR_DELAYED
|
[1, 0.84, 0, 0.9], // TRIAGE_COLOR_DELAYED
|
||||||
[1, 0, 0, 0.9], // TRIAGE_COLOR_IMMEDIATE
|
[1, 0, 0, 0.9], // TRIAGE_COLOR_IMMEDIATE
|
||||||
[0, 0, 0, 0.9], // TRIAGE_COLOR_DECEASED
|
[0.15, 0.15, 0.15, 0.9], // TRIAGE_COLOR_DECEASED
|
||||||
[0.5, 0.5, 0.5, 0] // TRIAGE_COLOR_NONE
|
[0.5, 0.5, 0.5, 0] // TRIAGE_COLOR_NONE
|
||||||
];
|
];
|
||||||
|
|
||||||
// Per-frame handler to draw icons
|
// Per-frame handler to draw icons
|
||||||
// cleanup
|
// cleanup
|
||||||
[milsim_client_medState3D_drawTargetsPfh] call CBA_fnc_removePerFrameHandler;
|
if (!isNil "milsim_client_medState3D_pfh") then {
|
||||||
|
[milsim_client_medState3D_pfh] call CBA_fnc_removePerFrameHandler;
|
||||||
|
};
|
||||||
// add pfh
|
// add pfh
|
||||||
milsim_client_medState3D_pfh = [{
|
milsim_client_medState3D_pfh = [{
|
||||||
// if disabled, skip processing
|
// if disabled, skip processing
|
||||||
@@ -59,6 +61,8 @@ milsim_client_medState3D_pfh = [{
|
|||||||
) then {continue};
|
) then {continue};
|
||||||
|
|
||||||
// color based on triage level
|
// color based on triage level
|
||||||
|
private _triageLevel = _x getVariable ["ace_medical_triageLevel", -1];
|
||||||
|
if (_triageLevel == -1) then {continue};
|
||||||
private _color = milsim_client_medState3D_colors select (
|
private _color = milsim_client_medState3D_colors select (
|
||||||
(_x getVariable ["ace_medical_triageLevel", -1]) -1
|
(_x getVariable ["ace_medical_triageLevel", -1]) -1
|
||||||
);
|
);
|
||||||
@@ -79,7 +83,9 @@ milsim_client_medState3D_pfh = [{
|
|||||||
|
|
||||||
// subroutine to gather nearest 50 units every 5 seconds and store in milsim_client_medState3D_drawTargets
|
// subroutine to gather nearest 50 units every 5 seconds and store in milsim_client_medState3D_drawTargets
|
||||||
// cleanup
|
// cleanup
|
||||||
[milsim_client_medState3D_drawTargetsPfh] call CBA_fnc_removePerFrameHandler;
|
if (!isNil "milsim_client_medState3D_drawTargetsPfh") then {
|
||||||
|
[milsim_client_medState3D_drawTargetsPfh] call CBA_fnc_removePerFrameHandler;
|
||||||
|
};
|
||||||
// add pfh
|
// add pfh
|
||||||
milsim_client_medState3D_drawTargetsPfh = [{
|
milsim_client_medState3D_drawTargetsPfh = [{
|
||||||
milsim_client_medState3D_drawTargets = (
|
milsim_client_medState3D_drawTargets = (
|
||||||
|
|||||||
Reference in New Issue
Block a user