From d26a9b23a408a3380bfa7a875634b773b910e11a Mon Sep 17 00:00:00 2001 From: deathride58 Date: Wed, 3 Jan 2018 23:29:47 -0500 Subject: [PATCH] datums folder --- code/datums/action.dm | 18 ++- code/datums/actions/flightsuit.dm | 2 - code/datums/antagonists/changeling.dm | 13 +- code/datums/antagonists/cult.dm | 4 +- code/datums/antagonists/datum_traitor.dm | 10 +- code/datums/brain_damage/severe.dm | 10 +- code/datums/components/decal.dm | 2 +- code/datums/components/forensics.dm | 2 +- code/datums/components/spooky.dm | 2 +- code/datums/datacore.dm | 1 + code/datums/datum.dm | 9 ++ code/datums/diseases/advance/presets.dm | 90 +++++------ .../datums/diseases/advance/symptoms/beard.dm | 54 +++---- .../diseases/advance/symptoms/confusion.dm | 64 ++++---- .../datums/diseases/advance/symptoms/dizzy.dm | 2 +- .../diseases/advance/symptoms/flesh_eating.dm | 2 +- .../diseases/advance/symptoms/headache.dm | 2 +- code/datums/diseases/advance/symptoms/heal.dm | 152 +++++++++--------- .../diseases/advance/symptoms/itching.dm | 2 +- .../diseases/advance/symptoms/sensory.dm | 2 +- .../diseases/advance/symptoms/shedding.dm | 58 +++---- .../diseases/advance/symptoms/shivering.dm | 2 +- .../diseases/advance/symptoms/sneeze.dm | 7 +- .../diseases/advance/symptoms/vision.dm | 5 +- .../diseases/advance/symptoms/weight.dm | 2 +- .../datums/diseases/advance/symptoms/youth.dm | 54 +++---- code/datums/diseases/beesease.dm | 2 +- code/datums/diseases/cold.dm | 2 +- code/datums/diseases/cold9.dm | 2 +- code/datums/diseases/gbs.dm | 20 +-- code/datums/diseases/magnitis.dm | 2 +- code/datums/diseases/retrovirus.dm | 2 +- code/datums/explosion.dm | 9 ++ code/datums/helper_datums/getrev.dm | 3 +- code/datums/helper_datums/topic_input.dm | 122 +++++++------- code/datums/mind.dm | 46 +++--- code/datums/mutations.dm | 1 - code/datums/mutations/sight.dm | 8 +- code/datums/saymode.dm | 24 ++- code/datums/weakrefs.dm | 1 + .../weather/weather_types/radiation_storm.dm | 29 ++-- code/datums/wires/radio.dm | 3 +- 42 files changed, 443 insertions(+), 404 deletions(-) diff --git a/code/datums/action.dm b/code/datums/action.dm index a2abe139a4..fb1f2fb8cb 100644 --- a/code/datums/action.dm +++ b/code/datums/action.dm @@ -170,14 +170,15 @@ ..(current_button) else if(target && current_button.appearance_cache != target.appearance) //replace with /ref comparison if this is not valid. var/obj/item/I = target - current_button.appearance_cache = I.appearance var/old_layer = I.layer var/old_plane = I.plane I.layer = FLOAT_LAYER //AAAH I.plane = FLOAT_PLANE //^ what that guy said - current_button.overlays = list(I) + current_button.cut_overlays() + current_button.add_overlay(I) I.layer = old_layer I.plane = old_plane + current_button.appearance_cache = I.appearance /datum/action/item_action/toggle_light name = "Toggle Light" @@ -344,6 +345,19 @@ /datum/action/item_action/change name = "Change" +/datum/action/item_action/nano_picket_sign + name = "Retext Nano Picket Sign" + var/obj/item/picket_sign/S + +/datum/action/item_action/nano_picket_sign/New(Target) + ..() + if(istype(Target, /obj/item/picket_sign)) + S = Target + +/datum/action/item_action/nano_picket_sign/Trigger() + if(istype(S)) + S.retext(owner) + /datum/action/item_action/adjust /datum/action/item_action/adjust/New(Target) diff --git a/code/datums/actions/flightsuit.dm b/code/datums/actions/flightsuit.dm index 3e78fa5332..cf249fed31 100644 --- a/code/datums/actions/flightsuit.dm +++ b/code/datums/actions/flightsuit.dm @@ -1,5 +1,3 @@ - - /datum/action/item_action/flightsuit icon_icon = 'icons/mob/actions/actions_flightsuit.dmi' diff --git a/code/datums/antagonists/changeling.dm b/code/datums/antagonists/changeling.dm index da7e425ecc..53d0c37143 100644 --- a/code/datums/antagonists/changeling.dm +++ b/code/datums/antagonists/changeling.dm @@ -78,7 +78,7 @@ . = ..() /datum/antagonist/changeling/on_removal() - remove_changeling_powers(FALSE) + remove_changeling_powers() owner.objectives -= objectives . = ..() @@ -100,11 +100,11 @@ chem_recharge_slowdown = initial(chem_recharge_slowdown) mimicing = "" -/datum/antagonist/changeling/proc/remove_changeling_powers(keep_free_powers=0) +/datum/antagonist/changeling/proc/remove_changeling_powers() if(ishuman(owner.current) || ismonkey(owner.current)) reset_properties() for(var/obj/effect/proc_holder/changeling/p in purchasedpowers) - if((p.dna_cost == 0 && keep_free_powers) || p.always_keep) + if(p.always_keep) continue purchasedpowers -= p p.on_refund(owner.current) @@ -116,13 +116,13 @@ /datum/antagonist/changeling/proc/reset_powers() if(purchasedpowers) - remove_changeling_powers(TRUE) - //Purchase free powers. + remove_changeling_powers() + //Repurchase free powers. for(var/path in all_powers) var/obj/effect/proc_holder/changeling/S = new path() if(!S.dna_cost) if(!has_sting(S)) - purchasedpowers+=S + purchasedpowers += S S.on_purchase(owner.current,TRUE) /datum/antagonist/changeling/proc/has_sting(obj/effect/proc_holder/changeling/power) @@ -223,7 +223,6 @@ if(verbose) to_chat(user, "[target] is not compatible with our biology.") return - if((target.has_disability(DISABILITY_NOCLONE)) || (target.has_disability(DISABILITY_NOCLONE))) if(verbose) to_chat(user, "DNA of [target] is ruined beyond usability!") diff --git a/code/datums/antagonists/cult.dm b/code/datums/antagonists/cult.dm index 5b80cb68a6..cccc442c4d 100644 --- a/code/datums/antagonists/cult.dm +++ b/code/datums/antagonists/cult.dm @@ -131,7 +131,7 @@ SSticker.mode.cult -= owner SSticker.mode.update_cult_icons_removed(owner) if(!silent) - owner.current.visible_message("[owner.current] looks like [owner.current.p_they()] just reverted to their old faith!", ignored_mob = owner.current) + owner.current.visible_message("[owner.current] looks like [owner.current.p_they()] just reverted to their old faith!", ignored_mob = owner.current) to_chat(owner.current, "An unfamiliar white light flashes through your mind, cleansing the taint of the Geometer and all your memories as her servant.") owner.current.log_message("Has renounced the cult of Nar'Sie!", INDIVIDUAL_ATTACK_LOG) if(cult_team.blood_target && cult_team.blood_target_image && owner.current.client) @@ -243,7 +243,7 @@ return sacced || completed /datum/objective/sacrifice/update_explanation_text() - if(target && !sacced) + if(target) explanation_text = "Sacrifice [target], the [target.assigned_role] via invoking a Sacrifice rune with them on it and three acolytes around it." else explanation_text = "The veil has already been weakened here, proceed to the final objective." diff --git a/code/datums/antagonists/datum_traitor.dm b/code/datums/antagonists/datum_traitor.dm index 3ccdc7ddfb..80487f69e8 100644 --- a/code/datums/antagonists/datum_traitor.dm +++ b/code/datums/antagonists/datum_traitor.dm @@ -127,6 +127,7 @@ if(prob(30)) objective_count += forge_single_objective() + for(var/i = objective_count, i < CONFIG_GET(number/traitor_objectives_amount), i++) var/datum/objective/assassinate/kill_objective = new kill_objective.owner = owner @@ -152,11 +153,6 @@ maroon_objective.owner = owner maroon_objective.find_target() add_objective(maroon_objective) - else if(prob(50)) - var/datum/objective/assassinate/late/late_objective = new - late_objective.owner = owner - late_objective.find_target() - add_objective(late_objective) else var/datum/objective/assassinate/kill_objective = new kill_objective.owner = owner @@ -306,8 +302,8 @@ var/uplink_true = FALSE var/purchases = "" for(var/datum/component/uplink/H in GLOB.uplinks) - if(H && H.owner && H.owner == owner.key) - TC_uses += H.spent_telecrystals + if(H.owner && H.owner == owner.key) + TC_uses += H.purchase_log.total_spent uplink_true = TRUE purchases += H.purchase_log.generate_render(FALSE) diff --git a/code/datums/brain_damage/severe.dm b/code/datums/brain_damage/severe.dm index 57fc11710d..ba4eaa376e 100644 --- a/code/datums/brain_damage/severe.dm +++ b/code/datums/brain_damage/severe.dm @@ -50,17 +50,11 @@ lose_text = "Your vision returns." /datum/brain_trauma/severe/blindness/on_gain() - owner.become_blind() - ..() - -//no fiddling with genetics to get out of this one -/datum/brain_trauma/severe/blindness/on_life() - if(!(owner.disabilities & BLIND)) - on_gain() + owner.become_blind(TRAUMA_DISABILITY) ..() /datum/brain_trauma/severe/blindness/on_lose() - owner.cure_blind() + owner.cure_blind(TRAUMA_DISABILITY) ..() /datum/brain_trauma/severe/paralysis diff --git a/code/datums/components/decal.dm b/code/datums/components/decal.dm index 6378695c24..6b7f846e83 100644 --- a/code/datums/components/decal.dm +++ b/code/datums/components/decal.dm @@ -62,4 +62,4 @@ qdel(src) /datum/component/decal/proc/examine(mob/user) - to_chat(user, description) + to_chat(user, description) \ No newline at end of file diff --git a/code/datums/components/forensics.dm b/code/datums/components/forensics.dm index 55633a2087..1950b8b664 100644 --- a/code/datums/components/forensics.dm +++ b/code/datums/components/forensics.dm @@ -138,7 +138,7 @@ if(laststamppos) LAZYSET(hiddenprints, M.key, copytext(hiddenprints[M.key], 1, laststamppos)) hiddenprints[M.key] += " Last: [M.real_name]\[[current_time]\][hasgloves]. Ckey: [M.ckey]" //made sure to be existing by if(!LAZYACCESS);else - fingerprintslast = M.ckey + parent.fingerprintslast = M.ckey return TRUE /datum/component/forensics/proc/add_blood_DNA(list/dna) //list(dna_enzymes = type) diff --git a/code/datums/components/spooky.dm b/code/datums/components/spooky.dm index 3f3b0341ee..a62b7dcaab 100644 --- a/code/datums/components/spooky.dm +++ b/code/datums/components/spooky.dm @@ -57,4 +57,4 @@ var/t = stripped_input(H, "Enter your new skeleton name", H.real_name, null, MAX_NAME_LEN) if(!t) t = "spooky skeleton" - H.fully_replace_character_name(H.real_name, t) + H.fully_replace_character_name(null, t) diff --git a/code/datums/datacore.dm b/code/datums/datacore.dm index 5f9cf3ad9a..c22af19396 100644 --- a/code/datums/datacore.dm +++ b/code/datums/datacore.dm @@ -1,3 +1,4 @@ + /datum/datacore var/medical[] = list() var/medicalPrintCount = 0 diff --git a/code/datums/datum.dm b/code/datums/datum.dm index 4c08b1000d..6a3ad57878 100644 --- a/code/datums/datum.dm +++ b/code/datums/datum.dm @@ -17,6 +17,7 @@ /datum/proc/Destroy(force=FALSE, ...) tag = null weak_reference = null //ensure prompt GCing of weakref. + var/list/timers = active_timers active_timers = null for(var/thing in timers) @@ -24,6 +25,7 @@ if (timer.spent) continue qdel(timer) + var/list/dc = datum_components if(dc) var/all_components = dc[/datum/component] @@ -35,4 +37,11 @@ var/datum/component/C = all_components qdel(C, FALSE, TRUE) dc.Cut() + + var/list/focusers = src.focusers + if(focusers) + for(var/i in 1 to focusers.len) + var/mob/M = focusers[i] + M.set_focus(M) + return QDEL_HINT_QUEUE diff --git a/code/datums/diseases/advance/presets.dm b/code/datums/diseases/advance/presets.dm index 1a197f0f34..d2f6a73365 100644 --- a/code/datums/diseases/advance/presets.dm +++ b/code/datums/diseases/advance/presets.dm @@ -1,59 +1,59 @@ -// Cold - +// Cold + /datum/disease/advance/cold/New(var/process = TRUE, var/datum/disease/advance/D, var/copy = FALSE) - if(!D) - name = "Cold" - symptoms = list(new/datum/symptom/sneeze) - ..(process, D, copy) - - -// Flu - + if(!D) + name = "Cold" + symptoms = list(new/datum/symptom/sneeze) + ..(process, D, copy) + + +// Flu + /datum/disease/advance/flu/New(var/process = TRUE, var/datum/disease/advance/D, var/copy = FALSE) - if(!D) - name = "Flu" - symptoms = list(new/datum/symptom/cough) - ..(process, D, copy) - - -// Voice Changing - + if(!D) + name = "Flu" + symptoms = list(new/datum/symptom/cough) + ..(process, D, copy) + + +// Voice Changing + /datum/disease/advance/voice_change/New(var/process = TRUE, var/datum/disease/advance/D, var/copy = FALSE) - if(!D) - name = "Epiglottis Mutation" - symptoms = list(new/datum/symptom/voice_change) - ..(process, D, copy) - - -// Toxin Filter - + if(!D) + name = "Epiglottis Mutation" + symptoms = list(new/datum/symptom/voice_change) + ..(process, D, copy) + + +// Toxin Filter + /datum/disease/advance/heal/New(var/process = TRUE, var/datum/disease/advance/D, var/copy = FALSE) - if(!D) - name = "Liver Enhancer" - symptoms = list(new/datum/symptom/heal) - ..(process, D, copy) - - + if(!D) + name = "Liver Enhancer" + symptoms = list(new/datum/symptom/heal) + ..(process, D, copy) + + // Hallucigen - + /datum/disease/advance/hallucigen/New(var/process = TRUE, var/datum/disease/advance/D, var/copy = FALSE) - if(!D) + if(!D) name = "Second Sight" - symptoms = list(new/datum/symptom/hallucigen) - ..(process, D, copy) - -// Sensory Restoration - + symptoms = list(new/datum/symptom/hallucigen) + ..(process, D, copy) + +// Sensory Restoration + /datum/disease/advance/mind_restoration/New(var/process = TRUE, var/datum/disease/advance/D, var/copy = FALSE) - if(!D) + if(!D) name = "Intelligence Booster" symptoms = list(new/datum/symptom/mind_restoration) - ..(process, D, copy) - -// Sensory Destruction - + ..(process, D, copy) + +// Sensory Destruction + /datum/disease/advance/narcolepsy/New(var/process = TRUE, var/datum/disease/advance/D, var/copy = FALSE) - if(!D) + if(!D) name = "Experimental Insomnia Cure" symptoms = list(new/datum/symptom/narcolepsy) ..(process, D, copy) \ No newline at end of file diff --git a/code/datums/diseases/advance/symptoms/beard.dm b/code/datums/diseases/advance/symptoms/beard.dm index aa3919f3cf..c7a3ccec89 100644 --- a/code/datums/diseases/advance/symptoms/beard.dm +++ b/code/datums/diseases/advance/symptoms/beard.dm @@ -1,33 +1,33 @@ -/* -////////////////////////////////////// -Facial Hypertrichosis - - Very very Noticable. - Decreases resistance slightly. - Decreases stage speed. - Reduced transmittability - Intense Level. - -BONUS - Makes the mob grow a massive beard, regardless of gender. - -////////////////////////////////////// -*/ - -/datum/symptom/beard - - name = "Facial Hypertrichosis" +/* +////////////////////////////////////// +Facial Hypertrichosis + + Very very Noticable. + Decreases resistance slightly. + Decreases stage speed. + Reduced transmittability + Intense Level. + +BONUS + Makes the mob grow a massive beard, regardless of gender. + +////////////////////////////////////// +*/ + +/datum/symptom/beard + + name = "Facial Hypertrichosis" desc = "The virus increases hair production significantly, causing rapid beard growth." - stealth = -3 - resistance = -1 - stage_speed = -3 - transmittable = -1 - level = 4 - severity = 1 + stealth = -3 + resistance = -1 + stage_speed = -3 + transmittable = -1 + level = 4 + severity = 1 symptom_delay_min = 18 symptom_delay_max = 36 - -/datum/symptom/beard/Activate(datum/disease/advance/A) + +/datum/symptom/beard/Activate(datum/disease/advance/A) if(!..()) return var/mob/living/M = A.affected_mob diff --git a/code/datums/diseases/advance/symptoms/confusion.dm b/code/datums/diseases/advance/symptoms/confusion.dm index 209c7b0bf6..4ff69680ce 100644 --- a/code/datums/diseases/advance/symptoms/confusion.dm +++ b/code/datums/diseases/advance/symptoms/confusion.dm @@ -1,30 +1,30 @@ -/* -////////////////////////////////////// - -Confusion - - Little bit hidden. - Lowers resistance. - Decreases stage speed. - Not very transmittable. - Intense Level. - -Bonus - Makes the affected mob be confused for short periods of time. - -////////////////////////////////////// -*/ - -/datum/symptom/confusion - - name = "Confusion" +/* +////////////////////////////////////// + +Confusion + + Little bit hidden. + Lowers resistance. + Decreases stage speed. + Not very transmittable. + Intense Level. + +Bonus + Makes the affected mob be confused for short periods of time. + +////////////////////////////////////// +*/ + +/datum/symptom/confusion + + name = "Confusion" desc = "The virus interferes with the proper function of the neural system, leading to bouts of confusion and erratic movement." - stealth = 1 - resistance = -1 - stage_speed = -3 - transmittable = 0 - level = 4 - severity = 2 + stealth = 1 + resistance = -1 + stage_speed = -3 + transmittable = 0 + level = 4 + severity = 2 base_message_chance = 25 symptom_delay_min = 10 symptom_delay_max = 30 @@ -32,7 +32,7 @@ Bonus threshold_desc = "Resistance 6: Causes brain damage over time.
\ Transmission 6: Increases confusion duration.
\ Stealth 4: The symptom remains hidden until active." - + /datum/symptom/confusion/Start(datum/disease/advance/A) if(!..()) return @@ -42,20 +42,20 @@ Bonus power = 1.5 if(A.properties["stealth"] >= 4) suppress_warning = TRUE - -/datum/symptom/confusion/Activate(datum/disease/advance/A) + +/datum/symptom/confusion/Activate(datum/disease/advance/A) if(!..()) return var/mob/living/carbon/M = A.affected_mob switch(A.stage) if(1, 2, 3, 4) if(prob(base_message_chance) && !suppress_warning) - to_chat(M, "[pick("Your head hurts.", "Your mind blanks for a moment.")]") + to_chat(M, "[pick("Your head hurts.", "Your mind blanks for a moment.")]") else to_chat(M, "You can't think straight!") M.confused = min(100 * power, M.confused + 8) if(brain_damage) M.adjustBrainLoss(3 * power, 80) M.updatehealth() - - return + + return diff --git a/code/datums/diseases/advance/symptoms/dizzy.dm b/code/datums/diseases/advance/symptoms/dizzy.dm index bb83582425..c7f7198f6b 100644 --- a/code/datums/diseases/advance/symptoms/dizzy.dm +++ b/code/datums/diseases/advance/symptoms/dizzy.dm @@ -50,4 +50,4 @@ Bonus to_chat(M, "A wave of dizziness washes over you!") M.Dizzy(5) if(power >= 2) - M.set_drugginess(5) + M.set_drugginess(5) \ No newline at end of file diff --git a/code/datums/diseases/advance/symptoms/flesh_eating.dm b/code/datums/diseases/advance/symptoms/flesh_eating.dm index 2d5d22a63a..c38acc8e9e 100644 --- a/code/datums/diseases/advance/symptoms/flesh_eating.dm +++ b/code/datums/diseases/advance/symptoms/flesh_eating.dm @@ -127,4 +127,4 @@ Bonus M.reagents.add_reagent_list(list("heparin" = 2, "lipolicide" = 2)) if(zombie) M.reagents.add_reagent("romerol", 1) - return 1 + return 1 \ No newline at end of file diff --git a/code/datums/diseases/advance/symptoms/headache.dm b/code/datums/diseases/advance/symptoms/headache.dm index 3a8c82beed..973de1455b 100644 --- a/code/datums/diseases/advance/symptoms/headache.dm +++ b/code/datums/diseases/advance/symptoms/headache.dm @@ -57,4 +57,4 @@ BONUS M.adjustStaminaLoss(25) if(power >= 3 && A.stage >= 5) to_chat(M, "[pick("Your head hurts!", "You feel a burning knife inside your brain!", "A wave of pain fills your head!")]") - M.Stun(35) + M.Stun(35) \ No newline at end of file diff --git a/code/datums/diseases/advance/symptoms/heal.dm b/code/datums/diseases/advance/symptoms/heal.dm index 104a4c00c2..4f208b826b 100644 --- a/code/datums/diseases/advance/symptoms/heal.dm +++ b/code/datums/diseases/advance/symptoms/heal.dm @@ -1,10 +1,10 @@ /datum/symptom/heal name = "Basic Healing (does nothing)" //warning for adminspawn viruses desc = "You should not be seeing this." - stealth = 1 - resistance = -4 - stage_speed = -4 - transmittable = -4 + stealth = 0 + resistance = 0 + stage_speed = 0 + transmittable = 0 level = 0 //not obtainable base_message_chance = 20 //here used for the overlays symptom_delay_min = 1 @@ -22,7 +22,6 @@ /datum/symptom/heal/Activate(datum/disease/advance/A) if(!..()) return - //100% chance to activate for slow but consistent healing var/mob/living/M = A.affected_mob switch(A.stage) if(4, 5) @@ -45,20 +44,20 @@ return TRUE -/datum/symptom/heal/toxin +/datum/symptom/heal/starlight name = "Starlight Condensation" - desc = "The virus reacts to direct starlight, producing regenerative chemicals that can cure toxin damage." - stealth = 1 - resistance = -3 - stage_speed = -3 - transmittable = -3 + desc = "The virus reacts to direct starlight, producing regenerative chemicals. Works best against toxin-based damage." + stealth = -1 + resistance = -2 + stage_speed = 0 + transmittable = 1 level = 6 passive_message = "You miss the feeling of starlight on your skin." var/nearspace_penalty = 0.3 threshold_desc = "Stage Speed 6: Increases healing speed.
\ Transmission 6: Removes penalty for only being close to space." -/datum/symptom/heal/toxin/Start(datum/disease/advance/A) +/datum/symptom/heal/starlight/Start(datum/disease/advance/A) if(!..()) return if(A.properties["transmission"] >= 6) @@ -66,7 +65,7 @@ if(A.properties["stage_rate"] >= 6) power = 2 -/datum/symptom/heal/toxin/CanHeal(datum/disease/advance/A) +/datum/symptom/heal/starlight/CanHeal(datum/disease/advance/A) var/mob/living/M = A.affected_mob if(istype(get_turf(M), /turf/open/space)) return power @@ -75,15 +74,25 @@ if(istype(T, /turf/open/space)) return power * nearspace_penalty -/datum/symptom/heal/toxin/Heal(mob/living/M, datum/disease/advance/A, actual_power) +/datum/symptom/heal/starlight/Heal(mob/living/carbon/M, datum/disease/advance/A, actual_power) var/heal_amt = actual_power if(M.getToxLoss() && prob(5)) - to_chat(M, "Your skin tingles as the starlight purges toxins from your bloodstream.") - M.adjustToxLoss(-heal_amt) + to_chat(M, "Your skin tingles as the starlight seems to heal you.") + + M.adjustToxLoss(-(4 * heal_amt)) //most effective on toxins + + var/list/parts = M.get_damaged_bodyparts(1,1) + + if(!parts.len) + return + + for(var/obj/item/bodypart/L in parts) + if(L.heal_damage(heal_amt/parts.len, heal_amt/parts.len)) + M.update_damage_overlays() return 1 -/datum/symptom/heal/toxin/passive_message_condition(mob/living/M) - if(M.getToxLoss()) +/datum/symptom/heal/starlight/passive_message_condition(mob/living/M) + if(M.getBruteLoss() || M.getFireLoss() || M.getToxLoss()) return TRUE return FALSE @@ -91,7 +100,7 @@ name = "Toxolysis" stealth = 0 resistance = -2 - stage_speed = -2 + stage_speed = 2 transmittable = -2 level = 7 var/food_conversion = FALSE @@ -153,58 +162,50 @@ to_chat(C, "You feel an odd gurgle in your stomach, as if it was working much faster than normal.") return 1 -/datum/symptom/heal/brute - name = "Cellular Molding" - desc = "The virus is able to shift cells around when in conditions of high heat, repairing existing physical damage." - stealth = 1 - resistance = -3 - stage_speed = -3 - transmittable = -3 +/datum/symptom/heal/darkness + name = "Nocturnal Regeneration" + desc = "The virus is able to mend the host's flesh when in conditions of low light, repairing physical damage. More effective against brute damage." + stealth = 2 + resistance = -1 + stage_speed = -2 + transmittable = -1 level = 6 - passive_message = "You feel the flesh pulsing under your skin for a moment, but it's too cold to move." + passive_message = "You feel tingling on your skin as light passes over it." threshold_desc = "Stage Speed 8: Doubles healing speed." -/datum/symptom/heal/brute/Start(datum/disease/advance/A) +/datum/symptom/heal/darkness/Start(datum/disease/advance/A) if(!..()) return if(A.properties["stage_rate"] >= 8) power = 2 -/datum/symptom/heal/brute/CanHeal(datum/disease/advance/A) +/datum/symptom/heal/darkness/CanHeal(datum/disease/advance/A) var/mob/living/M = A.affected_mob - switch(M.bodytemperature) - if(0 to 340) - return FALSE - if(340 to BODYTEMP_HEAT_DAMAGE_LIMIT) - . = 0.3 * power - if(BODYTEMP_HEAT_DAMAGE_LIMIT to 400) - . = 0.75 * power - if(400 to 460) - . = power - else - . = 1.5 * power + var/light_amount = 0 + if(isturf(M.loc)) //else, there's considered to be no light + var/turf/T = M.loc + light_amount = min(1,T.get_lumcount()) - 0.5 + if(light_amount < SHADOW_SPECIES_LIGHT_THRESHOLD) + return power - if(M.on_fire) - . *= 2 - -/datum/symptom/heal/brute/Heal(mob/living/carbon/M, datum/disease/advance/A, actual_power) +/datum/symptom/heal/darkness/Heal(mob/living/carbon/M, datum/disease/advance/A, actual_power) var/heal_amt = 2 * actual_power - var/list/parts = M.get_damaged_bodyparts(1,0) //brute only + var/list/parts = M.get_damaged_bodyparts(1,1) if(!parts.len) return if(prob(5)) - to_chat(M, "You feel your flesh moving beneath your heated skin, mending your wounds.") + to_chat(M, "The darkness soothes and mends your wounds.") for(var/obj/item/bodypart/L in parts) - if(L.heal_damage(heal_amt/parts.len, 0)) + if(L.heal_damage(heal_amt/parts.len, heal_amt/parts.len * 0.5)) //more effective on brute M.update_damage_overlays() return 1 -/datum/symptom/heal/brute/passive_message_condition(mob/living/M) - if(M.getBruteLoss()) +/datum/symptom/heal/darkness/passive_message_condition(mob/living/M) + if(M.getBruteLoss() || M.getFireLoss()) return TRUE return FALSE @@ -212,8 +213,8 @@ name = "Regenerative Coma" desc = "The virus causes the host to fall into a death-like coma when severely damaged, then rapidly fixes the damage." stealth = 0 - resistance = 0 - stage_speed = -2 + resistance = 2 + stage_speed = -3 transmittable = -2 level = 8 passive_message = "The pain from your wounds makes you feel oddly sleepy..." @@ -283,20 +284,20 @@ return TRUE return FALSE -/datum/symptom/heal/burn +/datum/symptom/heal/water name = "Tissue Hydration" - desc = "The virus uses excess water inside and outside the body to repair burned tisue cells." - stealth = 1 - resistance = -3 - stage_speed = -3 - transmittable = -3 + desc = "The virus uses excess water inside and outside the body to repair damaged tissue cells. More effective against burns." + stealth = 0 + resistance = -1 + stage_speed = 0 + transmittable = 1 level = 6 - passive_message = "Your burned skin feels oddly dry..." + passive_message = "Your skin feels oddly dry..." var/absorption_coeff = 1 threshold_desc = "Resistance 5: Water is consumed at a much slower rate.
\ Stage Speed 7: Increases healing speed." -/datum/symptom/heal/burn/Start(datum/disease/advance/A) +/datum/symptom/heal/water/Start(datum/disease/advance/A) if(!..()) return if(A.properties["stage_rate"] >= 7) @@ -304,7 +305,7 @@ if(A.properties["stealth"] >= 2) absorption_coeff = 0.25 -/datum/symptom/heal/burn/CanHeal(datum/disease/advance/A) +/datum/symptom/heal/water/CanHeal(datum/disease/advance/A) . = 0 var/mob/living/M = A.affected_mob if(M.fire_stacks < 0) @@ -317,33 +318,33 @@ M.reagents.remove_reagent("water", 0.5 * absorption_coeff) . += power * 0.5 -/datum/symptom/heal/burn/Heal(mob/living/carbon/M, datum/disease/advance/A, actual_power) +/datum/symptom/heal/water/Heal(mob/living/carbon/M, datum/disease/advance/A, actual_power) var/heal_amt = 2 * actual_power - var/list/parts = M.get_damaged_bodyparts(0,1) //burn only + var/list/parts = M.get_damaged_bodyparts(1,1) //more effective on burns if(!parts.len) return if(prob(5)) - to_chat(M, "You feel yourself absorbing the water around you to soothe your burned skin.") + to_chat(M, "You feel yourself absorbing the water around you to soothe your damaged skin.") for(var/obj/item/bodypart/L in parts) - if(L.heal_damage(0, heal_amt/parts.len)) + if(L.heal_damage(heal_amt/parts.len * 0.5, heal_amt/parts.len)) M.update_damage_overlays() return 1 -/datum/symptom/heal/burn/passive_message_condition(mob/living/M) - if(M.getFireLoss()) +/datum/symptom/heal/water/passive_message_condition(mob/living/M) + if(M.getBruteLoss() || M.getFireLoss()) return TRUE return FALSE /datum/symptom/heal/plasma name = "Plasma Fixation" - desc = "The virus draws plasma from the atmosphere and from inside the body to stabilize body temperature and heal burns." + desc = "The virus draws plasma from the atmosphere and from inside the body to heal and stabilize body temperature." stealth = 0 - resistance = 0 + resistance = 3 stage_speed = -2 transmittable = -2 level = 8 @@ -379,8 +380,6 @@ /datum/symptom/heal/plasma/Heal(mob/living/carbon/M, datum/disease/advance/A, actual_power) var/heal_amt = 4 * actual_power - var/list/parts = M.get_damaged_bodyparts(0,1) //burn only - if(prob(5)) to_chat(M, "You feel yourself absorbing plasma inside and around you...") @@ -393,24 +392,25 @@ if(prob(5)) to_chat(M, "You feel warmer.") + M.adjustToxLoss(-heal_amt) + + var/list/parts = M.get_damaged_bodyparts(1,1) if(!parts.len) return if(prob(5)) - to_chat(M, "The pain from your burns fades rapidly.") - + to_chat(M, "The pain from your wounds fades rapidly.") for(var/obj/item/bodypart/L in parts) - if(L.heal_damage(0, heal_amt/parts.len)) + if(L.heal_damage(heal_amt/parts.len, heal_amt/parts.len)) M.update_damage_overlays() return 1 - /datum/symptom/heal/radiation name = "Radioactive Resonance" desc = "The virus uses radiation to fix damage through dna mutations." stealth = -1 resistance = -2 - stage_speed = 0 + stage_speed = 2 transmittable = -3 level = 6 symptom_delay_min = 1 @@ -450,6 +450,8 @@ if(cellular_damage) M.adjustCloneLoss(-heal_amt * 0.5) + M.adjustToxLoss(-(2 * heal_amt)) + var/list/parts = M.get_damaged_bodyparts(1,1) if(!parts.len) diff --git a/code/datums/diseases/advance/symptoms/itching.dm b/code/datums/diseases/advance/symptoms/itching.dm index 1c356247ee..1da9f5e8d7 100644 --- a/code/datums/diseases/advance/symptoms/itching.dm +++ b/code/datums/diseases/advance/symptoms/itching.dm @@ -51,4 +51,4 @@ BONUS var/can_scratch = scratch && !M.incapacitated() && get_location_accessible(M, picked_bodypart) M.visible_message("[can_scratch ? "[M] scratches [M.p_their()] [bodypart.name]." : ""]", "Your [bodypart.name] itches. [can_scratch ? " You scratch it." : ""]") if(can_scratch) - bodypart.receive_damage(0.5) + bodypart.receive_damage(0.5) \ No newline at end of file diff --git a/code/datums/diseases/advance/symptoms/sensory.dm b/code/datums/diseases/advance/symptoms/sensory.dm index b744fcb3af..911ffd7e26 100644 --- a/code/datums/diseases/advance/symptoms/sensory.dm +++ b/code/datums/diseases/advance/symptoms/sensory.dm @@ -105,4 +105,4 @@ M.adjust_eye_damage(-1) else if(prob(base_message_chance)) - to_chat(M, "[pick("Your eyes feel great.","You feel like your eyes can focus more clearly.", "You don't feel the need to blink.","Your ears feel great.","Your healing feels more acute.")]") + to_chat(M, "[pick("Your eyes feel great.","You feel like your eyes can focus more clearly.", "You don't feel the need to blink.","Your ears feel great.","Your healing feels more acute.")]") \ No newline at end of file diff --git a/code/datums/diseases/advance/symptoms/shedding.dm b/code/datums/diseases/advance/symptoms/shedding.dm index a578289e17..c5bbb6bc7b 100644 --- a/code/datums/diseases/advance/symptoms/shedding.dm +++ b/code/datums/diseases/advance/symptoms/shedding.dm @@ -1,39 +1,39 @@ -/* -////////////////////////////////////// -Alopecia - +/* +////////////////////////////////////// +Alopecia + Not Noticeable. Increases resistance slightly. - Reduces stage speed slightly. - Transmittable. - Intense Level. - -BONUS - Makes the mob lose hair. - -////////////////////////////////////// -*/ - -/datum/symptom/shedding - name = "Alopecia" + Reduces stage speed slightly. + Transmittable. + Intense Level. + +BONUS + Makes the mob lose hair. + +////////////////////////////////////// +*/ + +/datum/symptom/shedding + name = "Alopecia" desc = "The virus causes rapid shedding of head and body hair." stealth = 0 resistance = 1 - stage_speed = -1 + stage_speed = -1 transmittable = 3 - level = 4 - severity = 1 + level = 4 + severity = 1 base_message_chance = 50 symptom_delay_min = 45 symptom_delay_max = 90 - -/datum/symptom/shedding/Activate(datum/disease/advance/A) + +/datum/symptom/shedding/Activate(datum/disease/advance/A) if(!..()) return var/mob/living/M = A.affected_mob if(prob(base_message_chance)) - to_chat(M, "[pick("Your scalp itches.", "Your skin feels flakey.")]") + to_chat(M, "[pick("Your scalp itches.", "Your skin feels flakey.")]") if(ishuman(M)) var/mob/living/carbon/human/H = M switch(A.stage) @@ -45,11 +45,11 @@ BONUS if(!(H.facial_hair_style == "Shaved") || !(H.hair_style == "Bald")) to_chat(H, "Your hair starts to fall out in clumps...") addtimer(CALLBACK(src, .proc/Shed, H, TRUE), 50) - -/datum/symptom/shedding/proc/Shed(mob/living/carbon/human/H, fullbald) - if(fullbald) - H.facial_hair_style = "Shaved" - H.hair_style = "Bald" - else - H.hair_style = "Balding Hair" + +/datum/symptom/shedding/proc/Shed(mob/living/carbon/human/H, fullbald) + if(fullbald) + H.facial_hair_style = "Shaved" + H.hair_style = "Bald" + else + H.hair_style = "Balding Hair" H.update_hair() \ No newline at end of file diff --git a/code/datums/diseases/advance/symptoms/shivering.dm b/code/datums/diseases/advance/symptoms/shivering.dm index bad9062eb5..591626e530 100644 --- a/code/datums/diseases/advance/symptoms/shivering.dm +++ b/code/datums/diseases/advance/symptoms/shivering.dm @@ -56,4 +56,4 @@ Bonus M.bodytemperature = min(M.bodytemperature - (get_cold * A.stage), BODYTEMP_COLD_DAMAGE_LIMIT + 1) else M.bodytemperature -= (get_cold * A.stage) - return 1 + return 1 \ No newline at end of file diff --git a/code/datums/diseases/advance/symptoms/sneeze.dm b/code/datums/diseases/advance/symptoms/sneeze.dm index 8b5b59f71a..3648f5d707 100644 --- a/code/datums/diseases/advance/symptoms/sneeze.dm +++ b/code/datums/diseases/advance/symptoms/sneeze.dm @@ -46,7 +46,6 @@ Bonus if(1, 2, 3) if(!suppress_warning) M.emote("sniff") - else - M.emote("sneeze") - A.spread(5) - return + else + M.emote("sneeze") + A.spread(4 + power) \ No newline at end of file diff --git a/code/datums/diseases/advance/symptoms/vision.dm b/code/datums/diseases/advance/symptoms/vision.dm index 7c54aa7ea4..279ce51417 100644 --- a/code/datums/diseases/advance/symptoms/vision.dm +++ b/code/datums/diseases/advance/symptoms/vision.dm @@ -58,14 +58,15 @@ Bonus M.blur_eyes(20) M.adjust_eye_damage(5) if(eyes.eye_damage >= 10) - M.become_nearsighted() + M.become_nearsighted(EYE_DAMAGE) if(prob(eyes.eye_damage - 10 + 1)) if(!remove_eyes) if(!M.has_disability(DISABILITY_BLIND)) to_chat(M, "You go blind!") + M.become_blind(EYE_DAMAGE) else M.visible_message("[M]'s eyes fall off their sockets!", "Your eyes fall off their sockets!") eyes.Remove(M) eyes.forceMove(get_turf(M)) else - to_chat(M, "Your eyes burn horrifically!") + to_chat(M, "Your eyes burn horrifically!") \ No newline at end of file diff --git a/code/datums/diseases/advance/symptoms/weight.dm b/code/datums/diseases/advance/symptoms/weight.dm index 7052e90bf7..c97667733d 100644 --- a/code/datums/diseases/advance/symptoms/weight.dm +++ b/code/datums/diseases/advance/symptoms/weight.dm @@ -48,4 +48,4 @@ Bonus else to_chat(M, "[pick("So hungry...", "You'd kill someone for a bite of food...", "Hunger cramps seize you...")]") M.overeatduration = max(M.overeatduration - 100, 0) - M.nutrition = max(M.nutrition - 100, 0) + M.nutrition = max(M.nutrition - 100, 0) \ No newline at end of file diff --git a/code/datums/diseases/advance/symptoms/youth.dm b/code/datums/diseases/advance/symptoms/youth.dm index 6be34684e7..927be03ed9 100644 --- a/code/datums/diseases/advance/symptoms/youth.dm +++ b/code/datums/diseases/advance/symptoms/youth.dm @@ -1,35 +1,35 @@ -/* -////////////////////////////////////// -Eternal Youth - - Moderate stealth boost. - Increases resistance tremendously. - Increases stage speed tremendously. - Reduces transmission tremendously. - Critical Level. - -BONUS - Gives you immortality and eternal youth!!! - Can be used to buff your virus - -////////////////////////////////////// -*/ - -/datum/symptom/youth - - name = "Eternal Youth" +/* +////////////////////////////////////// +Eternal Youth + + Moderate stealth boost. + Increases resistance tremendously. + Increases stage speed tremendously. + Reduces transmission tremendously. + Critical Level. + +BONUS + Gives you immortality and eternal youth!!! + Can be used to buff your virus + +////////////////////////////////////// +*/ + +/datum/symptom/youth + + name = "Eternal Youth" desc = "The virus becomes symbiotically connected to the cells in the host's body, preventing and reversing aging. \ The virus, in turn, becomes more resistant, spreads faster, and is harder to spot, although it doesn't thrive as well without a host." - stealth = 3 - resistance = 4 - stage_speed = 4 - transmittable = -4 - level = 5 + stealth = 3 + resistance = 4 + stage_speed = 4 + transmittable = -4 + level = 5 base_message_chance = 100 symptom_delay_min = 25 symptom_delay_max = 50 - -/datum/symptom/youth/Activate(datum/disease/advance/A) + +/datum/symptom/youth/Activate(datum/disease/advance/A) if(!..()) return var/mob/living/M = A.affected_mob diff --git a/code/datums/diseases/beesease.dm b/code/datums/diseases/beesease.dm index 80ec0abe6b..dc848ab622 100644 --- a/code/datums/diseases/beesease.dm +++ b/code/datums/diseases/beesease.dm @@ -36,4 +36,4 @@ affected_mob.visible_message("[affected_mob] coughs up a swarm of bees!", \ "You cough up a swarm of bees!") new /mob/living/simple_animal/hostile/poison/bees(affected_mob.loc) - return + return \ No newline at end of file diff --git a/code/datums/diseases/cold.dm b/code/datums/diseases/cold.dm index 5915a784ea..e9f02b91b6 100644 --- a/code/datums/diseases/cold.dm +++ b/code/datums/diseases/cold.dm @@ -50,4 +50,4 @@ if(!affected_mob.resistances.Find(/datum/disease/flu)) var/datum/disease/Flu = new /datum/disease/flu(0) affected_mob.ForceContractDisease(Flu) - cure() + cure() \ No newline at end of file diff --git a/code/datums/diseases/cold9.dm b/code/datums/diseases/cold9.dm index 4b65fee700..6a21dbfd54 100644 --- a/code/datums/diseases/cold9.dm +++ b/code/datums/diseases/cold9.dm @@ -36,4 +36,4 @@ if(prob(1)) to_chat(affected_mob, "Your throat feels sore.") if(prob(10)) - to_chat(affected_mob, "You feel stiff.") + to_chat(affected_mob, "You feel stiff.") \ No newline at end of file diff --git a/code/datums/diseases/gbs.dm b/code/datums/diseases/gbs.dm index 71e4064676..6d77acd3ae 100644 --- a/code/datums/diseases/gbs.dm +++ b/code/datums/diseases/gbs.dm @@ -1,6 +1,6 @@ /datum/disease/gbs name = "GBS" - max_stages = 5 + max_stages = 4 spread_text = "On contact" spread_flags = VIRUS_SPREAD_BLOOD | VIRUS_SPREAD_CONTACT_SKIN | VIRUS_SPREAD_CONTACT_FLUIDS cure_text = "Synaptizine & Sulfur" @@ -16,25 +16,15 @@ ..() 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)) + if(3) + if(prob(5)) affected_mob.emote("gasp") if(prob(10)) - to_chat(affected_mob, "You're starting to feel very weak...") + to_chat(affected_mob, "Your body hurts all over!") if(4) - if(prob(10)) - affected_mob.emote("cough") - affected_mob.adjustToxLoss(5) - affected_mob.updatehealth() - if(5) - to_chat(affected_mob, "Your body feels as if it's trying to rip itself open...") + to_chat(affected_mob, "Your body feels as if it's trying to rip itself apart!") if(prob(50)) affected_mob.gib() else diff --git a/code/datums/diseases/magnitis.dm b/code/datums/diseases/magnitis.dm index 4430eee19d..91ce1ca71e 100644 --- a/code/datums/diseases/magnitis.dm +++ b/code/datums/diseases/magnitis.dm @@ -65,4 +65,4 @@ var/iter = rand(1,3) for(i=0,iRound ID: [GLOB.round_id]") if(GLOB.revdata.originmastercommit) to_chat(src, "Server revision compiled on: [GLOB.revdata.date]") var/prefix = "" diff --git a/code/datums/helper_datums/topic_input.dm b/code/datums/helper_datums/topic_input.dm index d27f259159..3e43905f1f 100644 --- a/code/datums/helper_datums/topic_input.dm +++ b/code/datums/helper_datums/topic_input.dm @@ -1,62 +1,62 @@ -/datum/topic_input - var/href - var/list/href_list - -/datum/topic_input/New(thref,list/thref_list) - href = thref - href_list = thref_list.Copy() - return - -/datum/topic_input/proc/get(i) - return listgetindex(href_list,i) - -/datum/topic_input/proc/getAndLocate(i) - var/t = get(i) - if(t) - t = locate(t) - if (istext(t)) - t = null - return t || null - -/datum/topic_input/proc/getNum(i) - var/t = get(i) - if(t) - t = text2num(t) - return isnum(t) ? t : null - -/datum/topic_input/proc/getObj(i) - var/t = getAndLocate(i) - return isobj(t) ? t : null - -/datum/topic_input/proc/getMob(i) - var/t = getAndLocate(i) - return ismob(t) ? t : null - -/datum/topic_input/proc/getTurf(i) - var/t = getAndLocate(i) - return isturf(t) ? t : null - -/datum/topic_input/proc/getAtom(i) +/datum/topic_input + var/href + var/list/href_list + +/datum/topic_input/New(thref,list/thref_list) + href = thref + href_list = thref_list.Copy() + return + +/datum/topic_input/proc/get(i) + return listgetindex(href_list,i) + +/datum/topic_input/proc/getAndLocate(i) + var/t = get(i) + if(t) + t = locate(t) + if (istext(t)) + t = null + return t || null + +/datum/topic_input/proc/getNum(i) + var/t = get(i) + if(t) + t = text2num(t) + return isnum(t) ? t : null + +/datum/topic_input/proc/getObj(i) + var/t = getAndLocate(i) + return isobj(t) ? t : null + +/datum/topic_input/proc/getMob(i) + var/t = getAndLocate(i) + return ismob(t) ? t : null + +/datum/topic_input/proc/getTurf(i) + var/t = getAndLocate(i) + return isturf(t) ? t : null + +/datum/topic_input/proc/getAtom(i) return getType(i, /atom) - -/datum/topic_input/proc/getArea(i) - var/t = getAndLocate(i) - return isarea(t) ? t : null - -/datum/topic_input/proc/getStr(i)//params should always be text, but... - var/t = get(i) - return istext(t) ? t : null - -/datum/topic_input/proc/getType(i,type) - var/t = getAndLocate(i) - return istype(t,type) ? t : null - -/datum/topic_input/proc/getPath(i) - var/t = get(i) - if(t) - t = text2path(t) - return ispath(t) ? t : null - -/datum/topic_input/proc/getList(i) - var/t = getAndLocate(i) - return islist(t) ? t : null + +/datum/topic_input/proc/getArea(i) + var/t = getAndLocate(i) + return isarea(t) ? t : null + +/datum/topic_input/proc/getStr(i)//params should always be text, but... + var/t = get(i) + return istext(t) ? t : null + +/datum/topic_input/proc/getType(i,type) + var/t = getAndLocate(i) + return istype(t,type) ? t : null + +/datum/topic_input/proc/getPath(i) + var/t = get(i) + if(t) + t = text2path(t) + return ispath(t) ? t : null + +/datum/topic_input/proc/getList(i) + var/t = getAndLocate(i) + return islist(t) ? t : null diff --git a/code/datums/mind.dm b/code/datums/mind.dm index 9a075f6811..b3545813ac 100644 --- a/code/datums/mind.dm +++ b/code/datums/mind.dm @@ -122,6 +122,8 @@ transfer_martial_arts(new_character) if(active || force_key_move) new_character.key = key //now transfer the key to link the client to our new body + +//CIT CHANGE - makes arousal update when transfering bodies if(isliving(new_character)) //New humans and such are by default enabled arousal. Let's always use the new mind's prefs. var/mob/living/L = new_character if(L.client && L.client.prefs) @@ -202,7 +204,6 @@ remove_antag_datum(ANTAG_DATUM_BROTHER) SSticker.mode.update_brother_icons_removed(src) - /datum/mind/proc/remove_nukeop() var/datum/antagonist/nukeop/nuke = has_antag_datum(/datum/antagonist/nukeop,TRUE) if(nuke) @@ -225,6 +226,7 @@ remove_antag_datum(rev.type) special_role = null + /datum/mind/proc/remove_antag_equip() var/list/Mob_Contents = current.get_contents() for(var/obj/item/I in Mob_Contents) @@ -462,20 +464,27 @@ text = uppertext(text) text = "[text]: " if (ishuman(current)) - text += "healthy | infected | HUMAN | other" + if(is_monkey_leader(src)) + text += "healthy | infected LEADER | human | other" + else + text += "healthy | infected | leader | HUMAN | other" else if(ismonkey(current)) var/found = FALSE for(var/datum/disease/transformation/jungle_fever/JF in current.viruses) found = TRUE break - if(found) - text += "healthy | INFECTED | human | other" + var/isLeader = is_monkey_leader(src) + + if(isLeader) + text += "healthy | infected LEADER | human | other" + else if(found) + text += "healthy | INFECTED | leader | human | other" else - text += "HEALTHY | infected | human | other" + text += "HEALTHY | infected | leader | human | other" else - text += "healthy | infected | human | OTHER" + text += "healthy | infected | leader | human | OTHER" if(current && current.client && (ROLE_MONKEY in current.client.prefs.be_special)) text += " | Enabled in Prefs" @@ -579,8 +588,8 @@ sections["revolution"] = text - /** Abductors **/ - text = "Abductor" + /** ABDUCTION **/ + text = "abductor" if(SSticker.mode.config_tag == "abductor") text = uppertext(text) text = "[text]: " @@ -807,7 +816,7 @@ else target_antag = target - var/new_obj_type = input("Select objective type:", "Objective type", def_value) as null|anything in list("assassinate", "late-assassinate", "maroon", "debrain", "protect", "destroy", "prevent", "hijack", "escape", "survive", "martyr", "steal", "download", "nuclear", "capture", "absorb", "custom") + var/new_obj_type = input("Select objective type:", "Objective type", def_value) as null|anything in list("assassinate", "maroon", "debrain", "protect", "destroy", "prevent", "hijack", "escape", "survive", "martyr", "steal", "download", "nuclear", "capture", "absorb", "custom") if (!new_obj_type) return @@ -842,12 +851,6 @@ //Will display as special role if the target is set as MODE. Ninjas/commandos/nuke ops. new_objective.update_explanation_text() - if ("late-assassinate") - new_objective = new /datum/objective/assassinate/late - new_objective.owner = src - new_objective.target = null - new_objective.find_target() //This will begin the "find-target" loop and update their explanation text - if ("destroy") var/list/possible_targets = active_ais(1) if(possible_targets.len) @@ -905,7 +908,7 @@ switch(new_obj_type) if("download") new_objective = new /datum/objective/download - new_objective.explanation_text = "Download [target_number] research levels." + new_objective.explanation_text = "Download [target_number] research node\s." if("capture") new_objective = new /datum/objective/capture new_objective.explanation_text = "Capture [target_number] lifeforms with an energy net. Live, rare specimens are worth more." @@ -1256,11 +1259,17 @@ else if (istype(M) && length(M.viruses)) for(var/thing in M.viruses) var/datum/disease/D = thing - D.cure(0) + D.cure(FALSE) + if("leader") + if(check_rights(R_ADMIN, 0)) + add_monkey_leader(src) + log_admin("[key_name(usr)] made [key_name(current)] a monkey leader!") + message_admins("[key_name_admin(usr)] made [key_name_admin(current)] a monkey leader!") if("infected") - if (check_rights(R_ADMIN, 0)) + if(check_rights(R_ADMIN, 0)) var/mob/living/carbon/human/H = current var/mob/living/carbon/monkey/M = current + add_monkey(src) if (istype(H)) log_admin("[key_name(usr)] attempting to monkeyize and infect [key_name(current)]") message_admins("[key_name_admin(usr)] attempting to monkeyize and infect [key_name_admin(current)]") @@ -1278,6 +1287,7 @@ for(var/datum/disease/transformation/jungle_fever/JF in M.viruses) JF.cure(0) stoplag() //because deleting of virus is doing throught spawn(0) //What + remove_monkey(src) log_admin("[key_name(usr)] attempting to humanize [key_name(current)]") message_admins("[key_name_admin(usr)] attempting to humanize [key_name_admin(current)]") H = M.humanize(TR_KEEPITEMS | TR_KEEPIMPLANTS | TR_KEEPORGANS | TR_KEEPDAMAGE | TR_KEEPVIRUS | TR_DEFAULTMSG) diff --git a/code/datums/mutations.dm b/code/datums/mutations.dm index 170c0a2a7f..a171cf91da 100644 --- a/code/datums/mutations.dm +++ b/code/datums/mutations.dm @@ -8,7 +8,6 @@ GLOBAL_LIST_EMPTY(mutations_list) GLOB.mutations_list[name] = src /datum/mutation/human - var/dna_block var/quality var/get_chance = 100 diff --git a/code/datums/mutations/sight.dm b/code/datums/mutations/sight.dm index dee26166dd..60f5d75c5e 100644 --- a/code/datums/mutations/sight.dm +++ b/code/datums/mutations/sight.dm @@ -7,12 +7,12 @@ /datum/mutation/human/nearsight/on_acquiring(mob/living/carbon/human/owner) if(..()) return - owner.become_nearsighted() + owner.become_nearsighted(GENETIC_MUTATION) /datum/mutation/human/nearsight/on_losing(mob/living/carbon/human/owner) if(..()) return - owner.cure_nearsighted() + owner.cure_nearsighted(GENETIC_MUTATION) //Blind makes you blind. Who knew? @@ -24,12 +24,12 @@ /datum/mutation/human/blind/on_acquiring(mob/living/carbon/human/owner) if(..()) return - owner.become_blind() + owner.become_blind(GENETIC_MUTATION) /datum/mutation/human/blind/on_losing(mob/living/carbon/human/owner) if(..()) return - owner.cure_blind() + owner.cure_blind(GENETIC_MUTATION) //X-Ray Vision lets you see through walls. diff --git a/code/datums/saymode.dm b/code/datums/saymode.dm index e372d5c0b2..176c762e9c 100644 --- a/code/datums/saymode.dm +++ b/code/datums/saymode.dm @@ -33,7 +33,7 @@ if(LINGHIVE_LING) var/datum/antagonist/changeling/changeling = user.mind.has_antag_datum(/datum/antagonist/changeling) var/msg = "[changeling.changelingID]: [message]" - log_talk(src,"[changeling.changelingID]/[user.key] : [message]",LOGSAY) + log_talk(user,"[changeling.changelingID]/[user.key] : [message]",LOGSAY) for(var/_M in GLOB.mob_list) var/mob/M = _M if(M in GLOB.dead_mob_list) @@ -110,3 +110,25 @@ AI.holopad_talk(message, language) return FALSE return TRUE + +/datum/saymode/monkey + key = "k" + mode = MODE_MONKEY + +/datum/saymode/monkey/handle_message(mob/living/user, message, datum/language/language) + var/datum/mind = user.mind + if(!mind) + return TRUE + if(is_monkey_leader(mind) || (ismonkey(user) && is_monkey(mind))) + log_talk(user, "(MONKEY) [user]/[user.key]: [message]",LOGSAY) + if(prob(75) && ismonkey(user)) + user.visible_message("\The [user] chimpers.") + var/msg = "\[[is_monkey_leader(mind) ? "Monkey Leader" : "Monkey"]\] [user]: [message]" + for(var/_M in GLOB.mob_list) + var/mob/M = _M + if(M in GLOB.dead_mob_list) + var/link = FOLLOW_LINK(M, user) + to_chat(M, "[link] [msg]") + if((is_monkey_leader(M.mind) || ismonkey(M)) && (M.mind in SSticker.mode.ape_infectees)) + to_chat(M, msg) + return FALSE diff --git a/code/datums/weakrefs.dm b/code/datums/weakrefs.dm index 2347d0f831..d8adba652c 100644 --- a/code/datums/weakrefs.dm +++ b/code/datums/weakrefs.dm @@ -16,3 +16,4 @@ /datum/weakref/proc/resolve() var/datum/D = locate(reference) return (!QDELETED(D) && D.weak_reference == src) ? D : null + diff --git a/code/datums/weather/weather_types/radiation_storm.dm b/code/datums/weather/weather_types/radiation_storm.dm index 995936e429..ab8f019d7c 100644 --- a/code/datums/weather/weather_types/radiation_storm.dm +++ b/code/datums/weather/weather_types/radiation_storm.dm @@ -25,7 +25,7 @@ /datum/weather/rad_storm/telegraph() ..() - status_alarm("alert") + status_alarm(TRUE) /datum/weather/rad_storm/weather_act(mob/living/L) @@ -49,24 +49,19 @@ if(..()) return priority_announce("The radiation threat has passed. Please return to your workplaces.", "Anomaly Alert") - status_alarm() - sleep(300) - revoke_maint_all_access() // Need to make this a timer at some point. - -/datum/weather/rad_storm/proc/status_alarm(command) //Makes the status displays show the radiation warning for those who missed the announcement. - var/datum/radio_frequency/frequency = SSradio.return_frequency(1435) + status_alarm(FALSE) +/datum/weather/rad_storm/proc/status_alarm(active) //Makes the status displays show the radiation warning for those who missed the announcement. + var/datum/radio_frequency/frequency = SSradio.return_frequency(FREQ_STATUS_DISPLAYS) if(!frequency) return - var/datum/signal/status_signal = new - var/atom/movable/virtualspeaker/virt = new /atom/movable/virtualspeaker(null) - status_signal.source = virt - status_signal.transmission_method = 1 - status_signal.data["command"] = "shuttle" + var/datum/signal/signal = new + if (active) + signal.data["command"] = "alert" + signal.data["picture_state"] = "radiation" + else + signal.data["command"] = "shuttle" - if(command == "alert") - status_signal.data["command"] = "alert" - status_signal.data["picture_state"] = "radiation" - - frequency.post_signal(src, status_signal) + var/atom/movable/virtualspeaker/virt = new(null) + frequency.post_signal(virt, signal) diff --git a/code/datums/wires/radio.dm b/code/datums/wires/radio.dm index b7b5e0d2c9..37d44a1bb0 100644 --- a/code/datums/wires/radio.dm +++ b/code/datums/wires/radio.dm @@ -11,8 +11,7 @@ /datum/wires/radio/interactable(mob/user) var/obj/item/device/radio/R = holder - if(R.b_stat) - return TRUE + return R.unscrewed /datum/wires/radio/on_pulse(index) var/obj/item/device/radio/R = holder