diff --git a/code/game/turfs/auto_turf.dm b/code/game/turfs/auto_turf.dm index e07f7324bcc2..16550c05c013 100644 --- a/code/game/turfs/auto_turf.dm +++ b/code/game/turfs/auto_turf.dm @@ -75,6 +75,19 @@ if(bleed_layer) addtimer(CALLBACK(src, PROC_REF(changing_layer), 0), 1) +/turf/open/auto_turf/scorch(heat_level) + if(bleed_layer <= 0) + return + switch(heat_level) + if(1 to 19) + var/new_bleed_layer = min(0, bleed_layer - 1) + addtimer(CALLBACK(src, PROC_REF(changing_layer), new_bleed_layer), 1) + if(20 to 39) + var/new_bleed_layer = max(bleed_layer - 2, 0) + addtimer(CALLBACK(src, PROC_REF(changing_layer), new_bleed_layer), 1) + if(40 to INFINITY) + addtimer(CALLBACK(src, PROC_REF(changing_layer), 0), 1) + //Actual auto-turfs now @@ -146,6 +159,7 @@ //Ice colony snow /turf/open/auto_turf/snow + scorchable = TRUE name = "auto-snow" icon = 'icons/turf/floors/snow2.dmi' icon_state = "snow_0" diff --git a/code/game/turfs/snow.dm b/code/game/turfs/snow.dm index f7fb746cfbbc..c8afd734e862 100644 --- a/code/game/turfs/snow.dm +++ b/code/game/turfs/snow.dm @@ -8,6 +8,7 @@ icon = 'icons/turf/floors/snow2.dmi' icon_state = "snow_0" is_groundmap_turf = TRUE + scorchable = TRUE //PLACING/REMOVING/BUILDING /turf/open/snow/attackby(obj/item/I, mob/user) @@ -132,6 +133,22 @@ bleed_layer = 0 update_icon(1, 0) +//Flames act +/turf/open/snow/scorch(heat_level) + if(bleed_layer <= 0) + return + switch(heat_level) + if(1 to 19) + bleed_layer-- + update_icon(update_full = TRUE, skip_sides = FALSE) + if(20 to 39) + bleed_layer = max(bleed_layer - 2, 0) + update_icon(update_full = TRUE, skip_sides = FALSE) + if(40 to INFINITY) + bleed_layer = 0 + update_icon(update_full = TRUE, skip_sides = FALSE) + + //SNOW LAYERS-----------------------------------// /turf/open/snow/layer0 icon_state = "snow_0" diff --git a/code/modules/projectiles/guns/flamer/flamer.dm b/code/modules/projectiles/guns/flamer/flamer.dm index 62e37e4f7c3b..5daef0bdff74 100644 --- a/code/modules/projectiles/guns/flamer/flamer.dm +++ b/code/modules/projectiles/guns/flamer/flamer.dm @@ -478,15 +478,7 @@ INVOKE_ASYNC(FS, TYPE_PROC_REF(/datum/flameshape, handle_fire_spread), src, fire_spread_amount, burn_dam, fuel_pressure) //Apply fire effects onto everyone in the fire - // Melt a single layer of snow - if (istype(loc, /turf/open/snow)) - var/turf/open/snow/S = loc - - if (S.bleed_layer > 0) - S.bleed_layer-- - S.update_icon(1, 0) - - //scorch mah grass HNNGGG + //scorch mah grass HNNGGG and muh SNOW hhhhGGG if (istype(loc, /turf/open)) var/turf/open/scorch_turf_target = loc if(scorch_turf_target.scorchable)