-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
CPR will now automatically repeat, but you can no longer do it multiple times at once #52521
Conversation
Turned it into a loop, haven't tested it yet though. |
visible_message("<span class='notice'>[src] is trying to perform CPR on [target.name]!</span>", \ | ||
"<span class='notice'>You try to perform CPR on [target.name]... Hold still!</span>") | ||
|
||
if (!do_mob(src, target, time = panicking ? CPR_PANIC_SPEED : null)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if (!do_mob(src, target, time = panicking ? CPR_PANIC_SPEED : null)) | |
if (!do_mob(src, target, time = panicking ? CPR_PANIC_SPEED : 3 SECONDS)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would you accept something that moves 3 SECONDS
out to a define that do_after_mob
uses as well for consistency's sake?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missed this one
And yea, it would have been fine
I just want clarity, because null
in no way suggests it will be 3 seconds
if (target.health <= target.crit_threshold) | ||
if (!panicking) | ||
to_chat(src, "<span class='warning'>[target] still isn't up! You try harder!</span>") | ||
panicking = TRUE | ||
while (target.health <= target.crit_threshold) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if (target.health <= target.crit_threshold) | |
if (!panicking) | |
to_chat(src, "<span class='warning'>[target] still isn't up! You try harder!</span>") | |
panicking = TRUE | |
while (target.health <= target.crit_threshold) | |
if (target.health > target.crit_threshold) | |
panicking = FALSE | |
else | |
if (!panicking) | |
to_chat(src, "<span class='warning'>[target] still isn't up! You try harder!</span>") | |
panicking = TRUE | |
while (panicking) |
I meant something like this.
This PR has been inactive for long enough to be automatically marked as stale. This means it is at risk of being auto closed in ~ 7 days, please address any outstanding review items and ensure your PR is finished, if these are all true and you are auto-staled anyway, you need to actively ask maintainers if your PR will be merged. Once you have done any of the previous actions then you should request a maintainer remove the stale label on your PR, to reset the stale timer. If you feel no maintainer will respond in that time, you may wish to close this PR youself, while you seek maintainer comment, as you will then be able to reopen the PR yourself |
Not stale. |
About The Pull Request
This is from clicking once. The first time you do CPR, it will take the normal 3 seconds, but after that every attempt will take 0.8 seconds.
Why It's Good For The Game
Everyone and their mother knows to just repeatedly click on someone to do CPR. This just unjankifies it.
Changelog
馃啈
add: CPR will now automatically repeat, but you can no longer do it multiple times at once.
/:cl: