From 74c0d9cfab875d06612770ec9559111a71c18307 Mon Sep 17 00:00:00 2001 From: GDN <96800819+GDNgit@users.noreply.github.com> Date: Thu, 12 Oct 2023 11:15:46 -0500 Subject: [PATCH] adds the bread smite (#22755) * adds the bread smite * you cannot escape --- code/datums/spells/sentient_sword_lunge.dm | 2 +- code/modules/admin/topic.dm | 11 +++++++++++ code/modules/mob/living/simple_animal/shade.dm | 10 ++++++++++ 3 files changed, 22 insertions(+), 1 deletion(-) diff --git a/code/datums/spells/sentient_sword_lunge.dm b/code/datums/spells/sentient_sword_lunge.dm index ffc7821d4f7..c5b0520152b 100644 --- a/code/datums/spells/sentient_sword_lunge.dm +++ b/code/datums/spells/sentient_sword_lunge.dm @@ -12,7 +12,7 @@ return new /datum/spell_targeting/clicked_atom /obj/effect/proc_holder/spell/sentient_sword_lunge/cast(list/targets, mob/user = usr) - if(!istype(user.loc, /obj/item/nullrod/scythe/talking)) + if(!istype(user.loc, /obj/item)) to_chat(user, "You cannot use this ability if you're outside a blade!") return var/obj/item/nullrod/scythe/talking/user_sword = user.loc diff --git a/code/modules/admin/topic.dm b/code/modules/admin/topic.dm index 26ca159ea94..c141ad3aa92 100644 --- a/code/modules/admin/topic.dm +++ b/code/modules/admin/topic.dm @@ -2067,6 +2067,7 @@ ptypes += "Floor Cluwne" ptypes += "Shamebrero" ptypes += "Nugget" + ptypes += "Bread" var/punishment = input(owner, "How would you like to smite [M]?", "Its good to be baaaad...", "") as null|anything in ptypes if(!(punishment in ptypes)) return @@ -2189,6 +2190,16 @@ addtimer(CALLBACK(H, TYPE_PROC_REF(/mob/living/carbon/human, make_nugget)), 6 SECONDS) logmsg = "nugget" + if("Bread") + var/mob/living/simple_animal/shade/sword/bread/breadshade = new(H.loc) + var/bready = pick(/obj/item/reagent_containers/food/snacks/customizable/cook/bread, /obj/item/reagent_containers/food/snacks/sliceable/meatbread, /obj/item/reagent_containers/food/snacks/sliceable/xenomeatbread, /obj/item/reagent_containers/food/snacks/sliceable/spidermeatbread, /obj/item/reagent_containers/food/snacks/sliceable/bananabread, /obj/item/reagent_containers/food/snacks/sliceable/tofubread, /obj/item/reagent_containers/food/snacks/sliceable/bread, /obj/item/reagent_containers/food/snacks/sliceable/creamcheesebread, /obj/item/reagent_containers/food/snacks/sliceable/banarnarbread, /obj/item/reagent_containers/food/snacks/flatbread, /obj/item/reagent_containers/food/snacks/baguette) + var/obj/item/bread = new bready(get_turf(H)) + breadshade.forceMove(bread) + breadshade.key = H.key + breadshade.RegisterSignal(bread, COMSIG_PARENT_QDELETING, TYPE_PROC_REF(/mob/living/simple_animal/shade/sword/bread, handle_bread_deletion)) + qdel(H) + logmsg = "baked" + to_chat(breadshade, "Get bready for combat, you've been baked into a piece of bread! Before you break down and rye thinking that your life is over, people are after you waiting for a snack! If you'd rather not be toast, lunge away from any hungry crew else you bite the crust. At the yeast you may survive a little longer...") if(logmsg) log_admin("[key_name(owner)] smited [key_name(M)] with: [logmsg]") message_admins("[key_name_admin(owner)] smited [key_name_admin(M)] with: [logmsg]") diff --git a/code/modules/mob/living/simple_animal/shade.dm b/code/modules/mob/living/simple_animal/shade.dm index 8dfee426c0e..a00609a43dd 100644 --- a/code/modules/mob/living/simple_animal/shade.dm +++ b/code/modules/mob/living/simple_animal/shade.dm @@ -70,6 +70,16 @@ if(istype(host_sword)) health = host_sword.obj_integrity +/mob/living/simple_animal/shade/sword/bread + name = "Bread spirit" + +/mob/living/simple_animal/shade/sword/bread/update_runechat_msg_location() + runechat_msg_location = loc.UID() + +/mob/living/simple_animal/shade/sword/bread/proc/handle_bread_deletion(source) + SIGNAL_HANDLER + qdel(src) + /mob/living/simple_animal/shade/update_runechat_msg_location() if(istype(loc, /obj/item/soulstone) || istype(loc, /obj/item/nullrod/scythe/talking)) runechat_msg_location = loc.UID()