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

Various fixes for the medical restructure branch #6434

Merged
merged 12 commits into from
Jul 16, 2018

Conversation

thojkooi
Copy link
Contributor

  • Fix some duplicate class declarations that prevent start up
  • Fix various issues with the new defined variables
  • Fix medical item icons not found
  • Fix statemachine not initalizing
  • Fix various namespace issues with medical (there are more)

Some obvious yet to do things;

  • State events are not being fired.
  • Injuries are not being handled properly in the state machine (probably due to the above)

@thojkooi thojkooi added the kind/bug-fix Release Notes: **FIXED:** label Jul 15, 2018
@thojkooi thojkooi added this to the Medical Rewrite milestone Jul 15, 2018
@thojkooi thojkooi requested a review from kymckay July 15, 2018 13:07
Copy link
Member

@kymckay kymckay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Initial review pass, just some macro usage errors

@@ -34,5 +34,5 @@ private _damageThreshold = if (isPlayer _unit) then {
};

if ((_headDamage > _damageThreshold / 2) || {_bodyDamage > _damageThreshold} || {(_painLevel >= PAIN_UNCONSCIOUS) && {random 1 < 0.1}}) then {
[QGVAR(CriticalInjury), _unit] call CBA_fnc_localEvent;
[QEGVAR(medical, CriticalInjury), _unit] call CBA_fnc_localEvent;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Incorrect space in macro here

@@ -52,7 +52,7 @@ private _bloodLoss = GET_BLOOD_LOSS(_unit);
if (_bloodLoss > 0) then {
_unit setVariable [QGVAR(bloodloss), _bloodLoss, _syncValues];

[QGVAR(Injury), _unit] call CBA_fnc_localEvent;
[QEGVAR(medical, Injury), _unit] call CBA_fnc_localEvent;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same issue with the space

@@ -87,7 +87,7 @@ _unit setVariable [VAR_BLOOD_PRESS, _bloodPressure, _syncValues];

private _cardiacOutput = [_unit] call EFUNC(medical_status,getCardiacOutput);
if (_bloodLoss > BLOOD_LOSS_KNOCK_OUT_THRESHOLD * _cardiacOutput) then {
[QGVAR(CriticalVitals), _unit] call CBA_fnc_localEvent;
[QEGVAR(medical, CriticalVitals), _unit] call CBA_fnc_localEvent;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and here

@@ -98,10 +98,10 @@ if (!isPlayer _unit) then {

_bloodPressure params ["_bloodPressureL", "_bloodPressureH"];
if (_bloodPressureL < 40 || {_heartRate < 30}) then {
[QGVAR(CriticalVitals), _unit] call CBA_fnc_localEvent;
[QEGVAR(medical, CriticalVitals), _unit] call CBA_fnc_localEvent;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

here

};
if ((_heartRate < 20) || {_heartRate > 220} || {_bloodPressureH < 50}) then {
[QGVAR(FatalVitals), _unit] call CBA_fnc_localEvent;
[QEGVAR(medical, FatalVitals), _unit] call CBA_fnc_localEvent;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

here

@thojkooi thojkooi merged commit 81f1365 into medical-rewrite-restructure Jul 16, 2018
@thojkooi thojkooi deleted the fix-restructure branch July 16, 2018 10:34
BaerMitUmlaut pushed a commit that referenced this pull request Aug 5, 2019
Various fixes for the medical restructure branch
@PabstMirror PabstMirror modified the milestones: Medical Rewrite, 3.13.0, 3.13.0-temp3 Dec 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug-fix Release Notes: **FIXED:**
Projects
Development

Successfully merging this pull request may close these issues.

3 participants