diff --git a/code/modules/mob/living/carbon/alien/diona/diona_nymph.dm b/code/modules/mob/living/carbon/alien/diona/diona_nymph.dm index 6c2bcbac299..47a05557692 100644 --- a/code/modules/mob/living/carbon/alien/diona/diona_nymph.dm +++ b/code/modules/mob/living/carbon/alien/diona/diona_nymph.dm @@ -38,6 +38,30 @@ var/dark_survival = 216 // How long this diona can survive in darkness after energy is gone, before it dies var/datum/dionastats/DS var/mob/living/carbon/gestalt = null // If set, then this nymph is inside a gestalt + var/kept_clean = 0 + + var/mob/living/carbon/alien/diona/master_nymph //nymph who owns this nymph if split. AI diona nymphs will follow this nymph, and these nymphs can be controlled by the master. + var/list/mob/living/carbon/alien/diona/birds_of_feather = list() //list of all related nymphs + +/mob/living/carbon/alien/diona/proc/cleanupTransfer() + if(!kept_clean) + for(var/mob/living/carbon/alien/diona/D in birds_of_feather) + if(D.master_nymph == src) + D.master_nymph = null + if(!master_nymph && D != src) + master_nymph = D + D.master_nymph = master_nymph + D.birds_of_feather -= src + if(master_nymph && mind && !master_nymph.mind) + mind.transfer_to(master_nymph) + master_nymph.stunned = 0//Switching mind seems to temporarily stun mobs + message_admins("\The [src] has died with nymphs remaining; player now controls [key_name_admin(master_nymph)]") + log_admin("\The [src] has died with nymphs remaining; player now controls [key_name(master_nymph)]", ckey=key_name(master_nymph)) + master_nymph = null + birds_of_feather.Cut() + + kept_clean = 1 + /mob/living/carbon/alien/diona/flowery/Initialize(var/mapload) . = ..(mapload, 100) @@ -277,6 +301,7 @@ handle_stunned() handle_weakened() if(health <= 0) + cleanupTransfer() death() blinded = 1 silent = 0 @@ -324,6 +349,10 @@ return 1 +/mob/living/carbon/alien/diona/Destroy() + walk_to(src,0) + cleanupTransfer() + . = ..() /mob/living/carbon/alien/diona/proc/wear_hat(var/obj/item/new_hat) if(hat) @@ -331,3 +360,14 @@ hat = new_hat new_hat.forceMove(src) update_icons() + +/mob/living/carbon/alien/diona/MiddleClickOn(var/atom/A) + if(istype(A, /mob/living/carbon/alien/diona)) + var/mob/living/carbon/alien/diona/D = A + if(D.master_nymph == src) //if the nymph is subservient to you + mind.transfer_to(D) + D.stunned = 0//Switching mind seems to temporarily stun mobs + for(var/mob/living/carbon/alien/diona/DIO in src.birds_of_feather) //its me! + DIO.master_nymph = D + return 1 + . = ..() \ No newline at end of file diff --git a/code/modules/mob/living/carbon/alien/diona/diona_powers.dm b/code/modules/mob/living/carbon/alien/diona/diona_powers.dm index c827f439095..3a88fd50146 100644 --- a/code/modules/mob/living/carbon/alien/diona/diona_powers.dm +++ b/code/modules/mob/living/carbon/alien/diona/diona_powers.dm @@ -298,3 +298,18 @@ add_language(i) src << "You have mastered the [i] language!" language_progress.Remove(i) + +/mob/living/carbon/alien/diona/proc/transferMind(var/atom/A) + set category = "Abilities" + set name = "Switch Nymph" + set desc = "Transfer your control manually to another nymph in sight." + + for(var/mob/living/carbon/alien/diona/D in view(7)) + if(D.master_nymph == src && mind && !client) //if the nymph is subservient to you + mind.transfer_to(D) + D.stunned = 0//Switching mind seems to temporarily stun mobs + for(var/mob/living/carbon/alien/diona/DIO in src.birds_of_feather) //its me! + DIO.master_nymph = D + break + return 1 + ..() diff --git a/code/modules/mob/living/carbon/alien/diona/life.dm b/code/modules/mob/living/carbon/alien/diona/life.dm index 796775e8510..4a7ec297929 100644 --- a/code/modules/mob/living/carbon/alien/diona/life.dm +++ b/code/modules/mob/living/carbon/alien/diona/life.dm @@ -34,6 +34,10 @@ check_status_as_organ() if (!gestalt) + if(master_nymph && !client && master_nymph != src) + walk_to(src,master_nymph,1,movement_delay()) + else + walk_to(src,0) ..() diff --git a/code/modules/mob/living/carbon/diona_base.dm b/code/modules/mob/living/carbon/diona_base.dm index 81c706829b6..8cddc391a04 100644 --- a/code/modules/mob/living/carbon/diona_base.dm +++ b/code/modules/mob/living/carbon/diona_base.dm @@ -366,7 +366,7 @@ var/list/diona_banned_languages = list( updatehealth() /mob/living/carbon/human/proc/diona_regen_callback(organ_path, /datum/dionastats/DS) - if (!organ_path || !DS || DS.regening_organ) + if (!organ_path || !DS) return var/obj/item/organ/O = new organ_path(src) diff --git a/code/modules/mob/living/carbon/human/diona_gestalt.dm b/code/modules/mob/living/carbon/human/diona_gestalt.dm index 08b62d27c05..bdc3d71d962 100644 --- a/code/modules/mob/living/carbon/human/diona_gestalt.dm +++ b/code/modules/mob/living/carbon/human/diona_gestalt.dm @@ -20,6 +20,7 @@ setup_dionastats() verbs += /mob/living/carbon/human/proc/check_light verbs += /mob/living/carbon/human/proc/diona_split_nymph + verbs += /mob/living/proc/devour spawn(10) @@ -40,7 +41,6 @@ src << "We are named [real_name] for now, but we can choose a new name for our gestalt. (Check the Abilities Tab)" //This allows a gestalt to rename itself -once- upon reforming - verbs.Remove(/mob/living/proc/devour)//Gestalts cant devour verbs.Add(/mob/living/carbon/proc/absorb_nymph) topup_nymphs() @@ -223,12 +223,13 @@ //Start the splitting sound playsound(src.loc, 'sound/species/diona/gestalt_split.ogg', 100, 1) sleep(20) + var/list/nymphos = list() for(var/mob/living/carbon/alien/diona/D in src) if ((!D.key) && bestNymph == null) //As a safety, we choose the first unkeyed one to begin with, even if its dead. //We'll replace this choice when/if we find a better one bestNymph = D - + nymphos += D D.forceMove(T) D.split_languages(src) D.set_dir(pick(NORTH, SOUTH, EAST, WEST)) @@ -244,12 +245,16 @@ else //If a nymph is too heavily damaged, it cannot survive and will be born dead D.visible_message("[D] is too damaged to survive outside a gestalt, and expires with a pitiful chirrup", "You are too damaged to survive outside of your gestalt!", "You hear a pitiful chirrup!") D.stat = DEAD - //D.tumble(2)//So they're not all dumped on one tile for(var/obj/item/W in src) drop_from_inventory(W) if (bestNymph) + for(var/mob/living/carbon/alien/diona/D in nymphos) + D.master_nymph = bestNymph + D.birds_of_feather += nymphos + D.pixel_y += rand(-10,10) + D.pixel_x += rand(-10,10) bestNymph.set_dir(dir) transfer_languages(src, bestNymph) if(mind) diff --git a/code/modules/mob/living/carbon/human/species/station/station.dm b/code/modules/mob/living/carbon/human/species/station/station.dm index 9faed3e0a87..745690728a1 100644 --- a/code/modules/mob/living/carbon/human/species/station/station.dm +++ b/code/modules/mob/living/carbon/human/species/station/station.dm @@ -299,9 +299,7 @@ "r_hand" = list("path" = /obj/item/organ/external/hand/right/diona), "l_foot" = list("path" = /obj/item/organ/external/foot/diona), "r_foot" = list("path" = /obj/item/organ/external/foot/right/diona) - ) - - //inherent_verbs = list() + ) warning_low_pressure = 50 hazard_low_pressure = -1 diff --git a/code/modules/mob/living/devour.dm b/code/modules/mob/living/devour.dm index 06ba843a34a..29587dc4334 100644 --- a/code/modules/mob/living/devour.dm +++ b/code/modules/mob/living/devour.dm @@ -132,11 +132,11 @@ src.visible_message("[src] starts devouring [victim]","You start devouring [victim], this will take approximately [time_needed_string]. You and the victim must remain still to continue, but you can interrupt feeding anytime and leave with what you've already eaten.") - for (var/i = 1 to num_bites_needed) + for (var/i = 0 to num_bites_needed) if(do_mob(src, victim, bite_delay*10, extra_checks = CALLBACK(src, .proc/devouring_equals, victim))) face_atom(victim) - victim.adjustCloneLoss(victim_maxhealth*PEPB) - victim.adjustHalLoss(victim_maxhealth*PEPB*5)//Being eaten hurts! + victim.apply_damage(victim_maxhealth*PEPB,HALLOSS) + victim.apply_damage(victim_maxhealth*PEPB*5,CLONE) ingested.add_reagent(victim.composition_reagent, victim.composition_reagent_quantity*PEPB) visible_message("[src] bites a chunk out of [victim]","[bitemessage(victim)]") if (messes < victim.mob_size - 1 && prob(50)) diff --git a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Food-Drinks.dm b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Food-Drinks.dm index ca4299519e1..ad8d1f8137f 100644 --- a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Food-Drinks.dm +++ b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Food-Drinks.dm @@ -31,6 +31,7 @@ var/regen_factor = 0.8 var/injectable = 0 color = "#664330" + unaffected_species = IS_MACHINE /datum/reagent/nutriment/mix_data(var/list/newdata, var/newamount) if(!islist(newdata) || !newdata.len) diff --git a/html/changelogs/nanakowillriseagain.yml b/html/changelogs/nanakowillriseagain.yml new file mode 100644 index 00000000000..6c891a702be --- /dev/null +++ b/html/changelogs/nanakowillriseagain.yml @@ -0,0 +1,12 @@ + +author: Lord Fowl + +delete-after: True + +changes: + - rscadd: "Diona nymphs produced from a gestalt's death will now follow the player diona nymph." + - rscadd: "The player can freely control any of their constituent nymphs after they split at will by middle-clicking on them, and will switch to any living nymph should their active nymph die." + - rscadd: "Diona gestalts can now devour mobs as well as their constituent nymphs can." + - bugfix: "Diona will once again regrow severed limbs." + - bugfix: "Diona and nymphs will once again gain biomass from eating food." + - bugfix: "Devouring will now actually devour the target."