Skip to content

Commit

Permalink
Fix bad select
Browse files Browse the repository at this point in the history
  • Loading branch information
johnb432 committed Jan 5, 2025
1 parent eea3c5f commit 13c1418
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion addons/medical_engine/script_macros_medical.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@
#define GET_BANDAGED_WOUNDS(unit) (unit getVariable [VAR_BANDAGED_WOUNDS, createHashMap])
#define GET_STITCHED_WOUNDS(unit) (unit getVariable [VAR_STITCHED_WOUNDS, createHashMap])
#define GET_DAMAGE_THRESHOLD(unit) (unit getVariable [QEGVAR(medical,damageThreshold), [EGVAR(medical,AIDamageThreshold),EGVAR(medical,playerDamageThreshold)] select (isPlayer unit)])
#define GET_BODYPART_DAMAGE(unit) (unit getVariable [VAR_BODYPART_DAMAGE, DEFAULT_BODYPART_DAMAGE_VALUES])
#define GET_BODYPART_DAMAGE(unit) (unit getVariable [VAR_BODYPART_DAMAGE, DEFAULT_BODYPART_DAMAGE_VALUES])

// The following function calls are defined here just for consistency
#define GET_BLOOD_LOSS(unit) ([unit] call EFUNC(medical_status,getBloodLoss))
Expand Down
2 changes: 1 addition & 1 deletion addons/medical_treatment/functions/fnc_addTrauma.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
params ["_unit", "_bodyPart", "_trauma"];

private _partIndex = ALL_BODY_PARTS find _bodyPart;
private _bodyPartDamage = GET_BODYPART_DAMAGE(_unit) select _partIndex;
private _bodyPartDamage = GET_BODYPART_DAMAGE(_unit);
private _newDam = (_bodyPartDamage select _partIndex) + _trauma;

// Prevent obscenely small damage from lack of floating precision
Expand Down

0 comments on commit 13c1418

Please sign in to comment.