Refactors virus spreading

This commit is contained in:
XDTM
2017-10-09 14:08:21 +02:00
committed by CitadelStationBot
parent 6f2b89ae88
commit 7a0ce217db
60 changed files with 1057 additions and 187 deletions

View File

@@ -0,0 +1,26 @@
//Visibility Flags
#define HIDDEN_SCANNER 1
#define HIDDEN_PANDEMIC 2
//Disease Flags
#define CURABLE 1
#define CAN_CARRY 2
#define CAN_RESIST 4
//Spread Flags
#define VIRUS_SPREAD_SPECIAL 1
#define VIRUS_SPREAD_NON_CONTAGIOUS 2
#define VIRUS_SPREAD_BLOOD 4
#define VIRUS_SPREAD_CONTACT_FLUIDS 8
#define VIRUS_SPREAD_CONTACT_SKIN 16
#define VIRUS_SPREAD_AIRBORNE 32
//Severity Defines
#define VIRUS_SEVERITY_POSITIVE "Positive" //Diseases that buff, heal, or at least do nothing at all
#define VIRUS_SEVERITY_NONTHREAT "Harmless" //Diseases that may have annoying effects, but nothing disruptive (sneezing)
#define VIRUS_SEVERITY_MINOR "Minor" //Diseases that can annoy in concrete ways (dizziness)
#define VIRUS_SEVERITY_MEDIUM "Medium" //Diseases that can do minor harm, or severe annoyance (vomit)
#define VIRUS_SEVERITY_HARMFUL "Harmful" //Diseases that can do significant harm, or severe disruption (brainrot)
#define VIRUS_SEVERITY_DANGEROUS "Dangerous" //Diseases that can kill or maim if left untreated (flesh eating, blindness)
#define VIRUS_SEVERITY_BIOHAZARD "BIOHAZARD" //Diseases that can quickly kill an unprepared victim (fungal tb, gbs)

View File

@@ -0,0 +1,13 @@
/datum/component/infective
var/list/datum/disease/diseases //make sure these are the static, non-processing versions!
/datum/component/infective/Initialize(list/datum/disease/_diseases)
RegisterSignal(COMSIG_MOVABLE_CROSSED, .proc/Infect)
diseases = _diseases
/datum/component/infective/proc/Infect(atom/movable/AM)
var/mob/living/carbon/victim = AM
if(istype(victim))
for(var/datum/disease/D in diseases)
victim.ContactContractDisease(D, "feet")
return TRUE

View File

@@ -23,7 +23,7 @@
return 1
/mob/proc/ContractDisease(datum/disease/D)
/mob/proc/ContactContractDisease(datum/disease/D)
if(!CanContractDisease(D))
return 0
AddDisease(D)
@@ -56,42 +56,31 @@
DD.affected_mob.med_hud_set_status()
/mob/living/carbon/ContractDisease(datum/disease/D)
/mob/living/carbon/ContactContractDisease(datum/disease/D, target_zone)
if(!CanContractDisease(D))
return 0
var/obj/item/clothing/Cl = null
var/passed = 1
var/passed = TRUE
var/head_ch = 100
var/head_ch = 80
var/body_ch = 100
var/hands_ch = 25
var/feet_ch = 25
if(D.spread_flags & CONTACT_HANDS)
head_ch = 0
body_ch = 0
hands_ch = 100
feet_ch = 0
if(D.spread_flags & CONTACT_FEET)
head_ch = 0
body_ch = 0
hands_ch = 0
feet_ch = 100
var/hands_ch = 35
var/feet_ch = 15
if(prob(15/D.permeability_mod))
return
if(satiety>0 && prob(satiety/10)) // positive satiety makes it harder to contract the disease.
return
var/target_zone = pick(head_ch;1,body_ch;2,hands_ch;3,feet_ch;4)
if(!target_zone)
target_zone = pick(head_ch;"head",body_ch;"body",hands_ch;"hands",feet_ch;"feet")
if(ishuman(src))
var/mob/living/carbon/human/H = src
switch(target_zone)
if(1)
if("head")
if(isobj(H.head) && !istype(H.head, /obj/item/paper))
Cl = H.head
passed = prob((Cl.permeability_coefficient*100) - 1)
@@ -101,14 +90,14 @@
if(passed && isobj(H.wear_neck))
Cl = H.wear_neck
passed = prob((Cl.permeability_coefficient*100) - 1)
if(2)
if("body")
if(isobj(H.wear_suit))
Cl = H.wear_suit
passed = prob((Cl.permeability_coefficient*100) - 1)
if(passed && isobj(slot_w_uniform))
Cl = slot_w_uniform
passed = prob((Cl.permeability_coefficient*100) - 1)
if(3)
if("hands")
if(isobj(H.wear_suit) && H.wear_suit.body_parts_covered&HANDS)
Cl = H.wear_suit
passed = prob((Cl.permeability_coefficient*100) - 1)
@@ -116,7 +105,7 @@
if(passed && isobj(H.gloves))
Cl = H.gloves
passed = prob((Cl.permeability_coefficient*100) - 1)
if(4)
if("feet")
if(isobj(H.wear_suit) && H.wear_suit.body_parts_covered&FEET)
Cl = H.wear_suit
passed = prob((Cl.permeability_coefficient*100) - 1)
@@ -128,19 +117,30 @@
else if(ismonkey(src))
var/mob/living/carbon/monkey/M = src
switch(target_zone)
if(1)
if("head")
if(M.wear_mask && isobj(M.wear_mask))
Cl = M.wear_mask
passed = prob((Cl.permeability_coefficient*100) - 1)
if(!passed && (D.spread_flags & AIRBORNE) && !internal)
passed = (prob((50*D.permeability_mod) - 1))
if(passed)
AddDisease(D)
/mob/proc/AirborneContractDisease(datum/disease/D)
if((D.spread_flags & VIRUS_SPREAD_AIRBORNE) && prob((50*D.permeability_mod) - 1))
ForceContractDisease(D)
//Same as ContractDisease, except never overidden clothes checks
/mob/living/carbon/AirborneContractDisease(datum/disease/D)
if(internal)
return
..()
/mob/living/carbon/human/AirborneContractDisease(datum/disease/D)
if(dna && (NOBREATH in dna.species.species_traits))
return
..()
//Proc to use when you 100% want to infect someone, as long as they aren't immune
/mob/proc/ForceContractDisease(datum/disease/D)
if(!CanContractDisease(D))
return 0

View File

@@ -1,36 +1,8 @@
//Visibility Flags
#define HIDDEN_SCANNER 1
#define HIDDEN_PANDEMIC 2
//Disease Flags
#define CURABLE 1
#define CAN_CARRY 2
#define CAN_RESIST 4
//Spread Flags
#define SPECIAL 1
#define NON_CONTAGIOUS 2
#define BLOOD 4
#define CONTACT_FEET 8
#define CONTACT_HANDS 16
#define CONTACT_GENERAL 32
#define AIRBORNE 64
//Severity Defines
#define NONTHREAT "No threat"
#define MINOR "Minor"
#define MEDIUM "Medium"
#define HARMFUL "Harmful"
#define DANGEROUS "Dangerous!"
#define BIOHAZARD "BIOHAZARD THREAT!"
/datum/disease
//Flags
var/visibility_flags = 0
var/disease_flags = CURABLE|CAN_CARRY|CAN_RESIST
var/spread_flags = AIRBORNE
var/spread_flags = VIRUS_SPREAD_AIRBORNE | VIRUS_SPREAD_CONTACT_FLUIDS | VIRUS_SPREAD_CONTACT_SKIN
//Fluff
var/form = "Virus"
@@ -54,7 +26,7 @@
var/carrier = FALSE //If our host is only a carrier
var/bypasses_immunity = FALSE //Does it skip species virus immunity check? Some things may diseases and not viruses
var/permeability_mod = 1
var/severity = NONTHREAT
var/severity = VIRUS_SEVERITY_POSITIVE
var/list/required_organs = list()
var/needs_all_cures = TRUE
var/list/strain_data = list() //dna_spread special bullshit
@@ -95,25 +67,22 @@
if(!. || (needs_all_cures && . < cures.len))
return 0
//Airborne spreading
/datum/disease/proc/spread(force_spread = 0)
if(!affected_mob)
return
if((spread_flags & SPECIAL || spread_flags & NON_CONTAGIOUS || spread_flags & BLOOD) && !force_spread)
if(!(spread_flags & VIRUS_SPREAD_AIRBORNE) && !force_spread)
return
if(affected_mob.reagents.has_reagent("spaceacillin") || (affected_mob.satiety > 0 && prob(affected_mob.satiety/10)))
return
var/spread_range = 1
var/spread_range = 2
if(force_spread)
spread_range = force_spread
if(spread_flags & AIRBORNE)
spread_range++
var/turf/T = affected_mob.loc
if(istype(T))
for(var/mob/living/carbon/C in oview(spread_range, affected_mob))
@@ -121,7 +90,7 @@
if(V)
while(TRUE)
if(V == T)
C.ContractDisease(src)
C.AirborneContractDisease(src)
break
var/turf/Temp = get_step_towards(V, T)
if(!CANATMOSPASS(V, Temp))
@@ -152,12 +121,6 @@
/datum/disease/proc/GetDiseaseID()
return type
/datum/disease/proc/IsSpreadByTouch()
if(spread_flags & CONTACT_FEET || spread_flags & CONTACT_HANDS || spread_flags & CONTACT_GENERAL)
return 1
return 0
//don't use this proc directly. this should only ever be called by cure()
/datum/disease/proc/remove_virus()
affected_mob.viruses -= src //remove the datum from the list

View File

@@ -183,19 +183,19 @@
properties["stealth"] += S.stealth
properties["stage_rate"] += S.stage_speed
properties["transmittable"] += S.transmittable
properties["severity"] = max(properties["severity"], S.severity) // severity is based on the highest severity symptom
if(!S.neutered)
properties["severity"] = max(properties["severity"], S.severity) // severity is based on the highest severity non-neutered symptom
return
// Assign the properties that are in the list.
/datum/disease/advance/proc/AssignProperties()
if(properties && properties.len)
switch(properties["stealth"])
if(2 to INFINITY)
visibility_flags = HIDDEN_SCANNER
if(properties["stealth"] >= 2)
visibility_flags = HIDDEN_SCANNER
SetSpread(Clamp(2 ** (properties["transmittable"] - symptoms.len), VIRUS_SPREAD_BLOOD, VIRUS_SPREAD_AIRBORNE))
// The more symptoms we have, the less transmittable it is but some symptoms can make up for it.
SetSpread(Clamp(2 ** (properties["transmittable"] - symptoms.len), BLOOD, AIRBORNE))
permeability_mod = max(Ceiling(0.4 * properties["transmittable"]), 1)
cure_chance = 15 - Clamp(properties["resistance"], -5, 5) // can be between 10 and 20
stage_prob = max(properties["stage_rate"], 2)
@@ -208,35 +208,43 @@
// Assign the spread type and give it the correct description.
/datum/disease/advance/proc/SetSpread(spread_id)
switch(spread_id)
if(NON_CONTAGIOUS)
if(VIRUS_SPREAD_NON_CONTAGIOUS)
spread_flags = VIRUS_SPREAD_NON_CONTAGIOUS
spread_text = "None"
if(SPECIAL)
if(VIRUS_SPREAD_SPECIAL)
spread_flags = VIRUS_SPREAD_SPECIAL
spread_text = "None"
if(CONTACT_GENERAL, CONTACT_HANDS, CONTACT_FEET)
spread_text = "On contact"
if(AIRBORNE)
spread_text = "Airborne"
if(BLOOD)
if(VIRUS_SPREAD_BLOOD)
spread_flags = VIRUS_SPREAD_BLOOD
spread_text = "Blood"
spread_flags = spread_id
if(VIRUS_SPREAD_CONTACT_FLUIDS)
spread_flags = VIRUS_SPREAD_BLOOD | VIRUS_SPREAD_CONTACT_FLUIDS
spread_text = "Fluids"
if(VIRUS_SPREAD_CONTACT_SKIN)
spread_flags = VIRUS_SPREAD_BLOOD | VIRUS_SPREAD_CONTACT_FLUIDS | VIRUS_SPREAD_CONTACT_SKIN
spread_text = "On contact"
if(VIRUS_SPREAD_AIRBORNE)
spread_flags = VIRUS_SPREAD_BLOOD | VIRUS_SPREAD_CONTACT_FLUIDS | VIRUS_SPREAD_CONTACT_SKIN | VIRUS_SPREAD_AIRBORNE
spread_text = "Airborne"
/datum/disease/advance/proc/SetSeverity(level_sev)
switch(level_sev)
if(-INFINITY to 0)
severity = NONTHREAT
severity = VIRUS_SEVERITY_POSITIVE
if(1)
severity = MINOR
severity = VIRUS_SEVERITY_NONTHREAT
if(2)
severity = MEDIUM
severity = VIRUS_SEVERITY_MINOR
if(3)
severity = HARMFUL
severity = VIRUS_SEVERITY_MEDIUM
if(4)
severity = DANGEROUS
if(5 to INFINITY)
severity = BIOHAZARD
severity = VIRUS_SEVERITY_HARMFUL
if(5)
severity = VIRUS_SEVERITY_DANGEROUS
if(6 to INFINITY)
severity = VIRUS_SEVERITY_BIOHAZARD
else
severity = "Unknown"

View File

@@ -94,7 +94,7 @@ Bonus
stage_speed = -1
transmittable = -2
level = 7
severity = 3
severity = 6
base_message_chance = 15
symptom_delay_min = 14
symptom_delay_max = 30

View File

@@ -40,7 +40,7 @@ BONUS
return
if(A.properties["stealth"] >= 4)
suppress_warning = TRUE
if(A.spread_flags &= AIRBORNE) //infect bystanders
if(A.spread_flags &= VIRUS_SPREAD_AIRBORNE) //infect bystanders
infective = TRUE
if(A.properties["resistance"] >= 3) //strong enough to drop items
power = 1.5

View File

@@ -24,7 +24,7 @@ Bonus
stage_speed = -1
transmittable = -3
level = 4
severity = 3
severity = 4
base_message_chance = 100
symptom_delay_min = 25
symptom_delay_max = 80

View File

@@ -23,7 +23,7 @@ Bonus
stage_speed = 0
transmittable = -3
level = 6
severity = 3
severity = 4
var/list/possible_mutations
var/archived_dna = null
base_message_chance = 50

View File

@@ -23,7 +23,7 @@ Bonus
stage_speed = -3
transmittable = -1
level = 5
severity = 3
severity = 2
base_message_chance = 25
symptom_delay_min = 25
symptom_delay_max = 90

View File

@@ -22,7 +22,7 @@ Bonus
level = 6
symptom_delay_min = 15
symptom_delay_max = 80
severity = 5
severity = 4
var/sleep_level = 0
var/sleepy_ticks = 0
var/stamina = FALSE

View File

@@ -23,7 +23,6 @@ Bonus
stage_speed = -4
transmittable = -3
level = 5
severity = 0
symptom_delay_min = 5
symptom_delay_max = 10
var/purge_alcohol = FALSE

View File

@@ -24,7 +24,7 @@ Bonus
stage_speed = -4
transmittable = -3
level = 5
severity = 4
severity = 5
base_message_chance = 50
symptom_delay_min = 25
symptom_delay_max = 80

View File

@@ -28,7 +28,7 @@ Bonus
stage_speed = 0
transmittable = 1
level = 3
severity = 4
severity = 3
base_message_chance = 100
symptom_delay_min = 25
symptom_delay_max = 80

View File

@@ -24,7 +24,7 @@ Bonus
stage_speed = -2
transmittable = -2
level = 4
severity = 1
severity = 3
base_message_chance = 100
symptom_delay_min = 15
symptom_delay_max = 45
@@ -75,7 +75,7 @@ Bonus
stage_speed = -2
transmittable = -2
level = 3
severity = 1
severity = 3
base_message_chance = 100
symptom_delay_min = 15
symptom_delay_max = 45

View File

@@ -3,13 +3,13 @@
form = "Infection"
max_stages = 4
spread_text = "On contact"
spread_flags = CONTACT_GENERAL
spread_flags = VIRUS_SPREAD_BLOOD | VIRUS_SPREAD_CONTACT_SKIN | VIRUS_SPREAD_CONTACT_FLUIDS
cure_text = "Ethanol"
cures = list("ethanol")
agent = "Excess Lepidopticides"
viable_mobtypes = list(/mob/living/carbon/human, /mob/living/carbon/monkey)
desc = "If left untreated subject will regurgitate butterflies."
severity = MEDIUM
severity = VIRUS_SEVERITY_MINOR
/datum/disease/anxiety/stage_act()
..()

View File

@@ -7,9 +7,9 @@
viable_mobtypes = list(/mob/living/carbon/human)
permeability_mod = 1
desc = "If left untreated the subject will become very weak, and may vomit often."
severity = "Dangerous!"
severity = VIRUS_SEVERITY_MEDIUM
disease_flags = CAN_CARRY|CAN_RESIST
spread_flags = NON_CONTAGIOUS
spread_flags = VIRUS_SPREAD_NON_CONTAGIOUS
visibility_flags = HIDDEN_PANDEMIC
required_organs = list(/obj/item/organ/appendix)
bypasses_immunity = TRUE // Immunity is based on not having an appendix; this isn't a virus

View File

@@ -1,3 +1,4 @@
<<<<<<< HEAD
/datum/disease/beesease
name = "Beesease"
form = "Infection"
@@ -37,4 +38,45 @@
new /mob/living/simple_animal/hostile/poison/bees(affected_mob.loc)
//if(5)
//Plus if you die, you explode into bees
=======
/datum/disease/beesease
name = "Beesease"
form = "Infection"
max_stages = 4
spread_text = "On contact"
spread_flags = VIRUS_SPREAD_BLOOD | VIRUS_SPREAD_CONTACT_SKIN | VIRUS_SPREAD_CONTACT_FLUIDS
cure_text = "Sugar"
cures = list("sugar")
agent = "Apidae Infection"
viable_mobtypes = list(/mob/living/carbon/human, /mob/living/carbon/monkey)
desc = "If left untreated subject will regurgitate bees."
severity = VIRUS_SEVERITY_MEDIUM
/datum/disease/beesease/stage_act()
..()
switch(stage)
if(2) //also changes say, see say.dm
if(prob(2))
to_chat(affected_mob, "<span class='notice'>You taste honey in your mouth.</span>")
if(3)
if(prob(10))
to_chat(affected_mob, "<span class='notice'>Your stomach rumbles.</span>")
if(prob(2))
to_chat(affected_mob, "<span class='danger'>Your stomach stings painfully.</span>")
if(prob(20))
affected_mob.adjustToxLoss(2)
affected_mob.updatehealth()
if(4)
if(prob(10))
affected_mob.visible_message("<span class='danger'>[affected_mob] buzzes.</span>", \
"<span class='userdanger'>Your stomach buzzes violently!</span>")
if(prob(5))
to_chat(affected_mob, "<span class='danger'>You feel something moving in your throat.</span>")
if(prob(1))
affected_mob.visible_message("<span class='danger'>[affected_mob] coughs up a swarm of bees!</span>", \
"<span class='userdanger'>You cough up a swarm of bees!</span>")
new /mob/living/simple_animal/hostile/poison/bees(affected_mob.loc)
//if(5)
//Plus if you die, you explode into bees
>>>>>>> db0c10e... Refactors virus spreading (#31066)
return

View File

@@ -1,3 +1,4 @@
<<<<<<< HEAD
/datum/disease/brainrot
name = "Brainrot"
max_stages = 4
@@ -57,3 +58,64 @@
affected_mob.stuttering += 3
return
=======
/datum/disease/brainrot
name = "Brainrot"
max_stages = 4
spread_text = "On contact"
spread_flags = VIRUS_SPREAD_BLOOD | VIRUS_SPREAD_CONTACT_SKIN | VIRUS_SPREAD_CONTACT_FLUIDS
cure_text = "Mannitol"
cures = list("mannitol")
agent = "Cryptococcus Cosmosis"
viable_mobtypes = list(/mob/living/carbon/human)
cure_chance = 15//higher chance to cure, since two reagents are required
desc = "This disease destroys the braincells, causing brain fever, brain necrosis and general intoxication."
required_organs = list(/obj/item/organ/brain)
severity = VIRUS_SEVERITY_HARMFUL
/datum/disease/brainrot/stage_act() //Removed toxloss because damaging diseases are pretty horrible. Last round it killed the entire station because the cure didn't work -- Urist -ACTUALLY Removed rather than commented out, I don't see it returning - RR
..()
switch(stage)
if(2)
if(prob(2))
affected_mob.emote("blink")
if(prob(2))
affected_mob.emote("yawn")
if(prob(2))
to_chat(affected_mob, "<span class='danger'>You don't feel like yourself.</span>")
if(prob(5))
affected_mob.adjustBrainLoss(1)
affected_mob.updatehealth()
if(3)
if(prob(2))
affected_mob.emote("stare")
if(prob(2))
affected_mob.emote("drool")
if(prob(10) && affected_mob.getBrainLoss()<=98)//shouldn't retard you to death now
affected_mob.adjustBrainLoss(2)
affected_mob.updatehealth()
if(prob(2))
to_chat(affected_mob, "<span class='danger'>Your try to remember something important...but can't.</span>")
if(4)
if(prob(2))
affected_mob.emote("stare")
if(prob(2))
affected_mob.emote("drool")
if(prob(15) && affected_mob.getBrainLoss()<=98) //shouldn't retard you to death now
affected_mob.adjustBrainLoss(3)
affected_mob.updatehealth()
if(prob(2))
to_chat(affected_mob, "<span class='danger'>Strange buzzing fills your head, removing all thoughts.</span>")
if(prob(3))
to_chat(affected_mob, "<span class='danger'>You lose consciousness...</span>")
affected_mob.visible_message("<span class='warning'>[affected_mob] suddenly collapses</span>")
affected_mob.Unconscious(rand(100,200))
if(prob(1))
affected_mob.emote("snore")
if(prob(15))
affected_mob.stuttering += 3
return
>>>>>>> db0c10e... Refactors virus spreading (#31066)

View File

@@ -1,3 +1,4 @@
<<<<<<< HEAD
/datum/disease/cold
name = "The Cold"
max_stages = 3
@@ -63,4 +64,70 @@
if(!affected_mob.resistances.Find(/datum/disease/flu))
var/datum/disease/Flu = new /datum/disease/flu(0)
affected_mob.ContractDisease(Flu)
=======
/datum/disease/cold
name = "The Cold"
max_stages = 3
cure_text = "Rest & Spaceacillin"
cures = list("spaceacillin")
agent = "XY-rhinovirus"
viable_mobtypes = list(/mob/living/carbon/human, /mob/living/carbon/monkey)
permeability_mod = 0.5
desc = "If left untreated the subject will contract the flu."
severity = VIRUS_SEVERITY_NONTHREAT
/datum/disease/cold/stage_act()
..()
switch(stage)
if(2)
/*
if(affected_mob.sleeping && prob(40)) //removed until sleeping is fixed
to_chat(affected_mob, "\blue You feel better.")
cure()
return
*/
if(affected_mob.lying && prob(40)) //changed FROM prob(10) until sleeping is fixed
to_chat(affected_mob, "<span class='notice'>You feel better.</span>")
cure()
return
if(prob(1) && prob(5))
to_chat(affected_mob, "<span class='notice'>You feel better.</span>")
cure()
return
if(prob(1))
affected_mob.emote("sneeze")
if(prob(1))
affected_mob.emote("cough")
if(prob(1))
to_chat(affected_mob, "<span class='danger'>Your throat feels sore.</span>")
if(prob(1))
to_chat(affected_mob, "<span class='danger'>Mucous runs down the back of your throat.</span>")
if(3)
/*
if(affected_mob.sleeping && prob(25)) //removed until sleeping is fixed
to_chat(affected_mob, "\blue You feel better.")
cure()
return
*/
if(affected_mob.lying && prob(25)) //changed FROM prob(5) until sleeping is fixed
to_chat(affected_mob, "<span class='notice'>You feel better.</span>")
cure()
return
if(prob(1) && prob(1))
to_chat(affected_mob, "<span class='notice'>You feel better.</span>")
cure()
return
if(prob(1))
affected_mob.emote("sneeze")
if(prob(1))
affected_mob.emote("cough")
if(prob(1))
to_chat(affected_mob, "<span class='danger'>Your throat feels sore.</span>")
if(prob(1))
to_chat(affected_mob, "<span class='danger'>Mucous runs down the back of your throat.</span>")
if(prob(1) && prob(50))
if(!affected_mob.resistances.Find(/datum/disease/flu))
var/datum/disease/Flu = new /datum/disease/flu(0)
affected_mob.ForceContractDisease(Flu)
>>>>>>> db0c10e... Refactors virus spreading (#31066)
cure()

View File

@@ -1,3 +1,4 @@
<<<<<<< HEAD
/datum/disease/cold9
name = "The Cold"
max_stages = 3
@@ -36,4 +37,44 @@
if(prob(1))
to_chat(affected_mob, "<span class='danger'>Your throat feels sore.</span>")
if(prob(10))
=======
/datum/disease/cold9
name = "The Cold"
max_stages = 3
spread_text = "On contact"
spread_flags = VIRUS_SPREAD_BLOOD | VIRUS_SPREAD_CONTACT_SKIN | VIRUS_SPREAD_CONTACT_FLUIDS
cure_text = "Common Cold Anti-bodies & Spaceacillin"
cures = list("spaceacillin")
agent = "ICE9-rhinovirus"
viable_mobtypes = list(/mob/living/carbon/human)
desc = "If left untreated the subject will slow, as if partly frozen."
severity = VIRUS_SEVERITY_HARMFUL
/datum/disease/cold9/stage_act()
..()
switch(stage)
if(2)
affected_mob.bodytemperature -= 10
if(prob(1) && prob(10))
to_chat(affected_mob, "<span class='notice'>You feel better.</span>")
cure()
return
if(prob(1))
affected_mob.emote("sneeze")
if(prob(1))
affected_mob.emote("cough")
if(prob(1))
to_chat(affected_mob, "<span class='danger'>Your throat feels sore.</span>")
if(prob(5))
to_chat(affected_mob, "<span class='danger'>You feel stiff.</span>")
if(3)
affected_mob.bodytemperature -= 20
if(prob(1))
affected_mob.emote("sneeze")
if(prob(1))
affected_mob.emote("cough")
if(prob(1))
to_chat(affected_mob, "<span class='danger'>Your throat feels sore.</span>")
if(prob(10))
>>>>>>> db0c10e... Refactors virus spreading (#31066)
to_chat(affected_mob, "<span class='danger'>You feel stiff.</span>")

View File

@@ -2,7 +2,7 @@
name = "Space Retrovirus"
max_stages = 4
spread_text = "On contact"
spread_flags = CONTACT_GENERAL
spread_flags = VIRUS_SPREAD_BLOOD | VIRUS_SPREAD_CONTACT_SKIN | VIRUS_SPREAD_CONTACT_FLUIDS
cure_text = "Mutadone"
cures = list("mutadone")
disease_flags = CAN_CARRY|CAN_RESIST|CURABLE
@@ -11,7 +11,7 @@
var/datum/dna/original_dna = null
var/transformed = 0
desc = "This disease transplants the genetic code of the initial vector into new hosts."
severity = MEDIUM
severity = VIRUS_SEVERITY_MEDIUM
/datum/disease/dnaspread/stage_act()

View File

@@ -1,3 +1,4 @@
<<<<<<< HEAD
/datum/disease/fake_gbs
name = "GBS"
max_stages = 5
@@ -30,3 +31,37 @@
if(5)
if(prob(10))
affected_mob.emote("cough")
=======
/datum/disease/fake_gbs
name = "GBS"
max_stages = 5
spread_text = "On contact"
spread_flags = VIRUS_SPREAD_BLOOD | VIRUS_SPREAD_CONTACT_SKIN | VIRUS_SPREAD_CONTACT_FLUIDS
cure_text = "Synaptizine & Sulfur"
cures = list("synaptizine","sulfur")
agent = "Gravitokinetic Bipotential SADS-"
viable_mobtypes = list(/mob/living/carbon/human, /mob/living/carbon/monkey)
desc = "If left untreated death will occur."
severity = VIRUS_SEVERITY_BIOHAZARD
/datum/disease/fake_gbs/stage_act()
..()
switch(stage)
if(2)
if(prob(1))
affected_mob.emote("sneeze")
if(3)
if(prob(5))
affected_mob.emote("cough")
else if(prob(5))
affected_mob.emote("gasp")
if(prob(10))
to_chat(affected_mob, "<span class='danger'>You're starting to feel very weak...</span>")
if(4)
if(prob(10))
affected_mob.emote("cough")
if(5)
if(prob(10))
affected_mob.emote("cough")
>>>>>>> db0c10e... Refactors virus spreading (#31066)

View File

@@ -7,6 +7,7 @@
cure_chance = 10
agent = "H13N1 flu virion"
viable_mobtypes = list(/mob/living/carbon/human, /mob/living/carbon/monkey)
<<<<<<< HEAD
permeability_mod = 0.75
desc = "If left untreated the subject will feel quite unwell."
severity = MEDIUM
@@ -52,3 +53,50 @@
affected_mob.adjustToxLoss(1)
affected_mob.updatehealth()
return
=======
permeability_mod = 0.75
desc = "If left untreated the subject will feel quite unwell."
severity = VIRUS_SEVERITY_MINOR
/datum/disease/flu/stage_act()
..()
switch(stage)
if(2)
if(affected_mob.lying && prob(20))
to_chat(affected_mob, "<span class='notice'>You feel better.</span>")
stage--
return
if(prob(1))
affected_mob.emote("sneeze")
if(prob(1))
affected_mob.emote("cough")
if(prob(1))
to_chat(affected_mob, "<span class='danger'>Your muscles ache.</span>")
if(prob(20))
affected_mob.take_bodypart_damage(1)
if(prob(1))
to_chat(affected_mob, "<span class='danger'>Your stomach hurts.</span>")
if(prob(20))
affected_mob.adjustToxLoss(1)
affected_mob.updatehealth()
if(3)
if(affected_mob.lying && prob(15))
to_chat(affected_mob, "<span class='notice'>You feel better.</span>")
stage--
return
if(prob(1))
affected_mob.emote("sneeze")
if(prob(1))
affected_mob.emote("cough")
if(prob(1))
to_chat(affected_mob, "<span class='danger'>Your muscles ache.</span>")
if(prob(20))
affected_mob.take_bodypart_damage(1)
if(prob(1))
to_chat(affected_mob, "<span class='danger'>Your stomach hurts.</span>")
if(prob(20))
affected_mob.adjustToxLoss(1)
affected_mob.updatehealth()
return
>>>>>>> db0c10e... Refactors virus spreading (#31066)

View File

@@ -1,3 +1,4 @@
<<<<<<< HEAD
/datum/disease/fluspanish
name = "Spanish inquisition Flu"
max_stages = 3
@@ -34,3 +35,41 @@
to_chat(affected_mob, "<span class='danger'>You're burning in your own skin!</span>")
affected_mob.take_bodypart_damage(0,5)
return
=======
/datum/disease/fluspanish
name = "Spanish inquisition Flu"
max_stages = 3
spread_text = "Airborne"
cure_text = "Spaceacillin & Anti-bodies to the common flu"
cures = list("spaceacillin")
cure_chance = 10
agent = "1nqu1s1t10n flu virion"
viable_mobtypes = list(/mob/living/carbon/human)
permeability_mod = 0.75
desc = "If left untreated the subject will burn to death for being a heretic."
severity = VIRUS_SEVERITY_DANGEROUS
/datum/disease/fluspanish/stage_act()
..()
switch(stage)
if(2)
affected_mob.bodytemperature += 10
if(prob(5))
affected_mob.emote("sneeze")
if(prob(5))
affected_mob.emote("cough")
if(prob(1))
to_chat(affected_mob, "<span class='danger'>You're burning in your own skin!</span>")
affected_mob.take_bodypart_damage(0,5)
if(3)
affected_mob.bodytemperature += 20
if(prob(5))
affected_mob.emote("sneeze")
if(prob(5))
affected_mob.emote("cough")
if(prob(5))
to_chat(affected_mob, "<span class='danger'>You're burning in your own skin!</span>")
affected_mob.take_bodypart_damage(0,5)
return
>>>>>>> db0c10e... Refactors virus spreading (#31066)

View File

@@ -1,3 +1,4 @@
<<<<<<< HEAD
/datum/disease/gbs
name = "GBS"
max_stages = 5
@@ -38,4 +39,46 @@
if(prob(50))
affected_mob.gib()
else
=======
/datum/disease/gbs
name = "GBS"
max_stages = 5
spread_text = "On contact"
spread_flags = VIRUS_SPREAD_BLOOD | VIRUS_SPREAD_CONTACT_SKIN | VIRUS_SPREAD_CONTACT_FLUIDS
cure_text = "Synaptizine & Sulfur"
cures = list("synaptizine","sulfur")
cure_chance = 15//higher chance to cure, since two reagents are required
agent = "Gravitokinetic Bipotential SADS+"
viable_mobtypes = list(/mob/living/carbon/human)
disease_flags = CAN_CARRY|CAN_RESIST|CURABLE
permeability_mod = 1
severity = VIRUS_SEVERITY_BIOHAZARD
/datum/disease/gbs/stage_act()
..()
switch(stage)
if(2)
if(prob(45))
affected_mob.adjustToxLoss(5)
affected_mob.updatehealth()
if(prob(1))
affected_mob.emote("sneeze")
if(3)
if(prob(5))
affected_mob.emote("cough")
else if(prob(5))
affected_mob.emote("gasp")
if(prob(10))
to_chat(affected_mob, "<span class='danger'>You're starting to feel very weak...</span>")
if(4)
if(prob(10))
affected_mob.emote("cough")
affected_mob.adjustToxLoss(5)
affected_mob.updatehealth()
if(5)
to_chat(affected_mob, "<span class='danger'>Your body feels as if it's trying to rip itself open...</span>")
if(prob(50))
affected_mob.gib()
else
>>>>>>> db0c10e... Refactors virus spreading (#31066)
return

View File

@@ -1,3 +1,4 @@
<<<<<<< HEAD
/datum/disease/magnitis
name = "Magnitis"
max_stages = 4
@@ -19,6 +20,29 @@
to_chat(affected_mob, "<span class='danger'>You feel a slight shock course through your body.</span>")
if(prob(2))
for(var/obj/M in orange(2,affected_mob))
=======
/datum/disease/magnitis
name = "Magnitis"
max_stages = 4
spread_text = "Airborne"
cure_text = "Iron"
cures = list("iron")
agent = "Fukkos Miracos"
viable_mobtypes = list(/mob/living/carbon/human)
disease_flags = CAN_CARRY|CAN_RESIST|CURABLE
permeability_mod = 0.75
desc = "This disease disrupts the magnetic field of your body, making it act as if a powerful magnet. Injections of iron help stabilize the field."
severity = VIRUS_SEVERITY_MEDIUM
/datum/disease/magnitis/stage_act()
..()
switch(stage)
if(2)
if(prob(2))
to_chat(affected_mob, "<span class='danger'>You feel a slight shock course through your body.</span>")
if(prob(2))
for(var/obj/M in orange(2,affected_mob))
>>>>>>> db0c10e... Refactors virus spreading (#31066)
if(!M.anchored && (M.flags_1 & CONDUCT_1))
step_towards(M,affected_mob)
for(var/mob/living/silicon/S in orange(2,affected_mob))

View File

@@ -2,7 +2,7 @@
name = "Parrot Possession"
max_stages = 1
spread_text = "Paranormal"
spread_flags = SPECIAL
spread_flags = VIRUS_SPREAD_SPECIAL
disease_flags = CURABLE
cure_text = "Holy Water."
cures = list("holywater")
@@ -10,7 +10,7 @@
agent = "Avian Vengence"
viable_mobtypes = list(/mob/living/carbon/human)
desc = "Subject is possesed by the vengeful spirit of a parrot. Call the priest."
severity = MEDIUM
severity = VIRUS_SEVERITY_MEDIUM
var/mob/living/simple_animal/parrot/Poly/ghost/parrot
/datum/disease/parrot_possession/stage_act()

View File

@@ -1,3 +1,4 @@
<<<<<<< HEAD
/datum/disease/pierrot_throat
name = "Pierrot's Throat"
max_stages = 4
@@ -22,3 +23,33 @@
if(prob(10)) to_chat(affected_mob, "<span class='danger'>Your thoughts are interrupted by a loud <b>HONK!</b></span>")
if(4)
if(prob(5)) affected_mob.say( pick( list("HONK!", "Honk!", "Honk.", "Honk?", "Honk!!", "Honk?!", "Honk...") ) )
=======
/datum/disease/pierrot_throat
name = "Pierrot's Throat"
max_stages = 4
spread_text = "Airborne"
cure_text = "Banana products, especially banana bread."
cures = list("banana")
cure_chance = 75
agent = "H0NI<42 Virus"
viable_mobtypes = list(/mob/living/carbon/human)
permeability_mod = 0.75
desc = "If left untreated the subject will probably drive others to insanity."
severity = VIRUS_SEVERITY_MEDIUM
/datum/disease/pierrot_throat/stage_act()
..()
switch(stage)
if(1)
if(prob(10))
to_chat(affected_mob, "<span class='danger'>You feel a little silly.</span>")
if(2)
if(prob(10))
to_chat(affected_mob, "<span class='danger'>You start seeing rainbows.</span>")
if(3)
if(prob(10))
to_chat(affected_mob, "<span class='danger'>Your thoughts are interrupted by a loud <b>HONK!</b></span>")
if(4)
if(prob(5))
affected_mob.say( pick( list("HONK!", "Honk!", "Honk.", "Honk?", "Honk!!", "Honk?!", "Honk...") ) )
>>>>>>> db0c10e... Refactors virus spreading (#31066)

View File

@@ -1,3 +1,4 @@
<<<<<<< HEAD
/datum/disease/dna_retrovirus
name = "Retrovirus"
max_stages = 4
@@ -80,4 +81,88 @@
if(prob(50))
scramble_dna(affected_mob, 1, 0, rand(50,75))
else
=======
/datum/disease/dna_retrovirus
name = "Retrovirus"
max_stages = 4
spread_text = "Contact"
spread_flags = VIRUS_SPREAD_BLOOD | VIRUS_SPREAD_CONTACT_SKIN | VIRUS_SPREAD_CONTACT_FLUIDS
cure_text = "Rest or an injection of mutadone"
cure_chance = 6
agent = ""
viable_mobtypes = list(/mob/living/carbon/human)
desc = "A DNA-altering retrovirus that scrambles the structural and unique enzymes of a host constantly."
severity = VIRUS_SEVERITY_HARMFUL
permeability_mod = 0.4
stage_prob = 2
var/SE
var/UI
var/restcure = 0
/datum/disease/dna_retrovirus/New()
..()
agent = "Virus class [pick("A","B","C","D","E","F")][pick("A","B","C","D","E","F")]-[rand(50,300)]"
if(prob(40))
cures = list("mutadone")
else
restcure = 1
/datum/disease/dna_retrovirus/stage_act()
..()
switch(stage)
if(1)
if(restcure)
if(affected_mob.lying && prob(30))
to_chat(affected_mob, "<span class='notice'>You feel better.</span>")
cure()
return
if (prob(8))
to_chat(affected_mob, "<span class='danger'>Your head hurts.</span>")
if (prob(9))
to_chat(affected_mob, "You feel a tingling sensation in your chest.")
if (prob(9))
to_chat(affected_mob, "<span class='danger'>You feel angry.</span>")
if(2)
if(restcure)
if(affected_mob.lying && prob(20))
to_chat(affected_mob, "<span class='notice'>You feel better.</span>")
cure()
return
if (prob(8))
to_chat(affected_mob, "<span class='danger'>Your skin feels loose.</span>")
if (prob(10))
to_chat(affected_mob, "You feel very strange.")
if (prob(4))
to_chat(affected_mob, "<span class='danger'>You feel a stabbing pain in your head!</span>")
affected_mob.Unconscious(40)
if (prob(4))
to_chat(affected_mob, "<span class='danger'>Your stomach churns.</span>")
if(3)
if(restcure)
if(affected_mob.lying && prob(20))
to_chat(affected_mob, "<span class='notice'>You feel better.</span>")
cure()
return
if (prob(10))
to_chat(affected_mob, "<span class='danger'>Your entire body vibrates.</span>")
if (prob(35))
if(prob(50))
scramble_dna(affected_mob, 1, 0, rand(15,45))
else
scramble_dna(affected_mob, 0, 1, rand(15,45))
if(4)
if(restcure)
if(affected_mob.lying && prob(5))
to_chat(affected_mob, "<span class='notice'>You feel better.</span>")
cure()
return
if (prob(60))
if(prob(50))
scramble_dna(affected_mob, 1, 0, rand(50,75))
else
>>>>>>> db0c10e... Refactors virus spreading (#31066)
scramble_dna(affected_mob, 0, 1, rand(50,75))

View File

@@ -1,3 +1,4 @@
<<<<<<< HEAD
/datum/disease/rhumba_beat
name = "The Rhumba Beat"
max_stages = 5
@@ -13,6 +14,23 @@
/datum/disease/rhumba_beat/stage_act()
..()
if(affected_mob.ckey == "rosham")
=======
/datum/disease/rhumba_beat
name = "The Rhumba Beat"
max_stages = 5
spread_text = "On contact"
spread_flags = VIRUS_SPREAD_BLOOD | VIRUS_SPREAD_CONTACT_SKIN | VIRUS_SPREAD_CONTACT_FLUIDS
cure_text = "Chick Chicky Boom!"
cures = list("plasma")
agent = "Unknown"
viable_mobtypes = list(/mob/living/carbon/human)
permeability_mod = 1
severity = VIRUS_SEVERITY_BIOHAZARD
/datum/disease/rhumba_beat/stage_act()
..()
if(affected_mob.ckey == "rosham")
>>>>>>> db0c10e... Refactors virus spreading (#31066)
cure()
return
switch(stage)

View File

@@ -1,3 +1,4 @@
<<<<<<< HEAD
/datum/disease/transformation
name = "Transformation"
max_stages = 5
@@ -239,3 +240,247 @@
stage4 = list("<span class='danger'>You're ravenous.</span>")
stage5 = list("<span class='danger'>You have become a morph.</span>")
new_form = /mob/living/simple_animal/hostile/morph
=======
/datum/disease/transformation
name = "Transformation"
max_stages = 5
spread_text = "Acute"
spread_flags = VIRUS_SPREAD_SPECIAL
cure_text = "A coder's love (theoretical)."
agent = "Shenanigans"
viable_mobtypes = list(/mob/living/carbon/human, /mob/living/carbon/monkey, /mob/living/carbon/alien)
severity = VIRUS_SEVERITY_BIOHAZARD
stage_prob = 10
visibility_flags = HIDDEN_SCANNER|HIDDEN_PANDEMIC
disease_flags = CURABLE
var/list/stage1 = list("You feel unremarkable.")
var/list/stage2 = list("You feel boring.")
var/list/stage3 = list("You feel utterly plain.")
var/list/stage4 = list("You feel white bread.")
var/list/stage5 = list("Oh the humanity!")
var/new_form = /mob/living/carbon/human
/datum/disease/transformation/stage_act()
..()
switch(stage)
if(1)
if (prob(stage_prob) && stage1)
to_chat(affected_mob, pick(stage1))
if(2)
if (prob(stage_prob) && stage2)
to_chat(affected_mob, pick(stage2))
if(3)
if (prob(stage_prob*2) && stage3)
to_chat(affected_mob, pick(stage3))
if(4)
if (prob(stage_prob*2) && stage4)
to_chat(affected_mob, pick(stage4))
if(5)
do_disease_transformation(affected_mob)
/datum/disease/transformation/proc/do_disease_transformation(mob/living/affected_mob)
if(istype(affected_mob, /mob/living/carbon) && affected_mob.stat != DEAD)
if(stage5)
to_chat(affected_mob, pick(stage5))
if(jobban_isbanned(affected_mob, new_form))
affected_mob.death(1)
return
if(affected_mob.notransform)
return
affected_mob.notransform = 1
for(var/obj/item/W in affected_mob.get_equipped_items())
affected_mob.dropItemToGround(W)
for(var/obj/item/I in affected_mob.held_items)
affected_mob.dropItemToGround(I)
var/mob/living/new_mob = new new_form(affected_mob.loc)
if(istype(new_mob))
new_mob.a_intent = INTENT_HARM
if(affected_mob.mind)
affected_mob.mind.transfer_to(new_mob)
else
new_mob.key = affected_mob.key
new_mob.name = affected_mob.real_name
new_mob.real_name = new_mob.name
qdel(affected_mob)
/datum/disease/transformation/jungle_fever
name = "Jungle Fever"
cure_text = "Bananas"
cures = list("banana")
spread_text = "Monkey Bites"
spread_flags = VIRUS_SPREAD_SPECIAL
viable_mobtypes = list(/mob/living/carbon/monkey, /mob/living/carbon/human)
permeability_mod = 1
cure_chance = 1
disease_flags = CAN_CARRY|CAN_RESIST
desc = "Monkeys with this disease will bite humans, causing humans to mutate into a monkey."
severity = VIRUS_SEVERITY_BIOHAZARD
stage_prob = 4
visibility_flags = 0
agent = "Kongey Vibrion M-909"
new_form = /mob/living/carbon/monkey
stage1 = null
stage2 = null
stage3 = null
stage4 = list("<span class='warning'>Your back hurts.</span>", "<span class='warning'>You breathe through your mouth.</span>",
"<span class='warning'>You have a craving for bananas.</span>", "<span class='warning'>Your mind feels clouded.</span>")
stage5 = list("<span class='warning'>You feel like monkeying around.</span>")
/datum/disease/transformation/jungle_fever/do_disease_transformation(mob/living/carbon/affected_mob)
if(!ismonkey(affected_mob))
SSticker.mode.add_monkey(affected_mob.mind)
affected_mob.monkeyize(TR_KEEPITEMS | TR_KEEPIMPLANTS | TR_KEEPORGANS | TR_KEEPDAMAGE | TR_KEEPVIRUS | TR_KEEPSE)
/datum/disease/transformation/jungle_fever/stage_act()
..()
switch(stage)
if(2)
if(prob(2))
to_chat(affected_mob, "<span class='notice'>Your [pick("back", "arm", "leg", "elbow", "head")] itches.</span>")
if(3)
if(prob(4))
to_chat(affected_mob, "<span class='danger'>You feel a stabbing pain in your head.</span>")
affected_mob.confused += 10
if(4)
if(prob(3))
affected_mob.say(pick("Eeek, ook ook!", "Eee-eeek!", "Eeee!", "Ungh, ungh."))
/datum/disease/transformation/jungle_fever/cure()
SSticker.mode.remove_monkey(affected_mob.mind)
..()
/datum/disease/transformation/robot
name = "Robotic Transformation"
cure_text = "An injection of copper."
cures = list("copper")
cure_chance = 5
agent = "R2D2 Nanomachines"
desc = "This disease, actually acute nanomachine infection, converts the victim into a cyborg."
severity = VIRUS_SEVERITY_BIOHAZARD
visibility_flags = 0
stage1 = null
stage2 = list("Your joints feel stiff.", "<span class='danger'>Beep...boop..</span>")
stage3 = list("<span class='danger'>Your joints feel very stiff.</span>", "Your skin feels loose.", "<span class='danger'>You can feel something move...inside.</span>")
stage4 = list("<span class='danger'>Your skin feels very loose.</span>", "<span class='danger'>You can feel... something...inside you.</span>")
stage5 = list("<span class='danger'>Your skin feels as if it's about to burst off!</span>")
new_form = /mob/living/silicon/robot
/datum/disease/transformation/robot/stage_act()
..()
switch(stage)
if(3)
if (prob(8))
affected_mob.say(pick("Beep, boop", "beep, beep!", "Boop...bop"))
if (prob(4))
to_chat(affected_mob, "<span class='danger'>You feel a stabbing pain in your head.</span>")
affected_mob.Unconscious(40)
if(4)
if (prob(20))
affected_mob.say(pick("beep, beep!", "Boop bop boop beep.", "kkkiiiill mmme", "I wwwaaannntt tttoo dddiiieeee..."))
/datum/disease/transformation/xeno
name = "Xenomorph Transformation"
cure_text = "Spaceacillin & Glycerol"
cures = list("spaceacillin", "glycerol")
cure_chance = 5
agent = "Rip-LEY Alien Microbes"
desc = "This disease changes the victim into a xenomorph."
severity = VIRUS_SEVERITY_BIOHAZARD
visibility_flags = 0
stage1 = null
stage2 = list("Your throat feels scratchy.", "<span class='danger'>Kill...</span>")
stage3 = list("<span class='danger'>Your throat feels very scratchy.</span>", "Your skin feels tight.", "<span class='danger'>You can feel something move...inside.</span>")
stage4 = list("<span class='danger'>Your skin feels very tight.</span>", "<span class='danger'>Your blood boils!</span>", "<span class='danger'>You can feel... something...inside you.</span>")
stage5 = list("<span class='danger'>Your skin feels as if it's about to burst off!</span>")
new_form = /mob/living/carbon/alien/humanoid/hunter
/datum/disease/transformation/xeno/stage_act()
..()
switch(stage)
if(3)
if (prob(4))
to_chat(affected_mob, "<span class='danger'>You feel a stabbing pain in your head.</span>")
affected_mob.Unconscious(40)
if(4)
if (prob(20))
affected_mob.say(pick("You look delicious.", "Going to... devour you...", "Hsssshhhhh!"))
/datum/disease/transformation/slime
name = "Advanced Mutation Transformation"
cure_text = "frost oil"
cures = list("frostoil")
cure_chance = 80
agent = "Advanced Mutation Toxin"
desc = "This highly concentrated extract converts anything into more of itself."
severity = VIRUS_SEVERITY_BIOHAZARD
visibility_flags = 0
stage1 = list("You don't feel very well.")
stage2 = list("Your skin feels a little slimy.")
stage3 = list("<span class='danger'>Your appendages are melting away.</span>", "<span class='danger'>Your limbs begin to lose their shape.</span>")
stage4 = list("<span class='danger'>You are turning into a slime.</span>")
stage5 = list("<span class='danger'>You have become a slime.</span>")
new_form = /mob/living/simple_animal/slime/random
/datum/disease/transformation/slime/stage_act()
..()
switch(stage)
if(1)
if(ishuman(affected_mob) && affected_mob.dna && affected_mob.dna.species.id == "slime")
stage = 5
if(3)
if(ishuman(affected_mob))
var/mob/living/carbon/human/human = affected_mob
if(human.dna.species.id != "slime")
human.set_species(/datum/species/jelly/slime)
/datum/disease/transformation/corgi
name = "The Barkening"
cure_text = "Death"
cures = list("adminordrazine")
agent = "Fell Doge Majicks"
desc = "This disease transforms the victim into a corgi."
severity = VIRUS_SEVERITY_BIOHAZARD
visibility_flags = 0
stage1 = list("BARK.")
stage2 = list("You feel the need to wear silly hats.")
stage3 = list("<span class='danger'>Must... eat... chocolate....</span>", "<span class='danger'>YAP</span>")
stage4 = list("<span class='danger'>Visions of washing machines assail your mind!</span>")
stage5 = list("<span class='danger'>AUUUUUU!!!</span>")
new_form = /mob/living/simple_animal/pet/dog/corgi
/datum/disease/transformation/corgi/stage_act()
..()
switch(stage)
if(3)
if (prob(8))
affected_mob.say(pick("YAP", "Woof!"))
if(4)
if (prob(20))
affected_mob.say(pick("Bark!", "AUUUUUU"))
/datum/disease/transformation/morph
name = "Gluttony's Blessing"
cure_text = "nothing"
cures = list("adminordrazine")
agent = "Gluttony's Blessing"
desc = "A 'gift' from somewhere terrible."
stage_prob = 20
severity = VIRUS_SEVERITY_BIOHAZARD
visibility_flags = 0
stage1 = list("Your stomach rumbles.")
stage2 = list("Your skin feels saggy.")
stage3 = list("<span class='danger'>Your appendages are melting away.</span>", "<span class='danger'>Your limbs begin to lose their shape.</span>")
stage4 = list("<span class='danger'>You're ravenous.</span>")
stage5 = list("<span class='danger'>You have become a morph.</span>")
new_form = /mob/living/simple_animal/hostile/morph
>>>>>>> db0c10e... Refactors virus spreading (#31066)

View File

@@ -10,7 +10,7 @@
cure_chance = 5//like hell are you getting out of hell
desc = "A rare highly transmittable virulent virus. Few samples exist, rumoured to be carefully grown and cultured by clandestine bio-weapon specialists. Causes fever, blood vomiting, lung damage, weight loss, and fatigue."
required_organs = list(/obj/item/organ/lungs)
severity = DANGEROUS
severity = VIRUS_SEVERITY_BIOHAZARD
bypasses_immunity = TRUE // TB primarily impacts the lungs; it's also bacterial or fungal in nature; viral immunity should do nothing.
/datum/disease/tuberculosis/stage_act() //it begins

View File

@@ -10,7 +10,7 @@
disease_flags = CAN_CARRY|CAN_RESIST|CURABLE
permeability_mod = 0.75
desc = "Some speculate that this virus is the cause of the Space Wizard Federation's existence. Subjects affected show the signs of mental retardation, yelling obscure sentences or total gibberish. On late stages subjects sometime express the feelings of inner power, and, cite, 'the ability to control the forces of cosmos themselves!' A gulp of strong, manly spirits usually reverts them to normal, humanlike, condition."
severity = HARMFUL
severity = VIRUS_SEVERITY_HARMFUL
required_organs = list(/obj/item/bodypart/head)
/*

View File

@@ -412,10 +412,10 @@ GLOBAL_LIST_EMPTY(blood_splatter_icons)
. = ..()
transfer_blood = rand(2, 4)
/turf/add_blood(list/blood_dna)
/turf/add_blood(list/blood_dna, list/datum/disease/diseases)
var/obj/effect/decal/cleanable/blood/splatter/B = locate() in src
if(!B)
B = new /obj/effect/decal/cleanable/blood/splatter(src)
B = new /obj/effect/decal/cleanable/blood/splatter(src, diseases)
B.transfer_blood_dna(blood_dna) //give blood info to the blood decal.
return 1 //we bloodied the floor
@@ -524,7 +524,7 @@ GLOBAL_LIST_EMPTY(blood_splatter_icons)
/atom/proc/add_vomit_floor(mob/living/carbon/M, toxvomit = 0)
if(isturf(src))
var/obj/effect/decal/cleanable/vomit/V = new /obj/effect/decal/cleanable/vomit(src)
var/obj/effect/decal/cleanable/vomit/V = new /obj/effect/decal/cleanable/vomit(src, M.get_static_viruses())
// Make toxins vomit look different
if(toxvomit)
V.icon_state = "vomittox_[pick(1,4)]"

View File

@@ -61,16 +61,12 @@
//called when a carbon changes virus
/mob/living/carbon/proc/check_virus()
var/threat = 0
var/threat
for(var/thing in viruses)
var/datum/disease/D = thing
if(!(D.visibility_flags & HIDDEN_SCANNER))
if (D.severity != NONTHREAT) //a buffing virus gets an icon
threat = 2
return threat //harmful viruses have priority
else
threat = 1 //aka good virus
if(!threat || D.severity > threat) //a buffing virus gets an icon
threat = D.severity
return threat
//helper for getting the appropriate health status
@@ -162,21 +158,44 @@
/mob/living/carbon/med_hud_set_status()
var/image/holder = hud_list[STATUS_HUD]
var/icon/I = icon(icon, icon_state, dir)
<<<<<<< HEAD
var/virus_state = check_virus()
var/mob/living/simple_animal/borer/B = has_brain_worms()
=======
var/virus_threat = check_virus()
>>>>>>> db0c10e... Refactors virus spreading (#31066)
holder.pixel_y = I.Height() - world.icon_size
if(status_flags & XENO_HOST)
holder.icon_state = "hudxeno"
else if(stat == DEAD || (status_flags & FAKEDEATH))
holder.icon_state = "huddead"
<<<<<<< HEAD
else if(has_brain_worms() && B != null && B.controlling)
holder.icon_state = "hudbrainworm"
else if(virus_state == 2)
holder.icon_state = "hudill"
else if(virus_state == 1)
holder.icon_state = "hudbuff"
=======
>>>>>>> db0c10e... Refactors virus spreading (#31066)
else
holder.icon_state = "hudhealthy"
switch(virus_threat)
if(VIRUS_SEVERITY_BIOHAZARD)
holder.icon_state = "hudill5"
if(VIRUS_SEVERITY_DANGEROUS)
holder.icon_state = "hudill4"
if(VIRUS_SEVERITY_HARMFUL)
holder.icon_state = "hudill3"
if(VIRUS_SEVERITY_MEDIUM)
holder.icon_state = "hudill2"
if(VIRUS_SEVERITY_MINOR)
holder.icon_state = "hudill1"
if(VIRUS_SEVERITY_NONTHREAT)
holder.icon_state = "hudill0"
if(VIRUS_SEVERITY_POSITIVE)
holder.icon_state = "hudbuff"
if(null)
holder.icon_state = "hudhealthy"
/***********************************************

View File

@@ -43,7 +43,7 @@
for(var/thing in user.viruses)
var/datum/disease/D = thing
if(D.severity == NONTHREAT)
if(D.severity == VIRUS_SEVERITY_POSITIVE)
continue
D.cure()
return TRUE

View File

@@ -2,7 +2,7 @@
name = "Unnatural Wasting"
max_stages = 5
stage_prob = 10
spread_flags = NON_CONTAGIOUS
spread_flags = VIRUS_SPREAD_NON_CONTAGIOUS
cure_text = "Holy water or extensive rest."
spread_text = "A burst of unholy energy"
cures = list("holywater")
@@ -11,7 +11,7 @@
viable_mobtypes = list(/mob/living/carbon/human)
disease_flags = CURABLE
permeability_mod = 1
severity = BIOHAZARD
severity = VIRUS_SEVERITY_HARMFUL
var/stagedamage = 0 //Highest stage reached.
var/finalstage = 0 //Because we're spawning off the cure in the final stage, we need to check if we've done the final stage's effects.

View File

@@ -6,7 +6,7 @@
var/bloodiness = 0 //0-100, amount of blood in this decal, used for making footprints and affecting the alpha of bloody footprints
var/mergeable_decal = 1 //when two of these are on a same tile or do we need to merge them into just one?
/obj/effect/decal/cleanable/Initialize(mapload)
/obj/effect/decal/cleanable/Initialize(mapload, list/datum/disease/diseases)
if (random_icon_states && length(src.random_icon_states) > 0)
src.icon_state = pick(src.random_icon_states)
create_reagents(300)
@@ -14,10 +14,15 @@
for(var/obj/effect/decal/cleanable/C in src.loc)
if(C != src && C.type == src.type)
replace_decal(C)
if(LAZYLEN(diseases))
var/list/datum/disease/diseases_to_add = list()
for(var/datum/disease/D in diseases)
if(D.spread_flags & VIRUS_SPREAD_CONTACT_FLUIDS)
diseases_to_add += D
if(LAZYLEN(diseases_to_add))
AddComponent(/datum/component/infective, diseases_to_add)
. = ..()
/obj/effect/decal/cleanable/proc/replace_decal(obj/effect/decal/cleanable/C)
if(mergeable_decal)
qdel(C)
@@ -65,6 +70,7 @@
//Add "bloodiness" of this blood's type, to the human's shoes
//This is on /cleanable because fuck this ancient mess
/obj/effect/decal/cleanable/Crossed(atom/movable/O)
..()
if(ishuman(O))
var/mob/living/carbon/human/H = O
if(H.shoes && blood_state && bloodiness)

View File

@@ -18,7 +18,7 @@
desc = "Looks like it's been here a while. Eew."
bloodiness = 0
/obj/effect/decal/cleanable/blood/old/Initialize()
/obj/effect/decal/cleanable/blood/old/Initialize(mapload, list/datum/disease/diseases)
. = ..()
icon_state += "-old" //This IS necessary because the parent /blood type uses icon randomization.
blood_DNA["Non-human DNA"] = "A+"
@@ -39,7 +39,6 @@
var/list/existing_dirs = list()
blood_DNA = list()
/obj/effect/decal/cleanable/trail_holder/can_bloodcrawl_in()
return 1
@@ -53,7 +52,7 @@
random_icon_states = list("gib1", "gib2", "gib3", "gib4", "gib5", "gib6")
mergeable_decal = 0
/obj/effect/decal/cleanable/blood/gibs/Initialize()
/obj/effect/decal/cleanable/blood/gibs/Initialize(mapload, list/datum/disease/diseases)
. = ..()
reagents.add_reagent("liquidgibs", 5)
@@ -66,7 +65,11 @@
for(var/i = 0, i < pick(1, 200; 2, 150; 3, 50), i++)
sleep(2)
if(i > 0)
new /obj/effect/decal/cleanable/blood/splatter(loc)
var/list/datum/disease/diseases
GET_COMPONENT(infective, /datum/component/infective)
if(infective)
diseases = infective.diseases
new /obj/effect/decal/cleanable/blood/splatter(loc, diseases)
if(!step_to(src, get_step(src, direction), 0))
break
@@ -93,7 +96,7 @@
desc = "Space Jesus, why didn't anyone clean this up? It smells terrible."
bloodiness = 0
/obj/effect/decal/cleanable/blood/gibs/old/Initialize()
/obj/effect/decal/cleanable/blood/gibs/old/Initialize(mapload, list/datum/disease/diseases)
. = ..()
setDir(pick(1,2,4,8))
icon_state += "-old"
@@ -126,6 +129,7 @@
var/list/shoe_types = list()
/obj/effect/decal/cleanable/blood/footprints/Crossed(atom/movable/O)
..()
if(ishuman(O))
var/mob/living/carbon/human/H = O
var/obj/item/clothing/shoes/S = H.shoes
@@ -136,6 +140,7 @@
update_icon()
/obj/effect/decal/cleanable/blood/footprints/Uncrossed(atom/movable/O)
..()
if(ishuman(O))
var/mob/living/carbon/human/H = O
var/obj/item/clothing/shoes/S = H.shoes

View File

@@ -101,7 +101,7 @@
name = "crusty dried vomit"
desc = "You try not to look at the chunks, and fail."
/obj/effect/decal/cleanable/vomit/old/Initialize()
/obj/effect/decal/cleanable/vomit/old/Initialize(mapload, list/datum/disease/diseases)
. = ..()
icon_state += "-old"

View File

@@ -6,7 +6,7 @@
var/list/gibamounts = list() //amount to spawn for each gib decal type we'll spawn.
var/list/gibdirections = list() //of lists of possible directions to spread each gib decal type towards.
/obj/effect/gibspawner/Initialize(mapload, datum/dna/MobDNA)
/obj/effect/gibspawner/Initialize(mapload, datum/dna/MobDNA, list/datum/disease/diseases)
. = ..()
if(gibtypes.len != gibamounts.len || gibamounts.len != gibdirections.len)
@@ -24,7 +24,7 @@
if(gibamounts[i])
for(var/j = 1, j<= gibamounts[i], j++)
var/gibType = gibtypes[i]
gib = new gibType(loc)
gib = new gibType(loc, diseases)
if(iscarbon(loc))
var/mob/living/carbon/digester = loc
digester.stomach_contents += gib

View File

@@ -5,6 +5,7 @@
var/magboot_state = "magboots"
var/magpulse = 0
var/slowdown_active = 2
permeability_coefficient = 0.05
actions_types = list(/datum/action/item_action/toggle)
strip_delay = 70
equip_delay_other = 70

View File

@@ -23,6 +23,7 @@
armor = list(melee = 25, bullet = 25, laser = 25, energy = 25, bomb = 50, bio = 10, rad = 0, fire = 70, acid = 50)
strip_delay = 70
resistance_flags = 0
permeability_coefficient = 0.05 //Thick soles, and covers the ankle
pockets = /obj/item/storage/internal/pocket/shoes
/obj/item/clothing/shoes/combat/swat //overpowered boots for death squads
@@ -38,6 +39,7 @@
icon_state = "wizard"
strip_delay = 50
equip_delay_other = 50
permeability_coefficient = 0.9
/obj/item/clothing/shoes/sandal/marisa
desc = "A pair of magic black shoes."
@@ -54,7 +56,7 @@
desc = "A pair of yellow rubber boots, designed to prevent slipping on wet surfaces."
name = "galoshes"
icon_state = "galoshes"
permeability_coefficient = 0.05
permeability_coefficient = 0.01
flags_1 = NOSLIP_1
slowdown = SHOES_SLOWDOWN+1
strip_delay = 50
@@ -102,6 +104,7 @@
strip_delay = 50
equip_delay_other = 50
resistance_flags = 0
permeability_coefficient = 0.05 //Thick soles, and covers the ankle
pockets = /obj/item/storage/internal/pocket/shoes
/obj/item/clothing/shoes/jackboots/fast
@@ -112,6 +115,7 @@
desc = "Boots lined with 'synthetic' animal fur."
icon_state = "winterboots"
item_state = "winterboots"
permeability_coefficient = 0.15
cold_protection = FEET|LEGS
min_cold_protection_temperature = SHOES_MIN_TEMP_PROTECT
heat_protection = FEET|LEGS
@@ -125,6 +129,7 @@
item_state = "jackboots"
lefthand_file = 'icons/mob/inhands/equipment/security_lefthand.dmi'
righthand_file = 'icons/mob/inhands/equipment/security_righthand.dmi'
permeability_coefficient = 0.15
strip_delay = 40
equip_delay_other = 40
pockets = /obj/item/storage/internal/pocket/shoes
@@ -171,6 +176,7 @@
item_state = "roman"
strip_delay = 100
equip_delay_other = 100
permeability_coefficient = 0.9
/obj/item/clothing/shoes/griffin
name = "griffon boots"
@@ -188,6 +194,7 @@
resistance_flags = FIRE_PROOF
pockets = /obj/item/storage/internal/pocket/shoes
actions_types = list(/datum/action/item_action/bhop)
permeability_coefficient = 0.05
var/jumpdistance = 5 //-1 from to see the actual distance, e.g 4 goes over 3 tiles
var/jumpspeed = 3
var/recharging_rate = 60 //default 6 seconds between each dash

View File

@@ -869,7 +869,12 @@
var/obj/item/device/flightpack/pack = null
var/mob/living/carbon/human/wearer = null
var/active = FALSE
<<<<<<< HEAD
resistance_flags = FIRE_PROOF
=======
permeability_coefficient = 0.01
resistance_flags = FIRE_PROOF | ACID_PROOF
>>>>>>> db0c10e... Refactors virus spreading (#31066)
/obj/item/clothing/shoes/flightshoes/Destroy()
pack = null

View File

@@ -147,6 +147,7 @@
var/obj/item/reagent_containers/food/snacks/meat/slab/allmeat[meat_produced]
var/obj/item/stack/sheet/animalhide/skin
var/list/datum/disease/diseases = mob_occupant.get_static_viruses()
if(ishuman(occupant))
var/mob/living/carbon/human/gibee = occupant
@@ -180,26 +181,28 @@
mob_occupant.death(1)
mob_occupant.ghostize()
qdel(src.occupant)
spawn(src.gibtime)
playsound(src.loc, 'sound/effects/splat.ogg', 50, 1)
operating = FALSE
var/turf/T = get_turf(src)
var/list/turf/nearby_turfs = RANGE_TURFS(3,T) - T
if(skin)
skin.forceMove(loc)
skin.throw_at(pick(nearby_turfs),meat_produced,3)
for (var/i=1 to meat_produced)
var/obj/item/meatslab = allmeat[i]
meatslab.forceMove(loc)
meatslab.throw_at(pick(nearby_turfs),i,3)
for (var/turfs=1 to meat_produced)
var/turf/gibturf = pick(nearby_turfs)
if (!gibturf.density && src in view(gibturf))
new gibtype(gibturf,i)
addtimer(CALLBACK(src, .proc/make_meat, skin, allmeat, meat_produced, gibtype, diseases), gibtime)
pixel_x = initial(pixel_x) //return to its spot after shaking
operating = FALSE
update_icon()
/obj/machinery/gibber/proc/make_meat(obj/item/stack/sheet/animalhide/skin, list/obj/item/reagent_containers/food/snacks/meat/slab/allmeat, meat_produced, gibtype, list/datum/disease/diseases)
playsound(src.loc, 'sound/effects/splat.ogg', 50, 1)
operating = FALSE
var/turf/T = get_turf(src)
var/list/turf/nearby_turfs = RANGE_TURFS(3,T) - T
if(skin)
skin.forceMove(loc)
skin.throw_at(pick(nearby_turfs),meat_produced,3)
for (var/i=1 to meat_produced)
var/obj/item/meatslab = allmeat[i]
meatslab.forceMove(loc)
meatslab.throw_at(pick(nearby_turfs),i,3)
for (var/turfs=1 to meat_produced)
var/turf/gibturf = pick(nearby_turfs)
if (!gibturf.density && src in view(gibturf))
new gibtype(gibturf,i,diseases)
pixel_x = initial(pixel_x) //return to its spot after shaking
operating = FALSE
update_icon()
//auto-gibs anything that bumps into it
/obj/machinery/gibber/autogibber

View File

@@ -135,7 +135,7 @@
for(var/thing in O.viruses)
var/datum/disease/D = thing
if(!(D.spread_flags & SPECIAL))
if(!(D.spread_flags & VIRUS_SPREAD_SPECIAL))
B.data["viruses"] += D.Copy()
if(O.has_dna())
B.data["blood_DNA"] = O.dna.unique_enzymes

View File

@@ -846,7 +846,7 @@
agent = "dragon's blood"
desc = "What do dragons have to do with Space Station 13?"
stage_prob = 20
severity = BIOHAZARD
severity = VIRUS_SEVERITY_BIOHAZARD
visibility_flags = 0
stage1 = list("Your bones ache.")
stage2 = list("Your skin feels scaly.")

View File

@@ -139,7 +139,7 @@
if(blood_data["viruses"])
for(var/thing in blood_data["viruses"])
var/datum/disease/D = thing
if((D.spread_flags & SPECIAL) || (D.spread_flags & NON_CONTAGIOUS))
if((D.spread_flags & VIRUS_SPREAD_SPECIAL) || (D.spread_flags & VIRUS_SPREAD_NON_CONTAGIOUS))
continue
C.ForceContractDisease(D)
if(!(blood_data["blood_type"] in get_safe_blood(C.dna.blood_type)))
@@ -258,14 +258,14 @@
temp_blood_DNA |= drop.blood_DNA.Copy() //we transfer the dna from the drip to the splatter
qdel(drop)//the drip is replaced by a bigger splatter
else
drop = new(T)
drop = new(T, get_static_viruses())
drop.transfer_mob_blood_dna(src)
return
// Find a blood decal or create a new one.
var/obj/effect/decal/cleanable/blood/B = locate() in T
if(!B)
B = new /obj/effect/decal/cleanable/blood/splatter(T)
B = new /obj/effect/decal/cleanable/blood/splatter(T, get_static_viruses())
B.transfer_mob_blood_dna(src) //give blood info to the blood decal.
if(temp_blood_DNA)
B.blood_DNA |= temp_blood_DNA

View File

@@ -756,7 +756,7 @@
B.damaged_brain = 0
for(var/thing in viruses)
var/datum/disease/D = thing
if(D.severity != NONTHREAT)
if(D.severity != VIRUS_SEVERITY_POSITIVE)
D.cure(0)
if(admin_revive)
regenerate_limbs()

View File

@@ -113,13 +113,13 @@
for(var/thing in viruses)
var/datum/disease/D = thing
if(D.IsSpreadByTouch())
user.ContractDisease(D)
if(D.spread_flags & VIRUS_SPREAD_CONTACT_SKIN)
user.ContactContractDisease(D)
for(var/thing in user.viruses)
var/datum/disease/D = thing
if(D.IsSpreadByTouch())
ContractDisease(D)
if(D.spread_flags & VIRUS_SPREAD_CONTACT_SKIN)
ContactContractDisease(D)
if(lying && surgeries.len)
if(user.a_intent == INTENT_HELP)
@@ -132,13 +132,13 @@
/mob/living/carbon/attack_paw(mob/living/carbon/monkey/M)
for(var/thing in viruses)
var/datum/disease/D = thing
if(D.IsSpreadByTouch())
M.ContractDisease(D)
if(D.spread_flags & VIRUS_SPREAD_CONTACT_SKIN)
M.ContactContractDisease(D)
for(var/thing in M.viruses)
var/datum/disease/D = thing
if(D.IsSpreadByTouch())
ContractDisease(D)
if(D.spread_flags & VIRUS_SPREAD_CONTACT_SKIN)
ContactContractDisease(D)
if(M.a_intent == INTENT_HELP)
help_shake_act(M)

View File

@@ -6,9 +6,9 @@
/mob/living/carbon/human/spawn_gibs(with_bodyparts)
if(with_bodyparts)
new /obj/effect/gibspawner/human(get_turf(src), dna)
new /obj/effect/gibspawner/human(get_turf(src), dna, get_static_viruses())
else
new /obj/effect/gibspawner/humanbodypartless(get_turf(src), dna)
new /obj/effect/gibspawner/humanbodypartless(get_turf(src), dna, get_static_viruses())
/mob/living/carbon/human/spawn_dust(just_ash = FALSE)
if(just_ash)

View File

@@ -18,7 +18,7 @@
return
/mob/living/proc/spawn_gibs()
new /obj/effect/gibspawner/generic(get_turf(src))
new /obj/effect/gibspawner/generic(get_turf(src), null, get_static_viruses())
/mob/living/proc/spill_organs()
return

View File

@@ -108,6 +108,17 @@
//Even if we don't push/swap places, we "touched" them, so spread fire
spreadFire(M)
//Also diseases
for(var/thing in viruses)
var/datum/disease/D = thing
if(D.spread_flags & VIRUS_SPREAD_CONTACT_SKIN)
M.ContactContractDisease(D)
for(var/thing in M.viruses)
var/datum/disease/D = thing
if(D.spread_flags & VIRUS_SPREAD_CONTACT_SKIN)
ContactContractDisease(D)
if(now_pushing)
return 1
@@ -507,7 +518,7 @@
if((newdir in GLOB.cardinals) && (prob(50)))
newdir = turn(get_dir(target_turf, start), 180)
if(!blood_exists)
new /obj/effect/decal/cleanable/trail_holder(start)
new /obj/effect/decal/cleanable/trail_holder(start, get_static_viruses())
for(var/obj/effect/decal/cleanable/trail_holder/TH in start)
if((!(newdir in TH.existing_dirs) || trail_type == "trails_1" || trail_type == "trails_2") && TH.existing_dirs.len <= 16) //maximum amount of overlays is 16 (all light & heavy directions filled)

View File

@@ -376,8 +376,8 @@
var/datum/disease/D = thing
//the medibot can't detect viruses that are undetectable to Health Analyzers or Pandemic machines.
if(!(D.visibility_flags & HIDDEN_SCANNER || D.visibility_flags & HIDDEN_PANDEMIC) \
&& D.severity != NONTHREAT \
&& (D.stage > 1 || (D.spread_flags & AIRBORNE))) // medibot can't detect a virus in its initial stage unless it spreads airborne.
&& D.severity != VIRUS_SEVERITY_POSITIVE \
&& (D.stage > 1 || (D.spread_flags & VIRUS_SPREAD_AIRBORNE))) // medibot can't detect a virus in its initial stage unless it spreads airborne.
return 1 //STOP DISEASE FOREVER
return 0
@@ -428,8 +428,8 @@
var/datum/disease/D = thing
//detectable virus
if((!(D.visibility_flags & HIDDEN_SCANNER)) || (!(D.visibility_flags & HIDDEN_PANDEMIC)))
if(D.severity != NONTHREAT) //virus is harmful
if((D.stage > 1) || (D.spread_flags & AIRBORNE))
if(D.severity != VIRUS_SEVERITY_POSITIVE) //virus is harmful
if((D.stage > 1) || (D.spread_flags & VIRUS_SPREAD_AIRBORNE))
virus = 1
if(!reagent_id && (virus))

View File

@@ -1000,7 +1000,7 @@
var/datum/disease/parrot_possession/P = new
P.parrot = src
loc = H
H.ContractDisease(P)
H.ForceContractDisease(P)
parrot_interest = null
H.visible_message("<span class='danger'>[src] dive bombs into [H]'s chest and vanishes!</span>", "<span class='userdanger'>[src] dive bombs into your chest, vanishing! This can't be good!</span>")

View File

@@ -336,6 +336,18 @@
if(ismob(AM))
var/mob/M = AM
//Share diseases that are spread by touch
for(var/thing in viruses)
var/datum/disease/D = thing
if(D.spread_flags & VIRUS_SPREAD_CONTACT_SKIN)
M.ContactContractDisease(D)
for(var/thing in M.viruses)
var/datum/disease/D = thing
if(D.spread_flags & VIRUS_SPREAD_CONTACT_SKIN)
ContactContractDisease(D)
add_logs(src, M, "grabbed", addition="passive grab")
if(!supress_message)
visible_message("<span class='warning'>[src] has grabbed [M] passively!</span>")
@@ -941,6 +953,16 @@
/mob/proc/get_idcard()
return
/mob/proc/get_static_viruses() //used when creating blood and other infective objects
if(!LAZYLEN(viruses))
return
var/list/datum/disease/diseases = list()
for(var/datum/disease/D in viruses)
var/static_virus = D.Copy()
diseases += static_virus
return diseases
/mob/vv_get_dropdown()
. = ..()
. += "---"

View File

@@ -61,7 +61,7 @@
M.jitteriness = 0
for(var/thing in M.viruses)
var/datum/disease/D = thing
if(D.severity == NONTHREAT)
if(D.severity == VIRUS_SEVERITY_POSITIVE)
continue
D.cure()
..()

View File

@@ -16,11 +16,11 @@
for(var/thing in data["viruses"])
var/datum/disease/D = thing
if((D.spread_flags & SPECIAL) || (D.spread_flags & NON_CONTAGIOUS))
if((D.spread_flags & VIRUS_SPREAD_SPECIAL) || (D.spread_flags & VIRUS_SPREAD_NON_CONTAGIOUS))
continue
if(method == TOUCH || method == VAPOR)
M.ContractDisease(D)
if((method == TOUCH || method == VAPOR) && (D.spread_flags & VIRUS_SPREAD_CONTACT_FLUIDS))
M.ContactContractDisease(D)
else //ingest, patch or inject
M.ForceContractDisease(D)
@@ -1058,7 +1058,7 @@
/datum/reagent/xenomicrobes/reaction_mob(mob/M, method=TOUCH, reac_volume, show_message = 1, touch_protection = 0)
if(method==PATCH || method==INGEST || method==INJECT || (method == VAPOR && prob(min(reac_volume,100)*(1 - touch_protection))))
M.ContractDisease(new /datum/disease/transformation/xeno(0))
M.ForceContractDisease(new /datum/disease/transformation/xeno(0))
/datum/reagent/fungalspores
name = "Tubercle bacillus Cosmosis microbes"

View File

@@ -37,6 +37,7 @@
#include "code\__DEFINES\construction.dm"
#include "code\__DEFINES\contracts.dm"
#include "code\__DEFINES\cult.dm"
#include "code\__DEFINES\diseases.dm"
#include "code\__DEFINES\DNA.dm"
#include "code\__DEFINES\events.dm"
#include "code\__DEFINES\flags.dm"
@@ -301,6 +302,7 @@
#include "code\datums\antagonists\ninja.dm"
#include "code\datums\components\_component.dm"
#include "code\datums\components\archaeology.dm"
#include "code\datums\components\infective.dm"
#include "code\datums\components\material_container.dm"
#include "code\datums\components\paintable.dm"
#include "code\datums\components\slippery.dm"