mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-22 04:30:44 +01:00
[MIRROR] Vines get destroyed on bud's Destroy() (#3388)
* Vines get destroyed on bud's Destroy() (#56902) Simple fix for #56879 caused by qdelling the bud without clearing up the vines. * Vines get destroyed on bud's Destroy() Co-authored-by: Hadzabadza <hadzabadza@yandex.ru>
This commit is contained in:
@@ -28,6 +28,8 @@
|
||||
/// The countdown ghosts see to when the plant will hatch
|
||||
var/obj/effect/countdown/flower_bud/countdown
|
||||
|
||||
var/list/vines = list()
|
||||
|
||||
/obj/structure/alien/resin/flower_bud/Initialize()
|
||||
. = ..()
|
||||
countdown = new(src)
|
||||
@@ -38,12 +40,16 @@
|
||||
anchors += locate(x+2,y-2,z)
|
||||
|
||||
for(var/turf/T in anchors)
|
||||
Beam(T, "vine", maxdistance=5, beam_type=/obj/effect/ebeam/vine)
|
||||
vines += Beam(T, "vine", maxdistance=5, beam_type=/obj/effect/ebeam/vine)
|
||||
finish_time = world.time + growth_time
|
||||
addtimer(CALLBACK(src, .proc/bear_fruit), growth_time)
|
||||
addtimer(CALLBACK(src, .proc/progress_growth), growth_time/4)
|
||||
countdown.start()
|
||||
|
||||
/obj/structure/alien/resin/flower_bud/Destroy()
|
||||
QDEL_LIST(vines)
|
||||
return ..()
|
||||
|
||||
/**
|
||||
* Spawns a venus human trap, then qdels itself.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user