From a050bc450385ab107f2727ecaa113946d8435ad8 Mon Sep 17 00:00:00 2001 From: iloveloopers <140007537+iloveloopers@users.noreply.github.com> Date: Sun, 28 Apr 2024 23:31:32 -0400 Subject: [PATCH 1/3] Update Chemistry-Reagents.dm --- code/modules/reagents/Chemistry-Reagents.dm | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/code/modules/reagents/Chemistry-Reagents.dm b/code/modules/reagents/Chemistry-Reagents.dm index 9825c12501c0..3e4fb8f300a3 100644 --- a/code/modules/reagents/Chemistry-Reagents.dm +++ b/code/modules/reagents/Chemistry-Reagents.dm @@ -182,14 +182,17 @@ GLOBAL_LIST_INIT(name2reagent, build_name2reagent()) if(potency <= 0) continue P.process(M, potency, delta_time) - if(flags & REAGENT_CANNOT_OVERDOSE) - continue if(overdose && volume > overdose) - P.process_overdose(M, potency, delta_time) - if(overdose_critical && volume > overdose_critical) - P.process_critical(M, potency, delta_time) - var/overdose_message = "[istype(src, /datum/reagent/generated) ? "custom chemical" : initial(name)] overdose" - M.last_damage_data = create_cause_data(overdose_message, last_source_mob?.resolve()) + if(flags & REAGENT_CANNOT_OVERDOSE) + var/ammount_overdosed = volume - overdose + holder.remove_reagent(id, ammount_overdosed) + holder.add_reagent("sugar", ammount_overdosed) + else + P.process_overdose(M, potency, delta_time) + if(overdose_critical && volume > overdose_critical) + P.process_critical(M, potency, delta_time) + var/overdose_message = "[istype(src, /datum/reagent/generated) ? "custom chemical" : initial(name)] overdose" + M.last_damage_data = create_cause_data(overdose_message, last_source_mob?.resolve()) if(mods[REAGENT_PURGE]) holder.remove_all_type(/datum/reagent,mods[REAGENT_PURGE] * delta_time) From 846cb01667b20171895c50fdb3f8bd8d86bcf6d1 Mon Sep 17 00:00:00 2001 From: iloveloopers <140007537+iloveloopers@users.noreply.github.com> Date: Sun, 28 Apr 2024 23:31:46 -0400 Subject: [PATCH 2/3] Update prop_positive.dm --- .../chemistry_properties/prop_positive.dm | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/code/modules/reagents/chemistry_properties/prop_positive.dm b/code/modules/reagents/chemistry_properties/prop_positive.dm index a8a11fc299ad..60b3e82feaae 100644 --- a/code/modules/reagents/chemistry_properties/prop_positive.dm +++ b/code/modules/reagents/chemistry_properties/prop_positive.dm @@ -992,3 +992,20 @@ /datum/chem_property/positive/anticarcinogenic/process_critical(mob/living/M, potency = 1) M.take_limb_damage(POTENCY_MULTIPLIER_MEDIUM * potency)//Hyperactive apoptosis + +/datum/chem_property/positive/regulating + name = PROPERTY_REGULATING + code = "REG" + description = "The chemical regulates its own metabolization, any ammount overdosed is turned into sugar." + rarity = PROPERTY_COMMON + category = PROPERTY_TYPE_METABOLITE + max_level = 1 + value = 0 + +/datum/chem_property/positive/regulating/reset_reagent() + holder.flags = initial(holder.flags) + ..() + +/datum/chem_property/positive/regulating/update_reagent() + holder.flags |= REAGENT_CANNOT_OVERDOSE + ..() From f5da4cc32abe6c42ca5ba8a4782c617c654d8c7a Mon Sep 17 00:00:00 2001 From: iloveloopers <140007537+iloveloopers@users.noreply.github.com> Date: Sun, 28 Apr 2024 23:31:59 -0400 Subject: [PATCH 3/3] Update prop_special.dm --- .../chemistry_properties/prop_special.dm | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/code/modules/reagents/chemistry_properties/prop_special.dm b/code/modules/reagents/chemistry_properties/prop_special.dm index cee75ca58c06..7d602db24bfa 100644 --- a/code/modules/reagents/chemistry_properties/prop_special.dm +++ b/code/modules/reagents/chemistry_properties/prop_special.dm @@ -13,22 +13,6 @@ /datum/chem_property/special/boosting/pre_process(mob/living/M) return list(REAGENT_BOOST = level) -/datum/chem_property/special/regulating - name = PROPERTY_REGULATING - code = "REG" - description = "The chemical regulates its own metabolization and can thus never cause overdosis." - rarity = PROPERTY_LEGENDARY - category = PROPERTY_TYPE_METABOLITE - max_level = 1 - -/datum/chem_property/special/regulating/reset_reagent() - holder.flags = initial(holder.flags) - ..() - -/datum/chem_property/special/regulating/update_reagent() - holder.flags |= REAGENT_CANNOT_OVERDOSE - ..() - /datum/chem_property/special/hypergenetic name = PROPERTY_HYPERGENETIC code = "HGN"