diff --git a/code/game/objects/items/devices/scanners.dm b/code/game/objects/items/devices/scanners.dm index ada6dcfce83..d6446c64134 100644 --- a/code/game/objects/items/devices/scanners.dm +++ b/code/game/objects/items/devices/scanners.dm @@ -92,6 +92,23 @@ REAGENT SCANNER M.invisibility = INVISIBILITY_LEVEL_TWO +/proc/chemscan(var/mob/living/user, var/mob/living/M) + if(ishuman(M)) + var/mob/living/carbon/human/H = M + if(H.reagents) + if(H.reagents.reagent_list.len) + user.show_message("Subject contains the following reagents:") + for(var/datum/reagent/R in H.reagents.reagent_list) + user.show_message("[R.volume]u of [R.name][R.overdosed == 1 ? " - OVERDOSING" : "."]") + else + user.show_message("Subject contains no reagents.") + if(H.reagents.addiction_list.len) + user.show_message("Subject is addicted to the following reagents:") + for(var/datum/reagent/R in H.reagents.addiction_list) + user.show_message("[R.name]") + else + user.show_message("Subject is not addicted to any reagents.") + /obj/item/device/healthanalyzer name = "Health Analyzer" icon_state = "health" @@ -172,12 +189,8 @@ REAGENT SCANNER OX = fake_oxy > 50 ? "\red Severe oxygen deprivation detected\blue" : "Subject bloodstream oxygen level normal" user.show_message("[OX] | [TX] | [BU] | [BR]") if (istype(M, /mob/living/carbon)) - if(M:reagents.total_volume > 0 && upgraded) - user.show_message("\blue Reagents detected in subject's blood:") - for(var/A in M.reagents.reagent_list) - var/datum/reagent/R = A - user.show_message("\t \blue [M.reagents.get_reagent_amount(R.id)]u [R.name]") - if(M:virus2.len) + chemscan(user, M) + if(M:virus2.len) // WHAT IS TYPECASTING var/mob/living/carbon/C = M for (var/ID in C.virus2) if (ID in virusDB) diff --git a/code/modules/reagents/Chemistry-Reagents.dm b/code/modules/reagents/Chemistry-Reagents.dm index bd7e7b9fba6..e1fc9891302 100644 --- a/code/modules/reagents/Chemistry-Reagents.dm +++ b/code/modules/reagents/Chemistry-Reagents.dm @@ -22,7 +22,6 @@ datum var/volume = 0 var/nutriment_factor = 0 var/metabolization_rate = REAGENTS_METABOLISM - var/scannable = 1 //shows up on health analyzers //var/list/viruses = list() var/color = "#000000" // rgb: 0, 0, 0 (does not support alpha channels - yet!) @@ -89,6 +88,7 @@ datum return //Noticed runtime errors from pacid trying to damage ghosts, this should fix. --NEO // Certain elements in too large amounts cause side-effects holder.remove_reagent(src.id, metabolization_rate) //By default it slowly disappears. + current_cycle++ return // Called when two reagents of the same are mixing. @@ -1035,14 +1035,9 @@ datum description = "Most probably know this as Tylenol, but this chemical is a mild, simple painkiller." reagent_state = LIQUID color = "#C855DC" -<<<<<<< HEAD - scannable = 1 metabolization_rate = 0.2 // Lasts 2.5 minutes for 15 units -======= - custom_metabolism = 0.2 // Lasts 2.5 minutes for 15 units ->>>>>>> 8c265bf6aac1e630b2627439f8a95d5e2d917aab - on_mob_life(var/mob/living/M as mob) + on_mob_life(var/mob/living/M as mob) // what the fuck are you idiots smoking if(!M) M = holder.my_atom ..() return @@ -1080,12 +1075,7 @@ datum description = "A simple, yet effective painkiller." reagent_state = LIQUID color = "#C8A5DC" -<<<<<<< HEAD - scannable = 1 metabolization_rate = 0.2 // Lasts 2.5 minutes for 15 units -======= - custom_metabolism = 0.2 // Lasts 2.5 minutes for 15 units ->>>>>>> 8c265bf6aac1e630b2627439f8a95d5e2d917aab on_mob_life(var/mob/living/M as mob) if(!M) M = holder.my_atom @@ -1099,12 +1089,7 @@ datum description = "An effective and very addictive painkiller." reagent_state = LIQUID color = "#C805DC" -<<<<<<< HEAD metabolization_rate = 0.3 // Lasts 1.5 minutes for 15 units - scannable = 1 -======= - custom_metabolism = 0.3 // Lasts 1.5 minutes for 15 units ->>>>>>> 8c265bf6aac1e630b2627439f8a95d5e2d917aab on_mob_life(var/mob/living/M as mob) if(!M) M = holder.my_atom diff --git a/code/modules/reagents/newchem/newchem_procs.dm b/code/modules/reagents/newchem/newchem_procs.dm index a061f2c3ffe..9ed35668e76 100644 --- a/code/modules/reagents/newchem/newchem_procs.dm +++ b/code/modules/reagents/newchem/newchem_procs.dm @@ -9,9 +9,6 @@ datum/reagents var/addiction_tick = 1 var/list/datum/reagent/addiction_list = new/list() -datum/reagent/on_mob_life() - current_cycle++ - datum/reagents/proc/metabolize(var/mob/M) if(M) chem_temp = M.bodytemperature