Buncha fixes and QoL stuff. (pH, hypo, heater and dispencer_

This commit is contained in:
Thalpy
2019-06-30 19:16:27 +01:00
parent 538e0fad29
commit 937d6467e6
14 changed files with 126 additions and 51 deletions
@@ -310,10 +310,10 @@
if(istype(O, /obj/item/organ/genital))
organCheck = TRUE
if(/obj/item/organ/genital/penis)
dna.features["has_cock"] = TRUE
//dna.features["has_cock"] = TRUE
willyCheck = TRUE
if(/obj/item/organ/genital/breasts)
dna.features["has_breasts"] = TRUE//Goddamnit get in there.
//dna.features["has_breasts"] = TRUE//Goddamnit get in there.
breastCheck = TRUE
if(organCheck == FALSE)
if(ishuman(src) && dna.species.id == "human")
@@ -134,7 +134,7 @@
..()
/datum/reagent/fermi/BEsmaller
name = "Succubus milk"
name = "Modesty milk"
id = "BEsmaller"
description = "A volatile collodial mixture derived from milk that encourages mammary production via a potent estrogen mix."
color = "#E60584" // rgb: 96, 0, 255
@@ -158,18 +158,31 @@
..()
/datum/reagent/fermi/BEsmaller_hypo
name = "Modesty milk"
name = "Rectify milk" //Rectify
id = "BEsmaller_hypo"
color = "#E60584"
taste_description = "a milky ice cream like flavour."
metabolization_rate = 0.25
description = "A medicine used to treat organomegaly in a patient's breasts."
var/sizeConv = list("a" = 1, "b" = 2, "c" = 3, "d" = 4, "e" = 5)
/datum/reagent/fermi/BEsmaller_hypo/on_mob_add(mob/living/carbon/M)
. = ..()
if(M.dna.features["has_vag"])
var/obj/item/organ/genital/vagina/nV = new
nV.Insert(M)
if(M.dna.features["has_womb"])
var/obj/item/organ/genital/womb/nW = new
nW.Insert(M)
/datum/reagent/fermi/BEsmaller_hypo/on_mob_life(mob/living/carbon/M)
var/obj/item/organ/genital/breasts/B = M.getorganslot("breasts")
if(!B)
return..()
if(B.cached_size > (sizeConv[M.dna.features["breasts_size"]]+0.1))
if(!M.dna.features["has_breasts"])//Fast fix for those who don't want it.
B.cached_size = B.cached_size - 0.1
B.update()
else if(B.cached_size > (sizeConv[M.dna.features["breasts_size"]]+0.1))
B.cached_size = B.cached_size - 0.05
B.update()
else if(B.cached_size < (sizeConv[M.dna.features["breasts_size"]])+0.1)
@@ -285,7 +298,7 @@
..()
/datum/reagent/fermi/PEsmaller // Due to cozmo's request...!
name = "Incubus draft"
name = "Chastity draft"
id = "PEsmaller"
description = "A volatile collodial mixture derived from various masculine solutions that encourages a larger gentleman's package via a potent testosterone mix, formula derived from a collaboration from Fermichem and Doctor Ronald Hyatt, who is well known for his phallus palace."
color = "#888888" // This is greyish..?
@@ -310,17 +323,27 @@
..()
/datum/reagent/fermi/PEsmaller_hypo
name = "Chastity draft"
name = "Rectify draft"
id = "PEsmaller_hypo"
color = "#888888" // This is greyish..?
taste_description = "chinese dragon powder"
description = "A medicine used to treat organomegaly in a patient's penis."
metabolization_rate = 0.5
/datum/reagent/fermi/PEsmaller_hypo/on_mob_add(mob/living/carbon/M)
. = ..()
if(M.dna.features["has_balls"])
var/obj/item/organ/genital/testicles/nT = new
nT.Insert(M)
/datum/reagent/fermi/PEsmaller_hypo/on_mob_life(mob/living/carbon/M)
var/obj/item/organ/genital/penis/P = M.getorganslot("penis")
if(!P)
return ..()
if(P.cached_length > (M.dna.features["cock_length"]+0.1))
if(!M.dna.features["has_penis"])//Fast fix for those who don't want it.
P.cached_length = P.cached_length - 0.2
P.update()
else if(P.cached_length > (M.dna.features["cock_length"]+0.1))
P.cached_length = P.cached_length - 0.1
P.update()
else if(P.cached_length < (M.dna.features["cock_length"]+0.1))
@@ -139,8 +139,8 @@
/datum/chemical_reaction/fermi/breast_enlarger
name = "Sucubus milk"
id = "breast_enlarger"
results = list("breast_enlarger" = 0.4)
required_reagents = list("salglu_solution" = 0.1, "milk" = 0.5, "synthflesh" = 0.2, "silicon" = 0.2, "aphro" = 0.2)
results = list("breast_enlarger" = 0.8)
required_reagents = list("salglu_solution" = 0.1, "milk" = 0.1, "synthflesh" = 0.2, "silicon" = 0.3, "aphro" = 0.3)
mix_message = "the reaction gives off a mist of milk."
//FermiChem vars:
OptimalTempMin = 200
@@ -151,7 +151,7 @@
ReactpHLim = 3
CatalystFact = 0
CurveSharpT = 2
CurveSharppH = 2
CurveSharppH = 1
ThermicConstant = 1
HIonRelease = -0.1
RateUpLim = 5
@@ -159,6 +159,14 @@
FermiExplode = TRUE
PurityMin = 0.1
/datum/chemical_reaction/fermi/breast_enlarger/FermiFinish(datum/reagents/holder, var/atom/my_atom)
var/datum/reagent/fermi/breast_enlarger/BE = locate(/datum/reagent/fermi/breast_enlarger) in my_atom.reagents.reagent_list
var/cached_volume = BE.volume
if(BE.purity < 0.35)
holder.remove_reagent(src.id, cached_volume)
holder.add_reagent("BEsmaller", cached_volume)
/datum/chemical_reaction/fermi/breast_enlarger/FermiExplode(datum/reagents, var/atom/my_atom, volume, temp, pH)
var/obj/item/organ/genital/breasts/B = new /obj/item/organ/genital/breasts(get_turf(my_atom))
var/list/seen = viewers(8, get_turf(my_atom))
@@ -171,7 +179,7 @@
/datum/chemical_reaction/fermi/penis_enlarger
name = "Incubus draft"
id = "penis_enlarger"
results = list("penis_enlarger" = 0.4)
results = list("penis_enlarger" = 0.8)
required_reagents = list("blood" = 0.5, "synthflesh" = 0.2, "carbon" = 0.2, "aphro" = 0.2, "salglu_solution" = 0.1,)
mix_message = "the reaction gives off a spicy mist."
//FermiChem vars:
@@ -183,7 +191,7 @@
ReactpHLim = 3
CatalystFact = 0
CurveSharpT = 2
CurveSharppH = 2
CurveSharppH = 1
ThermicConstant = 1
HIonRelease = 0.1
RateUpLim = 5
@@ -200,6 +208,13 @@
P.length = ((PE.volume * PE.purity) / 10)//half as effective.
my_atom.reagents.clear_reagents()
/datum/chemical_reaction/fermi/penis_enlarger/FermiFinish(datum/reagents/holder, var/atom/my_atom)
var/datum/reagent/fermi/penis_enlarger/PE = locate(/datum/reagent/fermi/penis_enlarger) in my_atom.reagents.reagent_list
var/cached_volume = PE.volume
if(PE.purity < 0.35)
holder.remove_reagent(src.id, cached_volume)
holder.add_reagent("PEsmaller", cached_volume)
/datum/chemical_reaction/fermi/astral
name = "Astrogen"
id = "astral"
@@ -1,4 +1,4 @@
/obj/item/FermiChem/pHbooklet
/obj/item/fermichem/pHbooklet
name = "pH indicator booklet"
desc = "A booklet containing paper soaked in universal indicator."
icon_state = "pHbooklet"
@@ -9,10 +9,10 @@
w_class = WEIGHT_CLASS_TINY
//A little janky with pockets
/obj/item/FermiChem/pHbooklet/attack_hand(mob/user)
/obj/item/fermichem/pHbooklet/attack_hand(mob/user)
if(user.get_held_index_of_item(src))//Does this check pockets too..?
if(numberOfPages >= 1)
var/obj/item/FermiChem/pHpaper/P = new /obj/item/FermiChem/pHpaper
var/obj/item/fermichem/pHpaper/P = new /obj/item/fermichem/pHpaper
P.add_fingerprint(user)
P.forceMove(user.loc)
user.put_in_active_hand(P)
@@ -34,10 +34,10 @@
if(!I)
user.put_in_active_hand(src)
/obj/item/FermiChem/pHbooklet/MouseDrop()
/obj/item/fermichem/pHbooklet/MouseDrop()
var/mob/living/user = usr
if(numberOfPages >= 1)
var/obj/item/FermiChem/pHpaper/P = new /obj/item/FermiChem/pHpaper
var/obj/item/fermichem/pHpaper/P = new /obj/item/fermichem/pHpaper
P.add_fingerprint(user)
P.forceMove(user)
user.put_in_active_hand(P)
@@ -54,7 +54,7 @@
return
..()
/obj/item/FermiChem/pHpaper
/obj/item/fermichem/pHpaper
name = "pH indicator strip"
desc = "A piece of paper that will change colour depending on the pH of a solution."
icon_state = "pHpaper"
@@ -65,7 +65,7 @@
resistance_flags = FLAMMABLE
w_class = WEIGHT_CLASS_TINY
/obj/item/FermiChem/pHpaper/afterattack(obj/item/reagent_containers/cont, mob/user, proximity)
/obj/item/fermichem/pHpaper/afterattack(obj/item/reagent_containers/cont, mob/user, proximity)
if(!istype(cont))
return
if(used == TRUE)
@@ -107,20 +107,39 @@
desc += " The paper looks to be around a pH of [round(cont.reagents.pH, 1)]"
used = TRUE
/obj/item/FermiChem/pHmeter
name = "pH meter"
/obj/item/fermichem/pHmeter
name = "Chemistry Analyser"
desc = "A a electrode attached to a small circuit box that will tell you the pH of a solution. The screen currently displays nothing."
icon_state = "pHmeter"
icon = 'modular_citadel/icons/obj/FermiChem.dmi'
resistance_flags = FLAMMABLE
w_class = WEIGHT_CLASS_TINY
var/scanmode = 1
/obj/item/FermiChem/pHmeter/afterattack(atom/A, mob/user, proximity)
/obj/item/fermichem/pHmeter/attack_self(mob/user)
if(!scanmode)
to_chat(user, "<span class='notice'>You switch the chemical analyzer to give a detailed report.</span>")
scanmode = 1
else
to_chat(user, "<span class='notice'>You switch the chemical analyzer to give a reduced report.</span>")
scanmode = 0
/obj/item/fermichem/pHmeter/afterattack(atom/A, mob/user, proximity)
. = ..()
if(!istype(A, /obj/item/reagent_containers))
return
var/obj/item/reagent_containers/cont = A
if(LAZYLEN(cont.reagents.reagent_list) == null)
return
to_chat(user, "<span class='notice'>The pH meter beeps and displays [round(cont.reagents.pH, 0.1)]</span>")
desc = "An electrode attached to a small circuit box that will tell you the pH of a solution. The screen currently displays [round(cont.reagents.pH, 0.1)]."
var/out_message
to_chat(user, "<i>The chemistry meter beeps and displays:</i>")
out_message += "<span class='notice'><b>Total volume: [round(cont.volume, 0.01)] Total pH: [round(cont.reagents.pH, 0.1)]\n"
if(cont.reagents.fermiIsReacting)
out_message += "<span class='warning'>A reaction appears to be occuring currently.<span class='notice'>\n"
out_message += "Chemicals found in the beaker:</b>\n"
for(var/datum/reagent/R in cont.reagents.reagent_list)
out_message += "<b>[R.name]</b>, Purity: [R.purity] [(scanmode?"Overdose: [R.overdose_threshold], Addiction: [R.addiction_threshold], Base pH [R.pH]":"")]\n"
if(scanmode)
out_message += "Analysis: [R.description]\n"
to_chat(user, "[out_message]</span>")
desc = "An electrode attached to a small circuit box that will analyse a beaker. It can be toggled to give a reduced or extended report. The screen currently displays [round(cont.reagents.pH, 0.1)]."