Fixes some procs that sleep inside SHOULD_NOT_SLEEP procs (#96959)

## About The Pull Request

I fixed should_not_sleep() locally as it wasn't catching all cases. I
PR'd this but want to do some damage control before its merged so our
linters dont fail on master

This revealed some procs that are sleeping but could run in
SHOULD_NOT_SLEEP procs.

I'll probably keep doing more of these.

## Why It's Good For The Game

prevents procs that shouldnt nap from napping

## Changelog

🆑
fix: Fixed some sleeping procs that could run in procs that arent
allowed to sleep
/🆑
This commit is contained in:
CabinetOnFire
2026-07-14 21:12:31 +02:00
committed by GitHub
parent 6242466aba
commit ef8cfb8b8d
10 changed files with 13 additions and 12 deletions
+2 -1
View File
@@ -155,6 +155,7 @@
* force - TRUE if we should ignore buckled_mob.can_buckle_to
*/
/atom/movable/proc/unbuckle_mob(mob/living/buckled_mob, force = FALSE, can_fall = TRUE)
if(!isliving(buckled_mob))
CRASH("Non-living [buckled_mob] thing called unbuckle_mob() for source.")
if(buckled_mob.buckled != src)
@@ -203,7 +204,7 @@
if(!has_buckled_mobs())
return
for(var/m in buckled_mobs)
unbuckle_mob(m, force)
INVOKE_ASYNC(src, PROC_REF(unbuckle_mob), m, force)
//Handle any extras after buckling
//Called on buckle_mob()
+1 -1
View File
@@ -259,7 +259,7 @@
// Handle adding item associated actions
for(var/path in actions_types)
add_item_action(path)
INVOKE_ASYNC(src, PROC_REF(add_item_action), path)
actions_types = null
if(force_string)
+2 -2
View File
@@ -426,7 +426,7 @@
return
var/obj/item/toy/plush/narplush/P = locate() in range(1, src)
if(P && istype(P.loc, /turf/open) && !P.clashing)
clash_of_the_plushies(P)
INVOKE_ASYNC(src, PROC_REF(clash_of_the_plushies), P)
/obj/item/toy/plush/ratplush/proc/clash_of_the_plushies(obj/item/toy/plush/narplush/P)
clash_target = P
@@ -511,7 +511,7 @@
. = ..()
var/obj/item/toy/plush/ratplush/P = locate() in range(1, src)
if(P && istype(P.loc, /turf/open) && !P.clash_target && !clashing)
P.clash_of_the_plushies(src)
INVOKE_ASYNC(P, TYPE_PROC_REF(/obj/item/toy/plush/ratplush, clash_of_the_plushies), src)
/obj/item/toy/plush/lizard_plushie
name = "lizard plushie"