diff --git a/code/datums/weather/weather_types/ash_storm.dm b/code/datums/weather/weather_types/ash_storm.dm index 90ebf5b13cb..92a1ba1eed6 100644 --- a/code/datums/weather/weather_types/ash_storm.dm +++ b/code/datums/weather/weather_types/ash_storm.dm @@ -69,16 +69,12 @@ victim.adjustFireLoss(4) /datum/weather/ash_storm/end() - . = ..() GLOB.ash_storm_sounds -= weak_sounds for(var/turf/open/misc/asteroid/basalt/basalt as anything in GLOB.dug_up_basalt) if(!(basalt.loc in impacted_areas) || !(basalt.z in impacted_z_levels)) continue - GLOB.dug_up_basalt -= basalt - basalt.dug = FALSE - basalt.icon_state = "[basalt.base_icon_state]" - if(prob(basalt.floor_variance)) - basalt.icon_state += "[rand(0,12)]" + basalt.refill_dug() + return ..() //Emberfalls are the result of an ash storm passing by close to the playable area of lavaland. They have a 10% chance to trigger in place of an ash storm. /datum/weather/ash_storm/emberfall diff --git a/code/game/turfs/open/asteroid.dm b/code/game/turfs/open/asteroid.dm index 526bdf9cfca..cf7e07e75f3 100644 --- a/code/game/turfs/open/asteroid.dm +++ b/code/game/turfs/open/asteroid.dm @@ -50,24 +50,9 @@ if(has_floor_variance && prob(floor_variance)) icon_state = "[base_icon_state][rand(0,12)]" -/// Drops itemstack when dug and changes icon -/turf/open/misc/asteroid/proc/getDug() - dug = TRUE - broken = TRUE - new dig_result(src, 5) - if (prob(worm_chance)) - new /obj/item/food/bait/worm(src) - update_appearance() - -/// If the user can dig the turf -/turf/open/misc/asteroid/proc/can_dig(mob/user) - if(!dug) - return TRUE - if(user) - to_chat(user, span_warning("Looks like someone has dug here already!")) - /turf/open/misc/asteroid/burn_tile() return + /turf/open/misc/asteroid/MakeSlippery(wet_setting, min_wet_time, wet_time_to_add, max_wet_time, permanent) return @@ -77,12 +62,12 @@ /turf/open/misc/asteroid/ex_act(severity, target) return FALSE -/turf/open/misc/asteroid/attackby(obj/item/W, mob/user, params) +/turf/open/misc/asteroid/attackby(obj/item/attack_item, mob/user, params) . = ..() if(.) return TRUE - if(W.tool_behaviour == TOOL_SHOVEL || W.tool_behaviour == TOOL_MINING) + if(attack_item.tool_behaviour == TOOL_SHOVEL || attack_item.tool_behaviour == TOOL_MINING) if(!can_dig(user)) return TRUE @@ -91,16 +76,42 @@ balloon_alert(user, "digging...") - if(W.use_tool(src, user, 40, volume=50)) + if(attack_item.use_tool(src, user, 4 SECONDS, volume = 50)) if(!can_dig(user)) return TRUE getDug() - SSblackbox.record_feedback("tally", "pick_used_mining", 1, W.type) + SSblackbox.record_feedback("tally", "pick_used_mining", 1, attack_item.type) return TRUE - else if(istype(W, /obj/item/storage/bag/ore)) - for(var/obj/item/stack/ore/O in src) - SEND_SIGNAL(W, COMSIG_ATOM_ATTACKBY, O) + else if(istype(attack_item, /obj/item/storage/bag/ore)) + for(var/obj/item/stack/ore/dropped_ore in src) + SEND_SIGNAL(attack_item, COMSIG_ATOM_ATTACKBY, dropped_ore) +/// Drops itemstack when dug and changes icon +/turf/open/misc/asteroid/proc/getDug() + if(dug || broken) + return + dug = TRUE + broken = TRUE + new dig_result(src, 5) + if(prob(worm_chance)) + new /obj/item/food/bait/worm(src) + update_appearance() + +/// If the user can dig the turf +/turf/open/misc/asteroid/proc/can_dig(mob/user) + if(!dug && !broken) + return TRUE + if(user) + balloon_alert(user, "already excavated!") + +///Refills the previously dug tile +/turf/open/misc/asteroid/proc/refill_dug() + dug = FALSE + broken = FALSE + icon_state = base_icon_state + if(has_floor_variance && prob(floor_variance)) + icon_state = "[base_icon_state][rand(0,12)]" + update_appearance() /turf/open/floor/plating/lavaland_baseturf baseturfs = /turf/open/misc/asteroid/basalt/lava_land_surface @@ -114,7 +125,6 @@ /turf/open/misc/asteroid/dug/broken_states() return list("asteroid_dug") - /turf/open/misc/asteroid/lavaland_atmos initial_gas_mix = LAVALAND_DEFAULT_ATMOS planetary_atmos = TRUE @@ -141,6 +151,11 @@ GLOBAL_LIST_EMPTY(dug_up_basalt) GLOB.dug_up_basalt -= src return ..() +/turf/open/misc/asteroid/basalt/refill_dug() + . = ..() + GLOB.dug_up_basalt -= src + set_basalt_light(src) + /turf/open/misc/asteroid/basalt/lava //lava underneath baseturfs = /turf/open/lava/smooth diff --git a/code/modules/spells/spell_types/jaunt/_jaunt.dm b/code/modules/spells/spell_types/jaunt/_jaunt.dm index e73abb5b438..20271cd71ba 100644 --- a/code/modules/spells/spell_types/jaunt/_jaunt.dm +++ b/code/modules/spells/spell_types/jaunt/_jaunt.dm @@ -57,7 +57,7 @@ var/obj/effect/dummy/phased_mob/jaunt = new jaunt_type(loc_override || get_turf(jaunter), jaunter) RegisterSignal(jaunt, COMSIG_MOB_EJECTED_FROM_JAUNT, PROC_REF(on_jaunt_exited)) spell_requirements |= SPELL_CASTABLE_WHILE_PHASED - jaunter.add_traits(list(TRAIT_MAGICALLY_PHASED, TRAIT_RUNECHAT_HIDDEN), REF(src)) + jaunter.add_traits(list(TRAIT_MAGICALLY_PHASED, TRAIT_RUNECHAT_HIDDEN, TRAIT_WEATHER_IMMUNE), REF(src)) // Don't do the feedback until we have runechat hidden. // Otherwise the text will follow the jaunt holder, which reveals where our caster is travelling. spell_feedback(jaunter) @@ -101,7 +101,7 @@ /datum/action/cooldown/spell/jaunt/proc/on_jaunt_exited(obj/effect/dummy/phased_mob/jaunt, mob/living/unjaunter) SHOULD_CALL_PARENT(TRUE) spell_requirements &= ~SPELL_CASTABLE_WHILE_PHASED - unjaunter.remove_traits(list(TRAIT_MAGICALLY_PHASED, TRAIT_RUNECHAT_HIDDEN), REF(src)) + unjaunter.remove_traits(list(TRAIT_MAGICALLY_PHASED, TRAIT_RUNECHAT_HIDDEN, TRAIT_WEATHER_IMMUNE), REF(src)) // This needs to happen at the end, after all the traits and stuff is handled SEND_SIGNAL(unjaunter, COMSIG_MOB_AFTER_EXIT_JAUNT, src) diff --git a/code/modules/vehicles/mecha/_mecha.dm b/code/modules/vehicles/mecha/_mecha.dm index 37af7006831..51b1522e115 100644 --- a/code/modules/vehicles/mecha/_mecha.dm +++ b/code/modules/vehicles/mecha/_mecha.dm @@ -256,7 +256,7 @@ AddElement(/datum/element/atmos_sensitive, mapload) become_hearing_sensitive(trait_source = ROUNDSTART_TRAIT) - ADD_TRAIT(src, TRAIT_ASHSTORM_IMMUNE, ROUNDSTART_TRAIT) //protects pilots from ashstorms. + add_traits(list(TRAIT_ASHSTORM_IMMUNE, TRAIT_SNOWSTORM_IMMUNE), ROUNDSTART_TRAIT) //stormy weather (keeps rainin' all the time) for(var/key in equip_by_category) if(key == MECHA_L_ARM || key == MECHA_R_ARM) var/path = equip_by_category[key]