This repository was archived by the owner on May 22, 2025. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 456
Adds virology tumors that spread and (maybe) kill you #12740
Merged
Merged
Changes from all commits
Commits
Show all changes
23 commits
Select commit
Hold shift + click to select a range
0ffc750
tumors
ToasterBiome d99b0b1
put organs anywhere
ToasterBiome 298a312
tumors
ToasterBiome 171ee82
nerf spread chance but make it so you lose clothing slots
ToasterBiome d62b4bf
adds sprites
ToasterBiome 5617a99
regeneration
ToasterBiome 8f1fd3d
nicer zone names
ToasterBiome eb9f19d
only deal half
ToasterBiome 4763cfe
new shit
ToasterBiome 65c71c0
no mask/hat/suit only when you have visible tumors
ToasterBiome bee9fb2
adds some nice to_chats and clarifies transmission
ToasterBiome c921433
no more putting tumors in limbs you dont have
ToasterBiome dc02f09
yeah cool
ToasterBiome 16b38e2
free healing + maybe fixing the damn limb regeneration
ToasterBiome 609ad7a
regeneration is now per tumor
ToasterBiome 80fe87c
Update code/modules/surgery/organs/tumors.dm
ToasterBiome 6a76541
Update code/modules/surgery/organs/tumors.dm
ToasterBiome cd069a0
Update code/modules/surgery/organs/tumors.dm
ToasterBiome 30bf51e
Merge remote-tracking branch 'upstream/master' into tumor
ToasterBiome d721de6
Merge branch 'tumor' of https://github.com/ToasterBiome/Yogstation in…
ToasterBiome a03a007
Update surgery.dmi
ToasterBiome b0e1bed
fixes bibby shit
ToasterBiome 20e0062
whoops
ToasterBiome File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,112 @@ | ||
| //benign, premalignant, malignant tumors | ||
|
|
||
| /datum/symptom/tumor | ||
| name = "Benign tumors" | ||
| desc = "The virus causes benign growths all over your body." | ||
| stealth = 0 | ||
| resistance = 4 | ||
| stage_speed = -4 | ||
| transmittable = -4 | ||
| level = 3 | ||
| severity = 2 | ||
| symptom_delay_min = 5 | ||
| symptom_delay_max = 35 | ||
| threshold_descs = list( | ||
| "Transmission 7" = "Gives visible growths on the host's body, eventually preventing some clothes from being worn.", | ||
| "Stealth 4" = "Regenerates limbs that are incredibly fragile.", | ||
| "Resistance 8" = "Heals brute and burn damage in exchange for toxin damage." | ||
| ) | ||
| var/regeneration = FALSE | ||
| var/helpful = FALSE | ||
| var/tumor_chance = 0.5 | ||
| var/obj/item/organ/tumor/tumortype = /obj/item/organ/tumor | ||
| var/datum/disease/advance/ownerdisease //what disease it comes from | ||
|
|
||
| /datum/symptom/tumor/Start(datum/disease/advance/A) | ||
| . = ..() | ||
| if(!.) | ||
| return | ||
| ownerdisease = A; | ||
| if(A.totalTransmittable() >= 7) //visible growths | ||
| if(ishuman(A.affected_mob)) | ||
| A.affected_mob.visible_tumors = TRUE | ||
| if(A.totalStealth() >= 4) //regeneration of limbs | ||
| regeneration = TRUE | ||
| if(A.totalResistance() >= 8) //helpful healing instead of just toxin | ||
| helpful = TRUE | ||
|
|
||
| /datum/symptom/tumor/Activate(datum/disease/advance/A) | ||
| . = ..() | ||
|
|
||
| if(!.) | ||
| return | ||
| var/mob/living/carbon/human/M = A.affected_mob | ||
| if(!M) | ||
| return | ||
|
|
||
| if(M.visible_tumors) | ||
| //clothes wearing | ||
| if(A.stage > 2) | ||
| var/datum/species/S = M.dna?.species | ||
| if(S) | ||
| S.add_no_equip_slot(M, SLOT_WEAR_MASK) | ||
| S.add_no_equip_slot(M, SLOT_HEAD) | ||
|
|
||
| if(A.stage == 5) | ||
| var/datum/species/S = M.dna?.species | ||
| if(S) | ||
| S.add_no_equip_slot(M, SLOT_WEAR_SUIT) | ||
|
|
||
| //spreading | ||
| if(prob(tumor_chance)) //2% chance to make a new tumor somewhere | ||
| spread(M) | ||
|
|
||
| /datum/symptom/tumor/proc/spread(mob/living/carbon/human/M, from_tumor = FALSE) | ||
| if(!M) | ||
| return | ||
| var/list/possibleZones = list(BODY_ZONE_HEAD,BODY_ZONE_CHEST,BODY_ZONE_L_ARM,BODY_ZONE_R_ARM,BODY_ZONE_L_LEG,BODY_ZONE_R_LEG,BODY_ZONE_PRECISE_EYES,BODY_ZONE_PRECISE_GROIN) - M.get_missing_limbs() //no inserting into magic limbs you dont have | ||
| //check if we can put an organ in there | ||
| var/insertionZone = pick(possibleZones) | ||
| var/insertionAvailable = TRUE | ||
| for(var/obj/item/organ/tumor/IT in M.internal_organs) | ||
| if(IT.zone == insertionZone) | ||
| insertionAvailable = FALSE | ||
| if(insertionAvailable) | ||
| var/obj/item/organ/tumor/T = new tumortype() | ||
| T.name = T.name + " (" + parse_zone(insertionZone) + ")" | ||
| T.helpful = helpful | ||
| T.regeneration = regeneration | ||
| T.ownerdisease = ownerdisease | ||
| T.Insert(M,FALSE,FALSE,insertionZone) | ||
| if(from_tumor) | ||
| to_chat(M, span_warning("[pick("Your insides writhe.", "You feel your insides squirm.")]")) | ||
| else | ||
| to_chat(M, span_warning("Your [parse_zone(insertionZone)] hurts.")) | ||
|
|
||
| /datum/symptom/tumor/End(datum/disease/advance/A) | ||
| ..() | ||
| if(ishuman(A.affected_mob)) | ||
| //unfuck their tumors | ||
| var/mob/living/carbon/human/M = A.affected_mob | ||
| M.visible_tumors = FALSE | ||
| var/datum/species/S = M.dna?.species | ||
| if(S) | ||
| S.remove_no_equip_slot(M, SLOT_WEAR_MASK) | ||
| S.remove_no_equip_slot(M, SLOT_HEAD) | ||
| S.remove_no_equip_slot(M, SLOT_WEAR_SUIT) | ||
|
|
||
| /datum/symptom/tumor/premalignant | ||
| name = "Premalignant tumors" | ||
| desc = "The virus causes premalignant growths all over your body." | ||
| level = 5 | ||
| severity = 4 | ||
| tumor_chance = 1 | ||
| tumortype = /obj/item/organ/tumor/premalignant | ||
|
|
||
| /datum/symptom/tumor/malignant | ||
| name = "Malignant tumors" | ||
| desc = "The virus causes malignant growths all over your body." | ||
| level = 7 | ||
| severity = 6 | ||
| tumor_chance = 2 | ||
| tumortype = /obj/item/organ/tumor/malignant | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,80 @@ | ||
| #define TUMOR_STRENGTH_WEAK 0.125 | ||
| #define TUMOR_STRENGTH_AVERAGE 0.25 | ||
| #define TUMOR_STRENGTH_STRONG 0.5 | ||
|
|
||
| #define TUMOR_SPREAD_WEAK 0.5 | ||
| #define TUMOR_SPREAD_AVERAGE 1 | ||
| #define TUMOR_SPREAD_STRONG 2 | ||
|
|
||
| /obj/item/organ/tumor | ||
| name = "benign tumor" | ||
| desc = "Hope there aren't more of these." | ||
| icon_state = "tumor" | ||
|
|
||
| var/strength = TUMOR_STRENGTH_WEAK | ||
| var/spread_chance = TUMOR_SPREAD_WEAK | ||
|
|
||
| var/helpful = FALSE //keeping track if they're helpful or not | ||
| var/regeneration = FALSE //if limbs are regenerating | ||
| var/datum/disease/advance/tumor/ownerdisease //what disease it comes from | ||
|
|
||
| /obj/item/organ/tumor/Insert(mob/living/carbon/M, special = 0) | ||
| . = ..() | ||
| START_PROCESSING(SSobj, src) | ||
|
|
||
| /obj/item/organ/tumor/Remove(mob/living/carbon/M, special = 0) | ||
| . = ..() | ||
| var/tumors_left = FALSE | ||
| for(var/obj/item/organ/tumor/IT in owner.internal_organs) | ||
| if(IT.ownerdisease == ownerdisease) | ||
| tumors_left = TRUE | ||
| if(!tumors_left) | ||
| //cure the disease, removing all tumors | ||
| ownerdisease.cure() | ||
| STOP_PROCESSING(SSobj, src) | ||
|
|
||
| /obj/item/organ/tumor/process() | ||
| if(!owner) | ||
| return | ||
| if(!(src in owner.internal_organs)) | ||
| Remove(owner) | ||
| if(helpful) | ||
| if(owner.getBruteLoss() + owner.getFireLoss() > 0) | ||
| owner.adjustToxLoss(strength/2) | ||
| owner.adjustBruteLoss(-(strength/2)) | ||
| owner.adjustFireLoss(-(strength/2)) | ||
| else | ||
| owner.adjustToxLoss(strength) //just take toxin damage | ||
| //regeneration | ||
| if(regeneration && prob(spread_chance)) | ||
| var/list/missing_limbs = owner.get_missing_limbs() - list(BODY_ZONE_HEAD, BODY_ZONE_CHEST) //don't regenerate the head or chest | ||
| if(missing_limbs.len) | ||
| var/limb_to_regenerate = pick(missing_limbs) | ||
| owner.regenerate_limb(limb_to_regenerate,TRUE) | ||
| var/obj/item/bodypart/new_limb = owner.get_bodypart(limb_to_regenerate) | ||
| new_limb.receive_damage(45); //45 brute damage should be fine I think?????? | ||
| owner.emote("scream") | ||
| owner.visible_message(span_warning("Gnarly tumors burst out of [owner]'s stump and form into a [parse_zone(limb_to_regenerate)]!"), span_notice("You scream as your [parse_zone(limb_to_regenerate)] reforms.")) | ||
| if(prob(spread_chance)) | ||
| if(ownerdisease) | ||
| ownerdisease.spread(owner, TRUE) | ||
|
|
||
|
|
||
| /obj/item/organ/tumor/premalignant | ||
| name = "premalignant tumor" | ||
| desc = "It doesn't look too bad... at least you're not dead, right?" | ||
| strength = TUMOR_STRENGTH_AVERAGE | ||
| spread_chance = TUMOR_SPREAD_AVERAGE | ||
|
|
||
| /obj/item/organ/tumor/malignant | ||
| name = "malignant tumor" | ||
| desc = "Yikes. There's probably more of these in you." | ||
| strength = TUMOR_STRENGTH_STRONG | ||
| spread_chance = TUMOR_SPREAD_STRONG | ||
|
|
||
| #undef TUMOR_STRENGTH_WEAK | ||
| #undef TUMOR_STRENGTH_AVERAGE | ||
| #undef TUMOR_STRENGTH_STRONG | ||
| #undef TUMOR_SPREAD_WEAK | ||
| #undef TUMOR_SPREAD_AVERAGE | ||
| #undef TUMOR_SPREAD_STRONG |
Binary file not shown.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.