From 4085aaf49b067f38c6ee0323d8ea6516253833bc Mon Sep 17 00:00:00 2001 From: Zuhayr Date: Thu, 22 Aug 2013 16:03:37 -0700 Subject: [PATCH] Added two verbs to dionaea nymphs, gave them their own file. --- code/game/machinery/podmen.dm | 2 +- .../modules/mob/living/carbon/monkey/diona.dm | 122 ++++++++++++++++++ .../mob/living/carbon/monkey/monkey.dm | 71 ---------- 3 files changed, 123 insertions(+), 72 deletions(-) create mode 100644 code/modules/mob/living/carbon/monkey/diona.dm diff --git a/code/game/machinery/podmen.dm b/code/game/machinery/podmen.dm index b3be5ce053..7654bda964 100644 --- a/code/game/machinery/podmen.dm +++ b/code/game/machinery/podmen.dm @@ -153,5 +153,5 @@ Growing it to term with nothing injected will grab a ghost from the observers. * if (newname != "") podman.real_name = newname - parent.visible_message("\blue The pod disgorges a fully-formed plant person!") + parent.visible_message("\blue The pod disgorges a fully-formed plant creature!") parent.update_tray() diff --git a/code/modules/mob/living/carbon/monkey/diona.dm b/code/modules/mob/living/carbon/monkey/diona.dm new file mode 100644 index 0000000000..461c5a264f --- /dev/null +++ b/code/modules/mob/living/carbon/monkey/diona.dm @@ -0,0 +1,122 @@ +/* + Tiny babby plant critter plus procs. +*/ + +/mob/living/carbon/monkey/diona + name = "diona nymph" + voice_name = "diona nymph" + speak_emote = list("chirrups") + ico = "nymph" + var/list/donors = list() + var/ready_evolve = 0 + +/mob/living/carbon/monkey/diona/New() + + ..() + gender = NEUTER + dna.mutantrace = "plant" + greaterform = "Diona" + add_language("Rootspeak") + +//Verbs after this point. + +/mob/living/carbon/monkey/diona/verb/fertilize_plant() + + set category = "Diona" + set name = "Fertilize plant" + set desc = "Turn your food into nutrients for plants." + + var/list/trays = list() + for(var/obj/machinery/hydroponics/tray in range(1)) + if(tray.nutrilevel < 10) + trays += tray + + var/obj/machinery/hydroponics/target = input("Select a tray:") as null|anything in trays + + if(!src || !target || target.nutrilevel == 10) return //Sanity check. + + src.nutrition -= ((10-target.nutrilevel)*5) + target.nutrilevel = 10 + src.visible_message("\red [src] secretes a trickle of green liquid from its tail, refilling [target]'s nutrient tray.","\red You secrete a trickle of green liquid from your tail, refilling [target]'s nutrient tray.") + +/mob/living/carbon/monkey/diona/verb/eat_weeds() + + set category = "Diona" + set name = "Eat Weeds" + set desc = "Clean the weeds out of soil or a hydroponics tray." + + var/list/trays = list() + for(var/obj/machinery/hydroponics/tray in range(1)) + if(tray.weedlevel > 0) + trays += tray + + var/obj/machinery/hydroponics/target = input("Select a tray:") as null|anything in trays + + if(!src || !target || target.weedlevel == 0) return //Sanity check. + + src.reagents.add_reagent("nutriment", target.weedlevel) + target.weedlevel = 0 + src.visible_message("\red [src] begins rooting through [target], ripping out weeds and eating them noisily.","\red You begin rooting through [target], ripping out weeds and eating them noisily.") + +/mob/living/carbon/monkey/diona/verb/evolve() + + set category = "Diona" + set name = "Evolve" + set desc = "Grow to a more complex form." + + if(donors.len < 5) + src << "You are not yet ready for your growth..." + return + + if(reagents.get_reagent_amount("nutriment") < 5) + src << "You have not yet consumed enough to grow..." + return + + src.visible_message("\red [src] begins to shift and quiver, and erupts in a shower of shed bark and twigs!","\red You begin to shift and quiver, then erupt in a shower of shed bark and twigs, attaining your adult form!") + var/mob/living/carbon/human/adult = new(loc) + adult.set_species("Diona") + for(var/datum/language/L in languages) + adult.add_language(L.name) + adult.regenerate_icons() + + adult.name = src.name + adult.real_name = src.real_name + adult.ckey = src.ckey + del(src) + +/mob/living/carbon/monkey/diona/verb/steal_blood() + set category = "Diona" + set name = "Steal Blood" + set desc = "Take a blood sample from a suitable donor." + + var/list/choices = list() + for(var/mob/living/C in view(1,src)) + if(C.real_name != real_name) + choices += C + + var/mob/living/M = input(src,"Who do you wish to take a sample from?") in null|choices + + if(!M || !src) return + + if(donors.Find(M.real_name)) + src << "\red That donor offers you nothing new." + return + + src.visible_message("\red [src] flicks out a feeler and neatly steals a sample of [M]'s blood.","\red You flick out a feeler and neatly steal a sample of [M]'s blood.") + donors += M.real_name + spawn(25) + update_progression() + +/mob/living/carbon/monkey/diona/proc/update_progression() + + if(!donors.len) + return + + if(donors.len == 5) + ready_evolve = 1 + src << "\green You feel ready to move on to your next stage of growth." + else if(donors.len == 3) + universal_speak = 1 + src << "\green You feel your awareness expand, and realize you know how to speak to the meat-creatures around you." + else + src << "\green The blood seeps into your small form, and you draw out the echoes of memories and personality from it, working them into your budding mind." \ No newline at end of file diff --git a/code/modules/mob/living/carbon/monkey/monkey.dm b/code/modules/mob/living/carbon/monkey/monkey.dm index ad288d1914..7f109dd7d7 100644 --- a/code/modules/mob/living/carbon/monkey/monkey.dm +++ b/code/modules/mob/living/carbon/monkey/monkey.dm @@ -34,77 +34,6 @@ ico = "stokkey" uni_append = "044C5D" -/mob/living/carbon/monkey/diona - name = "diona nymph" - voice_name = "diona nymph" - speak_emote = list("chirrups") - ico = "nymph" - var/list/donors = list() - var/ready_evolve = 0 - -/mob/living/carbon/monkey/diona/verb/evolve() - - set category = "Diona" - set name = "Evolve" - set desc = "Grow to a more complex form." - - if(donors.len < 5) - src << "You are not yet ready for your growth..." - return - - if(reagents.get_reagent_amount("nutriment") < 5) - src << "You have not yet consumed enough to grow..." - return - - src.visible_message("\red [src] begins to shift and quiver, and erupts in a shower of shed bark and twigs!","\red You begin to shift and quiver, then erupt in a shower of shed bark and twigs, attaining your adult form!") - var/mob/living/carbon/human/adult = new(loc) - adult.set_species("Diona") - for(var/datum/language/L in languages) - adult.add_language(L.name) - adult.regenerate_icons() - - adult.name = src.name - adult.real_name = src.real_name - adult.ckey = src.ckey - del(src) - -/mob/living/carbon/monkey/diona/verb/steal_blood() - set category = "Diona" - set name = "Steal Blood" - set desc = "Take a blood sample from a suitable donor." - - var/list/choices = list() - for(var/mob/living/C in view(1,src)) - if(C.real_name != real_name) - choices += C - - var/mob/living/M = input(src,"Who do you wish to take a sample from?") in null|choices - - if(!M || !src) return - - if(donors.Find(M.real_name)) - src << "\red That donor offers you nothing new." - return - - src.visible_message("\red [src] flicks out a feeler and neatly steals a sample of [M]'s blood.","\red You flick out a feeler and neatly steal a sample of [M]'s blood.") - donors += M.real_name - spawn(25) - update_progression() - -/mob/living/carbon/monkey/diona/proc/update_progression() - - if(!donors.len) - return - - if(donors.len == 5) - ready_evolve = 1 - src << "\green You feel ready to move on to your next stage of growth." - else if(donors.len == 3) - universal_speak = 1 - src << "\green You feel your awareness expand, and realize you know how to speak to the meat-creatures around you." - else - src << "\green The blood seeps into your small form, and you draw out the echoes of memories and personality from it, working them into your budding mind." - /mob/living/carbon/monkey/New() var/datum/reagents/R = new/datum/reagents(1000) reagents = R