Merge pull request #16597 from Kashargul/miscGripper

up ports misc gripper, gargoyle, petrification, some message fixes
This commit is contained in:
Heroman3003
2024-11-30 14:41:36 +10:00
committed by GitHub
23 changed files with 1092 additions and 61 deletions
+49 -1
View File
@@ -1 +1,49 @@
#define MOB_WATER_LAYER 36
// These are used as the layers for the icons, as well as indexes in a list that holds onto them.
// Technically the layers used are all -100+layer to make them FLOAT_LAYER overlays.
//Human Overlays Indexes/////////
#define MUTATIONS_LAYER 1 //Mutations like fat, and lasereyes
#define SKIN_LAYER 2 //Skin things added by a call on species
#define BLOOD_LAYER 3 //Bloodied hands/feet/anything else
#define BODYPARTS_LAYER 4 //Bodyparts layer
#define MOB_DAM_LAYER 5 //Injury overlay sprites like open wounds
#define SURGERY_LAYER 6 //Overlays for open surgical sites
#define UNDERWEAR_LAYER 7 //Underwear/bras/etc
#define TAIL_LOWER_LAYER 8 //Tail as viewed from the south
#define WING_LOWER_LAYER 9 //Wings as viewed from the south
#define SHOES_LAYER_ALT 10 //Shoe-slot item (when set to be under uniform via verb)
#define UNIFORM_LAYER 11 //Uniform-slot item
#define ID_LAYER 12 //ID-slot item
#define SHOES_LAYER 13 //Shoe-slot item
#define GLOVES_LAYER 14 //Glove-slot item
#define BELT_LAYER 15 //Belt-slot item
#define SUIT_LAYER 16 //Suit-slot item
#define TAIL_UPPER_LAYER 17 //Some species have tails to render (As viewed from the N, E, or W)
#define GLASSES_LAYER 18 //Eye-slot item
#define BELT_LAYER_ALT 19 //Belt-slot item (when set to be above suit via verb)
#define SUIT_STORE_LAYER 20 //Suit storage-slot item
#define BACK_LAYER 21 //Back-slot item
#define HAIR_LAYER 22 //The human's hair
#define HAIR_ACCESSORY_LAYER 23 //Simply move this up a number if things are added.
#define EARS_LAYER 24 //Both ear-slot items (combined image)
#define EYES_LAYER 25 //Mob's eyes (used for glowing eyes)
#define FACEMASK_LAYER 26 //Mask-slot item
#define GLASSES_LAYER_ALT 27 //So some glasses can appear on top of hair and things
#define HEAD_LAYER 28 //Head-slot item
#define HANDCUFF_LAYER 29 //Handcuffs, if the human is handcuffed, in a secret inv slot
#define LEGCUFF_LAYER 30 //Same as handcuffs, for legcuffs
#define L_HAND_LAYER 31 //Left-hand item
#define R_HAND_LAYER 32 //Right-hand item
#define WING_LAYER 33 //Wings or protrusions over the suit.
#define TAIL_UPPER_LAYER_ALT 34 //Modified tail-sprite layer. Tend to be larger.
#define MODIFIER_EFFECTS_LAYER 35 //Effects drawn by modifiers
#define FIRE_LAYER 36 //'Mob on fire' overlay layer
#define MOB_WATER_LAYER 37
#define TARGETED_LAYER 38 //'Aimed at' overlay layer
#define VORE_BELLY_LAYER 39
#define VORE_TAIL_LAYER 40
#define TOTAL_LAYERS 40 // <---- KEEP THIS UPDATED, should always equal the highest number here, used to initialize a list.
//These two are only used for gargoyles currently
#define HUMAN_BODY_LAYERS list(MUTATIONS_LAYER, TAIL_LOWER_LAYER, WING_LOWER_LAYER, BODYPARTS_LAYER, SKIN_LAYER, BLOOD_LAYER, MOB_DAM_LAYER, TAIL_UPPER_LAYER, HAIR_LAYER, HAIR_ACCESSORY_LAYER, EYES_LAYER, WING_LAYER, VORE_BELLY_LAYER, VORE_TAIL_LAYER, TAIL_UPPER_LAYER_ALT)
#define HUMAN_OTHER_LAYERS list(MODIFIER_EFFECTS_LAYER, FIRE_LAYER, MOB_WATER_LAYER, TARGETED_LAYER)
+101
View File
@@ -0,0 +1,101 @@
/datum/component/gargoyle
var/energy = 100
var/transformed = FALSE
var/paused = FALSE
var/paused_loc
var/cooldown
var/mob/living/carbon/human/gargoyle //easy reference
var/obj/structure/gargoyle/statue //another easy ref
//Adjustable mod
var/identifier = "statue"
var/adjective = "hardens"
var/material = "stone"
var/tint = "#FFFFFF"
/datum/component/gargoyle/Initialize()
if (!ishuman(parent))
return COMPONENT_INCOMPATIBLE
gargoyle = parent
add_verb(gargoyle,/mob/living/carbon/human/proc/gargoyle_transformation)
add_verb(gargoyle,/mob/living/carbon/human/proc/gargoyle_pause)
add_verb(gargoyle,/mob/living/carbon/human/proc/gargoyle_checkenergy)
START_PROCESSING(SSprocessing, src)
/datum/component/gargoyle/process()
if (QDELETED(gargoyle))
return
if (paused && gargoyle.loc != paused_loc)
unpause()
if (energy > 0)
if (!transformed && !paused)
energy = max(0,energy-0.05)
else if (!transformed && isturf(gargoyle.loc))
gargoyle.gargoyle_transformation()
if (transformed)
if (!statue)
transformed = FALSE
statue.damage(-0.5)
energy = min(energy+0.3, 100)
/datum/component/gargoyle/proc/unpause()
if (!paused || transformed)
paused = FALSE
paused_loc = null
UnregisterSignal(gargoyle, COMSIG_ATOM_ENTERING)
return
if (gargoyle?.loc != paused_loc)
paused = FALSE
paused_loc = null
energy = max(energy - 5, 0)
if (energy == 0)
gargoyle.gargoyle_transformation()
UnregisterSignal(gargoyle, COMSIG_ATOM_ENTERING)
//verbs or action buttons...?
/mob/living/carbon/human/proc/gargoyle_transformation()
set name = "Gargoyle - Petrification"
set category = "Abilities.Gargoyle"
set desc = "Turn yourself into (or back from) being a gargoyle."
if (stat == DEAD)
return
var/datum/component/gargoyle/comp = GetComponent(/datum/component/gargoyle)
if (comp)
if (comp.energy <= 0 && isturf(loc))
to_chat(src, span_danger("You suddenly turn into a [comp.identifier] as you run out of energy!"))
else if (comp.cooldown > world.time)
var/time_to_wait = (comp.cooldown - world.time) / (1 SECONDS)
to_chat(src, span_warning("You can't transform just yet again! Wait for another [round(time_to_wait,0.1)] seconds!"))
return
if (istype(loc, /obj/structure/gargoyle))
qdel(loc)
else if (isturf(loc))
new /obj/structure/gargoyle(loc, src)
/mob/living/carbon/human/proc/gargoyle_pause()
set name = "Gargoyle - Pause"
set category = "Abilities.Gargoyle"
set desc = "Pause your energy while standing still, so you don't use up any more, though you will lose a small amount upon moving again."
if (stat)
return
var/datum/component/gargoyle/comp = GetComponent(/datum/component/gargoyle)
if (comp && !comp.transformed && !comp.paused)
comp.paused = TRUE
comp.paused_loc = loc
comp.RegisterSignal(src, COMSIG_ATOM_ENTERING, /datum/component/gargoyle/proc/unpause)
to_chat(src, span_notice("You start conserving your energy."))
/mob/living/carbon/human/proc/gargoyle_checkenergy()
set name = "Gargoyle - Check Energy"
set category = "Abilities.Gargoyle"
set desc = "Check how much energy you have remaining as a gargoyle."
var/datum/component/gargoyle/comp = GetComponent(/datum/component/gargoyle)
if (comp)
to_chat(src, span_notice("You have [round(comp.energy,0.01)] energy remaining. It is currently [comp.paused ? "stable" : (comp.transformed ? "increasing" : "decreasing")]."))
+254
View File
@@ -0,0 +1,254 @@
/obj/machinery/petrification
name = "odd interface"
desc = "An odd looking machine with an interface, some buttons and a tiny keyboard on the side."
icon = 'icons/obj/machines/petrification.dmi'
icon_state = "petrification"
idle_power_usage = 100
active_power_usage = 1000
use_power = USE_POWER_IDLE
anchored = TRUE
unacidable = TRUE
dir = EAST
var/material = "stone"
var/identifier = "statue"
var/adjective = "hardens"
var/tint = "#ffffff"
var/able_to_unpetrify = TRUE
var/discard_clothes = TRUE
var/mob/living/carbon/human/target
var/list/remotes = list()
/obj/machinery/petrification/New()
. = ..()
if(!pixel_x && !pixel_y)
pixel_x = (dir & 3) ? 0 : (dir == 4 ? 26 : -26)
pixel_y = (dir & 3) ? (dir == 1 ? 26 : -26) : 0
/obj/machinery/petrification/proc/get_viable_targets()
var/list/targets = list()
//dir is the opposite of whichever direction we want to scan
var/turf/center
center = get_step(src, turn(dir, 180))
if (!center)
return
//square of 3x3 in front of the device
for (var/n = center.x-1; n <= center.x+1; n++)
for (var/m = center.y-1; m <= center.y+1; m++)
var/turf/T = locate(n,m,z)
if (!isturf(T))
continue
for (var/mob/living/carbon/human/H in T)
if (H.stat == DEAD)
continue
var/option = "[H]["[H]" != H.real_name ? " ([H.real_name])" : ""]"
var/r = 1
if (option in targets)
while ("[option] ([r])" in targets)
r += 1
option = "[option] ([r])"
targets[option] = H
return targets
/obj/machinery/petrification/proc/is_valid_target(var/mob/living/carbon/human/H)
if (QDELETED(H) || !istype(H) || !H.client)
return FALSE
var/turf/T = H.loc
if (!isturf(T))
return FALSE
var/turf/center
center = get_step(get_turf(src), turn(dir, 180))
if (!center)
return
if (T.z != z || T.x > center.x + 1 || T.x < center.x - 1 || T.y > center.y + 1 || T.y < center.y - 1)
return FALSE
return TRUE
/obj/machinery/petrification/proc/popup_msg(var/mob/user, var/message, var/notice = TRUE)
if (notice)
message = "A notice pops up on the interface: \"[message]\""
if (target)
to_chat(user, span_notice("[message]"))
/obj/machinery/petrification/proc/petrify(var/mob/user, var/obj/item/petrifier/petrifier = null)
. = FALSE
var/mat = material
var/idt = identifier
var/adj = adjective
var/tnt = tint
var/can_unpetrify = able_to_unpetrify
var/no_clothes = discard_clothes
var/mob/living/carbon/human/statue = target
if (petrifier && istype(petrifier))
mat = petrifier.material
idt = petrifier.identifier
adj = petrifier.adjective
tnt = petrifier.tint
can_unpetrify = petrifier.able_to_unpetrify
no_clothes = petrifier.discard_clothes
statue = petrifier.target
if (QDELETED(statue) || !istype(statue))
popup_msg(user, "Invalid target.")
return
if (statue.stat == DEAD)
popup_msg(user, "The target must be alive.")
return
if (!statue.client)
popup_msg(user, "The target must be capable of conscious thought.")
return
if (!istext(mat) || !istext(idt) || !istext(adj) || !istext(tnt))
popup_msg(user, "Invalid options.")
var/turf/T = statue.loc
if (!istype(T))
popup_msg(user, "They must be visible to the [petrifier ? "device" : "machine"].")
if (!petrifier)
var/turf/center = get_step(get_turf(src), turn(dir, 180))
if (!center)
return
if (T.z != z || T.x > center.x + 1 || T.x < center.x - 1 || T.y > center.y + 1 || T.y < center.y - 1)
popup_msg(user, "They are out of range. They must be standing within a 3x3 square in front of the machine.")
return
else
var/turf/center = get_turf(petrifier)
if (!center)
return
if (T.z != center.z || get_dist(center, T) > 4)
popup_msg(user, "They are out of range. They must be standing within 4 tiles of the device.")
return
var/datum/component/gargoyle/comp = statue.GetComponent(/datum/component/gargoyle)
if (no_clothes)
for(var/obj/item/W in statue)
if(istype(W, /obj/item/implant/backup) || istype(W, /obj/item/nif))
continue
statue.drop_from_inventory(W)
var/obj/structure/gargoyle/G = new(T, statue, idt, mat, adj, tnt, can_unpetrify, no_clothes)
G.was_rayed = TRUE
if (can_unpetrify)
add_verb(statue,/mob/living/carbon/human/proc/gargoyle_transformation)
comp?.cooldown = 0
else
remove_verb(statue,/mob/living/carbon/human/proc/gargoyle_transformation)
remove_verb(statue,/mob/living/carbon/human/proc/gargoyle_pause)
remove_verb(statue,/mob/living/carbon/human/proc/gargoyle_checkenergy)
comp?.cooldown = INFINITY
if (!petrifier)
visible_message(span_notice("A ray of purple light streams out of \the [src], aimed directly at [statue]. Everywhere the light touches on them quickly [adj] into [mat]."))
SStgui.update_uis(src)
return TRUE
/obj/machinery/petrification/attack_hand(var/mob/user as mob)
if(..())
return
user.set_machine(src)
tgui_interact(user)
/obj/machinery/petrification/tgui_interact(mob/user, datum/tgui/ui = null)
ui = SStgui.try_update_ui(user, src, ui)
if(!ui)
ui = new(user, src, "PetrificationInterface", name)
ui.open()
/obj/machinery/petrification/tgui_data(mob/user)
var/list/data = list()
data["material"] = material
data["identifier"] = identifier
data["adjective"] = adjective
data["tint"] = tint
var/list/h = rgb2num(tint)
data["t"] = ((h[1]*0.299)+(h[2]*0.587)+(h[3]*0.114)) > 102 //0.4 luminance
data["target"] = "[target ? target : "None"]"
data["able_to_unpetrify"] = able_to_unpetrify
data["discard_clothes"] = discard_clothes
data["can_remote"] = is_valid_target(target) && istext(material) && istext(identifier) && istext(adjective) && istext(tint)
return data
/obj/machinery/petrification/proc/set_input(var/option, mob/user)
var/list/only_these = list("tint","material","identifier","adjective","able_to_unpetrify","discard_clothes","target")
if (!(option in only_these))
return
switch(option)
if("tint")
var/new_color = input(user, "Choose the color for the [identifier] to be:", "Statue color", tint) as color|null
if (new_color)
tint = new_color
if("material","identifier","adjective")
var/input = tgui_input_text(user, "What should the [option] be?", "Statue [option]", vars[option], MAX_NAME_LEN)
input = sanitizeSafe(input, 25)
if (length(input) <= 0)
return
if (option == "adjective")
if (copytext_char(input, -1) != "s")
switch(copytext_char(input, -2))
if ("ss")
input += "es"
if ("sh")
input += "es"
if ("ch")
input += "es"
else
switch(copytext_char(input, -1))
if("s", "x", "z")
input += "es"
else
input += "s"
vars[option] = input
if("able_to_unpetrify", "discard_clothes")
vars[option] = !vars[option]
if("target")
var/list/targets = get_viable_targets()
if (!length(targets))
popup_msg(user, "No targets within range. Make sure there is a humanoid being within a 3x3 metre square in front of the interface.")
return
var/selected = input(user, "Choose the target.", "Petrification Target") as null|anything in targets
if (selected && ishuman(targets[selected]) && is_valid_target(targets[selected]))
var/confirmation = tgui_alert(targets[selected], "You have been selected as a petrification target. If you press confirm, you will possibly be turned into a statue, and if the option is selected, possibly one that cannot be reverted back from a statue at all.","Petrification Target",list("Confirm", "Cancel"))
if (confirmation != "Confirm")
popup_msg(user, "They declined the request.", FALSE)
return
var/double = tgui_alert(targets[selected], "This is your last warning, are you -certain-?","Petrification Target",list("Confirm", "Cancel"))
if (confirmation == "Confirm" && double == "Confirm")
target = targets[selected]
else
popup_msg(user, "They declined the request.", FALSE)
/obj/machinery/petrification/tgui_act(action, list/params, datum/tgui/ui, datum/tgui_state/state)
if(..())
return TRUE
if (ui.user)
add_fingerprint(ui.user)
switch(action)
if("set_option")
if (params["option"])
set_input(params["option"], ui.user)
SStgui.update_uis(src)
return TRUE
if("petrify")
petrify(ui.user)
return TRUE
if("remote")
if (is_valid_target(target) && istext(material) && istext(identifier) && istext(adjective) && istext(tint))
var/obj/item/petrifier/PE = remotes[target]
if (!QDELETED(PE))
PE.visible_message(span_warning("\The [PE] disappears!"))
qdel(PE)
var/obj/item/petrifier/P = new(loc, src)
P.material = material
P.identifier = identifier
P.adjective = adjective
P.tint = tint
P.able_to_unpetrify = able_to_unpetrify
P.discard_clothes = discard_clothes
P.target = target
remotes[target] = P
ui.user.put_in_hands(P)
return TRUE
return TRUE
/obj/item/paper/petrification_notes
name = "written notes"
info = "<font face=\"Times New Roman\">" + span_italics("Found this buried in the machine over there after digging through it a bit- I hooked it up to one of our displays so it was a bit more usable- seems to be a spare part, it was right next to another one that actually " + span_bold("was") + " hooked up. Turns things into other materials, probably one of the components that makes that machine work.") + "</font>"
+28
View File
@@ -0,0 +1,28 @@
/obj/item/petrifier
name = "odd button"
desc = "A metal device with a single, purple button on it, and a tiny interface."
icon = 'icons/obj/machines/petrification.dmi'
icon_state = "petrifier"
var/mob/living/carbon/human/target
var/identifier = "statue"
var/material = "stone"
var/adjective = "hardens"
var/tint = "#FFFFFF"
var/discard_clothes = TRUE
var/able_to_unpetrify = TRUE
var/obj/machinery/petrification/linked
/obj/item/petrifier/Initialize(mapload, var/to_link)
. = ..()
linked = to_link
/obj/item/petrifier/attack_self(var/mob/user)
. = ..()
if (!isturf(user.loc) && user.get_ultimate_mob() != target)
to_chat(user, span_warning("The device beeps but does nothing."))
return
if (linked?.petrify(user, src))
visible_message(span_notice("A ray of purple light streams out of \the [src], aimed directly at [target]. Everywhere the light touches on them quickly [adjective] into [material]."))
to_chat(user, span_warning("The device fizzles and crumbles into dust."))
qdel(src)
+293
View File
@@ -0,0 +1,293 @@
/obj/structure/gargoyle
name = "statue"
desc = "A very lifelike carving."
density = TRUE
anchored = TRUE
var/mob/living/carbon/human/gargoyle
var/initial_sleep
var/initial_blind
var/initial_is_shifted
var/initial_lying
var/initial_lying_prev
var/wagging
var/flapping
var/obj_integrity = 100
var/original_int = 100
var/max_integrity = 100
var/stored_examine
var/identifier = "statue"
var/material = "stone"
var/adjective = "hardens"
var/list/tail_lower_dirs = list(SOUTH, EAST, WEST)
var/image/tail_image
var/tail_alt = TAIL_UPPER_LAYER
var/can_revert = TRUE
var/was_rayed = FALSE
/obj/structure/gargoyle/Initialize(mapload, var/mob/living/carbon/human/H, var/ident_ovr, var/mat_ovr, var/adj_ovr, var/tint_ovr, var/revert = TRUE, var/discard_clothes)
. = ..()
if (isspace(loc) || isopenspace(loc))
anchored = FALSE
if (!istype(H) || !isturf(H.loc))
return
var/datum/component/gargoyle/comp = H.GetComponent(/datum/component/gargoyle)
var/tint = "#FFFFFF"
if (comp)
comp.cooldown = world.time + (15 SECONDS)
comp.statue = src
comp.transformed = TRUE
comp.paused = FALSE
identifier = length(comp.identifier) > 0 ? comp.identifier : initial(identifier)
material = length(comp.material) > 0 ? comp.material : initial(material)
tint = length(comp.tint) > 0 ? comp.tint : initial(tint)
adjective = length(comp.adjective) > 0 ? comp.adjective : initial(adjective)
if (copytext_char(adjective, -1) != "s")
adjective += "s"
gargoyle = H
if (H.get_effective_size(TRUE) < 0.5) // "So small! I can step over it!"
density = FALSE
if (ident_ovr)
identifier = ident_ovr
if (mat_ovr)
material = mat_ovr
if (adj_ovr)
adjective = adj_ovr
if (tint_ovr)
tint = tint_ovr
if (H.tail_style?.clip_mask_state)
tail_lower_dirs.Cut()
else if (H.tail_style)
tail_lower_dirs = H.tail_style.lower_layer_dirs.Copy()
tail_alt = H.tail_alt ? TAIL_UPPER_LAYER_ALT : TAIL_UPPER_LAYER
max_integrity = H.getMaxHealth() + 100
obj_integrity = H.health + 100
original_int = obj_integrity
name = "[identifier] of [H.name]"
desc = "A very lifelike [identifier] made of [material]."
stored_examine = H.examine(H)
description_fluff = H.get_description_fluff()
if (H.buckled)
H.buckled.unbuckle_mob(H, TRUE)
//icon = H.icon
//copy_overlays(H)
//calculate our tints
var/list/RGB = rgb2num(tint)
var/colorr = rgb(RGB[1]*0.299, RGB[2]*0.299, RGB[3]*0.299)
var/colorg = rgb(RGB[1]*0.587, RGB[2]*0.587, RGB[3]*0.587)
var/colorb = rgb(RGB[1]*0.114, RGB[2]*0.114, RGB[3]*0.114)
var/tint_color = list(colorr, colorg, colorb, "#000000")
var/list/body_layers = HUMAN_BODY_LAYERS
var/list/other_layers = HUMAN_OTHER_LAYERS
for (var/i = 1; i <= length(H.overlays_standing); i++)
if (i in other_layers)
continue
if (discard_clothes && !(i in body_layers))
continue
if (istype(H.overlays_standing[i], /image) && (i in body_layers))
var/image/old_image = H.overlays_standing[i]
var/image/new_image = image(old_image)
if (i == TAIL_LOWER_LAYER || i == TAIL_UPPER_LAYER || i == TAIL_UPPER_LAYER_ALT)
tail_image = new_image
new_image.color = tint_color
new_image.layer = old_image.layer
add_overlay(new_image)
else
if (!isnull(H.overlays_standing[i]))
add_overlay(H.overlays_standing[i])
initial_sleep = H.sleeping
initial_blind = H.eye_blind
initial_is_shifted = H.is_shifted
transform = H.transform
layer = H.layer
pixel_x = H.pixel_x
pixel_y = H.pixel_y
dir = H.dir
initial_lying = H.lying
initial_lying_prev = H.lying_prev
H.sdisabilities |= MUTE
if (H.appearance_flags & PIXEL_SCALE)
appearance_flags |= PIXEL_SCALE
wagging = H.wagging
H.transforming = TRUE
flapping = H.flapping
H.toggle_tail(FALSE, FALSE)
H.toggle_wing(FALSE, FALSE)
H.visible_message(span_warning("[H]'s skin rapidly [adjective] as they turn to [material]!"), span_warning("Your skin abruptly [adjective] as you turn to [material]!"))
H.forceMove(src)
H.SetBlinded(0)
H.SetSleeping(0)
H.status_flags |= GODMODE
H.updatehealth()
H.canmove = 0
can_revert = revert
START_PROCESSING(SSprocessing, src)
/obj/structure/gargoyle/Destroy()
STOP_PROCESSING(SSprocessing, src)
if (!gargoyle)
return ..()
if (can_revert)
unpetrify(deleting = FALSE) //don't delete if we're already deleting!
else
visible_message(span_warning("The [identifier] loses shape and crumbles into a pile of [material]!"))
. = ..()
/obj/structure/gargoyle/process()
if (!gargoyle)
qdel(src)
if (gargoyle.loc != src)
can_revert = TRUE //something's gone wrong, they escaped, lets not qdel them
unpetrify(deal_damage = FALSE, deleting = TRUE)
/obj/structure/gargoyle/examine_icon()
var/icon/examine_icon = icon(icon=src.icon, icon_state=src.icon_state, dir=SOUTH, frame=1, moving=0)
examine_icon.MapColors(rgb(77,77,77), rgb(150,150,150), rgb(28,28,28), rgb(0,0,0))
return examine_icon
/obj/structure/gargoyle/get_description_info()
if (gargoyle)
if (isspace(loc) || isopenspace(loc))
return
return "It can be [anchored ? "un" : ""]anchored with a wrench."
/obj/structure/gargoyle/examine(mob/user)
. = ..()
if (gargoyle && stored_examine)
. += "The [identifier] seems to have a bit more to them..."
. += stored_examine
return
/obj/structure/gargoyle/proc/unpetrify(var/deal_damage = TRUE, var/deleting = FALSE)
if (!gargoyle)
return
var/datum/component/gargoyle/comp = gargoyle.GetComponent(/datum/component/gargoyle)
if (comp)
comp.cooldown = world.time + (15 SECONDS)
comp.statue = null
comp.transformed = FALSE
else
if (was_rayed)
remove_verb(gargoyle,/mob/living/carbon/human/proc/gargoyle_transformation)
if (gargoyle.loc == src)
gargoyle.forceMove(loc)
gargoyle.transform = transform
gargoyle.pixel_x = pixel_x
gargoyle.pixel_y = pixel_y
gargoyle.is_shifted = initial_is_shifted
gargoyle.dir = dir
gargoyle.lying = initial_lying
gargoyle.lying_prev = initial_lying_prev
gargoyle.toggle_tail(wagging, FALSE)
gargoyle.toggle_wing(flapping, FALSE)
gargoyle.sdisabilities &= ~MUTE //why is there no ADD_TRAIT etc here that's actually ussssed
gargoyle.status_flags &= ~GODMODE
gargoyle.SetBlinded(initial_blind)
gargoyle.SetSleeping(initial_sleep)
gargoyle.transforming = FALSE
gargoyle.canmove = 1
gargoyle.update_canmove()
var/hurtmessage = ""
if (deal_damage)
if (obj_integrity < original_int)
var/f = (original_int - obj_integrity) / 10
for (var/x in 1 to 10)
gargoyle.adjustBruteLoss(f)
hurtmessage = " " + span_bold("You feel your body take the damage that was dealt while being [material]!")
gargoyle.updatehealth()
alpha = 0
gargoyle.visible_message(span_warning("[gargoyle]'s skin rapidly reverts, returning them to normal!"), span_warning("Your skin reverts, freeing your movement once more![hurtmessage]"))
gargoyle = null
if (deleting)
qdel(src)
/obj/structure/gargoyle/return_air()
return return_air_for_internal_lifeform()
/obj/structure/gargoyle/return_air_for_internal_lifeform(var/mob/living/lifeform)
var/air_type = /datum/gas_mixture/belly_air
if(istype(lifeform))
air_type = lifeform.get_perfect_belly_air_type()
var/air = new air_type(1000)
return air
/obj/structure/gargoyle/proc/damage(var/damage)
if (was_rayed)
return //gargoyle quick regenerates, the others don't, so let's not have them getting too damaged
obj_integrity = min(obj_integrity-damage, max_integrity)
if(obj_integrity <= 0)
qdel(src)
/obj/structure/gargoyle/take_damage(var/damage)
damage(damage)
/obj/structure/gargoyle/attack_generic(var/mob/user, var/damage, var/attack_message = "hits")
user.do_attack_animation(src)
visible_message(span_danger("[user] [attack_message] the [src]!"))
damage(damage)
/obj/structure/gargoyle/attackby(var/obj/item/W as obj, var/mob/living/user as mob)
if(W.is_wrench())
if (isspace(loc) || isopenspace(loc))
to_chat(user, span_warning("You can't anchor that here!"))
anchored = FALSE
return ..()
playsound(src, W.usesound, 50, 1)
if (do_after(user, (2 SECONDS) * W.toolspeed, target = src))
to_chat(user, span_notice("You [anchored ? "un" : ""]anchor the [src]."))
anchored = !anchored
else if(!isrobot(user) && gargoyle && gargoyle.vore_selected && gargoyle.trash_catching)
if(istype(W,/obj/item/grab || /obj/item/holder))
gargoyle.vore_attackby(W, user)
return
if(gargoyle.adminbus_trash || is_type_in_list(W,edible_trash) && W.trash_eatable && !is_type_in_list(W,item_vore_blacklist))
to_chat(user, span_warning("You slip [W] into [gargoyle]'s [lowertext(gargoyle.vore_selected.name)] ."))
user.drop_item()
W.forceMove(gargoyle.vore_selected)
return
else if (!(W.flags & NOBLUDGEON))
user.setClickCooldown(user.get_attack_speed(W))
if(W.damtype == BRUTE || W.damtype == BURN)
user.do_attack_animation(src)
playsound(src, W.hitsound, 50, 1)
damage(W.force)
else
return ..()
/obj/structure/gargoyle/set_dir(var/new_dir)
. = ..()
if(. && tail_image)
cut_overlay(tail_image)
tail_image.layer = BODY_LAYER + ((dir in tail_lower_dirs) ? TAIL_LOWER_LAYER : tail_alt)
add_overlay(tail_image)
/obj/structure/gargoyle/hitby(atom/movable/AM as mob|obj,var/speed = THROWFORCE_SPEED_DIVISOR)
if(istype(AM,/obj/item) && gargoyle && gargoyle.vore_selected && gargoyle.trash_catching)
var/obj/item/I = AM
if(gargoyle.adminbus_trash || is_type_in_list(I,edible_trash) && I.trash_eatable && !is_type_in_list(I,item_vore_blacklist))
gargoyle.hitby(AM, speed)
return
else if(istype(AM,/mob/living) && gargoyle)
var/mob/living/L = AM
if(gargoyle.throw_vore && L.throw_vore && gargoyle.can_be_drop_pred && L.can_be_drop_prey)
var/drop_prey_temp = FALSE
if(gargoyle.can_be_drop_prey)
drop_prey_temp = TRUE
gargoyle.can_be_drop_prey = FALSE //Making sure the original gargoyle body is not the one getting throwvored instead.
gargoyle.hitby(L, speed)
if(drop_prey_temp)
gargoyle.can_be_drop_prey = TRUE
return
return ..()
@@ -573,6 +573,9 @@
H.l_hand.clean_blood()
H.bloody_hands = 0
H.germ_level = 0
H.hand_blood_color = null
LAZYCLEARLIST(H.blood_DNA)
H.update_bloodied()
else
user.clean_blood()
for(var/mob/V in viewers(src, null))
@@ -63,6 +63,9 @@ var/global/list/valid_bloodreagents = list("default","iron","copper","phoron","s
. += link + (trait_prefs[identifier] ? "Enabled" : "Disabled")
if (2) //TRAIT_PREF_TYPE_COLOR
. += " " + color_square(hex = trait_prefs[identifier]) + link + "Change"
if (3) //TRAIT_PREF_TYPE_STRING
var/string = trait_prefs[identifier]
. += link + (length(string) > 0 ? string : "\[Empty\]")
. += "</a></li>"
. += "</ul>"
if (altered)
@@ -101,6 +104,9 @@ var/global/list/valid_bloodreagents = list("default","iron","copper","phoron","s
var/new_color = input(user, "Choose the color for this trait preference:", "Trait Preference", trait_prefs[preference]) as color|null
if (new_color)
trait_prefs[preference] = new_color
if (3) //TRAIT_PREF_TYPE_STRING
var/new_string = instance.apply_sanitization_to_string(preference, tgui_input_text(user, "What should the new value be?", instance.has_preferences[preference][2], trait_prefs[preference], MAX_NAME_LEN))
trait_prefs[preference] = new_string
// Definition of the stuff for Ears
/datum/category_item/player_setup_item/vore/traits
+7 -2
View File
@@ -83,7 +83,7 @@
var/decl/emote/use_emote = get_emote_by_key(act)
if(!istype(use_emote))
to_chat(src, span_warning("Unknown emote '[act]'. Type <b>say *help</b> for a list of usable emotes."))
to_chat(src, span_warning("Unknown emote '[act]'. Type " + span_bold("say *help") + " for a list of usable emotes. ([act] [message])")) // Add full message in the event you used * instead of ! or something like that
return
if(!use_emote.mob_can_use(src))
@@ -210,6 +210,7 @@
var/turf/T = get_turf(src)
if(!T) return
if(client)
playsound(T, pick(emote_sound), 25, TRUE, falloff = 1 , is_global = TRUE, frequency = ourfreq, ignore_walls = FALSE, preference = /datum/preference/toggle/emote_sounds)
@@ -224,7 +225,11 @@
message = span_emote(span_bold("[src]") + " ([ghost_follow_link(src, M)]) [input]")
if(usr && usr.client && M && !(get_z(usr) == get_z(M)))
message = span_multizsay("[message]")
M.show_message(message, m_type)
// If you are in the same tile, right next to, or being held by a person doing an emote, you should be able to see it while blind
if(m_type != AUDIBLE_MESSAGE && (src.Adjacent(M) || (istype(src.loc, /obj/item/holder) && src.loc.loc == M)))
M.show_message(message)
else
M.show_message(message, m_type)
M.create_chat_message(src, "[runemessage]", FALSE, list("emote"), (m_type == AUDIBLE_MESSAGE))
for(var/obj/O as anything in o_viewers)
@@ -8,6 +8,7 @@
#define TRAIT_PREF_TYPE_BOOLEAN 1
#define TRAIT_PREF_TYPE_COLOR 2
#define TRAIT_PREF_TYPE_STRING 3
#define TRAIT_NO_VAREDIT_TARGET 0
#define TRAIT_VAREDIT_TARGET_SPECIES 1
@@ -1171,3 +1171,48 @@
/datum/trait/neutral/agraviaphobia/apply(var/datum/species/S,var/mob/living/carbon/human/H, var/trait_prefs = null)
..()
H.phobias |= AGRAVIAPHOBIA
/datum/trait/neutral/gargoyle
name = "Gargoyle (Adjustable)"
desc = "You turn into a statue (or similar) at will, but also whenever you run out of energy. Being a statue replenishes your energy slowly."
cost = 0
custom_only = FALSE //slimes, xenochimera, diona, proteans, etc, basically anything but custom doesn't make sense (as much as I wanna play a petrifying slime)
//Nah makes perfect sense, they could just be gene modded, not to mention we can expand this to have the statue and description of it renameable as well as color adjustable, to support general petrification
has_preferences = list("identifier" = list(TRAIT_PREF_TYPE_STRING, "Identifier", TRAIT_NO_VAREDIT_TARGET, "statue"),
"material" = list(TRAIT_PREF_TYPE_STRING, "Material", TRAIT_NO_VAREDIT_TARGET, "stone"),
"tint" = list(TRAIT_PREF_TYPE_COLOR, "Statue color", TRAIT_NO_VAREDIT_TARGET, "#FFFFFF"),
"adjective" = list(TRAIT_PREF_TYPE_STRING, "Adjective", TRAIT_NO_VAREDIT_TARGET, "hardens")/*,
"pickupable" = list(TRAIT_PREF_TYPE_BOOLEAN, "Can be picked up", TRAIT_NO_VAREDIT_TARGET, FALSE)*/)
/datum/trait/neutral/gargoyle/apply(var/datum/species/S,var/mob/living/carbon/human/H, var/list/trait_prefs)
..()
var/datum/component/gargoyle/G = H.LoadComponent(/datum/component/gargoyle)
if (trait_prefs)
G.tint = trait_prefs["tint"]
G.material = lowertext(trait_prefs["material"])
G.identifier = lowertext(trait_prefs["identifier"])
G.adjective = lowertext(trait_prefs["adjective"])
/datum/trait/neutral/gargoyle/apply_sanitization_to_string(var/pref, var/input)
if (has_preferences[pref][1] != TRAIT_PREF_TYPE_STRING || length(input) <= 0)
return
input = sanitizeSafe(input, 25)
if (length(input) <= 0)
return default_value_for_pref(pref)
input = lowertext(input)
if (pref == "adjective")
if (copytext_char(input, -1) != "s")
switch(copytext_char(input, -2))
if ("ss")
input += "es"
if ("sh")
input += "es"
if ("ch")
input += "es"
else
switch(copytext_char(input, -1))
if("s", "x", "z")
input += "es"
else
input += "s"
return input
@@ -75,4 +75,14 @@
return TRUE
if(TRAIT_PREF_TYPE_COLOR) //color
return "#ffffff"
if(TRAIT_PREF_TYPE_STRING) //string
return ""
return
/datum/trait/proc/apply_sanitization_to_string(var/pref, var/input)
if (has_preferences[pref][1] != TRAIT_PREF_TYPE_STRING || length(input) <= 0)
return default_value_for_pref(pref)
input = sanitizeSafe(input, MAX_NAME_LEN)
if (length(input) <= 0)
return default_value_for_pref(pref)
return input
@@ -57,52 +57,6 @@ var/global/list/damage_icon_parts = list() //see UpdateDamageIcon()
cut_overlay(I)
overlays_standing[cache_index] = null
// These are used as the layers for the icons, as well as indexes in a list that holds onto them.
// Technically the layers used are all -100+layer to make them FLOAT_LAYER overlays.
//Human Overlays Indexes/////////
#define MUTATIONS_LAYER 1 //Mutations like fat, and lasereyes
#define SKIN_LAYER 2 //Skin things added by a call on species
#define BLOOD_LAYER 3 //Bloodied hands/feet/anything else
#define MOB_DAM_LAYER 4 //Injury overlay sprites like open wounds
#define SURGERY_LAYER 5 //Overlays for open surgical sites
#define UNDERWEAR_LAYER 6 //Underwear/bras/etc
#define TAIL_LOWER_LAYER 7 //Tail as viewed from the south
#define WING_LOWER_LAYER 8 //Wings as viewed from the south
#define SHOES_LAYER_ALT 9 //Shoe-slot item (when set to be under uniform via verb)
#define UNIFORM_LAYER 10 //Uniform-slot item
#define ID_LAYER 11 //ID-slot item
#define SHOES_LAYER 12 //Shoe-slot item
#define GLOVES_LAYER 13 //Glove-slot item
#define BELT_LAYER 14 //Belt-slot item
#define SUIT_LAYER 15 //Suit-slot item
#define TAIL_UPPER_LAYER 16 //Some species have tails to render (As viewed from the N, E, or W)
#define GLASSES_LAYER 17 //Eye-slot item
#define BELT_LAYER_ALT 18 //Belt-slot item (when set to be above suit via verb)
#define SUIT_STORE_LAYER 19 //Suit storage-slot item
#define BACK_LAYER 20 //Back-slot item
#define HAIR_LAYER 21 //The human's hair
#define HAIR_ACCESSORY_LAYER 22 //VOREStation edit. Simply move this up a number if things are added.
#define EARS_LAYER 23 //Both ear-slot items (combined image)
#define EYES_LAYER 24 //Mob's eyes (used for glowing eyes)
#define FACEMASK_LAYER 25 //Mask-slot item
#define GLASSES_LAYER_ALT 26 //So some glasses can appear on top of hair and things
#define HEAD_LAYER 27 //Head-slot item
#define HANDCUFF_LAYER 28 //Handcuffs, if the human is handcuffed, in a secret inv slot
#define LEGCUFF_LAYER 29 //Same as handcuffs, for legcuffs
#define L_HAND_LAYER 30 //Left-hand item
#define R_HAND_LAYER 31 //Right-hand item
#define WING_LAYER 32 //Wings or protrusions over the suit.
#define TAIL_UPPER_LAYER_ALT 33 //Modified tail-sprite layer. Tend to be larger.
#define MODIFIER_EFFECTS_LAYER 34 //Effects drawn by modifiers
#define FIRE_LAYER 35 //'Mob on fire' overlay layer
// # define MOB_WATER_LAYER 36 //'Mob submerged' overlay layer // Moved to global defines
#define TARGETED_LAYER 37 //'Aimed at' overlay layer
#define VORE_BELLY_LAYER 38
#define VORE_TAIL_LAYER 39
#define TOTAL_LAYERS 39 //VOREStation edit. <---- KEEP THIS UPDATED, should always equal the highest number here, used to initialize a list.
//////////////////////////////////
/mob/living/carbon/human
var/list/overlays_standing[TOTAL_LAYERS]
var/previous_damage_appearance // store what the body last looked like, so we only have to update it if something changed
@@ -245,6 +199,8 @@ var/global/list/damage_icon_parts = list() //see UpdateDamageIcon()
if(QDESTROYING(src))
return
remove_layer(BODYPARTS_LAYER)
var/husk_color_mod = rgb(96,88,80)
var/hulk_color_mod = rgb(48,224,40)
@@ -427,6 +383,13 @@ var/global/list/damage_icon_parts = list() //see UpdateDamageIcon()
//END CACHED ICON GENERATION.
stand_icon.Blend(base_icon,ICON_OVERLAY)
var/image/body = image(stand_icon)
if (body)
body.layer = BODY_LAYER + BODYPARTS_LAYER
overlays_standing[BODYPARTS_LAYER] = body
apply_layer(BODYPARTS_LAYER)
icon = stand_icon
//tail
+2 -2
View File
@@ -371,7 +371,7 @@ var/list/channel_to_radio_key = new
if(M && src) //If we still exist, when the spawn processes
//VOREStation Add - Ghosts don't hear whispers
if(whispering && isobserver(M) && (!M.client?.prefs?.read_preference(/datum/preference/toggle/ghost_see_whisubtle) || \
(!client?.prefs?.read_preference(/datum/preference/toggle/whisubtle_vis) && !M.client?.holder)))
(!(client?.prefs?.read_preference(/datum/preference/toggle/whisubtle_vis) || (isbelly(M.loc) && src == M.loc:owner)) && !M.client?.holder)))
M.show_message(span_game(span_say(span_name(src.name) + " [w_not_heard].")), 2)
return
//VOREStation Add End
@@ -432,7 +432,7 @@ var/list/channel_to_radio_key = new
/mob/living/proc/say_signlang(var/message, var/verb="gestures", var/verb_understood="gestures", var/datum/language/language, var/type = 1)
var/turf/T = get_turf(src)
//We're in something, gesture to people inside the same thing
if(loc != T)
if(loc != T && !istype(loc, /obj/item/holder)) // Partially fixes sign language while being held.
for(var/mob/M in loc)
M.hear_signlang(message, verb, verb_understood, language, src, type)
@@ -177,6 +177,23 @@
/obj/item/material/gravemarker
)
/obj/item/gripper/scene
name = "misc gripper"
desc = "A simple grasping tool that can hold a variety of 'general' objects..."
can_hold = list(
/obj/item/capture_crystal,
/obj/item/clothing,
/obj/item/implanter,
/obj/item/disk/nifsoft/compliance,
/obj/item/handcuffs,
/obj/item/toy,
/obj/item/petrifier,
/obj/item/dice,
/obj/item/casino_platinum_chip,
/obj/item/spacecasinocash
)
/obj/item/gripper/no_use/organ
name = "organ gripper"
icon_state = "gripper-flesh"
@@ -208,6 +208,7 @@ var/global/list/robot_modules = list(
src.modules += new /obj/item/flash/robot(src)
src.modules += new /obj/item/extinguisher(src)
src.modules += new /obj/item/tool/crowbar/cyborg(src)
src.modules += new /obj/item/gripper/scene(src)
/obj/item/robot_module/robot/standard
name = "standard robot module"
+11
View File
@@ -126,6 +126,17 @@
/atom/proc/drain_power(var/drain_check,var/surge, var/amount = 0)
return -1
// used for petrification machines
/atom/proc/get_ultimate_mob()
var/mob/ultimate_mob
var/atom/to_check = loc
var/n = 0
while (to_check && !isturf(to_check) && n++ < 16)
if (ismob(to_check))
ultimate_mob = to_check
to_check = to_check.loc
return ultimate_mob
// Show a message to all mobs and objects in earshot of this one
// This would be for audible actions by the src mob
// message is the message output to anyone who can hear.
+13 -4
View File
@@ -3,7 +3,6 @@
/mob/verb/whisper(message as text)
set name = "Whisper"
set category = "IC.Subtle"
set hidden = 1
//VOREStation Addition Start
if(forced_psay)
@@ -15,7 +14,6 @@
/mob/verb/say_verb(message as text)
set name = "Say"
set category = "IC.Chat"
set hidden = 1
set instant = TRUE
@@ -33,7 +31,6 @@
/mob/verb/me_verb(message as message)
set name = "Me"
set category = "IC.Chat"
set desc = "Emote to nearby people (and your pred/prey)"
set hidden = 1
@@ -110,7 +107,19 @@
if(speaking.flags & NONVERBAL)
if(sdisabilities & BLIND || blinded)
return FALSE
if(!other || !(other in view(src)))
if(!other)
return FALSE
// Fixes seeing non-verbal languages while being held
if(istype(other.loc, /obj/item/holder))
if(istype(src.loc, /obj/item/holder))
if(!(other.loc in view(src.loc.loc)))
return FALSE
else if(!(other.loc in view(src)))
return FALSE
else if(istype(src.loc, /obj/item/holder))
if((!other) in view(src.loc.loc))
return FALSE
else if((!other) in view(src))
return FALSE
//Language check.
+82
View File
@@ -0,0 +1,82 @@
// Allows the usage of old style chat inputs even with TG Say enabled
/mob/verb/say_verb_old()
set name = "Say Old"
set category = "IC.Chat"
client?.start_thinking()
client?.start_typing()
var/message = tgui_input_text(usr, "Speak to people in sight.\nType your message:", "Say")
client?.stop_thinking()
if(message)
say_verb(message)
/mob/verb/me_verb_old()
set name = "Me Old"
set category = "IC.Chat"
set desc = "Emote to nearby people (and your pred/prey)"
client?.start_thinking()
client?.start_typing()
var/message = tgui_input_text(usr, "Emote to people in sight (and your pred/prey).\nType your message:", "Emote", multiline = TRUE)
client?.stop_thinking()
if(message)
me_verb(message)
/mob/verb/whisper_old()
set name = "Whisper Old"
set category = "IC.Subtle"
var/message = tgui_input_text(usr, "Speak to nearby people.\nType your message:", "Whisper")
if(message)
whisper(message)
/mob/verb/me_verb_subtle_old()
set name = "Subtle Old"
set category = "IC.Subtle"
set desc = "Emote to nearby people (and your pred/prey)"
var/message = tgui_input_text(usr, "Emote to nearby people (and your pred/prey).\nType your message:", "Subtle", multiline = TRUE)
if(message)
me_verb_subtle(message)
/mob/verb/me_verb_subtle_custom_old()
set name = "Subtle (Custom) Old"
set category = "IC.Subtle"
set desc = "Emote to nearby people, with ability to choose which specific portion of people you wish to target."
var/message = tgui_input_text(usr, "Emote to nearby people, with ability to choose which specific portion of people you wish to target.\nType your message:", "Subtle (Custom)", multiline = TRUE)
if(message)
me_verb_subtle_custom(message)
/mob/verb/psay_old()
set name = "Psay Old"
set category = "IC.Subtle"
var/message = tgui_input_text(usr, "Talk to people affected by complete absorbed or dominate predator/prey.\nType your message:", "Psay")
if(message)
psay(message)
/mob/verb/pme_old()
set name = "Pme Old"
set category = "IC.Subtle"
var/message = tgui_input_text(usr, "Emote to people affected by complete absorbed or dominate predator/prey.\nType your message:", "Pme")
if(message)
pme(message)
/mob/living/verb/player_narrate_ch()
set name = "Narrate (Player) Old"
set category = "IC.Chat"
var/message = tgui_input_text(usr, "Narrate an action or event! An alternative to emoting, for when your emote shouldn't start with your name!\nType your message:", "Narrate (Player)")
if(message)
player_narrate(message)
+1 -6
View File
@@ -4,7 +4,6 @@
/mob/verb/me_verb_subtle(message as message) //This would normally go in say.dm
set name = "Subtle"
set category = "IC.Subtle"
set desc = "Emote to nearby people (and your pred/prey)"
set hidden = 1
@@ -24,7 +23,6 @@
/mob/verb/me_verb_subtle_custom(message as message) // Literally same as above but with mode_selection set to true
set name = "Subtle (Custom)"
set category = "IC.Subtle"
set desc = "Emote to nearby people, with ability to choose which specific portion of people you wish to target."
if(forced_psay)
@@ -197,7 +195,7 @@
continue
if(src.client && M && !(get_z(src) == get_z(M)))
message = span_multizsay("[message]")
if(isobserver(M) && (!M.client?.prefs?.read_preference(/datum/preference/toggle/ghost_see_whisubtle) || \
if(isobserver(M) && (!(M.client?.prefs?.read_preference(/datum/preference/toggle/ghost_see_whisubtle) || (isbelly(M.loc) && src == M.loc:owner)) || \
!client?.prefs?.read_preference(/datum/preference/toggle/whisubtle_vis) && !M.client?.holder))
spawn(0)
M.show_message(undisplayed_message, 2)
@@ -254,7 +252,6 @@
///// PSAY /////
/mob/verb/psay(message as text)
set category = "IC.Subtle"
set name = "Psay"
set desc = "Talk to people affected by complete absorbed or dominate predator/prey."
@@ -352,7 +349,6 @@
///// PME /////
/mob/verb/pme(message as message)
set category = "IC.Subtle"
set name = "Pme"
set desc = "Emote to people affected by complete absorbed or dominate predator/prey."
@@ -448,7 +444,6 @@
M.me_verb(message)
/mob/living/verb/player_narrate(message as message)
set category = "IC.Chat"
set name = "Narrate (Player)"
set desc = "Narrate an action or event! An alternative to emoting, for when your emote shouldn't start with your name!"
+6
View File
@@ -609,6 +609,12 @@
forceMove(get_turf(src))
log_and_message_admins("[key_name(src)] used the OOC escape button to get out of a microwave.")
else if(istype(loc, /obj/structure/gargoyle) && loc:was_rayed)
var/obj/structure/gargoyle/G = loc
G.can_revert = TRUE
qdel(G)
log_and_message_admins("[key_name(src)] used the OOC escape button to revert back from being petrified.")
//You are in food and for some reason can't resist out
else if(istype(loc, /obj/item/reagent_containers/food))
var/obj/item/reagent_containers/food/F = src.loc
Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

@@ -0,0 +1,148 @@
import { BooleanLike } from 'common/react';
import { useBackend } from 'tgui/backend';
import { Button, LabeledList, Section } from 'tgui/components';
import { Window } from 'tgui/layouts';
type Data = {
material: string;
identifier: string;
adjective: string;
tint: string;
t: BooleanLike;
target: string;
able_to_unpetrify: BooleanLike;
discard_clothes: BooleanLike;
can_remote: BooleanLike;
};
export const PetrificationInterface = (props) => {
const { act, data } = useBackend<Data>();
const {
material,
identifier,
adjective,
tint,
t,
able_to_unpetrify,
discard_clothes,
target,
can_remote,
} = data;
return (
<Window width={425} height={313}>
<Window.Content scrollable>
<Section title="Interface">
<LabeledList>
<LabeledList.Item label="Identifier">
<Button
fluid
tooltip="The identifier for the petrification. ie. 'A statue of (target)'"
tooltipPosition="top"
onClick={() => act('set_option', { option: 'identifier' })}
>
{'Change Identifier: "' + identifier + '"'}
</Button>
</LabeledList.Item>
<LabeledList.Item label="Material">
<Button
fluid
tooltip={
'The material for the petrification. ie. "(name)' +
"'" +
's skin rapidly (adjective) as they turn to (material)!"'
}
tooltipPosition="top"
onClick={() => act('set_option', { option: 'material' })}
>
{'Change Material: "' + material + '"'}
</Button>
</LabeledList.Item>
<LabeledList.Item label="Adjective">
<Button
fluid
tooltip={
'The adjective for the petrification. ie. "(name)' +
"'" +
's skin rapidly (adjective) as they turn to (material)!"'
}
tooltipPosition="top"
onClick={() => act('set_option', { option: 'adjective' })}
>
{'Change Adjective: "' + adjective + '"'}
</Button>
</LabeledList.Item>
<LabeledList.Item label="Color">
<Button
fluid
backgroundColor={tint}
textColor={t ? '#000000' : '#ffffff'}
tooltip="The color of the statue. Pure white is direct greyscale."
tooltipPosition="top"
onClick={() => act('set_option', { option: 'tint' })}
>
Change Color
</Button>
</LabeledList.Item>
<LabeledList.Item label="Can Unpetrify">
<Button
fluid
selected={able_to_unpetrify}
tooltip="Whether or not the statue can be unpetrified. If yes, they will get a verb letting them turn back- if not, even if they're a gargoyle, it will be taken away. OOC Escape is always an option though."
tooltipPosition="top"
onClick={() =>
act('set_option', { option: 'able_to_unpetrify' })
}
>
{able_to_unpetrify ? 'Yes' : 'No'}
</Button>
</LabeledList.Item>
<LabeledList.Item label="Discard Clothes">
<Button
fluid
selected={discard_clothes}
tooltip="Whether the target's clothing falls off before the petrification happens. (Clothes do not change color when petrified, and cannot be removed while being a statue)"
tooltipPosition="top"
onClick={() => act('set_option', { option: 'discard_clothes' })}
>
{discard_clothes ? 'Enabled' : 'Disabled'}
</Button>
</LabeledList.Item>
<LabeledList.Item label="Target">
<Button
fluid
onClick={() => act('set_option', { option: 'target' })}
>
{target}
</Button>
</LabeledList.Item>
</LabeledList>
<br />
<Button
ml={1}
disabled={!can_remote}
tooltip={
'Turn the target to ' +
material +
". This is meant for roleplay/scene purposes. Please don't abuse it."
}
tooltipPosition="top"
onClick={() => act('petrify')}
>
Petrify
</Button>
<Button
mr={1}
disabled={!can_remote}
tooltip="Create a remote that will petrify the target with the given options when the button is pressed. It must be within 4 tiles of the target when pressed to work.. This is meant for roleplay/scene purposes. Please don't abuse it."
tooltipPosition="top"
onClick={() => act('remote')}
>
Create Remote
</Button>
</Section>
</Window.Content>
</Window>
);
};
+5
View File
@@ -449,6 +449,7 @@
#include "code\datums\autolathe\tools_vr.dm"
#include "code\datums\components\_component.dm"
#include "code\datums\components\connect_mob_behalf.dm"
#include "code\datums\components\gargoyle.dm"
#include "code\datums\components\material_container.dm"
#include "code\datums\components\overlay_lighting.dm"
#include "code\datums\components\recursive_move.dm"
@@ -977,6 +978,7 @@
#include "code\game\machinery\pandemic.dm"
#include "code\game\machinery\partslathe_vr.dm"
#include "code\game\machinery\pda_multicaster.dm"
#include "code\game\machinery\petrification.dm"
#include "code\game\machinery\pointdefense.dm"
#include "code\game\machinery\portable_turret.dm"
#include "code\game\machinery\portable_turret_vr.dm"
@@ -1293,6 +1295,7 @@
#include "code\game\objects\items\lockpicks.dm"
#include "code\game\objects\items\magazine.dm"
#include "code\game\objects\items\paintkit.dm"
#include "code\game\objects\items\petrifier.dm"
#include "code\game\objects\items\pizza_voucher_vr.dm"
#include "code\game\objects\items\poi_items.dm"
#include "code\game\objects\items\robobag.dm"
@@ -1607,6 +1610,7 @@
#include "code\game\objects\structures\fireaxe.dm"
#include "code\game\objects\structures\fitness.dm"
#include "code\game\objects\structures\fitness_vr.dm"
#include "code\game\objects\structures\gargoyle.dm"
#include "code\game\objects\structures\girders.dm"
#include "code\game\objects\structures\gravemarker.dm"
#include "code\game\objects\structures\grille.dm"
@@ -2886,6 +2890,7 @@
#include "code\modules\mob\mob_planes_vr.dm"
#include "code\modules\mob\mob_transformation_simple.dm"
#include "code\modules\mob\say.dm"
#include "code\modules\mob\say_old.dm"
#include "code\modules\mob\say_vr.dm"
#include "code\modules\mob\theme_lists.dm"
#include "code\modules\mob\transform_procs.dm"