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

CPR changes #6771

Closed
wants to merge 14 commits into from
12 changes: 8 additions & 4 deletions code/modules/mob/living/carbon/human/human_attackhand.dm
Original file line number Diff line number Diff line change
Expand Up @@ -55,17 +55,21 @@
SPAN_HELPFUL("You feel a <b>breath of fresh air</b> enter your lungs. It feels good."),
SPAN_HELPFUL("You <b>perform CPR</b> on <b>[src]</b>. Repeat at least every <b>7 seconds</b>."),
SPAN_NOTICE("<b>[attacking_mob]</b> performs <b>CPR</b> on <b>[src]</b>."))
if(is_revivable() && stat == DEAD)
if(is_revivable() && !check_tod() && stat == DEAD)
attacking_mob.visible_message(SPAN_NOTICE("<b>[attacking_mob]</b> performs <b>CPR</b> on <b>[src]</b>."),
SPAN_HELPFUL("You perform <b>CPR</b> on <b>[src]</b>. You feel it may be a lost cause."))
balloon_alert(attacking_mob, "you perform cpr, but feel it may be a lost cause")
Comment on lines +59 to +61
Copy link
Contributor

Choose a reason for hiding this comment

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

Rather than this, perform the check status verb for them. Or better yet, just always have the check status verb done so many iterations rather than this.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Rather than this, perform the check status verb for them. Or better yet, just always have the check status verb done so many iterations rather than this.

sure - im not sure of the best way to code this though

else if(is_revivable() && stat == DEAD)
Copy link
Contributor

Choose a reason for hiding this comment

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

Ultimately the behavior of cpr shouldn't be changing.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ultimately the behavior of cpr shouldn't be changing.

I'm not sure what you mean by this - if you mean the failed CPR leading to more failed CPR thing, I definitely want to change that behavior

if(cpr_cooldown < world.time)
revive_grace_period += 7 SECONDS
cpr_cooldown = world.time + 7 SECONDS
Copy link
Contributor

Choose a reason for hiding this comment

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

Let the cpr_cooldown still be set on a failure if they are alive like existing behavior

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Let the cpr_cooldown still be set on a failure if they are alive like existing behavior

This is definitely an intentional change for the reasons I mentioned in the PR description and the debate in the comments. If you don't want this change, feel free to close the PR, as it's the main change at this point. I will mark it as balance though as per suggestions.

attacking_mob.visible_message(SPAN_NOTICE("<b>[attacking_mob]</b> performs <b>CPR</b> on <b>[src]</b>."),
SPAN_HELPFUL("You perform <b>CPR</b> on <b>[src]</b>."))
balloon_alert(attacking_mob, "you perform cpr")
else
attacking_mob.visible_message(SPAN_NOTICE("<b>[attacking_mob]</b> fails to perform CPR on <b>[src]</b>."),
SPAN_HELPFUL("You <b>fail</b> to perform <b>CPR</b> on <b>[src]</b>. Incorrect rhythm. Do it <b>slower</b>."))
balloon_alert(attacking_mob, "incorrect rhythm. do it slower")
cpr_cooldown = world.time + 7 SECONDS
zzzmike marked this conversation as resolved.
Show resolved Hide resolved
SPAN_HELPFUL("You <b>fail</b> to perform <b>CPR</b> on <b>[src]</b>. Incorrect rhythm. You (along with anyone else nearby) need to do it <b>slower</b>."))
balloon_alert(attacking_mob, "incorrect rhythm. you (along with others) should do it slower")
cpr_attempt_timer = 0
return 1

Expand Down
Loading