adds a vine spawning animation (#64363)

adds a cool little animation for spacevines spawning
https://gyazo.com/25fc2cf02a741e7e73df694fbb7c4f25
This commit is contained in:
jjpark-kb
2022-01-25 15:27:32 +00:00
committed by GitHub
parent 04c37c3327
commit 2c9607ea2d
+7 -1
View File
@@ -575,7 +575,13 @@
for(var/datum/spacevine_mutation/mutation in mutations)
mutation.on_spread(src, stepturf) //Only do the on_spread proc if it actually spreads.
stepturf = get_step(src,direction) //in case turf changes, to make sure no runtimes happen
master.spawn_spacevine_piece(stepturf, src)
var/obj/structure/spacevine/spawning_vine = master.spawn_spacevine_piece(stepturf, src) //Let's do a cool little animate
if(NSCOMPONENT(direction))
spawning_vine.pixel_y = direction == NORTH ? -32 : 32
animate(spawning_vine, pixel_y = 0, time = 1 SECONDS)
else
spawning_vine.pixel_x = direction == EAST ? -32 : 32
animate(spawning_vine, pixel_x = 0, time = 1 SECONDS)
/// Destroying an explosive vine sets off a chain reaction
/obj/structure/spacevine/ex_act(severity, target)