mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-07-16 09:34:52 +01:00
Forensics Datum (#17796)
* forensics datum initial work * typo fix * glove recursion fix * missing bloodtype on organ data * removed frustrating and unneeded b_type var from humans * no leaky * listcheck * documenting * documentation
This commit is contained in:
@@ -461,11 +461,12 @@ var/const/CE_STABLE_THRESHOLD = 0.5
|
||||
|
||||
// Update blood information.
|
||||
if(source.data["blood_DNA"])
|
||||
B.blood_DNA = list()
|
||||
var/list/new_data = list()
|
||||
if(source.data["blood_type"])
|
||||
B.blood_DNA[source.data["blood_DNA"]] = source.data["blood_type"]
|
||||
new_data[source.data["blood_DNA"]] = source.data["blood_type"]
|
||||
else
|
||||
B.blood_DNA[source.data["blood_DNA"]] = "O+"
|
||||
new_data[source.data["blood_DNA"]] = "O+"
|
||||
B.init_forensic_data().merge_blooddna(null,new_data)
|
||||
|
||||
// Update virus information.
|
||||
if(source.data["viruses"])
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
self_clear = TRUE
|
||||
|
||||
// Setup cached dna data, as storing the entire DNA cloned is horrifically laggy
|
||||
b_type = dna.b_type
|
||||
unique_enzymes = dna.unique_enzymes
|
||||
body_gender = dna.GetUIState(DNA_UI_GENDER)
|
||||
if(!isnull(dna.GetUIValue(DNA_UI_SKIN_TONE)))
|
||||
|
||||
@@ -105,9 +105,7 @@ var/list/organ_cache = list()
|
||||
E.internal_organs = list()
|
||||
E.internal_organs |= src
|
||||
if(data)
|
||||
if(!blood_DNA)
|
||||
blood_DNA = list()
|
||||
blood_DNA[data.unique_enzymes] = data.b_type
|
||||
add_blooddna_organ(data)
|
||||
else
|
||||
data.setup_from_species(GLOB.all_species["Human"])
|
||||
|
||||
@@ -131,9 +129,8 @@ var/list/organ_cache = list()
|
||||
/obj/item/organ/proc/set_dna(var/datum/dna/new_dna)
|
||||
if(new_dna)
|
||||
data.setup_from_dna(new_dna)
|
||||
if(blood_DNA)
|
||||
blood_DNA.Cut()
|
||||
blood_DNA[data.unique_enzymes] = data.b_type
|
||||
forensic_data?.clear_blooddna()
|
||||
add_blooddna_organ(data)
|
||||
|
||||
/obj/item/organ/proc/die()
|
||||
if(robotic < ORGAN_ROBOT)
|
||||
@@ -460,10 +457,8 @@ var/list/organ_cache = list()
|
||||
|
||||
// Pass over the blood.
|
||||
reagents.trans_to(O, reagents.total_volume)
|
||||
|
||||
if(fingerprints) O.fingerprints = fingerprints.Copy()
|
||||
if(fingerprintshidden) O.fingerprintshidden = fingerprintshidden.Copy()
|
||||
if(fingerprintslast) O.fingerprintslast = fingerprintslast
|
||||
transfer_fingerprints_to(O)
|
||||
transfer_blooddna_to(O)
|
||||
|
||||
user.put_in_active_hand(O)
|
||||
qdel(src)
|
||||
|
||||
Reference in New Issue
Block a user