diff --git a/code/datums/helper_datums/teleport.dm b/code/datums/helper_datums/teleport.dm index 5e9371f754..79c12c7fea 100644 --- a/code/datums/helper_datums/teleport.dm +++ b/code/datums/helper_datums/teleport.dm @@ -85,6 +85,15 @@ var/mob/M = teleatom M.cancel_camera() + var/static/list/bread_cache = typecacheof(/obj/item/reagent_containers/food/snacks/store/bread) + var/list/breadlist = typecache_filter_list(teleatom.GetAllContents(), bread_cache) + if(breadlist.len && (channel == TELEPORT_CHANNEL_BLUESPACE || channel == TELEPORT_CHANNEL_QUANTUM)) + for(var/obj/item/reagent_containers/food/snacks/store/bread/bread in breadlist) + bread.bread_teleport() + else if(istype(teleatom, /obj/item/reagent_containers/food/snacks/store/bread)) + var/obj/item/reagent_containers/food/snacks/store/bread/bread = teleatom + bread.bread_teleport() + return TRUE /proc/tele_play_specials(atom/movable/teleatom, atom/location, datum/effect_system/effect, sound) diff --git a/code/modules/food_and_drinks/food/snacks_bread.dm b/code/modules/food_and_drinks/food/snacks_bread.dm index 0d7c715654..3b133d8675 100644 --- a/code/modules/food_and_drinks/food/snacks_bread.dm +++ b/code/modules/food_and_drinks/food/snacks_bread.dm @@ -7,6 +7,12 @@ foodtype = GRAIN dunkable = TRUE +/obj/item/reagent_containers/food/snacks/store/bread/proc/bread_teleport() + // you did WHAT? + new /mob/living/simple_animal/hostile/bread(get_turf(src)) + visible_message("[src] begins to deform and grow grotesque tumors!") + qdel(src) + /obj/item/reagent_containers/food/snacks/breadslice icon = 'icons/obj/food/burgerbread.dmi' bitesize = 2 @@ -228,3 +234,25 @@ /obj/item/reagent_containers/food/snacks/butterdog/ComponentInitialize() . = ..() AddComponent(/datum/component/slippery, 80) + +/obj/item/reagent_containers/food/snacks/store/bread/tumor_bread + name = "dead tumor bread" + desc = "It's still within its expiration date, right?." + icon_state = "tumorbread" + slice_path = /obj/item/reagent_containers/food/snacks/breadslice/tumor_bread + list_reagents = list(/datum/reagent/consumable/nutriment = 10, /datum/reagent/toxin = 10) + foodtype = GROSS | GRAIN + tastes = list("wheat and tumors" = 10) + +//teleporting tumor bread kills it +/obj/item/reagent_containers/food/snacks/store/bread/tumor_bread/bread_teleport() + visible_message(src, "[src] explodes in a horrible mess of tumor and flour!") + qdel(src) + +/obj/item/reagent_containers/food/snacks/breadslice/tumor_bread + name = "tumor bread slice" + desc = "A slice of bread filled with tumors!" + icon_state = "tumorbreadslice" + filling_color = "#B2D72C" + list_reagents = list(/datum/reagent/consumable/nutriment = 2, /datum/reagent/toxin = 2) + foodtype = GROSS | GRAIN diff --git a/code/modules/mob/living/simple_animal/hostile/bread.dm b/code/modules/mob/living/simple_animal/hostile/bread.dm new file mode 100644 index 0000000000..317827028d --- /dev/null +++ b/code/modules/mob/living/simple_animal/hostile/bread.dm @@ -0,0 +1,69 @@ +//funny reference to the video 'Expiration Date' + +/mob/living/simple_animal/hostile/bread + name = "tumor bread" + desc = "I have done nothing but teleport bread for three days." + icon_state = "tumorbread" + health = 1 + maxHealth = 1 + turns_per_move = 5 //this isn't player speed =| + speed = 2 //this is player speed + melee_damage_lower = 1 + melee_damage_upper = 2 + obj_damage = 0 + loot = list(/obj/item/reagent_containers/food/snacks/store/bread/tumor_bread) + atmos_requirements = list("min_oxy" = 0, "max_oxy" = 0, "min_tox" = 0, "max_tox" = 0, "min_co2" = 0, "max_co2" = 0, "min_n2" = 0, "max_n2" = 0) + minbodytemp = 270 + maxbodytemp = INFINITY + pass_flags = PASSTABLE | PASSGRILLE | PASSMOB + mob_size = MOB_SIZE_TINY + response_help_continuous = "pokes" + response_help_simple = "poke" + response_disarm_continuous = "shoos" + response_disarm_simple = "shoo" + response_harm_continuous = "punches" + response_harm_simple = "punch" + speak_emote = list("growls") + mouse_opacity = 2 + density = TRUE + ventcrawler = VENTCRAWLER_ALWAYS + verb_say = "growls" + verb_ask = "growls inquisitively" + verb_exclaim = "growls loudly" + verb_yell = "growls loudly" + del_on_death = TRUE + +/mob/living/simple_animal/bread/hostile/Initialize() + . = ..() + var/area/A = get_area(src) + if(A) + notify_ghosts("A tumor bread has been created in \the [A.name].", source = src, action=NOTIFY_ATTACK, flashwindow = FALSE, ignore_dnr_observers = TRUE) + +/mob/living/simple_animal/hostile/bread/attack_ghost(mob/user) + if(key) //please stop using src. without a good reason. + return + if(CONFIG_GET(flag/use_age_restriction_for_jobs)) + if(!isnum(user.client.player_age)) + return + if(isobserver(user)) + var/mob/dead/observer/O = user + if(!O.can_reenter_round()) + return + if(!SSticker.mode) + to_chat(user, "Can't become a tumor bread before the game has started.") + return + var/be_bread = alert("Become a tumor bread? (Warning, You can no longer be cloned!)",,"Yes","No") + if(be_bread == "No" || QDELETED(src) || !isobserver(user)) + return + if(key) + to_chat(user, "Someone else already took this tumor bread.") + return + sentience_act() + user.transfer_ckey(src, FALSE) + density = TRUE + +/mob/living/simple_animal/hostile/bread/ex_act() + return + +/mob/living/simple_animal/hostile/bread/start_pulling() + return FALSE diff --git a/code/modules/mob/living/simple_animal/simple_animal.dm b/code/modules/mob/living/simple_animal/simple_animal.dm index 5fa6a0c22d..e9b97b3597 100644 --- a/code/modules/mob/living/simple_animal/simple_animal.dm +++ b/code/modules/mob/living/simple_animal/simple_animal.dm @@ -354,7 +354,7 @@ /mob/living/simple_animal/proc/drop_loot() if(loot.len) for(var/i in loot) - new i(loc) + new i(loc, dir = src.dir) /mob/living/simple_animal/death(gibbed) movement_type &= ~FLYING diff --git a/icons/mob/animal.dmi b/icons/mob/animal.dmi index 8db32b304b..68e6170969 100644 Binary files a/icons/mob/animal.dmi and b/icons/mob/animal.dmi differ diff --git a/icons/obj/food/burgerbread.dmi b/icons/obj/food/burgerbread.dmi index 7ef3a7d418..c5bf88ab6e 100644 Binary files a/icons/obj/food/burgerbread.dmi and b/icons/obj/food/burgerbread.dmi differ diff --git a/tgstation.dme b/tgstation.dme index 71abfdea8e..04cadaef0e 100644 --- a/tgstation.dme +++ b/tgstation.dme @@ -2716,6 +2716,7 @@ #include "code\modules\mob\living\simple_animal\hostile\banana_spider.dm" #include "code\modules\mob\living\simple_animal\hostile\bear.dm" #include "code\modules\mob\living\simple_animal\hostile\bees.dm" +#include "code\modules\mob\living\simple_animal\hostile\bread.dm" #include "code\modules\mob\living\simple_animal\hostile\carp.dm" #include "code\modules\mob\living\simple_animal\hostile\cat_butcher.dm" #include "code\modules\mob\living\simple_animal\hostile\dark_wizard.dm"