From cea99570628af9c4c21d4262692a53ad1a98be0f Mon Sep 17 00:00:00 2001 From: Iamgoofball Date: Tue, 24 Mar 2015 20:54:59 -0700 Subject: [PATCH 1/3] MUH FIXES --- code/game/objects/items/weapons/grenades/chem_grenade.dm | 5 +++-- code/modules/reagents/Chemistry-Machinery.dm | 2 +- code/modules/reagents/newchem/medicine.dm | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/code/game/objects/items/weapons/grenades/chem_grenade.dm b/code/game/objects/items/weapons/grenades/chem_grenade.dm index 02c7d142b0f..48a826abc96 100644 --- a/code/game/objects/items/weapons/grenades/chem_grenade.dm +++ b/code/game/objects/items/weapons/grenades/chem_grenade.dm @@ -266,10 +266,11 @@ invisibility = INVISIBILITY_MAXIMUM //kaboom del nadeassembly // do this now to stop infrared beams - + var/end_temp = 0 for(var/obj/item/weapon/reagent_containers/glass/G in beakers) G.reagents.trans_to(src, G.reagents.total_volume) - + end_temp += G.reagents.chem_temp + reagents.chem_temp = end_temp if(reagents.total_volume) //The possible reactions didnt use up all reagents. var/datum/effect/effect/system/steam_spread/steam = new /datum/effect/effect/system/steam_spread() steam.set_up(10, 0, get_turf(src)) diff --git a/code/modules/reagents/Chemistry-Machinery.dm b/code/modules/reagents/Chemistry-Machinery.dm index 1e216767dba..19f3f64724e 100644 --- a/code/modules/reagents/Chemistry-Machinery.dm +++ b/code/modules/reagents/Chemistry-Machinery.dm @@ -19,7 +19,7 @@ var/hackedcheck = 0 var/list/dispensable_reagents = list("hydrogen","lithium","carbon","nitrogen","oxygen","fluorine", "sodium","aluminum","silicon","phosphorus","sulfur","chlorine","potassium","iron", - "copper","mercury","plasma","radium","water","ethanol","sugar","sacid","tungsten","iodine","bromine") + "copper","mercury","plasma","radium","water","ethanol","sugar","sacid","tungsten","iodine","bromine","silver") var/list/hacked_reagents = list("toxin") var/hack_message = "You disable the safety safeguards, enabling the \"Mad Scientist\" mode." var/unhack_message = "You re-enable the safety safeguards, enabling the \"NT Standard\" mode." diff --git a/code/modules/reagents/newchem/medicine.dm b/code/modules/reagents/newchem/medicine.dm index 3dfc173651b..07594a305a8 100644 --- a/code/modules/reagents/newchem/medicine.dm +++ b/code/modules/reagents/newchem/medicine.dm @@ -144,7 +144,7 @@ datum/reagent/charcoal/on_mob_life(var/mob/living/M as mob) name = "Styptic Powder" id = "styptic_powder" result = "styptic_powder" - required_reagents = list("aluminium" = 1, "hydrogen" = 1, "oxygen" = 1, "sacid" = 1) + required_reagents = list("aluminum" = 1, "hydrogen" = 1, "oxygen" = 1, "sacid" = 1) result_amount = 4 mix_message = "The solution yields an astringent powder." From f165cb70794cb1d5562792c233dc8af94527a9e9 Mon Sep 17 00:00:00 2001 From: Iamgoofball Date: Tue, 24 Mar 2015 21:01:02 -0700 Subject: [PATCH 2/3] muh fixes 2.0 --- code/game/machinery/vending.dm | 2 +- code/modules/reagents/newchem/toxins.dm | 13 +++++++++++++ .../reagents/reagent_containers/glass/bottle.dm | 11 ++++++++++- 3 files changed, 24 insertions(+), 2 deletions(-) diff --git a/code/game/machinery/vending.dm b/code/game/machinery/vending.dm index d5dc9a0e838..92462c401c7 100644 --- a/code/game/machinery/vending.dm +++ b/code/game/machinery/vending.dm @@ -888,7 +888,7 @@ icon_deny = "med-deny" product_ads = "Go save some lives!;The best stuff for your medbay.;Only the finest tools.;Natural chemicals!;This stuff saves lives.;Don't you want some?;Ping!" req_access_txt = "5" - products = list(/obj/item/weapon/reagent_containers/glass/bottle/antitoxin = 4,/obj/item/weapon/reagent_containers/glass/bottle/inaprovaline = 4, + products = list(/obj/item/weapon/reagent_containers/glass/bottle/antitoxin = 4,/obj/item/weapon/reagent_containers/glass/bottle/morphine = 4,/obj/item/weapon/reagent_containers/glass/bottle/inaprovaline = 4, /obj/item/weapon/reagent_containers/glass/bottle/stoxin = 4,/obj/item/weapon/reagent_containers/glass/bottle/toxin = 4, /obj/item/weapon/reagent_containers/syringe/antiviral = 4,/obj/item/weapon/reagent_containers/syringe = 12, /obj/item/device/healthanalyzer = 5,/obj/item/device/healthupgrade = 5,/obj/item/weapon/reagent_containers/glass/beaker = 4, /obj/item/weapon/reagent_containers/dropper = 2, diff --git a/code/modules/reagents/newchem/toxins.dm b/code/modules/reagents/newchem/toxins.dm index e8b26c70533..64c77fd8fb3 100644 --- a/code/modules/reagents/newchem/toxins.dm +++ b/code/modules/reagents/newchem/toxins.dm @@ -198,6 +198,19 @@ datum/reagent/itching_powder/on_mob_life(var/mob/living/M as mob) required_reagents = list("fuel" = 1, "ammonia" = 1, "charcoal" = 1) result_amount = 3 +datum/reagent/facid/on_mob_life(var/mob/living/M as mob) + if(!M) M = holder.my_atom + M.adjustToxLoss(2*REM) + M.take_organ_damage(0, 1*REM) + ..() + return + +datum/reagent/facid + name = "Fluorosulfuric Acid" + id = "facid" + description = "" + reagent_state = LIQUID + color = "#CF3600" /datum/chemical_reaction/facid name = "Fluorosulfuric acid" id = "facid" diff --git a/code/modules/reagents/reagent_containers/glass/bottle.dm b/code/modules/reagents/reagent_containers/glass/bottle.dm index 5c903608707..72ad5b32575 100644 --- a/code/modules/reagents/reagent_containers/glass/bottle.dm +++ b/code/modules/reagents/reagent_containers/glass/bottle.dm @@ -192,4 +192,13 @@ icon_state = "bottle17" New() ..() - reagents.add_reagent("frostoil", 30) \ No newline at end of file + reagents.add_reagent("frostoil", 30) + +/obj/item/weapon/reagent_containers/glass/bottle/morphine + name = "Morphine Bottle" + desc = "A small bottle. Contains morphine." + icon = 'icons/obj/chemical.dmi' + icon_state = "bottle17" + New() + ..() + reagents.add_reagent("morphine", 30) \ No newline at end of file From 4f3cc168a456919fb8e81fc2aeef499d4ca54a2c Mon Sep 17 00:00:00 2001 From: Iamgoofball Date: Tue, 24 Mar 2015 21:11:18 -0700 Subject: [PATCH 3/3] fixes facid and makes it work, renames bad food --- code/modules/reagents/newchem/toxins.dm | 74 ++++++++++++++++++++++++- 1 file changed, 72 insertions(+), 2 deletions(-) diff --git a/code/modules/reagents/newchem/toxins.dm b/code/modules/reagents/newchem/toxins.dm index 64c77fd8fb3..c485f283835 100644 --- a/code/modules/reagents/newchem/toxins.dm +++ b/code/modules/reagents/newchem/toxins.dm @@ -148,7 +148,7 @@ datum/reagent/cyanide/on_mob_life(var/mob/living/M as mob) required_temp = 380 /datum/reagent/questionmark // food poisoning - name = "Bad Food" + name = "????" id = "????" description = "????" reagent_state = LIQUID @@ -211,8 +211,78 @@ datum/reagent/facid description = "" reagent_state = LIQUID color = "#CF3600" + +datum/reagent/facid/reaction_mob(var/mob/living/M, var/method=TOUCH, var/volume) + if(!istype(M, /mob/living)) + return //wooo more runtime fixin + if(method == TOUCH) + if(ishuman(M)) + var/mob/living/carbon/human/H = M + + if(H.wear_mask) + if(!H.wear_mask.unacidable) + qdel (H.wear_mask) + H.update_inv_wear_mask() + H << "\red Your mask melts away but protects you from the acid!" + else + H << "\red Your mask protects you from the acid!" + return + + if(H.head) + if(prob(15) && !H.head.unacidable) + qdel(H.head) + H.update_inv_head() + H << "\red Your helmet melts away but protects you from the acid" + else + H << "\red Your helmet protects you from the acid!" + return + + if(!H.unacidable) + var/datum/organ/external/affecting = H.get_organ("head") + if(affecting.take_damage(15, 0)) + H.UpdateDamageIcon() + H.emote("scream") + else if(ismonkey(M)) + var/mob/living/carbon/monkey/MK = M + + if(MK.wear_mask) + if(!MK.wear_mask.unacidable) + qdel (MK.wear_mask) + MK.update_inv_wear_mask() + MK << "\red Your mask melts away but protects you from the acid!" + else + MK << "\red Your mask protects you from the acid!" + return + + if(!MK.unacidable) + MK.take_organ_damage(min(15, volume * 4)) // same deal as sulphuric acid + else + if(!M.unacidable) + if(ishuman(M)) + var/mob/living/carbon/human/H = M + var/datum/organ/external/affecting = H.get_organ("head") + if(affecting.take_damage(15, 0)) + H.UpdateDamageIcon() + H.emote("scream") + H.status_flags |= DISFIGURED + else + M.take_organ_damage(min(15, volume * 4)) + +datum/reagent/facid/reaction_obj(var/obj/O, var/volume) + if(istype(O,/obj/item/weapon/organ/head)) + new/obj/item/weapon/skeleton/head(O.loc) + for(var/mob/M in viewers(5, O)) + M << "\red \the [O] melts." + qdel(O) + if((istype(O,/obj/item) || istype(O,/obj/effect/glowshroom))) + if(!O.unacidable) + var/obj/effect/decal/cleanable/molten_item/I = new/obj/effect/decal/cleanable/molten_item(O.loc) + I.desc = "Looks like this was \an [O] some time ago." + for(var/mob/M in viewers(5, O)) + M << "\red \the [O] melts." + qdel(O) /datum/chemical_reaction/facid - name = "Fluorosulfuric acid" + name = "Fluorosulfuric Acid" id = "facid" result = "facid" required_reagents = list("sacid" = 1, "fluorine" = 1, "hydrogen" = 1, "potassium" = 1)