From 4145b0f256e0ebee742e761ff670504d387a9d47 Mon Sep 17 00:00:00 2001 From: Fermi Date: Tue, 25 Jun 2019 07:22:20 +0100 Subject: [PATCH] Hotfix for egregious oversights. --- code/datums/brain_damage/hypnosis.dm | 3 +++ code/modules/surgery/organs/vocal_cords.dm | 22 +++++++++---------- .../reagents/chemistry/reagents/MKUltra.dm | 4 +++- .../reagents/chemistry/reagents/SDGF.dm | 1 + .../chemistry/reagents/enlargement.dm | 4 ++-- .../chemistry/reagents/fermi_reagents.dm | 15 ++++++++++--- .../reagents/chemistry/recipes/fermi.dm | 8 ++++++- 7 files changed, 39 insertions(+), 18 deletions(-) diff --git a/code/datums/brain_damage/hypnosis.dm b/code/datums/brain_damage/hypnosis.dm index 1b592ec3a8..8909d1b85f 100644 --- a/code/datums/brain_damage/hypnosis.dm +++ b/code/datums/brain_damage/hypnosis.dm @@ -15,6 +15,9 @@ hypnotic_phrase = phrase else friendliify(phrase) + if(IsAdminAdvancedProcCall()) + to_chat(usr, "Hypnosis New() skipped due to try/catch incompatibility with admin proccalling.") + qdel(src) try target_phrase = new("(\\b[hypnotic_phrase]\\b)","ig") catch(var/exception/e) diff --git a/code/modules/surgery/organs/vocal_cords.dm b/code/modules/surgery/organs/vocal_cords.dm index 0d8ca1f37f..6c3c7e89c6 100644 --- a/code/modules/surgery/organs/vocal_cords.dm +++ b/code/modules/surgery/organs/vocal_cords.dm @@ -1148,7 +1148,7 @@ var/mob/living/carbon/human/H = V var/datum/status_effect/chem/enthrall/E = H.has_status_effect(/datum/status_effect/chem/enthrall) switch(E.phase) - if(2 to INFINITY)//Tier 2 only + if(2 to INFINITY) var/items = H.get_contents() for(var/obj/item/W in items) if(W == H.w_uniform || W == H.wear_suit) @@ -1156,24 +1156,24 @@ addtimer(CALLBACK(GLOBAL_PROC, .proc/to_chat, H, "Before you can even think about it, you quickly remove your clothes in response to [(H.lewd?"your [E.enthrallGender]'s command'":"[E.master]'s directive'")]."), 5) E.cooldown += 10 - //WALK doesn't work? it does, randomly, work now + //WALK else if((findtext(message, walk_words))) for(var/V in listeners) var/mob/living/L = V var/datum/status_effect/chem/enthrall/E = L.has_status_effect(/datum/status_effect/chem/enthrall) switch(E.phase) - if(2 to INFINITY)//Tier 2 only + if(2 to INFINITY) if(L.m_intent != MOVE_INTENT_WALK) L.toggle_move_intent() E.cooldown += 1 - //RUN doesn't work? Nope, it randomly works now + //RUN else if((findtext(message, run_words))) for(var/V in listeners) var/mob/living/L = V var/datum/status_effect/chem/enthrall/E = L.has_status_effect(/datum/status_effect/chem/enthrall) switch(E.phase) - if(2 to INFINITY)//Tier 2 only + if(2 to INFINITY) if(L.m_intent != MOVE_INTENT_RUN) L.toggle_move_intent() E.cooldown += 1 @@ -1184,7 +1184,7 @@ var/mob/living/L = V var/datum/status_effect/chem/enthrall/E = L.has_status_effect(/datum/status_effect/chem/enthrall) switch(E.phase) - if(2 to INFINITY)//Tier 2 only + if(2 to INFINITY) L.lay_down() E.cooldown += 10 addtimer(CALLBACK(GLOBAL_PROC, .proc/to_chat, L, "[(L.lewd?"You eagerly lie down!":"You suddenly lie down!'")]"), 5) @@ -1195,7 +1195,7 @@ var/mob/living/L = V var/datum/status_effect/chem/enthrall/E = L.has_status_effect(/datum/status_effect/chem/enthrall) switch(E.phase) - if(2 to INFINITY)//Tier 2 only + if(2 to INFINITY) L.Knockdown(30 * power_multiplier * E.phase) E.cooldown += 8 addtimer(CALLBACK(GLOBAL_PROC, .proc/to_chat, L, "You suddenly drop to the ground!'"), 5) @@ -1342,7 +1342,7 @@ var/mob/living/L = V var/datum/status_effect/chem/enthrall/E = L.has_status_effect(/datum/status_effect/chem/enthrall) switch(E.phase) - if(3 to INFINITY)//Tier 3 only + if(3 to INFINITY) L.Stun(40 * power_multiplier) E.cooldown += 8 addtimer(CALLBACK(GLOBAL_PROC, .proc/to_chat, L, "Your muscles freeze up!"), 5) @@ -1353,7 +1353,7 @@ var/mob/living/carbon/C = V var/datum/status_effect/chem/enthrall/E = C.has_status_effect(/datum/status_effect/chem/enthrall) switch(E.phase) - if(3 to INFINITY)//Tier 3 only + if(3 to INFINITY) new /datum/hallucination/delusion(C, TRUE, null,150 * power_multiplier,0) //HOT @@ -1362,7 +1362,7 @@ var/mob/living/L = V var/datum/status_effect/chem/enthrall/E = L.has_status_effect(/datum/status_effect/chem/enthrall) switch(E.phase) - if(3 to INFINITY)//Tier 3 only + if(3 to INFINITY) L.adjust_bodytemperature(50 * power_multiplier)//This seems nuts, reduced it, but then it didn't do anything, so I reverted it. addtimer(CALLBACK(GLOBAL_PROC, .proc/to_chat, L, "You feel your metabolism speed up!"), 5) @@ -1372,7 +1372,7 @@ var/mob/living/L = V var/datum/status_effect/chem/enthrall/E = L.has_status_effect(/datum/status_effect/chem/enthrall) switch(E.phase) - if(3 to INFINITY)//Tier 3 only + if(3 to INFINITY) L.adjust_bodytemperature(-50 * power_multiplier) addtimer(CALLBACK(GLOBAL_PROC, .proc/to_chat, L, "You feel your metabolism slow down!"), 5) diff --git a/modular_citadel/code/modules/reagents/chemistry/reagents/MKUltra.dm b/modular_citadel/code/modules/reagents/chemistry/reagents/MKUltra.dm index 40497f4957..fd54775d76 100644 --- a/modular_citadel/code/modules/reagents/chemistry/reagents/MKUltra.dm +++ b/modular_citadel/code/modules/reagents/chemistry/reagents/MKUltra.dm @@ -145,6 +145,8 @@ Creating a chem with a low purity will make you permanently fall in love with so var/mob/living/creator pH = 10 OnMobMergeCheck = TRUE //Procs on_mob_add when merging into a human + can_synth = FALSE + /datum/reagent/fermi/enthrall/test name = "MKUltraTest" @@ -309,7 +311,7 @@ Creating a chem with a low purity will make you permanently fall in love with so if(!M.has_status_effect(STATUS_EFFECT_INLOVE)) var/list/seen = viewers(7, get_turf(M))//Sound and sight checkers for(var/victim in seen) - if((victim == /mob/living/simple_animal/pet/) || (victim == M) || (M.stat == DEAD)) + if((victim == /mob/living/simple_animal/pet/) || (victim == M) || (M.stat == DEAD) || (isliving(victim))) seen = seen - victim if(seen.len == 0) return diff --git a/modular_citadel/code/modules/reagents/chemistry/reagents/SDGF.dm b/modular_citadel/code/modules/reagents/chemistry/reagents/SDGF.dm index 80fcc303bc..cb92285e12 100644 --- a/modular_citadel/code/modules/reagents/chemistry/reagents/SDGF.dm +++ b/modular_citadel/code/modules/reagents/chemistry/reagents/SDGF.dm @@ -195,6 +195,7 @@ IMPORTANT FACTORS TO CONSIDER WHILE BALANCING name = "synthetic-derived growth factor" id = "SDGFheal" metabolization_rate = 1 + can_synth = FALSE /datum/reagent/fermi/SDGFheal/on_mob_life(mob/living/carbon/M)//Used to heal the clone after splitting, the clone spawns damaged. (i.e. insentivies players to make more than required, so their clone doesn't have to be treated) if(M.blood_volume < (BLOOD_VOLUME_NORMAL*M.blood_ratio)) diff --git a/modular_citadel/code/modules/reagents/chemistry/reagents/enlargement.dm b/modular_citadel/code/modules/reagents/chemistry/reagents/enlargement.dm index 0cc1f2b23f..ce39d26a6b 100644 --- a/modular_citadel/code/modules/reagents/chemistry/reagents/enlargement.dm +++ b/modular_citadel/code/modules/reagents/chemistry/reagents/enlargement.dm @@ -19,7 +19,7 @@ //OD is low for a reason. I'd like fermichems to have low ODs, and dangerous ODs, and since this is a meme chem that everyone will rush to make, it'll be a lesson learnt early. /datum/reagent/fermi/breast_enlarger - name = "Sucubus milk" + name = "Succubus milk" id = "breast_enlarger" description = "A volatile collodial mixture derived from milk that encourages mammary production via a potent estrogen mix." color = "#E60584" // rgb: 96, 0, 255 @@ -133,7 +133,7 @@ ..() /datum/reagent/fermi/BEsmaller - name = "Sucubus milk" + name = "Succubus 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 diff --git a/modular_citadel/code/modules/reagents/chemistry/reagents/fermi_reagents.dm b/modular_citadel/code/modules/reagents/chemistry/reagents/fermi_reagents.dm index 73337f2715..743055b279 100644 --- a/modular_citadel/code/modules/reagents/chemistry/reagents/fermi_reagents.dm +++ b/modular_citadel/code/modules/reagents/chemistry/reagents/fermi_reagents.dm @@ -99,6 +99,8 @@ hatArmor = (purity/10) else hatArmor = - (purity/10) + if(hatArmor > 90) + return ..() var/obj/item/W = M.head W.armor = W.armor.modifyAllRatings(hatArmor) ..() @@ -139,7 +141,7 @@ if(prob(20)) var/list/seen = viewers(5, get_turf(M))//Sound and sight checkers for(var/victim in seen) - if((victim == /mob/living/simple_animal/pet/) || (victim == M)) + if((istype(victim, /mob/living/simple_animal/pet/)) || (victim == M) || (!isliving(victim))) seen = seen - victim if(seen) to_chat(M, "You notice [pick(seen)]'s bulge [pick("OwO!", "uwu!")]") @@ -160,7 +162,7 @@ if(prob(20)) var/list/seen = viewers(5, get_turf(M))//Sound and sight checkers for(var/victim in seen) - if((victim = /mob/living/simple_animal/pet/) || (victim == M)) + if((istype(victim, /mob/living/simple_animal/pet/)) || (victim == M) || (!isliving(victim))) seen = seen - victim if(seen) to_chat(M, "You notice [pick(seen)]'s bulge [pick("OwO!", "uwu!")]") @@ -246,10 +248,15 @@ taste_description = "acid burns, ow" color = "#FFFFFF" pH = 0 + can_synth = FALSE /datum/reagent/fermi/fermiAcid/reaction_mob(mob/living/carbon/C, method) var/target = C.get_bodypart(BODY_ZONE_CHEST) - var/acidstr = ((5-C.reagents.pH)*2) + var/acidstr + if(!C.reagents.pH || C.reagents.pH >5) + acidstr = 3 + else + acidstr = ((5-C.reagents.pH)*2) //runtime - null.pH ? C.adjustFireLoss(acidstr/2, 0) if((method==VAPOR) && (!C.wear_mask)) if(prob(20)) @@ -283,6 +290,7 @@ id = "fermiTest" description = "You should be really careful with this...! Also, how did you get this?" addProc = TRUE + can_synth = FALSE /datum/reagent/fermi/fermiTest/on_new(datum/reagents/holder) ..() @@ -318,6 +326,7 @@ description = "You should be really careful with this...! Also, how did you get this? You shouldn't have this!" data = "merge" color = "FFFFFF" + can_synth = FALSE //I'm concerned this is too weak, but I also don't want deathmixes. /datum/reagent/fermi/fermiTox/on_mob_life(mob/living/carbon/C, method) diff --git a/modular_citadel/code/modules/reagents/chemistry/recipes/fermi.dm b/modular_citadel/code/modules/reagents/chemistry/recipes/fermi.dm index 4040735356..3ab3d1391d 100644 --- a/modular_citadel/code/modules/reagents/chemistry/recipes/fermi.dm +++ b/modular_citadel/code/modules/reagents/chemistry/recipes/fermi.dm @@ -18,7 +18,7 @@ pH = 7 var/ImpureTot = 0 var/turf/T = get_turf(my_atom) - + if(temp>500)//if hot, start a fire switch(temp) if (500 to 750) @@ -89,6 +89,8 @@ PurityMin = 0.4 //The minimum purity something has to be above, otherwise it explodes. /datum/chemical_reaction/fermi/eigenstate/FermiFinish(datum/reagents/holder, var/atom/my_atom)//Strange how this doesn't work but the other does. + if(!locate(/datum/reagent/fermi/eigenstate) in my_atom.reagents.reagent_list) + return var/turf/open/location = get_turf(my_atom) var/datum/reagent/fermi/eigenstate/E = locate(/datum/reagent/fermi/eigenstate) in my_atom.reagents.reagent_list if(location) @@ -397,6 +399,8 @@ /datum/chemical_reaction/fermi/fermiABuffer/FermiFinish(datum/reagents/holder, var/atom/my_atom) //might need this + if(!locate(/datum/reagent/fermi/fermiABuffer) in my_atom.reagents.reagent_list) + return var/datum/reagent/fermi/fermiABuffer/Fa = locate(/datum/reagent/fermi/fermiABuffer) in my_atom.reagents.reagent_list Fa.data = 3 @@ -423,6 +427,8 @@ /datum/chemical_reaction/fermi/fermiBBuffer/FermiFinish(datum/reagents/holder, var/atom/my_atom) //might need this + if(!locate(/datum/reagent/fermi/fermiBBuffer) in my_atom.reagents.reagent_list) + return var/datum/reagent/fermi/fermiBBuffer/Fb = locate(/datum/reagent/fermi/fermiBBuffer) in my_atom.reagents.reagent_list Fb.data = 11