From e72b6767ed0bd3f4090721d2c8efd3293d1900b4 Mon Sep 17 00:00:00 2001 From: XDTM Date: Sun, 23 Jul 2017 00:10:40 +0200 Subject: [PATCH] Virology fixes (#29428) * Pandemic now reads data from the virus itself rather than the global copy * Fixes id mismatch --- code/datums/diseases/advance/advance.dm | 3 ++- code/modules/reagents/chemistry/machinery/pandemic.dm | 7 ++++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/code/datums/diseases/advance/advance.dm b/code/datums/diseases/advance/advance.dm index f71055f3c63..e8ddfdc3d7e 100644 --- a/code/datums/diseases/advance/advance.dm +++ b/code/datums/diseases/advance/advance.dm @@ -294,6 +294,8 @@ var/list/L = list() for(var/datum/symptom/S in symptoms) L += S.id + if(S.neutered) + L += "N" L = sortList(L) // Sort the list so it doesn't matter which order the symptoms are in. var/result = jointext(L, ":") id = result @@ -324,7 +326,6 @@ if(!S.neutered) S.neutered = TRUE S.name += " (neutered)" - S.id += "N" //new disease is unique /* diff --git a/code/modules/reagents/chemistry/machinery/pandemic.dm b/code/modules/reagents/chemistry/machinery/pandemic.dm index 1685eeb72db..46597fb0280 100644 --- a/code/modules/reagents/chemistry/machinery/pandemic.dm +++ b/code/modules/reagents/chemistry/machinery/pandemic.dm @@ -46,10 +46,11 @@ var/list/this = list() this["name"] = D.name if(istype(D, /datum/disease/advance)) - var/datum/disease/advance/A = SSdisease.archive_diseases[D.GetDiseaseID()] - if(A.name == "Unknown") + var/datum/disease/advance/A = D + var/datum/disease/advance/archived = SSdisease.archive_diseases[D.GetDiseaseID()] + if(archived.name == "Unknown") this["can_rename"] = TRUE - this["name"] = A.name + this["name"] = archived.name this["is_adv"] = TRUE this["resistance"] = A.totalResistance() this["stealth"] = A.totalStealth()