mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-30 23:48:28 +01:00
Merge pull request #15209 from SteelSlayer/spawn-removal
Removes a bunch of spawn()'s
This commit is contained in:
@@ -36,15 +36,18 @@ BONUS
|
||||
if(3, 4)
|
||||
if(!(head_organ.h_style == "Bald") && !(head_organ.h_style == "Balding Hair"))
|
||||
to_chat(H, "<span class='warning'>Your hair starts to fall out in clumps...</span>")
|
||||
spawn(50)
|
||||
head_organ.h_style = "Balding Hair"
|
||||
H.update_hair()
|
||||
addtimer(CALLBACK(src, .proc/change_hair, H, head_organ, null, "Balding Hair"), 5 SECONDS)
|
||||
if(5)
|
||||
if(!(head_organ.f_style == "Shaved") || !(head_organ.h_style == "Bald"))
|
||||
to_chat(H, "<span class='warning'>Your hair starts to fall out in clumps...</span>")
|
||||
spawn(50)
|
||||
head_organ.f_style = "Shaved"
|
||||
head_organ.h_style = "Bald"
|
||||
H.update_hair()
|
||||
H.update_fhair()
|
||||
return
|
||||
addtimer(CALLBACK(src, .proc/change_hair, H, head_organ, "Shaved", "Bald"), 5 SECONDS)
|
||||
|
||||
/datum/symptom/shedding/proc/change_hair(mob/living/carbon/human/H, obj/item/organ/external/head/head_organ, f_style, h_style)
|
||||
if(!H || !head_organ)
|
||||
return
|
||||
if(f_style)
|
||||
head_organ.f_style = f_style
|
||||
H.update_fhair()
|
||||
if(h_style)
|
||||
head_organ.h_style = h_style
|
||||
H.update_hair()
|
||||
|
||||
@@ -84,14 +84,12 @@
|
||||
/datum/teleport/proc/playSpecials(atom/location,datum/effect_system/effect,sound)
|
||||
if(location)
|
||||
if(effect)
|
||||
spawn(-1)
|
||||
src = null
|
||||
effect.attach(location)
|
||||
effect.start()
|
||||
src = null
|
||||
effect.attach(location)
|
||||
effect.start()
|
||||
if(sound)
|
||||
spawn(-1)
|
||||
src = null
|
||||
playsound(location,sound,60,1)
|
||||
src = null
|
||||
playsound(location,sound,60,1)
|
||||
return
|
||||
|
||||
//do the monkey dance
|
||||
|
||||
@@ -44,9 +44,7 @@
|
||||
summoned_object.admin_spawned = TRUE
|
||||
|
||||
if(summon_lifespan)
|
||||
spawn(summon_lifespan)
|
||||
if(summoned_object)
|
||||
qdel(summoned_object)
|
||||
QDEL_IN(summoned_object, summon_lifespan)
|
||||
else
|
||||
switch(charge_type)
|
||||
if("recharge")
|
||||
|
||||
+16
-12
@@ -16,19 +16,23 @@
|
||||
/obj/effect/proc_holder/spell/aoe_turf/knock/cast(list/targets, mob/user = usr)
|
||||
for(var/turf/T in targets)
|
||||
for(var/obj/machinery/door/door in T.contents)
|
||||
spawn(1)
|
||||
if(istype(door,/obj/machinery/door/airlock/hatch/gamma))
|
||||
return
|
||||
if(istype(door,/obj/machinery/door/airlock))
|
||||
var/obj/machinery/door/airlock/A = door
|
||||
A.unlock(1) //forced because it's magic!
|
||||
door.open()
|
||||
INVOKE_ASYNC(src, .proc/try_open_airlock, door)
|
||||
for(var/obj/structure/closet/C in T.contents)
|
||||
spawn(1)
|
||||
if(istype(C, /obj/structure/closet/secure_closet))
|
||||
var/obj/structure/closet/secure_closet/SC = C
|
||||
SC.locked = 0
|
||||
C.open()
|
||||
INVOKE_ASYNC(src, .proc/try_open_closet, C)
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/knock/proc/try_open_airlock(obj/machinery/door/door)
|
||||
if(istype(door, /obj/machinery/door/airlock/hatch/gamma))
|
||||
return
|
||||
if(istype(door, /obj/machinery/door/airlock))
|
||||
var/obj/machinery/door/airlock/A = door
|
||||
A.unlock(TRUE) //forced because it's magic!
|
||||
door.open()
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/knock/proc/try_open_closet(obj/structure/closet/C)
|
||||
if(istype(C, /obj/structure/closet/secure_closet))
|
||||
var/obj/structure/closet/secure_closet/SC = C
|
||||
SC.locked = FALSE
|
||||
C.open()
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/knock/greater
|
||||
name = "Greater Knock"
|
||||
|
||||
Reference in New Issue
Block a user