Fully Re-Activates Disease1

This commit is contained in:
Fox-McCloud
2016-03-30 22:31:59 -04:00
parent df30c7430a
commit 560eb17f9d
10 changed files with 119 additions and 114 deletions
+35
View File
@@ -0,0 +1,35 @@
/datum/event/disease_outbreak
announceWhen = 15
var/virus_type
/datum/event/disease_outbreak/setup()
announceWhen = rand(15, 30)
/datum/event/disease_outbreak/announce()
command_announcement.Announce("Confirmed outbreak of level 7 major viral biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", new_sound = 'sound/AI/outbreak7.ogg')
/datum/event/disease_outbreak/start()
if(!virus_type)
virus_type = pick(/datum/disease/advance/flu, /datum/disease/advance/cold, /datum/disease/brainrot, /datum/disease/magnitis)
for(var/mob/living/carbon/human/H in shuffle(living_mob_list))
if(issmall(H)) //don't infect monkies; that's a waste
continue
var/turf/T = get_turf(H)
if(!T)
continue
if(T.z != 1)
continue
var/foundAlready = 0 // don't infect someone that already has the virus
for(var/datum/disease/D in H.viruses)
foundAlready = 1
break
if(H.stat == DEAD || foundAlready)
continue
var/datum/disease/D
D = new virus_type()
D.carrier = 1
H.AddDisease(D)
break
+3 -1
View File
@@ -139,6 +139,7 @@ var/list/event_last_fired = list()
severity = EVENT_LEVEL_MODERATE
available_events = list(
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Nothing", /datum/event/nothing, 1230),
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Appendicitis", /datum/event/spontaneous_appendicitis, 0, list(ASSIGNMENT_MEDICAL = 10), 1),
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Carp School", /datum/event/carp_migration, 200, list(ASSIGNMENT_ENGINEER = 10, ASSIGNMENT_SECURITY = 20), 1),
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Rogue Drones", /datum/event/rogue_drone, 40, list(ASSIGNMENT_SECURITY = 20)),
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Space Vines", /datum/event/spacevine, 250, list(ASSIGNMENT_ENGINEER = 10)),
@@ -169,7 +170,8 @@ var/list/event_last_fired = list()
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Gravitational Anomaly", /datum/event/anomaly/anomaly_grav, 200),
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Revenant", /datum/event/revenant, 150),
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Swarmer Spawn", /datum/event/spawn_swarmer, 150, is_one_shot = 1),
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Morph Spawn", /datum/event/spawn_morph, 0, is_one_shot = 1)
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Morph Spawn", /datum/event/spawn_morph, 0, is_one_shot = 1),
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Disease Outbreak", /datum/event/disease_outbreak, 0, list(ASSIGNMENT_MEDICAL = 150), 1)
)
/datum/event_container/major
@@ -0,0 +1,13 @@
/datum/event/spontaneous_appendicitis/start()
for(var/mob/living/carbon/human/H in shuffle(living_mob_list))
if(issmall(H)) //don't infect monkies; that's a waste
continue
var/foundAlready = 0 //don't infect someone that already has the virus
for(var/datum/disease/D in H.viruses)
foundAlready = 1
if(H.stat == 2 || foundAlready)
continue
var/datum/disease/D = new /datum/disease/appendicitis
H.ForceContractDisease(D)
break
-29
View File
@@ -1,29 +0,0 @@
/datum/event/viral_infection
severity = 1
/datum/event/viral_infection/setup()
announceWhen = rand(0, 3000)
endWhen = announceWhen + 1
severity = rand(1, 3)
/datum/event/viral_infection/announce()
command_announcement.Announce("Confirmed outbreak of level 7 viral biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", new_sound = 'sound/AI/outbreak7.ogg')
/datum/event/viral_infection/start()
var/list/candidates = list() //list of candidate keys
for(var/mob/living/carbon/human/G in player_list)
if(G.client && G.stat != DEAD)
candidates += G
if(!candidates.len) return
candidates = shuffle(candidates)//Incorporating Donkie's list shuffle
var/datum/disease2/disease/D = new /datum/disease2/disease
D.makerandom()
D.infectionchance = 1
message_admins("Viral Infection: releasing strain [D.uniqueID]")
while(severity > 0 && candidates.len)
var/mob/living/carbon/human/H = candidates[1]
H.virus2["[D.uniqueID]"] = D
candidates.Remove(candidates[1])
severity--
-28
View File
@@ -1,28 +0,0 @@
/datum/event/viral_outbreak
severity = 1
/datum/event/viral_outbreak/setup()
announceWhen = rand(0, 3000)
endWhen = announceWhen + 1
severity = rand(2, 4)
/datum/event/viral_outbreak/announce()
command_announcement.Announce("Confirmed outbreak of level 7 major viral biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", new_sound = 'sound/AI/outbreak7.ogg')
/datum/event/viral_outbreak/start()
var/list/candidates = list() //list of candidate keys
for(var/mob/living/carbon/human/G in player_list)
if(G.client && G.stat != DEAD)
candidates += G
if(!candidates.len) return
candidates = shuffle(candidates)//Incorporating Donkie's list shuffle
var/datum/disease2/disease/D = new /datum/disease2/disease
D.makerandom()
message_admins("Viral Outbreak: releasing strain [D.uniqueID]")
while(severity > 0 && candidates.len)
var/mob/living/carbon/human/H = candidates[1]
H.virus2["[D.uniqueID]"] = D
candidates.Remove(candidates[1])
severity--
+63
View File
@@ -13,6 +13,69 @@
..()
/datum/reagent/nanomachines
name = "Nanomachines"
id = "nanomachines"
description = "Microscopic construction robots."
color = "#535E66" // rgb: 83, 94, 102
/datum/reagent/nanomachines/on_mob_life(var/mob/living/carbon/M as mob)
if(!M) M = holder.my_atom
if(volume > 1.5)
M.ForceContractDisease(new /datum/disease/transformation/robot(0))
..()
/datum/reagent/xenomicrobes
name = "Xenomicrobes"
id = "xenomicrobes"
description = "Microbes with an entirely alien cellular structure."
color = "#535E66" // rgb: 83, 94, 102
/datum/reagent/xenomicrobes/on_mob_life(var/mob/living/carbon/M as mob)
if(!M) M = holder.my_atom
if(volume > 1.5)
M.ContractDisease(new /datum/disease/transformation/xeno(0))
..()
/datum/reagent/fungalspores
name = "Tubercle bacillus Cosmosis microbes"
id = "fungalspores"
description = "Active fungal spores."
color = "#92D17D" // rgb: 146, 209, 125
/datum/reagent/fungalspores/on_mob_life(var/mob/living/carbon/M as mob)
if(!M) M = holder.my_atom
if(volume > 2.5)
M.ForceContractDisease(new /datum/disease/tuberculosis(0))
..()
/datum/reagent/spore
name = "Blob Spores"
id = "spore"
description = "Spores of some blob creature thingy."
reagent_state = LIQUID
color = "#CE760A" // rgb: 206, 118, 10
var/client/blob_client = null
var/blob_point_rate = 3
/datum/reagent/spore/on_mob_life(var/mob/living/M)
if(!M) M = holder.my_atom
if(holder.has_reagent("atrazine",45))
holder.del_reagent("spore") //apparently this never metabolizes and stays in forever unless you have 45 units of atrazine in you or some stupid thing like that.
if(prob(1))
M << "<span class='danger'>Your mouth tastes funny.</span>"
if(prob(1) && prob(25))
if(iscarbon(M))
var/mob/living/carbon/C = M
if(directory[ckey(C.key)])
blob_client = directory[ckey(C.key)]
C.gib()
if(blob_client)
var/obj/effect/blob/core/core = new(get_turf(C), 200, blob_client, blob_point_rate)
if(core.overmind && core.overmind.mind)
core.overmind.mind.name = C.name
//virus food
/datum/reagent/virus_food
name = "Virus Food"
@@ -396,60 +396,6 @@
///////////////////////////////////////////////////////////////////////////////////////////////////////////////
/*
/datum/reagent/nanomachines
name = "Nanomachines"
id = "nanomachines"
description = "Microscopic construction robots."
reagent_state = LIQUID
color = "#535E66" // rgb: 83, 94, 102
/datum/reagent/nanomachines/reaction_mob(var/mob/M, var/method=TOUCH, var/volume)
src = null
if( (prob(10) && method==TOUCH) || method==INGEST)
M.contract_disease(new /datum/disease/robotic_transformation(0),1)
/datum/reagent/xenomicrobes
name = "Xenomicrobes"
id = "xenomicrobes"
description = "Microbes with an entirely alien cellular structure."
reagent_state = LIQUID
color = "#535E66" // rgb: 83, 94, 102
/datum/reagent/xenomicrobes/reaction_mob(var/mob/M, var/method=TOUCH, var/volume)
src = null
if( (prob(10) && method==TOUCH) || method==INGEST)
M.contract_disease(new /datum/disease/xeno_transformation(0),1)
*/
/datum/reagent/spore
name = "Blob Spores"
id = "spore"
description = "Spores of some blob creature thingy."
reagent_state = LIQUID
color = "#CE760A" // rgb: 206, 118, 10
var/client/blob_client = null
var/blob_point_rate = 3
/datum/reagent/spore/on_mob_life(var/mob/living/M)
if(!M) M = holder.my_atom
if (holder.has_reagent("atrazine",45))
holder.del_reagent("spore")
if (prob(1))
M << "\red Your mouth tastes funny."
if (prob(1) && prob(25))
if(iscarbon(M))
var/mob/living/carbon/C = M
if(directory[ckey(C.key)])
blob_client = directory[ckey(C.key)]
C.gib()
if(blob_client)
var/obj/effect/blob/core/core = new(get_turf(C), 200, blob_client, blob_point_rate)
if(core.overmind && core.overmind.mind)
core.overmind.mind.name = C.name
return
/datum/reagent/condensedcapsaicin
name = "Condensed Capsaicin"
id = "condensedcapsaicin"
@@ -846,6 +846,7 @@
New()
..()
reagents.add_reagent("nutriment", 2)
reagents.add_reagent("nanomachines", 10)
bitesize = 2
/obj/item/weapon/reagent_containers/food/snacks/roburgerbig
@@ -857,7 +858,7 @@
New()
..()
reagents.add_reagent("nanites", 100)
reagents.add_reagent("nanomachines", 100)
bitesize = 0.1
/obj/item/weapon/reagent_containers/food/snacks/xenoburger
+1 -1
View File
@@ -326,7 +326,7 @@
ejectItem(TRUE)
if(prob(EFFECT_PROB_VERYLOW-badThingCoeff))
visible_message("<span class='danger'>[src]'s chemical chamber has sprung a leak!</span>")
chosenchem = pick("mutationtoxin","itching_powder","sacid")
chosenchem = pick("mutationtoxin","nanomachines","sacid")
var/datum/reagents/R = new/datum/reagents(15)
R.my_atom = src
R.add_reagent(chosenchem , 15)