From 757d4a66beeefecfc41e920841250795064bad4c Mon Sep 17 00:00:00 2001 From: fludd12 Date: Thu, 23 Mar 2017 19:44:33 -0400 Subject: [PATCH] Redoes everything --- code/__HELPERS/text.dm | 30 +++++----- code/game/dna/genes/vg_powers.dm | 11 ++-- .../mob/living/carbon/human/human_defense.dm | 3 + .../reagents/chemistry/reagents/water.dm | 57 ++++++++++++++++++- 4 files changed, 80 insertions(+), 21 deletions(-) diff --git a/code/__HELPERS/text.dm b/code/__HELPERS/text.dm index 89755d7acf0..864fc094286 100644 --- a/code/__HELPERS/text.dm +++ b/code/__HELPERS/text.dm @@ -448,32 +448,32 @@ proc/checkhtml(var/t) // Pencode -/proc/pencode_to_html(text, mob/user, obj/item/weapon/pen/P = null, sign = 1, fields = 1, deffont = PEN_FONT, signfont = SIGNFONT, crayonfont = CRAYON_FONT) - text = replacetext(text, "\n", "
") - text = replacetext(text, "\[center\]", "
") - text = replacetext(text, "\[/center\]", "
") - text = replacetext(text, "\[br\]", "
") +/proc/pencode_to_html(text, mob/user, obj/item/weapon/pen/P = null, format = 1, sign = 1, fields = 1, deffont = PEN_FONT, signfont = SIGNFONT, crayonfont = CRAYON_FONT) text = replacetext(text, "\[b\]", "") text = replacetext(text, "\[/b\]", "") text = replacetext(text, "\[i\]", "") text = replacetext(text, "\[/i\]", "") text = replacetext(text, "\[u\]", "") text = replacetext(text, "\[/u\]", "") - text = replacetext(text, "\[large\]", "") - text = replacetext(text, "\[/large\]", "") if(sign) text = replacetext(text, "\[sign\]", "[user ? user.real_name : "Anonymous"]") if(fields) text = replacetext(text, "\[field\]", "") + if(format) + text = replacetext(text, "\[h1\]", "

") + text = replacetext(text, "\[/h1\]", "

") + text = replacetext(text, "\[h2\]", "

") + text = replacetext(text, "\[/h2\]", "

") + text = replacetext(text, "\[h3\]", "

") + text = replacetext(text, "\[/h3\]", "

") + text = replacetext(text, "\n", "
") + text = replacetext(text, "\[center\]", "
") + text = replacetext(text, "\[/center\]", "
") + text = replacetext(text, "\[br\]", "
") + text = replacetext(text, "\[large\]", "") + text = replacetext(text, "\[/large\]", "") - text = replacetext(text, "\[h1\]", "

") - text = replacetext(text, "\[/h1\]", "

") - text = replacetext(text, "\[h2\]", "

") - text = replacetext(text, "\[/h2\]", "

") - text = replacetext(text, "\[h3\]", "

") - text = replacetext(text, "\[/h3\]", "

") - - if(istype(P, /obj/item/toy/crayon)) // If it is a crayon, and he still tries to use these, make them empty! + if(istype(P, /obj/item/toy/crayon) | !format) // If it is a crayon, and he still tries to use these, make them empty! text = replacetext(text, "\[*\]", "") text = replacetext(text, "\[hr\]", "") text = replacetext(text, "\[small\]", "") diff --git a/code/game/dna/genes/vg_powers.dm b/code/game/dna/genes/vg_powers.dm index e159aa44247..0a336695082 100644 --- a/code/game/dna/genes/vg_powers.dm +++ b/code/game/dna/genes/vg_powers.dm @@ -211,11 +211,11 @@ /obj/effect/proc_holder/spell/targeted/remotetalk/choose_targets(mob/user = usr) var/list/targets = new /list() var/list/validtargets = new /list() - for(var/mob/M in view(user.client.view, user)) + var/turf/T = get_turf(user) + for(var/mob/M in range(14, T)) if(M && M.mind) if(M == user) continue - validtargets += M if(!validtargets.len) @@ -237,14 +237,15 @@ if(!say) return say = strip_html(say) + say = pencode_to_html(say, usr, format = 0, fields = 0 for(var/mob/living/target in targets) log_say("Project Mind: [key_name(user)]->[key_name(target)]: [say]") if(REMOTE_TALK in target.mutations) - target.show_message("You hear [user.real_name]'s voice: [say]") + target.show_message("You hear [user.real_name]'s voice: [say]") else - target.show_message("You hear a voice that seems to echo around the room: [say]") - user.show_message("You project your mind into [target.real_name]: [say]") + target.show_message("You hear a voice that seems to echo around the room: [say]") + user.show_message("You project your mind into [target.real_name]: [say]") for(var/mob/dead/observer/G in player_list) G.show_message("Telepathic message from [user] ([ghost_follow_link(user, ghost=G)]) to [target] ([ghost_follow_link(target, ghost=G)]): [say]") diff --git a/code/modules/mob/living/carbon/human/human_defense.dm b/code/modules/mob/living/carbon/human/human_defense.dm index 3f25873e5f2..c4b9540d899 100644 --- a/code/modules/mob/living/carbon/human/human_defense.dm +++ b/code/modules/mob/living/carbon/human/human_defense.dm @@ -471,3 +471,6 @@ emp_act ..() if(temperature >= 330) bodytemperature = bodytemperature + (temperature - bodytemperature) if(temperature <= 280) bodytemperature = bodytemperature - (bodytemperature - temperature) + if(get_species() == "Grey") + take_organ_damage(5,min(volume,20)) + emote("scream") diff --git a/code/modules/reagents/chemistry/reagents/water.dm b/code/modules/reagents/chemistry/reagents/water.dm index 70d2a9f76c0..773d03c6006 100644 --- a/code/modules/reagents/chemistry/reagents/water.dm +++ b/code/modules/reagents/chemistry/reagents/water.dm @@ -20,10 +20,65 @@ drink_desc = "The father of all refreshments." /datum/reagent/water/reaction_mob(mob/living/M, method=TOUCH, volume) -// Put out fire if(method == TOUCH) + // Put out fire M.adjust_fire_stacks(-(volume / 10)) M.ExtinguishMob() + if(ishuman(M)) + + var/mob/living/carbon/human/H = M + + if(H.get_species() != "Grey") //God this is so gross I hate it. + return + + if(volume > 25) + + if(H.wear_mask) + to_chat(H, "Your mask protects you from the water!") + return + + if(H.head) + to_chat(H, "Your helmet protects you from the water!") + return + + if(!M.unacidable) + if(prob(75)) + var/obj/item/organ/external/affecting = H.get_organ("head") + if(affecting) + affecting.take_damage(5, 10) + H.UpdateDamageIcon() + H.emote("scream") + else + M.take_organ_damage(5,10) + else + M.take_organ_damage(5,10) + + if(method == INGEST) + if(ishuman(M)) + var/mob/living/carbon/human/H = M + + if(H.get_species() != "Grey") + return + + if(volume < 10) + to_chat(M, "The watery solvent substance stings you, but isn't concentrated enough to harm you!") + + if(volume >=10 && volume <=25) + if(!H.unacidable) + M.take_organ_damage(0,min(max(volume-10,2)*2,20)) + M.emote("scream") + + + if(volume > 25) + if(!M.unacidable) + if(prob(75)) + var/obj/item/organ/external/affecting = H.get_organ("head") + if(affecting) + affecting.take_damage(0, 20) + H.UpdateDamageIcon() + H.emote("scream") + else + M.take_organ_damage(0,20) /datum/reagent/water/reaction_turf(turf/simulated/T, volume) if(!istype(T))