diff --git a/code/datums/status_effects/status_effect.dm b/code/datums/status_effects/status_effect.dm index d3c2f44abb..b9ba1ac0ed 100644 --- a/code/datums/status_effects/status_effect.dm +++ b/code/datums/status_effects/status_effect.dm @@ -68,6 +68,9 @@ /datum/status_effect/proc/tick() //Called every tick. +/datum/status_effect/proc/before_remove() //! Called before being removed; returning FALSE will cancel removal + return TRUE + /datum/status_effect/proc/on_remove() //Called whenever the buff expires or is removed; do note that at the point this is called, it is out of the owner's status_effects but owner is not yet null SHOULD_CALL_PARENT(TRUE) REMOVE_TRAIT(owner, TRAIT_COMBAT_MODE_LOCKED, src) @@ -129,7 +132,7 @@ if(status_effects) var/datum/status_effect/S1 = effect for(var/datum/status_effect/S in status_effects) - if(initial(S1.id) == S.id) + if(initial(S1.id) == S.id && S.before_remove(arguments)) qdel(S) . = TRUE diff --git a/code/game/objects/objs.dm b/code/game/objects/objs.dm index d2d72193b7..6b50df97dc 100644 --- a/code/game/objects/objs.dm +++ b/code/game/objects/objs.dm @@ -314,3 +314,6 @@ current_skin = choice icon_state = unique_reskin[choice] to_chat(M, "[src] is now skinned as '[choice]'.") + +/obj/proc/plunger_act(obj/item/plunger/P, mob/living/user, reinforced) + return diff --git a/code/game/objects/structures/lavaland/geyser.dm b/code/game/objects/structures/lavaland/geyser.dm new file mode 100644 index 0000000000..4f6256e9c4 --- /dev/null +++ b/code/game/objects/structures/lavaland/geyser.dm @@ -0,0 +1,86 @@ +//If you look at the "geyser_soup" overlay icon_state, you'll see that the first frame has 25 ticks. +//That's because the first 18~ ticks are completely skipped for some ungodly weird fucking byond reason + +/obj/structure/geyser + name = "geyser" + icon = 'icons/obj/lavaland/terrain.dmi' + icon_state = "geyser" + anchored = TRUE + + var/erupting_state = null //set to null to get it greyscaled from "[icon_state]_soup". Not very usable with the whole random thing, but more types can be added if you change the spawn prob + var/activated = FALSE //whether we are active and generating chems + var/reagent_id = /datum/reagent/fuel/oil + var/potency = 2 //how much reagents we add every process (2 seconds) + var/max_volume = 500 + var/start_volume = 50 + +/obj/structure/geyser/proc/start_chemming() + activated = TRUE + create_reagents(max_volume, DRAINABLE) + reagents.add_reagent(reagent_id, start_volume) + START_PROCESSING(SSfluids, src) //It's main function is to be plumbed, so use SSfluids + if(erupting_state) + icon_state = erupting_state + else + var/mutable_appearance/I = mutable_appearance('icons/obj/lavaland/terrain.dmi', "[icon_state]_soup") + I.color = mix_color_from_reagents(reagents.reagent_list) + add_overlay(I) + +/obj/structure/geyser/process() + if(activated && reagents.total_volume <= reagents.maximum_volume) //this is also evaluated in add_reagent, but from my understanding proc calls are expensive + reagents.add_reagent(reagent_id, potency) + +/obj/structure/geyser/plunger_act(obj/item/plunger/P, mob/living/user, _reinforced) + if(!_reinforced) + to_chat(user, "The [P.name] isn't strong enough!") + return + if(activated) + to_chat(user, "The [name] is already active!") + return + + to_chat(user, "You start vigorously plunging [src]!") + if(do_after(user, 50 * P.plunge_mod, target = src) && !activated) + start_chemming() + +/obj/structure/geyser/random + erupting_state = null + var/list/options = list(/datum/reagent/clf3 = 10, /datum/reagent/water/hollowwater = 10, /datum/reagent/medicine/omnizine/protozine = 6, /datum/reagent/wittel = 1) + +/obj/structure/geyser/random/Initialize() + . = ..() + reagent_id = pickweight(options) + +/obj/item/plunger + name = "plunger" + desc = "It's a plunger for plunging." + icon = 'icons/obj/watercloset.dmi' + icon_state = "plunger" + + slot_flags = ITEM_SLOT_MASK + + var/plunge_mod = 1 //time*plunge_mod = total time we take to plunge an object + var/reinforced = FALSE //whether we do heavy duty stuff like geysers + +/obj/item/plunger/attack_obj(obj/O, mob/living/user) + if(!O.plunger_act(src, user, reinforced)) + return ..() + +/obj/item/plunger/throw_impact(atom/hit_atom, datum/thrownthing/tt) + . = ..() + if(tt.target_zone != BODY_ZONE_HEAD) + return + if(iscarbon(hit_atom)) + var/mob/living/carbon/H = hit_atom + if(!H.wear_mask) + H.equip_to_slot_if_possible(src, ITEM_SLOT_MASK) + H.visible_message("The plunger slams into [H]'s face!", "The plunger suctions to your face!") + +/obj/item/plunger/reinforced + name = "reinforced plunger" + desc = "It's an M. 7 Reinforced Plunger© for heavy duty plunging." + icon_state = "reinforced_plunger" + + reinforced = TRUE + plunge_mod = 0.8 + + custom_premium_price = 1200 diff --git a/code/game/turfs/simulated/floor/plating/asteroid.dm b/code/game/turfs/simulated/floor/plating/asteroid.dm index 838157f64d..46cde93c02 100644 --- a/code/game/turfs/simulated/floor/plating/asteroid.dm +++ b/code/game/turfs/simulated/floor/plating/asteroid.dm @@ -403,7 +403,6 @@ return new randumb(T) - /turf/open/floor/plating/asteroid/snow gender = PLURAL name = "snow" diff --git a/code/modules/assembly/signaler.dm b/code/modules/assembly/signaler.dm index c5e2cbb422..e70b6e5c74 100644 --- a/code/modules/assembly/signaler.dm +++ b/code/modules/assembly/signaler.dm @@ -186,7 +186,7 @@ /obj/item/assembly/signaler/anomaly/manual_suicide(mob/living/carbon/user) user.visible_message("[user]'s [src] is reacting to the radio signal, warping [user.p_their()] body!") - user.set_suicide(TRUE) + user.suiciding = TRUE user.suicide_log() user.gib() diff --git a/code/modules/mob/living/simple_animal/hostile/mining_mobs/ice_demon.dm b/code/modules/mob/living/simple_animal/hostile/mining_mobs/ice_demon.dm index 27447aab11..e00ec9fe25 100644 --- a/code/modules/mob/living/simple_animal/hostile/mining_mobs/ice_demon.dm +++ b/code/modules/mob/living/simple_animal/hostile/mining_mobs/ice_demon.dm @@ -11,7 +11,7 @@ speak_emote = list("telepathically cries") speed = 2 move_to_delay = 2 - projectiletype = /obj/projectile/temp/basilisk/ice + projectiletype = /obj/item/projectile/temp/basilisk/ice projectilesound = 'sound/weapons/pierce.ogg' ranged = TRUE ranged_message = "manifests ice" diff --git a/code/modules/mob/living/simple_animal/hostile/retaliate/clown.dm b/code/modules/mob/living/simple_animal/hostile/retaliate/clown.dm index c46df9e77d..7cf1bf3beb 100644 --- a/code/modules/mob/living/simple_animal/hostile/retaliate/clown.dm +++ b/code/modules/mob/living/simple_animal/hostile/retaliate/clown.dm @@ -6,7 +6,6 @@ icon_living = "clown" icon_dead = "clown_dead" icon_gib = "clown_gib" - health_doll_icon = "clown" //if >32x32, it will use this generic. for all the huge clown mobs that subtype from this mob_biotypes = MOB_ORGANIC|MOB_HUMANOID turns_per_move = 5 response_disarm = "gently pushes aside" @@ -31,7 +30,6 @@ minbodytemp = 270 maxbodytemp = 370 unsuitable_atmos_damage = 10 - footstep_type = FOOTSTEP_MOB_SHOE var/banana_time = 0 // If there's no time set it won't spawn. var/banana_type = /obj/item/grown/bananapeel var/attack_reagent diff --git a/tgstation.dme b/tgstation.dme index b7849d8bda..5eb9560d8e 100755 --- a/tgstation.dme +++ b/tgstation.dme @@ -1187,6 +1187,7 @@ #include "code\game\objects\structures\crates_lockers\crates\secure.dm" #include "code\game\objects\structures\crates_lockers\crates\wooden.dm" #include "code\game\objects\structures\icemoon\cave_entrance.dm" +#include "code\game\objects\structures\lavaland\geyser.dm" #include "code\game\objects\structures\lavaland\necropolis_tendril.dm" #include "code\game\objects\structures\signs\_signs.dm" #include "code\game\objects\structures\signs\signs_departments.dm"