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

Added "medical_onSetDead" local event in fnc_setDead.sqf #1523

Merged
merged 2 commits into from
Jun 7, 2015

Conversation

AgentRev
Copy link
Contributor

@AgentRev AgentRev commented Jun 6, 2015

I am currently in the process of porting a mission to ACE3, and it contains a scoreboard system which requires capture of the "source" and "projectile" parameters passed to the HandleDamage event, either when the player falls unconscious or right before being considered dead, in order to give appropriate credit. For the "unconscious" part, I am able to recover those values within the medical_onUnconscious event, but there is no equivalent for the "dead" part.

Since most ACE-handled deaths are triggered via fnc_setDead within medical's fnc_handleDamage scripts, adding a medical_onSetDead event at this location allows extraction of aforementioned parameters, which is enough to make the scoreboard work properly.

@bux bux added the kind/enhancement Release Notes: **IMPROVED:** label Jun 6, 2015
@bux bux added this to the 3.1.0 milestone Jun 6, 2015
@@ -74,5 +74,8 @@ _unit setvariable ["ACE_isDead", true, true];
if (isPLayer _unit) then {
_unit setvariable ["isDeadPlayer", true, true];
};

["medical_onSetDead", _unit] call EFUNC(common,localEvent);
Copy link
Contributor

Choose a reason for hiding this comment

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

Change the parameters to [_unit] and we can merge it

@AgentRev
Copy link
Contributor Author

AgentRev commented Jun 7, 2015

@Glowbal there you go

@thojkooi
Copy link
Contributor

thojkooi commented Jun 7, 2015

Thank you @AgentRev

thojkooi added a commit that referenced this pull request Jun 7, 2015
Added "medical_onSetDead" local event in fnc_setDead.sqf
@thojkooi thojkooi merged commit 610f74d into acemod:master Jun 7, 2015
@AgentRev AgentRev deleted the onSetDead branch June 7, 2015 22:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement Release Notes: **IMPROVED:**
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants