diff --git a/code/controllers/subsystem/nightshift.dm b/code/controllers/subsystem/nightshift.dm
index 78b2e63cf2..c45bd64702 100644
--- a/code/controllers/subsystem/nightshift.dm
+++ b/code/controllers/subsystem/nightshift.dm
@@ -42,6 +42,7 @@ SUBSYSTEM_DEF(nightshift)
update_nightshift(night_time, announcing)
/datum/controller/subsystem/nightshift/proc/update_nightshift(active, announce = TRUE, max_level_override)
+ set waitfor = FALSE
nightshift_active = active
if(announce)
if (active)
diff --git a/code/controllers/subsystem/processing/processing.dm b/code/controllers/subsystem/processing/processing.dm
index f5a423b353..661eafc2a5 100644
--- a/code/controllers/subsystem/processing/processing.dm
+++ b/code/controllers/subsystem/processing/processing.dm
@@ -47,5 +47,5 @@ SUBSYSTEM_DEF(processing)
* If you override this do not call parent, as it will return PROCESS_KILL. This is done to prevent objects that dont override process() from staying in the processing list
*/
/datum/proc/process(delta_time)
- // SHOULD_NOT_SLEEP(TRUE)
+ SHOULD_NOT_SLEEP(TRUE)
return PROCESS_KILL
diff --git a/code/datums/components/embedded.dm b/code/datums/components/embedded.dm
index ec5ec19a6b..eca38fee34 100644
--- a/code/datums/components/embedded.dm
+++ b/code/datums/components/embedded.dm
@@ -265,6 +265,7 @@
/// Items embedded/stuck to carbons both check whether they randomly fall out (if applicable), as well as if the target mob and limb still exists.
/// Items harmfully embedded in carbons have an additional check for random pain (if applicable)
/datum/component/embedded/proc/processCarbon()
+ set waitfor = FALSE
var/mob/living/carbon/victim = parent
if(!victim || !limb) // in case the victim and/or their limbs exploded (say, due to a sticky bomb)
diff --git a/code/datums/components/lockon_aiming.dm b/code/datums/components/lockon_aiming.dm
index 2f4401862d..4acdece7e5 100644
--- a/code/datums/components/lockon_aiming.dm
+++ b/code/datums/components/lockon_aiming.dm
@@ -158,6 +158,7 @@
autolock()
/datum/component/lockon_aiming/proc/autolock()
+ set waitfor = FALSE
var/mob/M = parent
if(!M.client)
return FALSE
diff --git a/code/datums/dna.dm b/code/datums/dna.dm
index 248b669ab1..a2982a3caf 100644
--- a/code/datums/dna.dm
+++ b/code/datums/dna.dm
@@ -405,7 +405,7 @@
/mob/living/carbon/human/proc/hardset_dna(ui, list/mutation_index, newreal_name, newblood_type, datum/species/mrace, newfeatures, list/default_mutation_genes)
-
+ set waitfor = FALSE
if(newreal_name)
real_name = newreal_name
dna.generate_unique_enzymes()
diff --git a/code/datums/elements/earhealing.dm b/code/datums/elements/earhealing.dm
index 91c2120fc2..1c74777845 100644
--- a/code/datums/elements/earhealing.dm
+++ b/code/datums/elements/earhealing.dm
@@ -24,7 +24,8 @@
else
user_by_item -= source
-/datum/element/earhealing/process()
+/datum/element/earhealing/proc/do_process()
+ set waitfor = FALSE
for(var/i in user_by_item)
var/mob/living/carbon/user = user_by_item[i]
if(HAS_TRAIT(user, TRAIT_DEAF))
@@ -35,3 +36,6 @@
ears.deaf = max(ears.deaf - 0.25, (ears.damage < ears.maxHealth ? 0 : 1)) // Do not clear deafness if our ears are too damaged
ears.damage = max(ears.damage - 0.025, 0)
CHECK_TICK
+
+/datum/element/earhealing/process()
+ do_process()
diff --git a/code/datums/wires/_wires.dm b/code/datums/wires/_wires.dm
index 1c9c14ee3e..81f99cfa69 100644
--- a/code/datums/wires/_wires.dm
+++ b/code/datums/wires/_wires.dm
@@ -166,6 +166,7 @@
on_pulse(wire, user)
/datum/wires/proc/pulse_color(color, mob/living/user)
+ set waitfor = FALSE
LAZYINITLIST(current_users)
if(current_users[user])
return FALSE
diff --git a/code/game/gamemodes/dynamic/dynamic.dm b/code/game/gamemodes/dynamic/dynamic.dm
index 55f91ba3d3..c7fee7df96 100644
--- a/code/game/gamemodes/dynamic/dynamic.dm
+++ b/code/game/gamemodes/dynamic/dynamic.dm
@@ -711,10 +711,15 @@ GLOBAL_VAR_INIT(dynamic_forced_storyteller, null)
update_playercounts()
if (storyteller.should_inject_antag())
SSblackbox.record_feedback("tally","dynamic",1,"Attempted midround injections")
- var/list/drafted_rules = storyteller.midround_draft()
- if (drafted_rules.len > 0)
- SSblackbox.record_feedback("tally","dynamic",1,"Successful midround injections")
- picking_midround_latejoin_rule(drafted_rules)
+ do_midround_injection()
+
+/datum/game_mode/dynamic/proc/do_midround_injection()
+ set waitfor = FALSE
+ var/list/drafted_rules = storyteller.midround_draft()
+ if (drafted_rules.len > 0)
+ SSblackbox.record_feedback("tally","dynamic",1,"Successful midround injections")
+ picking_midround_latejoin_rule(drafted_rules)
+
/// Updates current_players.
/datum/game_mode/dynamic/proc/update_playercounts()
diff --git a/code/game/gamemodes/gangs/dominator.dm b/code/game/gamemodes/gangs/dominator.dm
index ed17d830ba..a253aa906c 100644
--- a/code/game/gamemodes/gangs/dominator.dm
+++ b/code/game/gamemodes/gangs/dominator.dm
@@ -105,14 +105,18 @@
if(tempgang != gang)
tempgang.message_gangtools("WARNING: [gang.name] Gang takeover imminent. Their dominator at [domloc.map_name] must be destroyed!",1,1)
else
- Cinematic(CINEMATIC_MALF,world) //Here is the gang victory trigger on the dominator ending.
- gang.winner = TRUE
- SSticker.news_report = GANG_VICTORY
- SSticker.force_ending = TRUE
+ endgame()
if(!.)
STOP_PROCESSING(SSmachines, src)
+/obj/machinery/dominator/proc/endgame()
+ set waitfor = FALSE
+ Cinematic(CINEMATIC_MALF,world) //Here is the gang victory trigger on the dominator ending.
+ gang.winner = TRUE
+ SSticker.news_report = GANG_VICTORY
+ SSticker.force_ending = TRUE
+
/obj/machinery/dominator/play_attack_sound(damage_amount, damage_type = BRUTE, damage_flag = 0)
switch(damage_type)
if(BRUTE)
diff --git a/code/game/machinery/cloning.dm b/code/game/machinery/cloning.dm
index e95543cffb..a3bdfe4243 100644
--- a/code/game/machinery/cloning.dm
+++ b/code/game/machinery/cloning.dm
@@ -173,10 +173,7 @@
clonemind.transfer_to(H)
else if(get_clone_mind == CLONEPOD_POLL_MIND)
- var/list/candidates = pollCandidatesForMob("Do you want to play as [clonename]'s defective clone? (Don't ERP without permission from the original)", null, null, null, 100, H, POLL_IGNORE_CLONE)
- if(LAZYLEN(candidates))
- var/mob/C = pick(candidates)
- H.key = C.key
+ poll_for_mind(H, clonename)
if(grab_ghost_when == CLONER_FRESH_CLONE)
H.grab_ghost()
@@ -206,6 +203,13 @@
attempting = FALSE
return TRUE
+/obj/machinery/clonepod/proc/poll_for_mind(mob/living/carbon/human/H, clonename)
+ set waitfor = FALSE
+ var/list/candidates = pollCandidatesForMob("Do you want to play as [clonename]'s defective clone? (Don't ERP without permission from the original)", null, null, null, 100, H, POLL_IGNORE_CLONE)
+ if(LAZYLEN(candidates))
+ var/mob/C = pick(candidates)
+ H.key = C.key
+
//Grow clones to maturity then kick them out. FREELOADERS
/obj/machinery/clonepod/process()
var/mob/living/mob_occupant = occupant
diff --git a/code/game/machinery/computer/pod.dm b/code/game/machinery/computer/pod.dm
index 97e2d4ea0a..f1cf187ff9 100644
--- a/code/game/machinery/computer/pod.dm
+++ b/code/game/machinery/computer/pod.dm
@@ -34,6 +34,7 @@
* Initiates launching sequence by checking if all components are functional, opening poddoors, firing mass drivers and then closing poddoors
*/
/obj/machinery/computer/pod/proc/alarm()
+ set waitfor = FALSE
if(stat & (NOPOWER|BROKEN))
return
diff --git a/code/game/machinery/porta_turret/portable_turret.dm b/code/game/machinery/porta_turret/portable_turret.dm
index aad64df6d9..db8f666368 100644
--- a/code/game/machinery/porta_turret/portable_turret.dm
+++ b/code/game/machinery/porta_turret/portable_turret.dm
@@ -503,6 +503,7 @@
return 1
/obj/machinery/porta_turret/proc/popUp() //pops the turret up
+ set waitfor = FALSE
if(!anchored)
return
if(raising || raised)
@@ -521,6 +522,7 @@
layer = MOB_LAYER
/obj/machinery/porta_turret/proc/popDown() //pops the turret down
+ set waitfor = FALSE
if(raising || !raised)
return
if(stat & BROKEN)
diff --git a/code/game/machinery/syndicatebomb.dm b/code/game/machinery/syndicatebomb.dm
index 561daf433d..4009b1b56b 100644
--- a/code/game/machinery/syndicatebomb.dm
+++ b/code/game/machinery/syndicatebomb.dm
@@ -288,6 +288,7 @@
qdel(src)
/obj/item/bombcore/proc/defuse()
+ set waitfor = FALSE
//Note: Because of how var/defused is used you shouldn't override this UNLESS you intend to set the var to 0 or
// otherwise remove the core/reset the wires before the end of defuse(). It will repeatedly be called otherwise.
diff --git a/code/game/mecha/combat/neovgre.dm b/code/game/mecha/combat/neovgre.dm
index 584a2d007e..75470abe88 100644
--- a/code/game/mecha/combat/neovgre.dm
+++ b/code/game/mecha/combat/neovgre.dm
@@ -70,7 +70,6 @@
cell.charge = INFINITY
max_integrity = INFINITY
obj_integrity = max_integrity
- CHECK_TICK //Just to be on the safe side lag wise
else
if(cell.charge < cell.maxcharge)
for(var/obj/effect/clockwork/sigil/transmission/T in range(SIGIL_ACCESS_RANGE, src))
@@ -80,7 +79,6 @@
adjust_clockwork_power(-delta)
if(obj_integrity < max_integrity && istype(loc, /turf/open/floor/clockwork))
obj_integrity += min(max_integrity - obj_integrity, max_integrity / 200)
- CHECK_TICK
/obj/mecha/combat/neovgre/Initialize()
.=..()
diff --git a/code/game/objects/items/pneumaticCannon.dm b/code/game/objects/items/pneumaticCannon.dm
index e62208f848..42e345b502 100644
--- a/code/game/objects/items/pneumaticCannon.dm
+++ b/code/game/objects/items/pneumaticCannon.dm
@@ -266,6 +266,7 @@
. += tank.icon_state
/obj/item/pneumatic_cannon/proc/fill_with_type(type, amount)
+ set waitfor = FALSE
if(!ispath(type, /obj) && !ispath(type, /mob))
return FALSE
var/loaded = 0
diff --git a/code/game/objects/structures/transit_tubes/station.dm b/code/game/objects/structures/transit_tubes/station.dm
index 119026a66e..376725b262 100644
--- a/code/game/objects/structures/transit_tubes/station.dm
+++ b/code/game/objects/structures/transit_tubes/station.dm
@@ -121,6 +121,7 @@
/obj/structure/transit_tube/station/proc/launch_pod()
+ set waitfor = FALSE
if(launch_cooldown >= world.time)
return
for(var/obj/structure/transit_tube_pod/pod in loc)
diff --git a/code/modules/antagonists/_common/antag_datum.dm b/code/modules/antagonists/_common/antag_datum.dm
index b92b659183..4082a48e71 100644
--- a/code/modules/antagonists/_common/antag_datum.dm
+++ b/code/modules/antagonists/_common/antag_datum.dm
@@ -96,6 +96,7 @@ GLOBAL_LIST_EMPTY(antagonists)
//Proc called when the datum is given to a mind.
/datum/antagonist/proc/on_gain()
+ set waitfor = FALSE
if(!(owner?.current))
return
if(!silent)
diff --git a/code/modules/antagonists/clockcult/clock_effects/clock_sigils.dm b/code/modules/antagonists/clockcult/clock_effects/clock_sigils.dm
index 34370faa0a..4b88d203d6 100644
--- a/code/modules/antagonists/clockcult/clock_effects/clock_sigils.dm
+++ b/code/modules/antagonists/clockcult/clock_effects/clock_sigils.dm
@@ -225,18 +225,22 @@
return ..()
/obj/effect/clockwork/sigil/transmission/process()
- var/power_drained = 0
- var/power_mod = 0.005
- for(var/t in spiral_range_turfs(SIGIL_ACCESS_RANGE, src))
- var/turf/T = t
- for(var/M in T)
- var/atom/movable/A = M
- power_drained += A.power_drain(TRUE)
+ do_process()
- CHECK_TICK
+/obj/effect/clockwork/sigil/transmission/proc/do_process()
+ set waitfor = FALSE
+ var/power_drained = 0
+ var/power_mod = 0.005
+ for(var/t in spiral_range_turfs(SIGIL_ACCESS_RANGE, src))
+ var/turf/T = t
+ for(var/M in T)
+ var/atom/movable/A = M
+ power_drained += A.power_drain(TRUE)
- adjust_clockwork_power(power_drained * power_mod * 15)
- new /obj/effect/temp_visual/ratvar/sigil/transmission(loc, 1 + (power_drained * 0.0035))
+ CHECK_TICK
+
+ adjust_clockwork_power(power_drained * power_mod * 15)
+ new /obj/effect/temp_visual/ratvar/sigil/transmission(loc, 1 + (power_drained * 0.0035))
/obj/effect/clockwork/sigil/transmission/proc/charge_cyborg(mob/living/silicon/robot/cyborg)
if(!cyborg_checks(cyborg))
diff --git a/code/modules/antagonists/clockcult/clock_structures/ark_of_the_clockwork_justicar.dm b/code/modules/antagonists/clockcult/clock_structures/ark_of_the_clockwork_justicar.dm
index 5fc2a0ab63..8fcc36a456 100644
--- a/code/modules/antagonists/clockcult/clock_structures/ark_of_the_clockwork_justicar.dm
+++ b/code/modules/antagonists/clockcult/clock_structures/ark_of_the_clockwork_justicar.dm
@@ -246,6 +246,36 @@
if(GATEWAY_RATVAR_COMING to INFINITY)
. += "The anomaly is stable! Something is coming through!"
+/obj/structure/destructible/clockwork/massive/celestial_gateway/proc/fulfill_purpose()
+ set waitfor = FALSE
+ countdown.stop()
+ resistance_flags |= INDESTRUCTIBLE
+ purpose_fulfilled = TRUE
+ make_glow()
+ animate(glow, transform = matrix() * 1.5, alpha = 255, time = 125)
+ sound_to_playing_players(volume = 100, channel = CHANNEL_JUSTICAR_ARK, S = sound('sound/effects/ratvar_rises.ogg')) //End the sounds
+ sleep(125)
+ make_glow()
+ animate(glow, transform = matrix() * 3, alpha = 0, time = 5)
+ QDEL_IN(src, 3)
+ sleep(3)
+ GLOB.clockwork_gateway_activated = TRUE
+ var/turf/T = SSmapping.get_station_center()
+ new /obj/structure/destructible/clockwork/massive/ratvar(T)
+ var/x0 = T.x
+ var/y0 = T.y
+ for(var/I in spiral_range_turfs(255, T, tick_checked = TRUE))
+ var/turf/T2 = I
+ if(!T2)
+ continue
+ var/dist = cheap_hypotenuse(T2.x, T2.y, x0, y0)
+ if(dist < 100)
+ dist = TRUE
+ else
+ dist = FALSE
+ T.ratvar_act(dist)
+ CHECK_TICK
+
/obj/structure/destructible/clockwork/massive/celestial_gateway/process()
adjust_clockwork_power(2.5) //Provides weak power generation on its own
if(seconds_until_activation)
@@ -306,33 +336,7 @@
glow.icon_state = "clockwork_gateway_closing"
if(GATEWAY_RATVAR_ARRIVAL to INFINITY)
if(!purpose_fulfilled)
- countdown.stop()
- resistance_flags |= INDESTRUCTIBLE
- purpose_fulfilled = TRUE
- make_glow()
- animate(glow, transform = matrix() * 1.5, alpha = 255, time = 125)
- sound_to_playing_players(volume = 100, channel = CHANNEL_JUSTICAR_ARK, S = sound('sound/effects/ratvar_rises.ogg')) //End the sounds
- sleep(125)
- make_glow()
- animate(glow, transform = matrix() * 3, alpha = 0, time = 5)
- QDEL_IN(src, 3)
- sleep(3)
- GLOB.clockwork_gateway_activated = TRUE
- var/turf/T = SSmapping.get_station_center()
- new /obj/structure/destructible/clockwork/massive/ratvar(T)
- var/x0 = T.x
- var/y0 = T.y
- for(var/I in spiral_range_turfs(255, T, tick_checked = TRUE))
- var/turf/T2 = I
- if(!T2)
- continue
- var/dist = cheap_hypotenuse(T2.x, T2.y, x0, y0)
- if(dist < 100)
- dist = TRUE
- else
- dist = FALSE
- T.ratvar_act(dist)
- CHECK_TICK
+ fulfill_purpose()
//Converts nearby turfs into their clockwork equivalent, with ever-increasing range the closer the ark is to summoning Ratvar
/obj/structure/destructible/clockwork/massive/celestial_gateway/proc/conversion_pulse()
diff --git a/code/modules/antagonists/clockcult/clock_structures/prolonging_prism.dm b/code/modules/antagonists/clockcult/clock_structures/prolonging_prism.dm
index 73488d736a..ededd0174c 100644
--- a/code/modules/antagonists/clockcult/clock_structures/prolonging_prism.dm
+++ b/code/modules/antagonists/clockcult/clock_structures/prolonging_prism.dm
@@ -60,12 +60,8 @@
delay_remaining += PRISM_DELAY_DURATION
toggle(0, user)
-/obj/structure/destructible/clockwork/powered/prolonging_prism/process()
- var/turf/own_turf = get_turf(src)
- if(SSshuttle.emergency.mode != SHUTTLE_CALL || delay_remaining <= 0 || !own_turf || !is_station_level(own_turf.z))
- forced_disable(FALSE)
- return
- . = ..()
+/obj/structure/destructible/clockwork/powered/prolonging_prism/proc/do_process()
+ set waitfor = FALSE
var/delay_amount = 40
delay_remaining -= delay_amount
var/efficiency = get_efficiency_mod()
@@ -114,6 +110,14 @@
new /obj/effect/temp_visual/ratvar/prolonging_prism(T)
CHECK_TICK //we may be going over a hell of a lot of turfs
+/obj/structure/destructible/clockwork/powered/prolonging_prism/process()
+ var/turf/own_turf = get_turf(src)
+ if(SSshuttle.emergency.mode != SHUTTLE_CALL || delay_remaining <= 0 || !own_turf || !is_station_level(own_turf.z))
+ forced_disable(FALSE)
+ return
+ . = ..()
+ do_process()
+
/obj/structure/destructible/clockwork/powered/prolonging_prism/proc/get_delay_cost()
return FLOOR(delay_cost, MIN_CLOCKCULT_POWER)
diff --git a/code/modules/antagonists/clockcult/clock_structures/ratvar_the_clockwork_justicar.dm b/code/modules/antagonists/clockcult/clock_structures/ratvar_the_clockwork_justicar.dm
index 24ad1af88a..51f8dc7101 100644
--- a/code/modules/antagonists/clockcult/clock_structures/ratvar_the_clockwork_justicar.dm
+++ b/code/modules/antagonists/clockcult/clock_structures/ratvar_the_clockwork_justicar.dm
@@ -110,6 +110,7 @@
//Put me in Reebe, will you? Ratvar has found and is going to do a hecking murder on Nar'Sie
/obj/structure/destructible/clockwork/massive/ratvar/proc/clash_of_the_titans(obj/singularity/narsie/narsie)
+ set waitfor = FALSE
var/winner = "Undeclared"
var/base_victory_chance = 1
while(src && narsie)
diff --git a/code/modules/antagonists/cult/cult_structures.dm b/code/modules/antagonists/cult/cult_structures.dm
index 25fd446b06..a0093e4da1 100644
--- a/code/modules/antagonists/cult/cult_structures.dm
+++ b/code/modules/antagonists/cult/cult_structures.dm
@@ -204,26 +204,31 @@
STOP_PROCESSING(SSfastprocess, src)
return ..()
+/obj/structure/destructible/cult/pylon/proc/heal_friends()
+ set waitfor = FALSE
+ for(var/mob/living/L in range(5, src))
+ if(iscultist(L) || isshade(L) || isconstruct(L))
+ if(L.health != L.maxHealth)
+ new /obj/effect/temp_visual/heal(get_turf(src), "#960000")
+ if(ishuman(L))
+ L.adjustBruteLoss(-1, 0, only_organic = FALSE)
+ L.adjustFireLoss(-1, 0, only_organic = FALSE)
+ L.updatehealth()
+ if(isshade(L) || isconstruct(L))
+ var/mob/living/simple_animal/M = L
+ if(M.health < M.maxHealth)
+ M.adjustHealth(-3)
+ if(ishuman(L) && L.blood_volume < (BLOOD_VOLUME_NORMAL * L.blood_ratio))
+ L.blood_volume += 1.0
+ CHECK_TICK
+
+
/obj/structure/destructible/cult/pylon/process()
if(!anchored)
return
if(last_heal <= world.time)
last_heal = world.time + heal_delay
- for(var/mob/living/L in range(5, src))
- if(iscultist(L) || isshade(L) || isconstruct(L))
- if(L.health != L.maxHealth)
- new /obj/effect/temp_visual/heal(get_turf(src), "#960000")
- if(ishuman(L))
- L.adjustBruteLoss(-1, 0, only_organic = FALSE)
- L.adjustFireLoss(-1, 0, only_organic = FALSE)
- L.updatehealth()
- if(isshade(L) || isconstruct(L))
- var/mob/living/simple_animal/M = L
- if(M.health < M.maxHealth)
- M.adjustHealth(-3)
- if(ishuman(L) && L.blood_volume < (BLOOD_VOLUME_NORMAL * L.blood_ratio))
- L.blood_volume += 1.0
- CHECK_TICK
+ heal_friends()
if(last_corrupt <= world.time)
var/list/validturfs = list()
var/list/cultturfs = list()
diff --git a/code/modules/antagonists/devil/devil.dm b/code/modules/antagonists/devil/devil.dm
index 3b6dc68986..65ce89d33f 100644
--- a/code/modules/antagonists/devil/devil.dm
+++ b/code/modules/antagonists/devil/devil.dm
@@ -515,7 +515,6 @@ GLOBAL_LIST_INIT(devil_suffix, list(" the Red", " the Soulless", " the Master",
var/mob/living/silicon/robot_devil = owner.current
var/laws = list("You may not use violence to coerce someone into selling their soul.", "You may not directly and knowingly physically harm a devil, other than yourself.", GLOB.lawlorify[LAW][ban], GLOB.lawlorify[LAW][obligation], "Accomplish your objectives at all costs.")
robot_devil.set_law_sixsixsix(laws)
- sleep(10)
if(owner.assigned_role == "Clown" && ishuman(owner.current))
var/mob/living/carbon/human/S = owner.current
to_chat(S, "Your infernal nature has allowed you to overcome your clownishness.")
diff --git a/code/modules/antagonists/traitor/equipment/Malf_Modules.dm b/code/modules/antagonists/traitor/equipment/Malf_Modules.dm
index 0659655da5..fcc8bcade8 100644
--- a/code/modules/antagonists/traitor/equipment/Malf_Modules.dm
+++ b/code/modules/antagonists/traitor/equipment/Malf_Modules.dm
@@ -401,6 +401,7 @@ GLOBAL_LIST_INIT(blacklisted_malf_machines, typecacheof(list(
next_announce += DOOMSDAY_ANNOUNCE_INTERVAL
/obj/machinery/doomsday_device/proc/detonate()
+ set waitfor = FALSE
sound_to_playing_players('sound/machines/alarm.ogg')
sleep(100)
for(var/i in GLOB.mob_living_list)
diff --git a/code/modules/arousal/arousal.dm b/code/modules/arousal/arousal.dm
index bd8b5dbf7a..36da6c73ba 100644
--- a/code/modules/arousal/arousal.dm
+++ b/code/modules/arousal/arousal.dm
@@ -197,6 +197,7 @@
//Here's the main proc itself
/mob/living/carbon/human/proc/mob_climax(forced_climax=FALSE,cause = "") //Forced is instead of the other proc, makes you cum if you have the tools for it, ignoring restraints
+ set waitfor = FALSE
if(mb_cd_timer > world.time)
if(!forced_climax) //Don't spam the message to the victim if forced to come too fast
to_chat(src, "You need to wait [DisplayTimeText((mb_cd_timer - world.time), TRUE)] before you can do that again!")
diff --git a/code/modules/assembly/infrared.dm b/code/modules/assembly/infrared.dm
index 899eb12511..d0ed0f2436 100644
--- a/code/modules/assembly/infrared.dm
+++ b/code/modules/assembly/infrared.dm
@@ -81,6 +81,7 @@
return
/obj/item/assembly/infra/proc/refreshBeam()
+ set waitfor = FALSE
QDEL_LIST(beams)
if(throwing || !on || !secured)
return
diff --git a/code/modules/events/portal_storm.dm b/code/modules/events/portal_storm.dm
index 5ef30d0030..59bb22e9af 100644
--- a/code/modules/events/portal_storm.dm
+++ b/code/modules/events/portal_storm.dm
@@ -56,7 +56,10 @@
next_boss_spawn = startWhen + CEILING(2 * number_of_hostiles / number_of_bosses, 1)
/datum/round_event/portal_storm/announce(fake)
- set waitfor = 0
+ do_announce()
+
+/datum/round_event/portal_storm/proc/do_announce()
+ set waitfor = FALSE
sound_to_playing_players('sound/magic/lightning_chargeup.ogg')
sleep(80)
priority_announce("Massive bluespace anomaly detected en route to [station_name()]. Brace for impact.")
diff --git a/code/modules/events/wizard/fakeexplosion.dm b/code/modules/events/wizard/fakeexplosion.dm
index 5858064819..3ba20f4768 100644
--- a/code/modules/events/wizard/fakeexplosion.dm
+++ b/code/modules/events/wizard/fakeexplosion.dm
@@ -7,5 +7,4 @@
/datum/round_event/wizard/fake_explosion/start()
sound_to_playing_players('sound/machines/alarm.ogg')
- sleep(100)
- Cinematic(CINEMATIC_NUKE_FAKE,world)
+ addtimer(CALLBACK(GLOBAL_PROC,.proc/Cinematic, CINEMATIC_NUKE_FAKE, world), 100)
diff --git a/code/modules/fields/fields.dm b/code/modules/fields/fields.dm
index cb8d3e8dcf..8c7b414996 100644
--- a/code/modules/fields/fields.dm
+++ b/code/modules/fields/fields.dm
@@ -64,7 +64,8 @@
pass = FALSE
return pass
-/datum/proximity_monitor/advanced/process()
+/datum/proximity_monitor/advanced/proc/lag_checked_process()
+ set waitfor = FALSE
if(process_inner_turfs)
for(var/turf/T in field_turfs)
process_inner_turf(T)
@@ -72,7 +73,10 @@
if(process_edge_turfs)
for(var/turf/T in edge_turfs)
process_edge_turf(T)
- CHECK_TICK //Same here.
+ CHECK_TICK //Same here.
+
+/datum/proximity_monitor/advanced/process()
+ lag_checked_process()
/datum/proximity_monitor/advanced/proc/process_inner_turf(turf/T)
diff --git a/code/modules/hydroponics/hydroponics.dm b/code/modules/hydroponics/hydroponics.dm
index aca727ad8d..fa7decc437 100644
--- a/code/modules/hydroponics/hydroponics.dm
+++ b/code/modules/hydroponics/hydroponics.dm
@@ -391,6 +391,7 @@
mutate(4, 10, 2, 4, 50, 4, 10, 3)
/obj/machinery/hydroponics/proc/mutatespecie() // Mutagent produced a new plant!
+ set waitfor = FALSE
if(!myseed || dead)
return
diff --git a/code/modules/mining/machine_redemption.dm b/code/modules/mining/machine_redemption.dm
index 6cba540ca0..1adc951447 100644
--- a/code/modules/mining/machine_redemption.dm
+++ b/code/modules/mining/machine_redemption.dm
@@ -145,8 +145,11 @@
D.createmessage("Ore Redemption Machine", "New minerals available!", msg, 1, 0)
/obj/machinery/mineral/ore_redemption/process()
- if(!materials.mat_container || panel_open || !powered())
- return
+ if(materials.mat_container && !panel_open && powered())
+ process_all_ores()
+
+/obj/machinery/mineral/ore_redemption/proc/process_all_ores()
+ set waitfor = FALSE
var/atom/input = get_step(src, input_dir)
var/obj/structure/ore_box/OB = locate() in input
if(OB)
@@ -165,6 +168,7 @@
else if(!message_sent)
send_console_message()
+
/obj/machinery/mineral/ore_redemption/attackby(obj/item/W, mob/user, params)
if(default_unfasten_wrench(user, W))
return
diff --git a/code/modules/mining/machine_unloading.dm b/code/modules/mining/machine_unloading.dm
index dc7caa12c8..b39b0df6ab 100644
--- a/code/modules/mining/machine_unloading.dm
+++ b/code/modules/mining/machine_unloading.dm
@@ -10,22 +10,25 @@
output_dir = EAST
speed_process = TRUE
-/obj/machinery/mineral/unloading_machine/process()
- var/turf/T = get_step(src,input_dir)
- if(T)
- var/limit
- for(var/obj/structure/ore_box/B in T)
- for (var/obj/item/stack/ore/O in B)
- B.contents -= O
- unload_mineral(O)
- limit++
- if (limit>=10)
- return
- CHECK_TICK
- CHECK_TICK
- for(var/obj/item/I in T)
- unload_mineral(I)
+/obj/machinery/mineral/unloading_machine/proc/horrible_quadratic_monster(var/turf/T)
+ set waitfor = FALSE
+ var/limit = 0
+ for(var/obj/structure/ore_box/B in T)
+ for (var/obj/item/stack/ore/O in B)
+ B.contents -= O
+ unload_mineral(O)
limit++
if (limit>=10)
return
CHECK_TICK
+ for(var/obj/item/I in T)
+ unload_mineral(I)
+ limit++
+ if (limit>=10)
+ return
+ CHECK_TICK
+
+/obj/machinery/mineral/unloading_machine/process()
+ var/turf/T = get_step(src,input_dir)
+ if(T)
+ horrible_quadratic_monster(T)
diff --git a/code/modules/mining/mint.dm b/code/modules/mining/mint.dm
index 2a8e0f2516..f8a4ba4a72 100644
--- a/code/modules/mining/mint.dm
+++ b/code/modules/mining/mint.dm
@@ -64,8 +64,6 @@
if(materials.use_amount_mat(coin_mat, chosen))
for(var/coin_to_make in 1 to 5)
create_coins()
- produced_coins++
- CHECK_TICK
else
var/found_new = FALSE
for(var/datum/material/inserted_material in materials.materials)
@@ -131,6 +129,7 @@
return TRUE
/obj/machinery/mineral/mint/proc/create_coins()
+ set waitfor = FALSE
var/turf/T = get_step(src,output_dir)
var/temp_list = list()
temp_list[chosen] = 400
@@ -143,3 +142,5 @@
O.forceMove(bag_to_use) //don't bother sending the signal, the new bag is empty and all that.
SSblackbox.record_feedback("amount", "coins_minted", 1)
+ produced_coins++
+ CHECK_TICK
diff --git a/code/modules/mob/living/silicon/ai/ai.dm b/code/modules/mob/living/silicon/ai/ai.dm
index ce6a5dcda1..1f582b68bf 100644
--- a/code/modules/mob/living/silicon/ai/ai.dm
+++ b/code/modules/mob/living/silicon/ai/ai.dm
@@ -182,6 +182,7 @@
. = ..()
/mob/living/silicon/ai/proc/set_core_display_icon(input, client/C)
+ set waitfor = FALSE
if(client && !C)
C = client
if(!input && !C?.prefs?.preferred_ai_core_display)
diff --git a/code/modules/mob/living/simple_animal/hostile/bosses/boss.dm b/code/modules/mob/living/simple_animal/hostile/bosses/boss.dm
index 98700ffaf0..1b0d210d9c 100644
--- a/code/modules/mob/living/simple_animal/hostile/bosses/boss.dm
+++ b/code/modules/mob/living/simple_animal/hostile/bosses/boss.dm
@@ -133,6 +133,10 @@
chance_to_hold_onto_points = highest_cost*0.5
if(points != max_points && prob(chance_to_hold_onto_points))
return //Let's save our points for a better ability (unless we're at max points, in which case we can't save anymore!)
+ do_ability()
+
+/datum/boss_active_timed_battle/proc/do_ability()
+ set waitfor = FALSE
if(!boss.client)
abilities = shuffle(abilities)
for(var/ab in abilities)
diff --git a/code/modules/modular_computers/computers/item/computer.dm b/code/modules/modular_computers/computers/item/computer.dm
index 131a098258..64c99e01bf 100644
--- a/code/modules/modular_computers/computers/item/computer.dm
+++ b/code/modules/modular_computers/computers/item/computer.dm
@@ -349,6 +349,7 @@
// Relays kill program request to currently active program. Use this to quit current program.
/obj/item/modular_computer/proc/kill_program(forced = FALSE)
+ set waitfor = FALSE
if(active_program)
active_program.kill_program(forced)
active_program = null
diff --git a/code/modules/reagents/chemistry/recipes.dm b/code/modules/reagents/chemistry/recipes.dm
index 7df061c8aa..41c0ed717e 100644
--- a/code/modules/reagents/chemistry/recipes.dm
+++ b/code/modules/reagents/chemistry/recipes.dm
@@ -40,6 +40,7 @@
/datum/chemical_reaction/proc/on_reaction(datum/reagents/holder, multiplier, specialreact)
+ set waitfor = FALSE
return
//I recommend you set the result amount to the total volume of all components.
diff --git a/code/modules/recycling/conveyor2.dm b/code/modules/recycling/conveyor2.dm
index aefb670dd3..e9c17ecc28 100644
--- a/code/modules/recycling/conveyor2.dm
+++ b/code/modules/recycling/conveyor2.dm
@@ -268,16 +268,19 @@ GLOBAL_LIST_EMPTY(conveyors_by_id)
// timed process
// if the switch changed, update the linked conveyors
-/obj/machinery/conveyor_switch/process()
- if(!operated)
- return
- operated = 0
-
+/obj/machinery/conveyor_switch/proc/do_process()
+ set waitfor = FALSE
for(var/obj/machinery/conveyor/C in GLOB.conveyors_by_id[id])
C.operating = position
C.update_move_direction()
CHECK_TICK
+/obj/machinery/conveyor_switch/process()
+ if(!operated)
+ return
+ operated = 0
+ do_process()
+
// attack with hand, switch position
/obj/machinery/conveyor_switch/interact(mob/user)
add_fingerprint(user)
diff --git a/code/modules/vore/eating/living.dm b/code/modules/vore/eating/living.dm
index 41d7da16a1..ca5ee0f476 100644
--- a/code/modules/vore/eating/living.dm
+++ b/code/modules/vore/eating/living.dm
@@ -59,13 +59,14 @@
// Critical adjustments due to TG grab changes - Poojawa
/mob/living/proc/vore_attack(var/mob/living/user, var/mob/living/prey, var/mob/living/pred)
- lazy_init_belly()
+ set waitfor = FALSE
if(!user || !prey || !pred)
return
if(!isliving(pred)) //no badmin, you can't feed people to ghosts or objects.
return
+ lazy_init_belly()
if(pred == prey) //you click your target
if(!CHECK_BITFIELD(pred.vore_flags,FEEDING))
to_chat(user, "They aren't able to be fed.")
diff --git a/code/modules/zombie/organs.dm b/code/modules/zombie/organs.dm
index 2681f781a9..a724d26314 100644
--- a/code/modules/zombie/organs.dm
+++ b/code/modules/zombie/organs.dm
@@ -45,7 +45,7 @@
if(!owner)
return
if(!(src in owner.internal_organs))
- Remove(owner)
+ INVOKE_ASYNC(src,.proc/Remove,owner)
if(owner.mob_biotypes & MOB_MINERAL)//does not process in inorganic things
return
if (causes_damage && !iszombie(owner) && owner.stat != DEAD)
diff --git a/modular_citadel/code/modules/reagents/chemistry/recipes/fermi.dm b/modular_citadel/code/modules/reagents/chemistry/recipes/fermi.dm
index ab39e6f4a7..edaaeb19b2 100644
--- a/modular_citadel/code/modules/reagents/chemistry/recipes/fermi.dm
+++ b/modular_citadel/code/modules/reagents/chemistry/recipes/fermi.dm
@@ -28,6 +28,7 @@
//Called when temperature is above a certain threshold, or if purity is too low.
/datum/chemical_reaction/proc/FermiExplode(datum/reagents/R0, var/atom/my_atom, volume, temp, pH, Exploding = FALSE)
+ set waitfor = FALSE
if (Exploding == TRUE)
return