-Got rid of a redundant del() in the PANDEMIC. Fixes Issue 1116.

-Added a new symptom. Voice Change will randomly change the voice of the affected mob. It isn't obtainable by Mutagen and I'll likely put it in the virus crate when I have more dangerous viruses.
-Added two new symptom procs. Start() will be called once and it'll be called when the advance disease processes. Allows you to setup stuff for your symptom. End() will be called before the disease is deleted.
-Diseases that spread by blood won't spread by contact anymore. You will need to directly inject someone to get them to catch the disease.
-Put a limit on shivering and fevers.
-Added a specialvoice variable. You can use SetSpecialVoice() to set a special voice that the player will say instead. To unset it, use UnsetSpecialVoice(). GetSpecialVoice() will return the player's special voice value.
-Added two DEFINEs for the limit which is how much a human can take before taking burn damage from heat or coldness. 
-Some symptom value changes.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@5136 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
giacomand@gmail.com
2012-11-20 16:39:11 +00:00
parent 333e4015d5
commit 9250be52a7
15 changed files with 109 additions and 235 deletions

View File

@@ -39,6 +39,7 @@ var/list/advance_cures = list(
var/list/symptoms = list() // The symptoms of the disease.
var/id = ""
var/processing = 0
/*
@@ -70,10 +71,22 @@ var/list/advance_cures = list(
..(process, D)
return
/datum/disease/advance/Del()
if(processing)
for(var/datum/symptom/S in symptoms)
S.End(src)
..()
// Randomly pick a symptom to activate.
/datum/disease/advance/stage_act()
..()
if(symptoms && symptoms.len)
if(!processing)
processing = 1
for(var/datum/symptom/S in symptoms)
S.Start(src)
for(var/datum/symptom/S in symptoms)
S.Activate(src)
else
@@ -392,6 +405,8 @@ var/list/advance_cures = list(
AD.Refresh()
for(var/mob/living/carbon/human/H in shuffle(living_mob_list))
if(H.z != 1)
continue
if(!H.has_disease(D))
H.contract_disease(D, 1)
break

View File

@@ -21,7 +21,7 @@ BONUS
stealth = -1
resistance = 3
stage_speed = 1
transmittable = 1
transmittable = 2
level = 1
/datum/symptom/cough/Activate(var/datum/disease/advance/A)

View File

@@ -21,7 +21,7 @@ Bonus
stealth = 0
resistance = 3
stage_speed = 3
transmittable = 1
transmittable = 2
level = 2
/datum/symptom/fever/Activate(var/datum/disease/advance/A)
@@ -29,6 +29,7 @@ Bonus
if(prob(SYMPTOM_ACTIVATION_PROB))
var/mob/living/carbon/M = A.affected_mob
M << "<span class='notice'>[pick("You feel hot.", "You feel like you're burning.")]</span>"
M.bodytemperature += 20 * A.stage
if(M.bodytemperature < BODYTEMP_HEAT_DAMAGE_LIMIT)
M.bodytemperature = min(M.bodytemperature + (20 * A.stage), BODYTEMP_HEAT_DAMAGE_LIMIT - 1)
return

View File

@@ -21,7 +21,7 @@ Bonus
stealth = 0
resistance = 2
stage_speed = 2
transmittable = 1
transmittable = 2
level = 2
/datum/symptom/shivering/Activate(var/datum/disease/advance/A)
@@ -29,6 +29,7 @@ Bonus
if(prob(SYMPTOM_ACTIVATION_PROB))
var/mob/living/carbon/M = A.affected_mob
M << "<span class='notice'>[pick("You feel cold.", "You start shaking from the cold.")]</span>"
M.bodytemperature -= 20 * A.stage
if(M.bodytemperature < BODYTEMP_COLD_DAMAGE_LIMIT)
M.bodytemperature = min(M.bodytemperature - (20 * A.stage), BODYTEMP_COLD_DAMAGE_LIMIT + 1)
return

View File

@@ -22,7 +22,7 @@ Bonus
stealth = -2
resistance = 3
stage_speed = 0
transmittable = 3
transmittable = 4
level = 1
/datum/symptom/sneeze/Activate(var/datum/disease/advance/A)

View File

@@ -25,7 +25,14 @@ var/global/const/SYMPTOM_ACTIVATION_PROB = 3
return
CRASH("We couldn't assign an ID!")
/datum/symptom/proc/Activate(var/mob/living/M, var/stage)
// Called when processing of the advance disease, which holds this symptom, starts.
/datum/symptom/proc/Start(var/datum/disease/advance/A)
return
// Called when the advance disease is going to be deleted or when the advance disease stops processing.
/datum/symptom/proc/End(var/datum/disease/advance/A)
return
/datum/symptom/proc/Activate(var/datum/disease/advance/A)
return

View File

@@ -0,0 +1,54 @@
/*
//////////////////////////////////////
Voice Change
Very Very noticable.
Lowers resistance considerably.
Decreases stage speed.
Reduced transmittable.
Fatal Level.
Bonus
Changes the voice of the affected mob. Causing confusion in communication.
//////////////////////////////////////
*/
/datum/symptom/voice_change
name = "Voice Change"
stealth = -2
resistance = -3
stage_speed = -3
transmittable = -1
level = 6
/datum/symptom/voice_change/Activate(var/datum/disease/advance/A)
..()
if(prob(SYMPTOM_ACTIVATION_PROB))
var/mob/living/carbon/M = A.affected_mob
switch(A.stage)
if(1, 2, 3, 4)
M << "<span class='notice'>[pick("Your throat hurts.", "You clear your throat.")]</span>"
else
if(ishuman(M))
var/mob/living/carbon/human/H = M
var/random_name = ""
switch(H.gender)
if(MALE)
random_name = (pick(first_names_male))
else
random_name = (pick(first_names_female))
random_name += " [pick(last_names)]"
H.SetSpecialVoice(random_name)
return
/datum/symptom/voice_change/End(var/datum/disease/advance/A)
..()
if(ishuman(A.affected_mob))
var/mob/living/carbon/human/H = A.affected_mob
H.UnsetSpecialVoice()
return