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

Medical - Update setDead to use setHitpointDamage instigator param #8397

Merged
merged 11 commits into from
Nov 15, 2021

Conversation

LinkIsGrim
Copy link
Contributor

@LinkIsGrim LinkIsGrim commented Aug 28, 2021

When merged this pull request will:

  • Title.
  • Fixes scoreboard not counting kills etc, Slack discussion.
  • Count forced respawn or script kill while unit is unconscious as kill for last instigator.

Forward compatible, but only has full effect with 2.06 profiling branch or 2.08.
Needs #8373.

@PabstMirror
Copy link
Contributor

I think we could capture respawn button press by modifying https://github.com/acemod/ACE3/blob/master/addons/common/functions/fnc_disableUserInput.sqf#L69

something like

_ctrl ctrlSetEventHandler ["buttonClick", QUOTE(closeDialog 0; [player, "respawn_button"] call EFUNC(medical_status,setDead); [false] call DFUNC(disableUserInput);)];

@PabstMirror PabstMirror added this to the Ongoing milestone Oct 7, 2021
@PabstMirror PabstMirror added the kind/enhancement Release Notes: **IMPROVED:** label Oct 7, 2021
@LinkIsGrim
Copy link
Contributor Author

[player, "respawn_button"] call EFUNC(medical_status,setDead)

Need to add a check for medical being loaded, which is going to look terrible inside that QUOTE macro

Co-authored-by: Filip Maciejewski <veteran29@users.noreply.github.com>
@PabstMirror
Copy link
Contributor

2.06.148309 new PROFILING branch with PERFORMANCE binaries, v1, server and client, windows 32/64-bit, linux server 32/64-bit

  • Added: Instigator parameter to setHitPointDamage/setHit/setHitIndex script commands

I guess changes to the command are still being worked on

@dedmen
Copy link
Contributor

dedmen commented Oct 29, 2021

The command is ready and working, no other changes planned to it

@PabstMirror
Copy link
Contributor

Did some testing and I think this seems to be working fine
I made some changes in commit 4304701

the main change is we no longer need to handle if (_causeOfDeath != "#scripted" || {IS_UNCONSCIOUS(_unit)}) then { because it's handled by the button directly

@PabstMirror PabstMirror modified the milestones: Ongoing, 3.14.1 Nov 12, 2021
@LinkIsGrim
Copy link
Contributor Author

Is anything needed from me on this? I'm a bit busy the next month, not sure if I can make time to work on anything.

@PabstMirror
Copy link
Contributor

I pushed those changes to this branch, so it should be good to go

@jonpas jonpas changed the title Medical - update setDead to use setHitpointDamage instigator param Medical - Update setDead to use setHitpointDamage instigator param Nov 14, 2021
@PabstMirror PabstMirror merged commit a9296f6 into acemod:master Nov 15, 2021
AndreasBrostrom pushed a commit to AndreasBrostrom/ACE3 that referenced this pull request Dec 3, 2021
acemod#8397)

* Redoing this

* Revert "Redoing this"

This reverts commit 80ff709.

* Do this properly

* Update fnc_handleKilled.sqf

* use setDead function directly

* Handle scripted camera

* redo acemod#8387

I'm dumb.

* try this

* if construct outside of ctrlSetEventHandler

Co-authored-by: Filip Maciejewski <veteran29@users.noreply.github.com>

* tweak disableUserInput / handleKilled

Co-authored-by: Filip Maciejewski <veteran29@users.noreply.github.com>
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
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.

6 participants