diff --git a/.gitignore b/.gitignore index f11d80fbec5..d87340a7fa6 100644 --- a/.gitignore +++ b/.gitignore @@ -19,6 +19,7 @@ cfg/ #Ignore everything in datafolder and subdirectories /data/**/* /tmp/**/* +/cache/**/* #Visual studio stuff *.vscode/* diff --git a/code/ATMOSPHERICS/_atmospherics_helpers.dm b/code/ATMOSPHERICS/_atmospherics_helpers.dm index 76b520a45fa..da777c25815 100644 --- a/code/ATMOSPHERICS/_atmospherics_helpers.dm +++ b/code/ATMOSPHERICS/_atmospherics_helpers.dm @@ -17,7 +17,7 @@ /client/proc/atmos_toggle_debug(var/obj/machinery/atmospherics/M in view()) set name = "Toggle Debug Messages" - set category = "Debug" + set category = "Debug.Misc" M.debug = !M.debug to_chat(usr, "[M]: Debug messages toggled [M.debug? "on" : "off"].") @@ -439,7 +439,7 @@ var/sink_heat_capacity = sink.heat_capacity() var/transfer_heat_capacity = source.heat_capacity()*estimate_moles/source_total_moles air_temperature = (sink.temperature*sink_heat_capacity + source.temperature*transfer_heat_capacity) / (sink_heat_capacity + transfer_heat_capacity) - + //get the number of moles that would have to be transfered to bring sink to the target pressure return pressure_delta*output_volume/(air_temperature * R_IDEAL_GAS_EQUATION) diff --git a/code/ATMOSPHERICS/atmospherics.dm b/code/ATMOSPHERICS/atmospherics.dm index 508bb929b6a..7f3368cc537 100644 --- a/code/ATMOSPHERICS/atmospherics.dm +++ b/code/ATMOSPHERICS/atmospherics.dm @@ -35,8 +35,8 @@ Pipelines + Other Objects -> Pipe network var/obj/machinery/atmospherics/node1 var/obj/machinery/atmospherics/node2 -/obj/machinery/atmospherics/New(loc, newdir) - ..() +/obj/machinery/atmospherics/Initialize(mapload, newdir) + . = ..() if(!icon_manager) icon_manager = new() if(!isnull(newdir)) diff --git a/code/ATMOSPHERICS/components/binary_devices/binary_atmos_base.dm b/code/ATMOSPHERICS/components/binary_devices/binary_atmos_base.dm index cee94b9b5a7..54de979b6c3 100644 --- a/code/ATMOSPHERICS/components/binary_devices/binary_atmos_base.dm +++ b/code/ATMOSPHERICS/components/binary_devices/binary_atmos_base.dm @@ -9,8 +9,8 @@ var/datum/pipe_network/network1 var/datum/pipe_network/network2 -/obj/machinery/atmospherics/binary/New() - ..() +/obj/machinery/atmospherics/binary/Initialize() + . = ..() air1 = new air2 = new @@ -126,4 +126,4 @@ update_icon() update_underlays() - return null \ No newline at end of file + return null diff --git a/code/ATMOSPHERICS/components/binary_devices/circulator.dm b/code/ATMOSPHERICS/components/binary_devices/circulator.dm index 00a88c02375..5c795e38871 100644 --- a/code/ATMOSPHERICS/components/binary_devices/circulator.dm +++ b/code/ATMOSPHERICS/components/binary_devices/circulator.dm @@ -24,8 +24,9 @@ density = TRUE -/obj/machinery/atmospherics/binary/circulator/New() - ..() +/obj/machinery/atmospherics/binary/circulator/Initialize() + . = ..() + desc = initial(desc) + " Its outlet port is to the [dir2text(dir)]." air1.volume = 400 @@ -149,4 +150,4 @@ return src.set_dir(turn(src.dir, 90)) - desc = initial(desc) + " Its outlet port is to the [dir2text(dir)]." \ No newline at end of file + desc = initial(desc) + " Its outlet port is to the [dir2text(dir)]." diff --git a/code/ATMOSPHERICS/components/binary_devices/dp_vent_pump.dm b/code/ATMOSPHERICS/components/binary_devices/dp_vent_pump.dm index 251aa4c1473..36616ae721d 100644 --- a/code/ATMOSPHERICS/components/binary_devices/dp_vent_pump.dm +++ b/code/ATMOSPHERICS/components/binary_devices/dp_vent_pump.dm @@ -42,8 +42,11 @@ //2: Do not pass input_pressure_min //4: Do not pass output_pressure_max -/obj/machinery/atmospherics/binary/dp_vent_pump/New() - ..() +/obj/machinery/atmospherics/binary/dp_vent_pump/Initialize() + . = ..() + if(frequency) + set_frequency(frequency) + air1.volume = ATMOS_DEFAULT_VOLUME_PUMP air2.volume = ATMOS_DEFAULT_VOLUME_PUMP icon = null @@ -55,8 +58,8 @@ /obj/machinery/atmospherics/binary/dp_vent_pump/high_volume name = "Large Dual Port Air Vent" -/obj/machinery/atmospherics/binary/dp_vent_pump/high_volume/New() - ..() +/obj/machinery/atmospherics/binary/dp_vent_pump/high_volume/Initialize() + . = ..() air1.volume = ATMOS_DEFAULT_VOLUME_PUMP + 800 air2.volume = ATMOS_DEFAULT_VOLUME_PUMP + 800 @@ -194,11 +197,6 @@ return 1 -/obj/machinery/atmospherics/binary/dp_vent_pump/Initialize() - . = ..() - if(frequency) - set_frequency(frequency) - /obj/machinery/atmospherics/binary/dp_vent_pump/examine(mob/user) . = ..() if(Adjacent(user)) diff --git a/code/ATMOSPHERICS/components/binary_devices/passive_gate.dm b/code/ATMOSPHERICS/components/binary_devices/passive_gate.dm index 661ef6384e5..4a680494f78 100644 --- a/code/ATMOSPHERICS/components/binary_devices/passive_gate.dm +++ b/code/ATMOSPHERICS/components/binary_devices/passive_gate.dm @@ -27,10 +27,12 @@ var/id = null var/datum/radio_frequency/radio_connection -/obj/machinery/atmospherics/binary/passive_gate/New() - ..() +/obj/machinery/atmospherics/binary/passive_gate/Initialize() + . = ..() air1.volume = ATMOS_DEFAULT_VOLUME_PUMP * 2.5 air2.volume = ATMOS_DEFAULT_VOLUME_PUMP * 2.5 + if(frequency) + set_frequency(frequency) /obj/machinery/atmospherics/binary/passive_gate/Destroy() unregister_radio(src, frequency) @@ -169,11 +171,6 @@ return 1 -/obj/machinery/atmospherics/binary/passive_gate/Initialize() - . = ..() - if(frequency) - set_frequency(frequency) - /obj/machinery/atmospherics/binary/passive_gate/receive_signal(datum/signal/signal) if(!signal.data["tag"] || (signal.data["tag"] != id) || (signal.data["sigtype"]!="command")) return 0 diff --git a/code/ATMOSPHERICS/components/binary_devices/pump.dm b/code/ATMOSPHERICS/components/binary_devices/pump.dm index 70784f0519d..4c1a0d0ad80 100644 --- a/code/ATMOSPHERICS/components/binary_devices/pump.dm +++ b/code/ATMOSPHERICS/components/binary_devices/pump.dm @@ -37,10 +37,13 @@ Thus, the two variables affect pump operation are set in New(): var/id = null var/datum/radio_frequency/radio_connection -/obj/machinery/atmospherics/binary/pump/New() - ..() +/obj/machinery/atmospherics/binary/pump/Initialize() + . = ..() + air1.volume = ATMOS_DEFAULT_VOLUME_PUMP air2.volume = ATMOS_DEFAULT_VOLUME_PUMP + if(frequency) + set_frequency(frequency) /obj/machinery/atmospherics/binary/pump/Destroy() unregister_radio(src, frequency) @@ -166,11 +169,6 @@ Thus, the two variables affect pump operation are set in New(): return data -/obj/machinery/atmospherics/binary/pump/Initialize() - . = ..() - if(frequency) - set_frequency(frequency) - /obj/machinery/atmospherics/binary/pump/receive_signal(datum/signal/signal) if(!signal.data["tag"] || (signal.data["tag"] != id) || (signal.data["sigtype"]!="command")) return 0 diff --git a/code/ATMOSPHERICS/components/omni_devices/filter.dm b/code/ATMOSPHERICS/components/omni_devices/filter.dm index 8990ba011f3..4409482f507 100644 --- a/code/ATMOSPHERICS/components/omni_devices/filter.dm +++ b/code/ATMOSPHERICS/components/omni_devices/filter.dm @@ -20,8 +20,9 @@ var/list/filtering_outputs = list() //maps gasids to gas_mixtures -/obj/machinery/atmospherics/omni/atmos_filter/New() - ..() +/obj/machinery/atmospherics/omni/atmos_filter/Initialize() + . = ..() + rebuild_filtering_list() for(var/datum/omni_port/P in ports) P.air.volume = ATMOS_DEFAULT_VOLUME_FILTER diff --git a/code/ATMOSPHERICS/components/omni_devices/mixer.dm b/code/ATMOSPHERICS/components/omni_devices/mixer.dm index fa627ddc64b..02c701c91e8 100644 --- a/code/ATMOSPHERICS/components/omni_devices/mixer.dm +++ b/code/ATMOSPHERICS/components/omni_devices/mixer.dm @@ -24,8 +24,9 @@ var/list/mixing_inputs = list() -/obj/machinery/atmospherics/omni/mixer/New() - ..() +/obj/machinery/atmospherics/omni/mixer/Initialize() + . = ..() + if(mapper_set()) var/con = 0 for(var/datum/omni_port/P in ports) diff --git a/code/ATMOSPHERICS/components/omni_devices/omni_base.dm b/code/ATMOSPHERICS/components/omni_devices/omni_base.dm index aecb911561c..9201cee4a16 100644 --- a/code/ATMOSPHERICS/components/omni_devices/omni_base.dm +++ b/code/ATMOSPHERICS/components/omni_devices/omni_base.dm @@ -25,8 +25,9 @@ var/list/ports = new() -/obj/machinery/atmospherics/omni/New() - ..() +/obj/machinery/atmospherics/omni/Initialize() + . = ..() + icon_state = "base" ports = new() diff --git a/code/ATMOSPHERICS/components/trinary_devices/filter.dm b/code/ATMOSPHERICS/components/trinary_devices/filter.dm index fc2cb986cc1..31544ac1f72 100755 --- a/code/ATMOSPHERICS/components/trinary_devices/filter.dm +++ b/code/ATMOSPHERICS/components/trinary_devices/filter.dm @@ -39,8 +39,9 @@ if(frequency) radio_connection = radio_controller.add_object(src, frequency, RADIO_ATMOSIA) -/obj/machinery/atmospherics/trinary/atmos_filter/New() - ..() +/obj/machinery/atmospherics/trinary/atmos_filter/Initialize() + . = ..() + switch(filter_type) if(0) //removing hydrocarbons filtered_out = list("phoron") @@ -56,6 +57,8 @@ air1.volume = ATMOS_DEFAULT_VOLUME_FILTER air2.volume = ATMOS_DEFAULT_VOLUME_FILTER air3.volume = ATMOS_DEFAULT_VOLUME_FILTER + if(frequency) + set_frequency(frequency) /obj/machinery/atmospherics/trinary/atmos_filter/Destroy() unregister_radio(src, frequency) @@ -106,11 +109,6 @@ return 1 -/obj/machinery/atmospherics/trinary/atmos_filter/Initialize() - . = ..() - if(frequency) - set_frequency(frequency) - /obj/machinery/atmospherics/trinary/atmos_filter/attack_hand(user) // -- TLE if(..()) return diff --git a/code/ATMOSPHERICS/components/trinary_devices/mixer.dm b/code/ATMOSPHERICS/components/trinary_devices/mixer.dm index ef3149f78ef..6397be2c59e 100644 --- a/code/ATMOSPHERICS/components/trinary_devices/mixer.dm +++ b/code/ATMOSPHERICS/components/trinary_devices/mixer.dm @@ -37,8 +37,9 @@ icon_state += "off" update_use_power(USE_POWER_OFF) -/obj/machinery/atmospherics/trinary/mixer/New() - ..() +/obj/machinery/atmospherics/trinary/mixer/Initialize() + . = ..() + air1.volume = ATMOS_DEFAULT_VOLUME_MIXER air2.volume = ATMOS_DEFAULT_VOLUME_MIXER air3.volume = ATMOS_DEFAULT_VOLUME_MIXER * 1.5 diff --git a/code/ATMOSPHERICS/components/trinary_devices/trinary_base.dm b/code/ATMOSPHERICS/components/trinary_devices/trinary_base.dm index 9e1d183b9bb..7e91b8941fb 100644 --- a/code/ATMOSPHERICS/components/trinary_devices/trinary_base.dm +++ b/code/ATMOSPHERICS/components/trinary_devices/trinary_base.dm @@ -17,8 +17,8 @@ var/datum/pipe_network/network2 var/datum/pipe_network/network3 -/obj/machinery/atmospherics/trinary/New() - ..() +/obj/machinery/atmospherics/trinary/Initialize() + . = ..() air1 = new air2 = new diff --git a/code/ATMOSPHERICS/components/unary/outlet_injector.dm b/code/ATMOSPHERICS/components/unary/outlet_injector.dm index fa47021ddde..57144148fd4 100644 --- a/code/ATMOSPHERICS/components/unary/outlet_injector.dm +++ b/code/ATMOSPHERICS/components/unary/outlet_injector.dm @@ -24,9 +24,12 @@ level = 1 -/obj/machinery/atmospherics/unary/outlet_injector/New() - ..() +/obj/machinery/atmospherics/unary/outlet_injector/Initialize() + . = ..() + air_contents.volume = ATMOS_DEFAULT_VOLUME_PUMP + 500 //Give it a small reservoir for injecting. Also allows it to have a higher flow rate limit than vent pumps, to differentiate injectors a bit more. + if(frequency) + set_frequency(frequency) /obj/machinery/atmospherics/unary/outlet_injector/Destroy() unregister_radio(src, frequency) @@ -122,11 +125,6 @@ return 1 -/obj/machinery/atmospherics/unary/outlet_injector/Initialize() - . = ..() - if(frequency) - set_frequency(frequency) - /obj/machinery/atmospherics/unary/outlet_injector/receive_signal(datum/signal/signal) if(!signal.data["tag"] || (signal.data["tag"] != id) || (signal.data["sigtype"]!="command")) return 0 diff --git a/code/ATMOSPHERICS/components/unary/unary_base.dm b/code/ATMOSPHERICS/components/unary/unary_base.dm index 1f8026209dd..da5e116dc97 100644 --- a/code/ATMOSPHERICS/components/unary/unary_base.dm +++ b/code/ATMOSPHERICS/components/unary/unary_base.dm @@ -13,10 +13,10 @@ var/welded = 0 //defining this here for ventcrawl stuff -/obj/machinery/atmospherics/unary/New() - ..() - air_contents = new +/obj/machinery/atmospherics/unary/Initialize() + . = ..() + air_contents = new air_contents.volume = 200 /obj/machinery/atmospherics/unary/init_dir() diff --git a/code/ATMOSPHERICS/components/unary/vent_pump.dm b/code/ATMOSPHERICS/components/unary/vent_pump.dm index 9f32aa32ecc..2d8c9ee1163 100644 --- a/code/ATMOSPHERICS/components/unary/vent_pump.dm +++ b/code/ATMOSPHERICS/components/unary/vent_pump.dm @@ -81,10 +81,7 @@ /obj/machinery/atmospherics/unary/vent_pump/Initialize() . = ..() - //soundloop = new(list(src), FALSE) -/obj/machinery/atmospherics/unary/vent_pump/New() - ..() air_contents.volume = ATMOS_DEFAULT_VOLUME_PUMP icon = null @@ -119,8 +116,8 @@ icon_connect_type = "-aux" connect_types = CONNECT_TYPE_AUX //connects to aux pipes -/obj/machinery/atmospherics/unary/vent_pump/high_volume/New() - ..() +/obj/machinery/atmospherics/unary/vent_pump/high_volume/Initialize() + . = ..() air_contents.volume = ATMOS_DEFAULT_VOLUME_PUMP + 800 // VOREStation Edit Start - Wall mounted vents @@ -144,8 +141,8 @@ power_channel = ENVIRON power_rating = 30000 //15 kW ~ 20 HP -/obj/machinery/atmospherics/unary/vent_pump/engine/New() - ..() +/obj/machinery/atmospherics/unary/vent_pump/engine/Initialize() + . = ..() air_contents.volume = ATMOS_DEFAULT_VOLUME_PUMP + 500 //meant to match air injector /obj/machinery/atmospherics/unary/vent_pump/update_icon(var/safety = 0) diff --git a/code/ATMOSPHERICS/components/unary/vent_scrubber.dm b/code/ATMOSPHERICS/components/unary/vent_scrubber.dm index 0fc8d0cff79..4ab5156968e 100644 --- a/code/ATMOSPHERICS/components/unary/vent_scrubber.dm +++ b/code/ATMOSPHERICS/components/unary/vent_scrubber.dm @@ -32,8 +32,8 @@ use_power = USE_POWER_IDLE icon_state = "map_scrubber_on" -/obj/machinery/atmospherics/unary/vent_scrubber/New() - ..() +/obj/machinery/atmospherics/unary/vent_scrubber/Initialize() + . = ..() air_contents.volume = ATMOS_DEFAULT_VOLUME_FILTER icon = null diff --git a/code/ATMOSPHERICS/mainspipe.dm b/code/ATMOSPHERICS/mainspipe.dm deleted file mode 100644 index b67b289d25e..00000000000 --- a/code/ATMOSPHERICS/mainspipe.dm +++ /dev/null @@ -1,708 +0,0 @@ -// internal pipe, don't actually place or use these -obj/machinery/atmospherics/pipe/mains_component - var/obj/machinery/atmospherics/mains_pipe/parent_pipe - var/list/obj/machinery/atmospherics/pipe/mains_component/nodes = new() - - New(loc) - ..(loc) - parent_pipe = loc - - check_pressure(pressure) - var/datum/gas_mixture/environment = loc.loc.return_air() - - var/pressure_difference = pressure - environment.return_pressure() - - if(pressure_difference > parent_pipe.maximum_pressure) - mains_burst() - - else if(pressure_difference > parent_pipe.fatigue_pressure) - //TODO: leak to turf, doing pfshhhhh - if(prob(5)) - mains_burst() - - else return 1 - - pipeline_expansion() - return nodes - - disconnect(obj/machinery/atmospherics/reference) - if(nodes.Find(reference)) - nodes.Remove(reference) - - proc/mains_burst() - parent_pipe.burst() - -obj/machinery/atmospherics/mains_pipe - icon = 'icons/obj/atmospherics/mainspipe.dmi' - layer = PIPES_LAYER - plane = PLATING_PLANE - - var/volume = 0 - - var/alert_pressure = 80*ONE_ATMOSPHERE - - var/initialize_mains_directions = 0 - - var/list/obj/machinery/atmospherics/mains_pipe/nodes = new() - var/obj/machinery/atmospherics/pipe/mains_component/supply - var/obj/machinery/atmospherics/pipe/mains_component/scrubbers - var/obj/machinery/atmospherics/pipe/mains_component/aux - - var/minimum_temperature_difference = 300 - var/thermal_conductivity = 0 //WALL_HEAT_TRANSFER_COEFFICIENT No - - var/maximum_pressure = 70*ONE_ATMOSPHERE - var/fatigue_pressure = 55*ONE_ATMOSPHERE - alert_pressure = 55*ONE_ATMOSPHERE - - New() - ..() - - supply = new(src) - supply.volume = volume - supply.nodes.len = nodes.len - scrubbers = new(src) - scrubbers.volume = volume - scrubbers.nodes.len = nodes.len - aux = new(src) - aux.volume = volume - aux.nodes.len = nodes.len - - hide(var/i) - if(level == 1 && istype(loc, /turf/simulated)) - invisibility = i ? 101 : 0 - update_icon() - - proc/burst() - for(var/obj/machinery/atmospherics/pipe/mains_component/pipe in contents) - burst() - - proc/check_pressure(pressure) - var/datum/gas_mixture/environment = loc.return_air() - - var/pressure_difference = pressure - environment.return_pressure() - - if(pressure_difference > maximum_pressure) - burst() - - else if(pressure_difference > fatigue_pressure) - //TODO: leak to turf, doing pfshhhhh - if(prob(5)) - burst() - - else return 1 - - get_neighbor_nodes_for_init() - return nodes - - disconnect() - ..() - for(var/obj/machinery/atmospherics/pipe/mains_component/node in nodes) - node.disconnect() - - Destroy() - disconnect() - ..() - - atmos_init() - for(var/i = 1 to nodes.len) - var/obj/machinery/atmospherics/mains_pipe/node = nodes[i] - if(node) - supply.nodes[i] = node.supply - scrubbers.nodes[i] = node.scrubbers - aux.nodes[i] = node.aux - -obj/machinery/atmospherics/mains_pipe/simple - name = "mains pipe" - desc = "A one meter section of 3-line mains pipe" - - dir = SOUTH - initialize_mains_directions = SOUTH|NORTH - - New() - nodes.len = 2 - ..() - switch(dir) - if(SOUTH || NORTH) - initialize_mains_directions = SOUTH|NORTH - if(EAST || WEST) - initialize_mains_directions = EAST|WEST - if(NORTHEAST) - initialize_mains_directions = NORTH|EAST - if(NORTHWEST) - initialize_mains_directions = NORTH|WEST - if(SOUTHEAST) - initialize_mains_directions = SOUTH|EAST - if(SOUTHWEST) - initialize_mains_directions = SOUTH|WEST - - proc/normalize_dir() - if(dir==3) - set_dir(1) - else if(dir==12) - set_dir(4) - - update_icon() - if(nodes[1] && nodes[2]) - icon_state = "intact[invisibility ? "-f" : "" ]" - - //var/node1_direction = get_dir(src, node1) - //var/node2_direction = get_dir(src, node2) - - //set_dir(node1_direction|node2_direction) - - else - if(!nodes[1]&&!nodes[2]) - qdel(src) //TODO: silent deleting looks weird - var/have_node1 = nodes[1]?1:0 - var/have_node2 = nodes[2]?1:0 - icon_state = "exposed[have_node1][have_node2][invisibility ? "-f" : "" ]" - - atmos_init() - normalize_dir() - var/node1_dir - var/node2_dir - - for(var/direction in cardinal) - if(direction&initialize_mains_directions) - if (!node1_dir) - node1_dir = direction - else if (!node2_dir) - node2_dir = direction - - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,node1_dir)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[1] = target - break - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,node2_dir)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[2] = target - break - - ..() // initialize internal pipes - - var/turf/T = src.loc // hide if turf is not intact - if(level == 1 && !T.is_plating()) hide(1) - update_icon() - - hidden - level = 1 - icon_state = "intact-f" - - visible - level = 2 - icon_state = "intact" - -obj/machinery/atmospherics/mains_pipe/manifold - name = "manifold pipe" - desc = "A manifold composed of mains pipes" - - dir = SOUTH - initialize_mains_directions = EAST|NORTH|WEST - volume = 105 - - New() - nodes.len = 3 - ..() - initialize_mains_directions = (NORTH|SOUTH|EAST|WEST) & ~dir - - atmos_init() - var/connect_directions = initialize_mains_directions - - for(var/direction in cardinal) - if(direction&connect_directions) - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,direction)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[1] = target - connect_directions &= ~direction - break - if (nodes[1]) - break - - - for(var/direction in cardinal) - if(direction&connect_directions) - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,direction)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[2] = target - connect_directions &= ~direction - break - if (nodes[2]) - break - - - for(var/direction in cardinal) - if(direction&connect_directions) - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,direction)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[3] = target - connect_directions &= ~direction - break - if (nodes[3]) - break - - ..() // initialize internal pipes - - var/turf/T = src.loc // hide if turf is not intact - if(level == 1 && !T.is_plating()) hide(1) - update_icon() - - update_icon() - icon_state = "manifold[invisibility ? "-f" : "" ]" - - hidden - level = 1 - icon_state = "manifold-f" - - visible - level = 2 - icon_state = "manifold" - -obj/machinery/atmospherics/mains_pipe/manifold4w - name = "manifold pipe" - desc = "A manifold composed of mains pipes" - - dir = SOUTH - initialize_mains_directions = EAST|NORTH|WEST|SOUTH - volume = 105 - - New() - nodes.len = 4 - ..() - - atmos_init() - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,NORTH)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[1] = target - break - - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,SOUTH)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[2] = target - break - - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,EAST)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[3] = target - break - - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,WEST)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[3] = target - break - - ..() // initialize internal pipes - - var/turf/T = src.loc // hide if turf is not intact - if(level == 1 && !T.is_plating()) hide(1) - update_icon() - - update_icon() - icon_state = "manifold4w[invisibility ? "-f" : "" ]" - - hidden - level = 1 - icon_state = "manifold4w-f" - - visible - level = 2 - icon_state = "manifold4w" - -obj/machinery/atmospherics/mains_pipe/split - name = "mains splitter" - desc = "A splitter for connecting to a single pipe off a mains." - - var/obj/machinery/atmospherics/pipe/mains_component/split_node - var/obj/machinery/atmospherics/node3 - var/icon_type - - New() - nodes.len = 2 - ..() - initialize_mains_directions = turn(dir, 90) | turn(dir, -90) - initialize_directions = dir // actually have a normal connection too - - atmos_init() - var/node1_dir - var/node2_dir - var/node3_dir - - node1_dir = turn(dir, 90) - node2_dir = turn(dir, -90) - node3_dir = dir - - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,node1_dir)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[1] = target - break - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,node2_dir)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[2] = target - break - for(var/obj/machinery/atmospherics/target in get_step(src,node3_dir)) - if(target.initialize_directions & get_dir(target,src)) - node3 = target - break - - ..() // initialize internal pipes - - // bind them - spawn(5) - if(node3 && split_node) - var/datum/pipe_network/N1 = node3.return_network(src) - var/datum/pipe_network/N2 = split_node.return_network(split_node) - if(N1 && N2) - N1.merge(N2) - - var/turf/T = src.loc // hide if turf is not intact - if(level == 1 && !T.is_plating()) hide(1) - update_icon() - - update_icon() - icon_state = "split-[icon_type][invisibility ? "-f" : "" ]" - - return_network(A) - return split_node.return_network(A) - - supply - icon_type = "supply" - - New() - ..() - split_node = supply - - hidden - level = 1 - icon_state = "split-supply-f" - - visible - level = 2 - icon_state = "split-supply" - - scrubbers - icon_type = "scrubbers" - - New() - ..() - split_node = scrubbers - - hidden - level = 1 - icon_state = "split-scrubbers-f" - - visible - level = 2 - icon_state = "split-scrubbers" - - aux - icon_type = "aux" - - New() - ..() - split_node = aux - - hidden - level = 1 - icon_state = "split-aux-f" - - visible - level = 2 - icon_state = "split-aux" - -obj/machinery/atmospherics/mains_pipe/split3 - name = "triple mains splitter" - desc = "A splitter for connecting to the 3 pipes on a mainline." - - var/obj/machinery/atmospherics/supply_node - var/obj/machinery/atmospherics/scrubbers_node - var/obj/machinery/atmospherics/aux_node - - New() - nodes.len = 1 - ..() - initialize_mains_directions = dir - initialize_directions = cardinal & ~dir // actually have a normal connection too - - atmos_init() - var/node1_dir - var/supply_node_dir - var/scrubbers_node_dir - var/aux_node_dir - - node1_dir = dir - aux_node_dir = turn(dir, 180) - if(dir & (NORTH|SOUTH)) - supply_node_dir = EAST - scrubbers_node_dir = WEST - else - supply_node_dir = SOUTH - scrubbers_node_dir = NORTH - - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src, node1_dir)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[1] = target - break - for(var/obj/machinery/atmospherics/target in get_step(src,supply_node_dir)) - if(target.initialize_directions & get_dir(target,src)) - supply_node = target - break - for(var/obj/machinery/atmospherics/target in get_step(src,scrubbers_node_dir)) - if(target.initialize_directions & get_dir(target,src)) - scrubbers_node = target - break - for(var/obj/machinery/atmospherics/target in get_step(src,aux_node_dir)) - if(target.initialize_directions & get_dir(target,src)) - aux_node = target - break - - ..() // initialize internal pipes - - // bind them - spawn(5) - if(supply_node) - var/datum/pipe_network/N1 = supply_node.return_network(src) - var/datum/pipe_network/N2 = supply.return_network(supply) - if(N1 && N2) - N1.merge(N2) - if(scrubbers_node) - var/datum/pipe_network/N1 = scrubbers_node.return_network(src) - var/datum/pipe_network/N2 = scrubbers.return_network(scrubbers) - if(N1 && N2) - N1.merge(N2) - if(aux_node) - var/datum/pipe_network/N1 = aux_node.return_network(src) - var/datum/pipe_network/N2 = aux.return_network(aux) - if(N1 && N2) - N1.merge(N2) - - var/turf/T = src.loc // hide if turf is not intact - if(level == 1 && !T.is_plating()) hide(1) - update_icon() - - update_icon() - icon_state = "split-t[invisibility ? "-f" : "" ]" - - return_network(obj/machinery/atmospherics/reference) - var/obj/machinery/atmospherics/A - - A = supply_node.return_network(reference) - if(!A) - A = scrubbers_node.return_network(reference) - if(!A) - A = aux_node.return_network(reference) - - return A - - hidden - level = 1 - icon_state = "split-t-f" - - visible - level = 2 - icon_state = "split-t" - -obj/machinery/atmospherics/mains_pipe/cap - name = "pipe cap" - desc = "A cap for the end of a mains pipe" - - dir = SOUTH - initialize_directions = SOUTH - volume = 35 - - New() - nodes.len = 1 - ..() - initialize_mains_directions = dir - - update_icon() - icon_state = "cap[invisibility ? "-f" : ""]" - - atmos_init() - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,dir)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[1] = target - break - - ..() - - var/turf/T = src.loc // hide if turf is not intact - if(level == 1 && !T.is_plating()) hide(1) - update_icon() - - hidden - level = 1 - icon_state = "cap-f" - - visible - level = 2 - icon_state = "cap" - -//TODO: Get Mains valves working! -/* -obj/machinery/atmospherics/mains_pipe/valve - icon_state = "mvalve0" - - name = "mains shutoff valve" - desc = "A mains pipe valve" - - var/open = 1 - - dir = SOUTH - initialize_mains_directions = SOUTH|NORTH - - New() - nodes.len = 2 - ..() - initialize_mains_directions = dir | turn(dir, 180) - - update_icon(animation) - var/turf/simulated/floor = loc - var/hide = istype(floor) ? floor.intact : 0 - level = 1 - for(var/obj/machinery/atmospherics/mains_pipe/node in nodes) - if(node.level == 2) - hide = 0 - level = 2 - break - - if(animation) - flick("[hide?"h":""]mvalve[src.open][!src.open]",src) - else - icon_state = "[hide?"h":""]mvalve[open]" - - Initialize() - normalize_dir() - var/node1_dir - var/node2_dir - - for(var/direction in cardinal) - if(direction&initialize_mains_directions) - if (!node1_dir) - node1_dir = direction - else if (!node2_dir) - node2_dir = direction - - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,node1_dir)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[1] = target - break - for(var/obj/machinery/atmospherics/mains_pipe/target in get_step(src,node2_dir)) - if(target.initialize_mains_directions & get_dir(target,src)) - nodes[2] = target - break - - if(open) - ..() // initialize internal pipes - - update_icon() - - proc/normalize_dir() - if(dir==3) - set_dir(1) - else if(dir==12) - set_dir(4) - - proc/open() - if(open) return 0 - - open = 1 - update_icon() - - Initialize() - - return 1 - - proc/close() - if(!open) return 0 - - open = 0 - update_icon() - - for(var/obj/machinery/atmospherics/pipe/mains_component/node in src) - for(var/obj/machinery/atmospherics/pipe/mains_component/o in node.nodes) - o.disconnect(node) - o.build_network() - - return 1 - - attack_ai(mob/user as mob) - return - - attack_paw(mob/user as mob) - return attack_hand(user) - - attack_hand(mob/user as mob) - src.add_fingerprint(usr) - update_icon(1) - sleep(10) - if (open) - close() - else - open() - - digital // can be controlled by AI - name = "digital mains valve" - desc = "A digitally controlled valve." - icon_state = "dvalve0" - - attack_ai(mob/user as mob) - return src.attack_hand(user) - - attack_hand(mob/user as mob) - if(!src.allowed(user)) - to_chat(user, span_warning("Access denied.")) - return - ..() - - //Radio remote control - - proc - set_frequency(new_frequency) - radio_controller.remove_object(src, frequency) - frequency = new_frequency - if(frequency) - radio_connection = radio_controller.add_object(src, frequency, RADIO_ATMOSIA) - - var/frequency = 0 - var/id = null - var/datum/radio_frequency/radio_connection - - Initialize() - ..() - if(frequency) - set_frequency(frequency) - - update_icon(animation) - var/turf/simulated/floor = loc - var/hide = istype(floor) ? floor.intact : 0 - level = 1 - for(var/obj/machinery/atmospherics/mains_pipe/node in nodes) - if(node.level == 2) - hide = 0 - level = 2 - break - - if(animation) - flick("[hide?"h":""]dvalve[src.open][!src.open]",src) - else - icon_state = "[hide?"h":""]dvalve[open]" - - receive_signal(datum/signal/signal) - if(!signal.data["tag"] || (signal.data["tag"] != id)) - return 0 - - switch(signal.data["command"]) - if("valve_open") - if(!open) - open() - - if("valve_close") - if(open) - close() - - if("valve_toggle") - if(open) - close() - else - open() -*/ diff --git a/code/ATMOSPHERICS/pipes/he_pipes.dm b/code/ATMOSPHERICS/pipes/he_pipes.dm index 11f826ae050..0d9e673e689 100644 --- a/code/ATMOSPHERICS/pipes/he_pipes.dm +++ b/code/ATMOSPHERICS/pipes/he_pipes.dm @@ -23,8 +23,8 @@ buckle_lying = 1 // BubbleWrap -/obj/machinery/atmospherics/pipe/simple/heat_exchanging/New() - ..() +/obj/machinery/atmospherics/pipe/simple/heat_exchanging/Initialize() + . = ..() // BubbleWrap END color = "#404040" //we don't make use of the fancy overlay system for colours, use this to set the default. diff --git a/code/ATMOSPHERICS/pipes/manifold.dm b/code/ATMOSPHERICS/pipes/manifold.dm index a02f0e66de0..88cb10994ea 100644 --- a/code/ATMOSPHERICS/pipes/manifold.dm +++ b/code/ATMOSPHERICS/pipes/manifold.dm @@ -19,8 +19,8 @@ level = 1 -/obj/machinery/atmospherics/pipe/manifold/New() - ..() +/obj/machinery/atmospherics/pipe/manifold/Initialize() + . = ..() alpha = 255 icon = null diff --git a/code/ATMOSPHERICS/pipes/manifold4w.dm b/code/ATMOSPHERICS/pipes/manifold4w.dm index eac8494a65d..3773ebce73b 100644 --- a/code/ATMOSPHERICS/pipes/manifold4w.dm +++ b/code/ATMOSPHERICS/pipes/manifold4w.dm @@ -20,8 +20,8 @@ level = 1 -/obj/machinery/atmospherics/pipe/manifold4w/New() - ..() +/obj/machinery/atmospherics/pipe/manifold4w/Initialize() + . = ..() alpha = 255 icon = null diff --git a/code/ATMOSPHERICS/pipes/pipe_base.dm b/code/ATMOSPHERICS/pipes/pipe_base.dm index ff6fb4bba2f..b25c3c5dfda 100644 --- a/code/ATMOSPHERICS/pipes/pipe_base.dm +++ b/code/ATMOSPHERICS/pipes/pipe_base.dm @@ -24,10 +24,10 @@ /obj/machinery/atmospherics/pipe/drain_power() return -1 -/obj/machinery/atmospherics/pipe/New() +/obj/machinery/atmospherics/pipe/Initialize() if(istype(get_turf(src), /turf/simulated/wall) || istype(get_turf(src), /turf/simulated/shuttle/wall) || istype(get_turf(src), /turf/unsimulated/wall)) level = 1 - ..() + . = ..() /obj/machinery/atmospherics/pipe/hides_under_flooring() return level != 2 diff --git a/code/ATMOSPHERICS/pipes/simple.dm b/code/ATMOSPHERICS/pipes/simple.dm index ccfe7bb0b73..466e943bed0 100644 --- a/code/ATMOSPHERICS/pipes/simple.dm +++ b/code/ATMOSPHERICS/pipes/simple.dm @@ -26,8 +26,8 @@ level = 1 -/obj/machinery/atmospherics/pipe/simple/New() - ..() +/obj/machinery/atmospherics/pipe/simple/Initialize() + . = ..() // Pipe colors and icon states are handled by an image cache - so color and icon should // be null. For mapping purposes color is defined in the object definitions. diff --git a/code/ATMOSPHERICS/pipes/tank.dm b/code/ATMOSPHERICS/pipes/tank.dm index 0476d906a12..34afa7bbe4f 100644 --- a/code/ATMOSPHERICS/pipes/tank.dm +++ b/code/ATMOSPHERICS/pipes/tank.dm @@ -18,9 +18,9 @@ pipe_flags = PIPING_DEFAULT_LAYER_ONLY density = TRUE -/obj/machinery/atmospherics/pipe/tank/New() +/obj/machinery/atmospherics/pipe/tank/Initialize() icon_state = "air" - ..() + . = ..() /obj/machinery/atmospherics/pipe/tank/init_dir() initialize_directions = dir @@ -74,7 +74,7 @@ name = "Pressure Tank (Air)" icon_state = "air_map" -/obj/machinery/atmospherics/pipe/tank/air/New() +/obj/machinery/atmospherics/pipe/tank/air/Initialize() air_temporary = new air_temporary.volume = volume air_temporary.temperature = T20C @@ -83,21 +83,21 @@ "nitrogen",(start_pressure*N2STANDARD)*(air_temporary.volume)/(R_IDEAL_GAS_EQUATION*air_temporary.temperature)) - ..() + . = ..() icon_state = "air" /obj/machinery/atmospherics/pipe/tank/oxygen name = "Pressure Tank (Oxygen)" icon_state = "o2_map" -/obj/machinery/atmospherics/pipe/tank/oxygen/New() +/obj/machinery/atmospherics/pipe/tank/oxygen/Initialize() air_temporary = new air_temporary.volume = volume air_temporary.temperature = T20C air_temporary.adjust_gas("oxygen", (start_pressure)*(air_temporary.volume)/(R_IDEAL_GAS_EQUATION*air_temporary.temperature)) - ..() + . = ..() icon_state = "o2" /obj/machinery/atmospherics/pipe/tank/nitrogen @@ -105,28 +105,28 @@ icon_state = "n2_map" volume = 40000 //Vorestation edit -/obj/machinery/atmospherics/pipe/tank/nitrogen/New() +/obj/machinery/atmospherics/pipe/tank/nitrogen/Initialize() air_temporary = new air_temporary.volume = volume air_temporary.temperature = T20C air_temporary.adjust_gas("nitrogen", (start_pressure)*(air_temporary.volume)/(R_IDEAL_GAS_EQUATION*air_temporary.temperature)) - ..() + . = ..() icon_state = "n2" /obj/machinery/atmospherics/pipe/tank/carbon_dioxide name = "Pressure Tank (Carbon Dioxide)" icon_state = "co2_map" -/obj/machinery/atmospherics/pipe/tank/carbon_dioxide/New() +/obj/machinery/atmospherics/pipe/tank/carbon_dioxide/Initialize() air_temporary = new air_temporary.volume = volume air_temporary.temperature = T20C air_temporary.adjust_gas("carbon_dioxide", (start_pressure)*(air_temporary.volume)/(R_IDEAL_GAS_EQUATION*air_temporary.temperature)) - ..() + . = ..() icon_state = "co2" /obj/machinery/atmospherics/pipe/tank/phoron @@ -134,26 +134,26 @@ icon_state = "phoron_map" connect_types = CONNECT_TYPE_REGULAR|CONNECT_TYPE_FUEL -/obj/machinery/atmospherics/pipe/tank/phoron/New() +/obj/machinery/atmospherics/pipe/tank/phoron/Initialize() air_temporary = new air_temporary.volume = volume air_temporary.temperature = T20C air_temporary.adjust_gas("phoron", (start_pressure)*(air_temporary.volume)/(R_IDEAL_GAS_EQUATION*air_temporary.temperature)) - ..() + . = ..() icon_state = "phoron" /obj/machinery/atmospherics/pipe/tank/nitrous_oxide name = "Pressure Tank (Nitrous Oxide)" icon_state = "n2o_map" -/obj/machinery/atmospherics/pipe/tank/nitrous_oxide/New() +/obj/machinery/atmospherics/pipe/tank/nitrous_oxide/Initialize() air_temporary = new air_temporary.volume = volume air_temporary.temperature = T0C air_temporary.adjust_gas("nitrous_oxide", (start_pressure)*(air_temporary.volume)/(R_IDEAL_GAS_EQUATION*air_temporary.temperature)) - ..() + . = ..() icon_state = "n2o" diff --git a/code/ZAS/Diagnostic.dm b/code/ZAS/Diagnostic.dm index fba24568028..7126588a30f 100644 --- a/code/ZAS/Diagnostic.dm +++ b/code/ZAS/Diagnostic.dm @@ -1,5 +1,5 @@ /client/proc/ZoneTick() - set category = "Debug" + set category = "Debug.Misc" set name = "Process Atmos" set desc = "Manually run a single tick of the air subsystem" @@ -17,7 +17,7 @@ */ /client/proc/Zone_Info(turf/T as null|turf) - set category = "Debug" + set category = "Debug.Misc" if(T) if(istype(T,/turf/simulated) && T:zone) T:zone:dbg_data(src) @@ -36,7 +36,7 @@ /client/var/list/zone_debug_images /client/proc/Test_ZAS_Connection(var/turf/simulated/T as turf) - set category = "Debug" + set category = "Debug.Misc" if(!istype(T)) return @@ -95,6 +95,6 @@ to_chat(mob, "both turfs can merge.") /client/proc/ZASSettings() - set category = "Debug" + set category = "Debug.Dangerous" vsc.SetDefault(mob) diff --git a/code/ZAS/Fire.dm b/code/ZAS/Fire.dm index 5c3a24d882a..46871cc785e 100644 --- a/code/ZAS/Fire.dm +++ b/code/ZAS/Fire.dm @@ -177,8 +177,8 @@ If it gains pressure too slowly, it may leak or just rupture instead of explodin animate(src, color = fire_color(air_contents.temperature), 5) set_light(l_color = color) -/obj/fire/New(newLoc,fl) - ..() +/obj/fire/Initialize(mapload, fl) + . = ..() if(!istype(loc, /turf)) qdel(src) diff --git a/code/__defines/_compile_options.dm b/code/__defines/_compile_options.dm index 57748c44197..ffee05a3e58 100644 --- a/code/__defines/_compile_options.dm +++ b/code/__defines/_compile_options.dm @@ -46,3 +46,6 @@ #endif //ifdef GC_FAILURE_HARD_LOOKUP #endif //ifdef REFERENCE_TRACKING + +// Standard flags to use for browser-options +#define DEFAULT_CLIENT_BROWSER_OPTIONS "byondstorage,find" diff --git a/code/__defines/diseases.dm b/code/__defines/diseases.dm new file mode 100644 index 00000000000..30f1d6252be --- /dev/null +++ b/code/__defines/diseases.dm @@ -0,0 +1,30 @@ +#define VIRUS_SYMPTOM_LIMIT 6 + +//Visibility Flags +#define HIDDEN_SCANNER (1<<0) +#define HIDDEN_PANDEMIC (1<<1) + +//Disease Flags +#define CURABLE (1<<0) +#define CAN_CARRY (1<<1) +#define CAN_RESIST (1<<2) + +//Spread Flags +#define SPECIAL (1<<0) +#define NON_CONTAGIOUS (1<<1) +#define BLOOD (1<<2) +#define CONTACT_FEET (1<<3) +#define CONTACT_HANDS (1<<4) +#define CONTACT_GENERAL (1<<5) +#define AIRBORNE (1<<6) + + +//Severity Defines +#define NONTHREAT "No threat" +#define MINOR "Minor" +#define MEDIUM "Medium" +#define HARMFUL "Harmful" +#define DANGEROUS "Dangerous!" +#define BIOHAZARD "BIOHAZARD THREAT!" + +#define SYMPTOM_ACTIVATION_PROB 3 diff --git a/code/__defines/jobs.dm b/code/__defines/jobs.dm index 6d625e96092..c20f5e3cd98 100644 --- a/code/__defines/jobs.dm +++ b/code/__defines/jobs.dm @@ -200,6 +200,7 @@ #define JOB_ALT_ELECTRICIAN "Electrician" #define JOB_ALT_CONSTRUCTION_ENGINEER "Construction Engineer" #define JOB_ALT_ENGINEERING_CONTRACTOR "Engineering Contractor" + #define JOB_ALT_COMPUTER_TECHNICIAN "Computer Technician" #define JOB_ATMOSPHERIC_TECHNICIAN "Atmospheric Technician" // Atmospheric Technician alt titles @@ -292,6 +293,7 @@ #define JOB_ALT_ASSEMBLY_TECHNICIAN "Assembly Technician" #define JOB_ALT_BIOMECHANICAL_ENGINEER "Biomechanical Engineer" #define JOB_ALT_MECHATRONIC_ENGINEER "Mechatronic Engineer" + #define JOB_ALT_SOFTWARE_ENGINEER "Software Engineer" #define JOB_XENOBOTANIST "Xenobotanist" // Xenobotanist alt titles diff --git a/code/__defines/math.dm b/code/__defines/math.dm index f4539605f22..846753ab568 100644 --- a/code/__defines/math.dm +++ b/code/__defines/math.dm @@ -220,3 +220,9 @@ #define ROUNDUPTOPOWEROFTWO(x) (2 ** -round(-log(2,x))) #define DEFAULT(a, b) (a? a : b) + +// sqrt, but if you give it a negative number, you get 0 instead of a runtime +/proc/sqrtor0(num) + if(num < 0) + return 0 + return sqrt(num) diff --git a/code/__defines/subsystems.dm b/code/__defines/subsystems.dm index 533d2c810c2..313da615bde 100644 --- a/code/__defines/subsystems.dm +++ b/code/__defines/subsystems.dm @@ -116,7 +116,7 @@ var/global/list/runlevel_flags = list(RUNLEVEL_LOBBY, RUNLEVEL_SETUP, RUNLEVEL_G // Subsystem init_order, from highest priority to lowest priority // Subsystems shutdown in the reverse of the order they initialize in // The numbers just define the ordering, they are meaningless otherwise. - +#define INIT_ORDER_SERVER_MAINT 93 #define INIT_ORDER_WEBHOOKS 50 #define INIT_ORDER_SQLITE 40 #define INIT_ORDER_GARBAGE 39 @@ -169,6 +169,7 @@ var/global/list/runlevel_flags = list(RUNLEVEL_LOBBY, RUNLEVEL_SETUP, RUNLEVEL_G #define FIRE_PRIORITY_VOTE 8 #define FIRE_PRIORITY_INSTRUMENTS 9 #define FIRE_PRIORITY_PING 10 +#define FIRE_PRIORITY_SERVER_MAINT 10 #define FIRE_PRIORITY_AI 10 #define FIRE_PRIORITY_GARBAGE 15 #define FIRE_PRIORITY_ASSETS 20 diff --git a/code/_helpers/_lists.dm b/code/_helpers/_lists.dm index cb8c9898459..b71b20e0370 100644 --- a/code/_helpers/_lists.dm +++ b/code/_helpers/_lists.dm @@ -209,6 +209,13 @@ result = first - second return result +/** + * Removes any null entries from the list + * Returns TRUE if the list had nulls, FALSE otherwise +**/ +/proc/list_clear_nulls(list/list_to_clear) + return (list_to_clear.RemoveAll(null) > 0) + /* Two lists may be different (A!=B) even if they have the same elements. This actually tests if they have the same entries and values. diff --git a/code/_onclick/hud/human.dm b/code/_onclick/hud/human.dm index 9a7c8e200d0..1f5fc4f4974 100644 --- a/code/_onclick/hud/human.dm +++ b/code/_onclick/hud/human.dm @@ -396,7 +396,7 @@ HUD.inventory_shown = 0 /mob/living/carbon/human/verb/toggle_hotkey_verbs() - set category = "OOC" + set category = "OOC.Client Settings" set name = "Toggle hotkey buttons" set desc = "This disables or enables the user interface buttons which can be used with hotkeys." diff --git a/code/_onclick/observer.dm b/code/_onclick/observer.dm index f8dc673b5f9..7e0f0bdc698 100644 --- a/code/_onclick/observer.dm +++ b/code/_onclick/observer.dm @@ -2,7 +2,7 @@ /mob/observer/dead/verb/toggle_inquisition() // warning: unexpected inquisition set name = "Toggle Inquisitiveness" set desc = "Sets whether your ghost examines everything on click by default" - set category = "Ghost" + set category = "Ghost.Settings" if(!client) return client.inquisitive_ghost = !client.inquisitive_ghost if(client.inquisitive_ghost) diff --git a/code/_onclick/rig.dm b/code/_onclick/rig.dm index dc57ad2150c..6ca619c7677 100644 --- a/code/_onclick/rig.dm +++ b/code/_onclick/rig.dm @@ -10,7 +10,7 @@ /client/verb/toggle_hardsuit_mode() set name = "Toggle Hardsuit Activation Mode" set desc = "Switch between hardsuit activation modes." - set category = "OOC" + set category = "OOC.Game Settings" hardsuit_click_mode++ if(hardsuit_click_mode > MAX_HARDSUIT_CLICK_MODE) diff --git a/code/controllers/configuration/entries/game_options.dm b/code/controllers/configuration/entries/game_options.dm index 867460f861f..5508d5e168b 100644 --- a/code/controllers/configuration/entries/game_options.dm +++ b/code/controllers/configuration/entries/game_options.dm @@ -12,10 +12,12 @@ /datum/config_entry/flag/limbs_can_break /datum/config_entry/number/organ_health_multiplier - default = 1 + integer = FALSE + default = 1.0 /datum/config_entry/number/organ_regeneration_multiplier - default = 1 + integer = FALSE + default = 1.0 // FIXME: Unused ///datum/config_entry/flag/revival_pod_plants diff --git a/code/controllers/configuration/entries/general.dm b/code/controllers/configuration/entries/general.dm index 981e59067f0..0b145d4be54 100644 --- a/code/controllers/configuration/entries/general.dm +++ b/code/controllers/configuration/entries/general.dm @@ -549,13 +549,12 @@ /datum/config_entry/flag/persistence_ignore_mapload /datum/config_entry/flag/allow_byond_links - default = TRUE //CHOMP Edit turned this on - + default = TRUE /datum/config_entry/flag/allow_discord_links - default = TRUE //CHOMP Edit turned this on + default = TRUE /datum/config_entry/flag/allow_url_links - default = TRUE // honestly if I were you i'd leave this one off, only use in dire situations //CHOMP Edit: pussy. + default = TRUE // honestly if I were you i'd leave this one off, only use in dire situations /datum/config_entry/flag/starlight // Whether space turfs have ambient light or not diff --git a/code/controllers/hooks.dm b/code/controllers/hooks.dm index e7888304e58..293a90aff04 100644 --- a/code/controllers/hooks.dm +++ b/code/controllers/hooks.dm @@ -29,10 +29,10 @@ error("Invalid hook '/hook/[hook]' called.") return 0 - var/caller = new hook_path + var/requester = new hook_path var/status = 1 for(var/P in typesof("[hook_path]/proc")) - if(!call(caller, P)(arglist(args))) + if(!call(requester, P)(arglist(args))) error("Hook '[P]' failed or runtimed.") status = 0 diff --git a/code/controllers/subsystems/plants.dm b/code/controllers/subsystems/plants.dm index af4815395e1..dc3c059bd79 100644 --- a/code/controllers/subsystems/plants.dm +++ b/code/controllers/subsystems/plants.dm @@ -147,7 +147,7 @@ SUBSYSTEM_DEF(plants) // Debug for testing seed genes. /client/proc/show_plant_genes() - set category = "Debug" + set category = "Debug.Investigate" set name = "Show Plant Genes" set desc = "Prints the round's plant gene masks." diff --git a/code/controllers/subsystems/server_maint.dm b/code/controllers/subsystems/server_maint.dm new file mode 100644 index 00000000000..e8d10d67487 --- /dev/null +++ b/code/controllers/subsystems/server_maint.dm @@ -0,0 +1,115 @@ +#define PING_BUFFER_TIME 25 + +SUBSYSTEM_DEF(server_maint) + name = "Server Tasks" + wait = 6 + flags = SS_POST_FIRE_TIMING + priority = FIRE_PRIORITY_SERVER_MAINT + init_order = INIT_ORDER_SERVER_MAINT + //init_stage = INITSTAGE_EARLY + runlevels = RUNLEVEL_LOBBY | RUNLEVELS_DEFAULT + var/list/currentrun + ///Associated list of list names to lists to clear of nulls + var/list/lists_to_clear + ///Delay between list clearings in ticks + var/delay = 5 + var/cleanup_ticker = 0 + +/*/datum/controller/subsystem/server_maint/PreInit() + world.hub_password = "" *///quickly! before the hubbies see us. + +/datum/controller/subsystem/server_maint/New() + if (fexists("tmp/")) + fdel("tmp/") + //if (CONFIG_GET(flag/hub)) + //world.update_hub_visibility(TRUE) + //Keep in mind, because of how delay works adding a list here makes each list take wait * delay more time to clear + //Do it for stuff that's properly important, and shouldn't have null checks inside its other uses + lists_to_clear = list( + "player_list" = global.player_list, + "mob_list" = global.mob_list, + "living_mob_list" = global.living_mob_list, + "dead_mob_list" = global.dead_mob_list, + "observer_mob_list" = global.observer_mob_list, + "listening_objects" = global.listening_objects, + "human_mob_list" = global.human_mob_list, + "silicon_mob_list" = global.silicon_mob_list, + "ai_list" = global.ai_list, + //"keyloop_list" = global.keyloop_list, //A null here will cause new clients to be unable to move. totally unacceptable + ) + + /*var/datum/tgs_version/tgsversion = world.TgsVersion() + if(tgsversion) + SSblackbox.record_feedback("text", "server_tools", 1, tgsversion.raw_parameter)*/ + + return SS_INIT_SUCCESS + +/datum/controller/subsystem/server_maint/fire(resumed = FALSE) + if(!resumed) + if(list_clear_nulls(GLOB.clients)) + log_world("Found a null in clients list!") + src.currentrun = GLOB.clients.Copy() + + var/position_in_loop = (cleanup_ticker / delay) + 1 //Index at 1, thanks byond + + if(!(position_in_loop % 1)) //If it's a whole number + var/listname = lists_to_clear[position_in_loop] + if(list_clear_nulls(lists_to_clear[listname])) + log_world("Found a null in [listname]!") + + cleanup_ticker++ + + var/amount_to_work = length(lists_to_clear) + if(cleanup_ticker >= amount_to_work * delay) //If we've already done a loop, reset + cleanup_ticker = 0 + + var/list/currentrun = src.currentrun + //var/round_started = SSticker.HasRoundStarted() + + //var/kick_inactive = CONFIG_GET(flag/kick_inactive) + //var/afk_period + //if(kick_inactive) + //afk_period = CONFIG_GET(number/afk_period) + for(var/I in currentrun) + var/client/C = I + //handle kicking inactive players + /*if(round_started && kick_inactive && !C.holder && C.is_afk(afk_period)) + var/cmob = C.mob + if (!isnewplayer(cmob) || !SSticker.queued_players.Find(cmob)) + log_access("AFK: [key_name(C)]") + to_chat(C, span_userdanger("You have been inactive for more than [DisplayTimeText(afk_period)] and have been disconnected.") + "
" + span_danger("You may reconnect via the button in the file menu or by " + span_bold(span_underline("clicking here to reconnect")" + ".")) + QDEL_IN(C, 1) //to ensure they get our message before getting disconnected + continue*/ + + if (!(!C || world.time - C.connection_time < PING_BUFFER_TIME || C.inactivity >= (wait-1))) + winset(C, null, "command=.update_ping+[num2text(world.time+world.tick_lag*TICK_USAGE_REAL/100, 32)]") + + if (MC_TICK_CHECK) //one day, when ss13 has 1000 people per server, you guys are gonna be glad I added this tick check + return + +/datum/controller/subsystem/server_maint/Shutdown() + if (fexists("tmp/")) + fdel("tmp/") + //kick_clients_in_lobby(span_boldannounce("The round came to an end with you in the lobby."), TRUE) //second parameter ensures only afk clients are kicked + var/server = CONFIG_GET(string/server) + for(var/thing in GLOB.clients) + if(!thing) + continue + var/client/C = thing + C?.tgui_panel?.send_roundrestart() + if(server) //if you set a server location in config.txt, it sends you there instead of trying to reconnect to the same world address. -- NeoFite + C << link("byond://[server]") + +/* +/datum/controller/subsystem/server_maint/proc/UpdateHubStatus() + if(!CONFIG_GET(flag/hub) || !CONFIG_GET(number/max_hub_pop)) + return FALSE //no point, hub / auto hub controls are disabled + + var/max_pop = CONFIG_GET(number/max_hub_pop) + + if(GLOB.clients.len > max_pop) + world.update_hub_visibility(FALSE) + else + world.update_hub_visibility(TRUE) +*/ +#undef PING_BUFFER_TIME diff --git a/code/controllers/subsystems/statpanel.dm b/code/controllers/subsystems/statpanel.dm index 870d32b1ec3..6e97b992292 100644 --- a/code/controllers/subsystems/statpanel.dm +++ b/code/controllers/subsystems/statpanel.dm @@ -136,7 +136,7 @@ SUBSYSTEM_DEF(statpanels) target.stat_panel.send_message("update_stat", list( global_data = global_data, - ping_str = "Ping: -- Not Available --", // [round(target.lastping, 1)]ms (Average: [round(target.avgping, 1)]ms)", + ping_str = "Ping: [round(target.lastping, 1)]ms (Average: [round(target.avgping, 1)]ms)", other_str = target.mob?.get_status_tab_items(), )) @@ -173,7 +173,9 @@ SUBSYSTEM_DEF(statpanels) target.stat_panel.send_message("update_examine", examine_update) /datum/controller/subsystem/statpanels/proc/set_tickets_tab(client/target) - var/list/tickets = GLOB.ahelp_tickets.stat_entry(target) + var/list/tickets = list() + if(check_rights(R_ADMIN|R_SERVER|R_MOD,FALSE,target)) //Prevents non-staff from opening the list of ahelp tickets + tickets += GLOB.ahelp_tickets.stat_entry(target) tickets += GLOB.mhelp_tickets.stat_entry(target) target.stat_panel.send_message("update_tickets", tickets) @@ -203,12 +205,12 @@ SUBSYSTEM_DEF(statpanels) return var/list/overrides = list() for(var/image/target_image as anything in target.images) - if(!target_image.loc || target_image.loc.loc != target_mob.listed_turf || !target_image.override) + if(!target_image.loc || target_image.loc.loc != target.tracked_turf || !target_image.override) continue overrides += target_image.loc - var/list/atoms_to_display = list(target_mob.listed_turf) - for(var/atom/movable/turf_content as anything in target_mob.listed_turf) + var/list/atoms_to_display = list(target.tracked_turf) + for(var/atom/movable/turf_content as anything in target.tracked_turf) if(turf_content.mouse_opacity == MOUSE_OPACITY_TRANSPARENT) continue if(turf_content.invisibility > target_mob.see_invisible) @@ -319,12 +321,11 @@ SUBSYSTEM_DEF(statpanels) // Handle turfs - if(target_mob?.listed_turf) - if(!target_mob.TurfAdjacent(target_mob.listed_turf)) - target.stat_panel.send_message("removed_listedturf") - target_mob.listed_turf = null + if(target.tracked_turf) + if(!target_mob.TurfAdjacent(target.tracked_turf)) + target_mob.set_listed_turf(null) - else if(target.stat_tab == target_mob?.listed_turf.name || !(target_mob?.listed_turf.name in target.panel_tabs)) + else if(target.stat_tab == target.tracked_turf.name || !(target.tracked_turf.name in target.panel_tabs)) set_turf_examine_tab(target, target_mob) return TRUE @@ -351,6 +352,8 @@ SUBSYSTEM_DEF(statpanels) /// Stat panel window declaration /client/var/datum/tgui_window/stat_panel +/// Turf examine turf +/client/var/turf/tracked_turf /// Datum that holds and tracks info about a client's object window /// Really only exists because I want to be able to do logic with signals @@ -365,8 +368,6 @@ SUBSYSTEM_DEF(statpanels) var/list/atoms_to_imagify = list() /// Our owner client var/client/parent - /// Are we currently tracking a turf? - var/actively_tracking = FALSE ///For reusing this logic for examines var/atom/examine_target var/flags = 0 @@ -418,28 +419,31 @@ SUBSYSTEM_DEF(statpanels) if(!length(to_make)) return PROCESS_KILL -/datum/object_window_info/proc/start_turf_tracking() - if(actively_tracking) +/datum/object_window_info/proc/start_turf_tracking(turf/new_turf) + if(parent.tracked_turf) stop_turf_tracking() var/static/list/connections = list( COMSIG_MOVABLE_MOVED = PROC_REF(on_mob_move), COMSIG_MOB_LOGOUT = PROC_REF(on_mob_logout), ) AddComponent(/datum/component/connect_mob_behalf, parent, connections) - RegisterSignal(parent.mob.listed_turf, COMSIG_ATOM_ENTERED, PROC_REF(turflist_changed)) - RegisterSignal(parent.mob.listed_turf, COMSIG_ATOM_EXITED, PROC_REF(turflist_changed)) - actively_tracking = TRUE + RegisterSignal(parent.tracked_turf, COMSIG_ATOM_ENTERED, PROC_REF(turflist_changed)) + RegisterSignal(parent.tracked_turf, COMSIG_ATOM_EXITED, PROC_REF(turflist_changed)) + parent.stat_panel.send_message("create_listedturf", new_turf) + parent.tracked_turf = new_turf /datum/object_window_info/proc/stop_turf_tracking() - qdel(GetComponent(/datum/component/connect_mob_behalf)) - UnregisterSignal(parent.mob.listed_turf, COMSIG_ATOM_ENTERED) - UnregisterSignal(parent.mob.listed_turf, COMSIG_ATOM_EXITED) - actively_tracking = FALSE + if(GetComponent(/datum/component/connect_mob_behalf)) + qdel(GetComponent(/datum/component/connect_mob_behalf)) + if(parent.tracked_turf) + UnregisterSignal(parent.tracked_turf, COMSIG_ATOM_ENTERED) + UnregisterSignal(parent.tracked_turf, COMSIG_ATOM_EXITED) + parent.stat_panel.send_message("remove_listedturf") + parent.tracked_turf = null /datum/object_window_info/proc/on_mob_move(mob/source) SIGNAL_HANDLER - var/turf/listed = source.listed_turf - if(!listed || !source.TurfAdjacent(listed)) + if(!parent.tracked_turf || !source.TurfAdjacent(parent.tracked_turf)) source.set_listed_turf(null) /datum/object_window_info/proc/on_mob_logout(mob/source) @@ -466,16 +470,12 @@ SUBSYSTEM_DEF(statpanels) /mob/proc/set_listed_turf(turf/new_turf) if(!client) - listed_turf = new_turf return if(!client.obj_window) client.obj_window = new(client) + if(client.tracked_turf == new_turf) + return if(!new_turf) client.obj_window.stop_turf_tracking() //Needs to go before listed_turf is set to null so signals can be removed - listed_turf = new_turf - - if(listed_turf) - client.stat_panel.send_message("create_listedturf", listed_turf.name) - client.obj_window.start_turf_tracking() - else - client.stat_panel.send_message("remove_listedturf") + return + client.obj_window.start_turf_tracking(new_turf) diff --git a/code/controllers/subsystems/vote.dm b/code/controllers/subsystems/vote.dm index 102ffe5028b..19030913c84 100644 --- a/code/controllers/subsystems/vote.dm +++ b/code/controllers/subsystems/vote.dm @@ -392,7 +392,7 @@ SUBSYSTEM_DEF(vote) usr.client.vote() /client/verb/vote() - set category = "OOC" + set category = "OOC.Game" set name = "Vote" if(SSvote) diff --git a/code/controllers/verbs.dm b/code/controllers/verbs.dm index fee7da9b853..702dbfddaeb 100644 --- a/code/controllers/verbs.dm +++ b/code/controllers/verbs.dm @@ -38,7 +38,7 @@ // Debug verbs. /client/proc/restart_controller(controller in list("Master", "Failsafe")) - set category = "Debug" + set category = "Debug.Dangerous" set name = "Restart Controller" set desc = "Restart one of the various periodic loop controllers for the game (be careful!)" @@ -55,7 +55,7 @@ message_admins("Admin [key_name_admin(usr)] has restarted the [controller] controller.") /client/proc/debug_antagonist_template(antag_type in all_antag_types) - set category = "Debug" + set category = "Debug.Investigate" set name = "Debug Antagonist" set desc = "Debug an antagonist template." @@ -65,7 +65,7 @@ message_admins("Admin [key_name_admin(usr)] is debugging the [antag.role_text] template.") /client/proc/debug_controller() - set category = "Debug" + set category = "Debug.Investigate" set name = "Debug Controller" set desc = "Debug the various subsystems/controllers for the game (be careful!)" diff --git a/code/datums/chat_message.dm b/code/datums/chat_message.dm index 9dc66a3cbc8..f216ae01cf5 100644 --- a/code/datums/chat_message.dm +++ b/code/datums/chat_message.dm @@ -51,8 +51,6 @@ var/list/runechat_image_cache = list() /// If we are currently processing animation and cleanup at EOL var/ending_life - /// deletion timer - var/timer_delete /** * Constructs a chat message overlay @@ -75,9 +73,6 @@ var/list/runechat_image_cache = list() generate_image(text, target, owner, extra_classes, lifespan) /datum/chatmessage/Destroy() - if(timer_delete) - deltimer(timer_delete) - timer_delete = null if(istype(owned_by, /client)) // hopefully the PARENT_QDELETING on client should beat this if it's a disconnect UnregisterSignal(owned_by, COMSIG_PARENT_QDELETING) if(owned_by.seen_messages) @@ -193,8 +188,7 @@ var/list/runechat_image_cache = list() if(sched_remaining > CHAT_MESSAGE_SPAWN_TIME) var/remaining_time = (sched_remaining) * (CHAT_MESSAGE_EXP_DECAY ** idx++) * (CHAT_MESSAGE_HEIGHT_DECAY ** combined_height) m.scheduled_destruction = world.time + remaining_time - spawn(remaining_time) - m.end_of_life() + m.schedule_end_of_life(remaining_time) // Build message image message = image(loc = message_loc, layer = ABOVE_MOB_LAYER) @@ -220,13 +214,16 @@ var/list/runechat_image_cache = list() // Prepare for destruction scheduled_destruction = world.time + (lifespan - CHAT_MESSAGE_EOL_FADE) - spawn(lifespan - CHAT_MESSAGE_EOL_FADE) - end_of_life() + schedule_end_of_life(lifespan - CHAT_MESSAGE_EOL_FADE) /datum/chatmessage/proc/unregister_qdel_self() // this should only call owned_by if the client is destroyed UnregisterSignal(owned_by, COMSIG_PARENT_QDELETING) owned_by = null qdel_self() + +/datum/chatmessage/proc/schedule_end_of_life(var/schedule) + addtimer(CALLBACK(src, PROC_REF(end_of_life)), schedule, TIMER_DELETE_ME) + /** * Applies final animations to overlay CHAT_MESSAGE_EOL_FADE deciseconds prior to message deletion */ @@ -235,7 +232,7 @@ var/list/runechat_image_cache = list() return ending_life = TRUE animate(message, alpha = 0, time = fadetime, flags = ANIMATION_PARALLEL) - timer_delete = QDEL_IN(src, fadetime) + addtimer(CALLBACK(GLOBAL_PROC, GLOBAL_PROC_REF(qdel), src), fadetime, TIMER_DELETE_ME) /** * Creates a message overlay at a defined location for a given speaker @@ -250,6 +247,9 @@ var/list/runechat_image_cache = list() if(!client) return + // Source Deleting + if(QDELETED(speaker)) + return // Doesn't want to hear if(ismob(speaker) && !client.prefs?.read_preference(/datum/preference/toggle/runechat_mob)) return @@ -356,7 +356,7 @@ var/list/runechat_image_cache = list() hearing_mobs = hear["mobs"] for(var/mob/M as anything in hearing_mobs) - if(!M.client) + if(!M?.client) continue M.create_chat_message(src, message, italics, classes, audible) diff --git a/code/datums/diseases/_MobProcs.dm b/code/datums/diseases/_MobProcs.dm new file mode 100644 index 00000000000..a24fa9264f8 --- /dev/null +++ b/code/datums/diseases/_MobProcs.dm @@ -0,0 +1,195 @@ +/mob/proc/HasDisease(datum/disease/D) + for(var/thing in GetViruses()) + var/datum/disease/DD = thing + if(DD.IsSame(D)) + return TRUE + return FALSE + +/mob/proc/CanContractDisease(datum/disease/D) + if(stat == DEAD && !D.allow_dead) + return FALSE + + if(D.GetDiseaseID() in GetResistances()) + return FALSE + + if(HasDisease(D)) + return FALSE + + if(istype(D, /datum/disease/advance) && count_by_type(GetViruses(), /datum/disease/advance) > 0) + return FALSE + + if(!(type in D.viable_mobtypes)) + return -1 + + if(isSynthetic()) + if(D.infect_synthetics) + return TRUE + return FALSE + + return TRUE + +/mob/proc/ContractDisease(datum/disease/D) + if(!CanContractDisease(D)) + return 0 + AddDisease(D) + return TRUE + +/mob/proc/AddDisease(datum/disease/D, respect_carrier = FALSE) + var/datum/disease/DD = new D.type(1, D, 0) + viruses += DD + DD.affected_mob = src + active_diseases += DD + + var/list/skipped = list("affected_mob", "holder", "carrier", "stage", "type", "parent_type", "vars", "transformed") + if(respect_carrier) + skipped -= "carrier" + for(var/V in DD.vars) + if(V in skipped) + continue + if(istype(DD.vars[V],/list)) + var/list/L = D.vars[V] + DD.vars[V] = L.Copy() + else + DD.vars[V] = D.vars[V] + + log_admin("[key_name(usr)] has contracted the virus \"[DD]\"") + +/mob/living/carbon/ContractDisease(datum/disease/D) + if(!CanContractDisease(D)) + return 0 + + var/obj/item/clothing/Cl = null + var/passed = 1 + + var/head_ch = 100 + var/body_ch = 100 + var/hands_ch = 25 + var/feet_ch = 25 + + if(D.spread_flags & CONTACT_HANDS) + head_ch = 0 + body_ch = 0 + hands_ch = 100 + feet_ch = 0 + if(D.spread_flags & CONTACT_FEET) + head_ch = 0 + body_ch = 0 + hands_ch = 0 + feet_ch = 100 + + if(prob(15/D.permeability_mod)) + return + + if(nutrition > 300 && prob(nutrition/10)) + return + + var/list/zone_weights = list( + 1 = head_ch, + 2 = body_ch, + 3 = hands_ch, + 4 = feet_ch + ) + + var/target_zone = pick(zone_weights) + + if(ishuman(src)) + var/mob/living/carbon/human/H = src + + switch(target_zone) + if(1) + if(isobj(H.head) && !istype(H.head, /obj/item/paper)) + Cl = H.head + passed = prob((Cl.permeability_coefficient*100) - 1) + if(passed && isobj(H.wear_mask)) + Cl = H.wear_mask + passed = prob((Cl.permeability_coefficient*100) - 1) + if(2) + if(isobj(H.wear_suit)) + Cl = H.wear_suit + passed = prob((Cl.permeability_coefficient*100) - 1) + if(passed && isobj(H.w_uniform)) + Cl = H.w_uniform + passed = prob((Cl.permeability_coefficient*100) - 1) + if(3) + if(isobj(H.wear_suit) && H.wear_suit.body_parts_covered & HANDS) + Cl = H.wear_suit + passed = prob((Cl.permeability_coefficient*100) - 1) + + if(passed && isobj(H.gloves)) + Cl = H.gloves + passed = prob((Cl.permeability_coefficient*100) - 1) + if(4) + if(isobj(H.wear_suit) && H.wear_suit.body_parts_covered & FEET) + Cl = H.wear_suit + passed = prob((Cl.permeability_coefficient*100) - 1) + + if(passed && isobj(H.shoes)) + Cl = H.shoes + passed = prob((Cl.permeability_coefficient*100) - 1) + if(!passed && (D.spread_flags & AIRBORNE) && !internal) + passed = (prob((50*D.permeability_mod) -1)) + + if(passed) + AddDisease(D) + return passed + +/mob/proc/ForceContractDisease(datum/disease/D, respect_carrier) + if(!CanContractDisease(D)) + return FALSE + + AddDisease(D, respect_carrier) + return TRUE + +/mob/living/carbon/human/CanContractDisease(datum/disease/D) + if(species.virus_immune && !D.bypasses_immunity) + return FALSE + + for(var/organ in D.required_organs) + if(locate(organ) in internal_organs) + continue + if(locate(organ) in organs) + continue + return FALSE + return ..() + +/mob/living/carbon/human/monkey/CanContractDisease(datum/disease/D) + . = ..() + if(. == -1) + if(D.viable_mobtypes.Find(/mob/living/carbon/human)) + return 1 + +/mob/living/proc/handle_diseases() + return + +/mob/proc/GetViruses() + LAZYINITLIST(viruses) + return viruses + +/mob/proc/GetResistances() + LAZYINITLIST(resistances) + return resistances + +/client/proc/ReleaseVirus() + set category = "Fun.Event Kit" + set name = "Release Virus" + set desc = "Release a pre-set virus." + + if(!is_admin()) + return FALSE + + var/datum/disease/D = tgui_input_list(usr, "Choose virus", "Viruses", subtypesof(/datum/disease), subtypesof(/datum/disease)) + var/mob/living/carbon/human/H = null + + if(isnull(D)) + return FALSE + + for(var/thing in shuffle(human_mob_list)) + H = thing + if(H.stat == DEAD) + continue + if(!H.HasDisease(D)) + H.ForceContractDisease(D) + break + + message_admins("[key_name_admin(usr)] has triggered a virus outbreak of [D.name]! Affected mob: [key_name_admin(H)]") + log_admin("[key_name_admin(usr)] infected [key_name_admin(H)] with [D.name]") diff --git a/code/datums/diseases/_disease.dm b/code/datums/diseases/_disease.dm new file mode 100644 index 00000000000..6ae5cdbb9e0 --- /dev/null +++ b/code/datums/diseases/_disease.dm @@ -0,0 +1,167 @@ +GLOBAL_LIST_INIT(diseases, subtypesof(/datum/disease)) + +/datum/disease + //Flags + var/visibility_flags = 0 + var/disease_flags = CURABLE|CAN_CARRY|CAN_RESIST + var/spread_flags = AIRBORNE + + //Fluff + /// Used for identification of viruses in the Medical Records Virus Database + var/medical_name + var/form = "Virus" + var/name = "No disease" + var/desc = "" + var/agent = "some microbes" + var/spread_text = "" + var/cure_text = "" + + //Stages + var/stage = 1 + var/max_stages = 0 + var/stage_prob = 4 + /// The fraction of stages the virus must at least be at to show up on medical HUDs. Rounded up. + var/discovery_threshold = 0.5 + /// If TRUE, this virus will show up on medical HUDs. Automatically set when it reaches mid-stage. + var/discovered = FALSE + + // Other + var/list/viable_mobtypes = list() + var/mob/living/carbon/affected_mob + var/list/cures = list() + var/infectivity = 65 + var/cure_chance = 8 + var/carrier = FALSE + var/bypasses_immunity = FALSE + var/virus_heal_resistant = FALSE + var/permeability_mod = 1 + var/severity = NONTHREAT + var/list/required_organs = list() + var/needs_all_cures = TRUE + var/list/strain_data = list() + var/allow_dead = FALSE + var/infect_synthetics = FALSE + var/processing = FALSE + +/datum/disease/Destroy() + affected_mob = null + active_diseases.Remove(src) + if(processing) + End() + return ..() + +/datum/disease/proc/stage_act() + if(!affected_mob) + return FALSE + var/cure = has_cure() + + if(carrier && !cure) + return FALSE + + if(!processing) + processing = TRUE + Start() + + stage = min(stage, max_stages) + + handle_stage_advance(cure) + + return handle_cure_testing(cure) + +/datum/disease/proc/handle_stage_advance(has_cure = FALSE) + if(!has_cure && prob(stage_prob)) + stage = min(stage + 1, max_stages) + if(!discovered && stage >= CEILING(max_stages * discovery_threshold, 1)) + discovered = TRUE + BITSET(affected_mob.hud_updateflag, STATUS_HUD) + +/datum/disease/proc/handle_cure_testing(has_cure = FALSE) + if(has_cure && prob(cure_chance)) + stage = max(stage -1, 1) + + if(disease_flags & CURABLE) + if(has_cure && prob(cure_chance)) + cure() + return FALSE + return TRUE + +/datum/disease/proc/has_cure() + if(!(disease_flags & CURABLE)) + return 0 + + var/cures_found = 0 + for(var/C_id in cures) + if(affected_mob.reagents.has_reagent(C_id)) + cures_found++ + + if(needs_all_cures && cures_found < length(cures)) + return FALSE + + return cures_found + +/datum/disease/proc/spread(force_spread = 0) + if(!affected_mob) + return + + if((spread_flags & SPECIAL || spread_flags & NON_CONTAGIOUS || spread_flags & BLOOD) && !force_spread) + return + + if(affected_mob.reagents.has_reagent("spaceacilin") || (affected_mob.nutrition > 300 && prob(affected_mob.nutrition/10))) + return + + var/spread_range = 1 + + if(force_spread) + spread_range = force_spread + + if(spread_flags & AIRBORNE) + spread_range++ + + var/turf/target = affected_mob.loc + if(istype(target)) + for(var/mob/living/carbon/C in oview(spread_range, affected_mob)) + var/turf/current = get_turf(C) + if(current) + while(TRUE) + if(current == target) + C.ContractDisease(src) + break + var/direction = get_dir(current, target) + var/turf/next = get_step(current, direction) + current = next + +/datum/disease/proc/cure() + if(affected_mob) + if(disease_flags & CAN_RESIST) + if(!(type in affected_mob.GetResistances())) + affected_mob.resistances += type + remove_virus() + qdel(src) + +/datum/disease/proc/IsSame(datum/disease/D) + if(ispath(D)) + return istype(src, D) + return istype(src, D.type) + +/datum/disease/proc/Copy() + var/datum/disease/D = new type() + D.strain_data = strain_data.Copy() + return D + +/datum/disease/proc/GetDiseaseID() + return type + +/datum/disease/proc/IsSpreadByTouch() + if(spread_flags & CONTACT_FEET || spread_flags & CONTACT_HANDS || spread_flags & CONTACT_GENERAL) + return 1 + return 0 + +/datum/disease/proc/remove_virus() + affected_mob.viruses -= src + BITSET(affected_mob.hud_updateflag, STATUS_HUD) + +/datum/disease/proc/Start() + return + +/datum/disease/proc/End() + return diff --git a/code/datums/diseases/advance/advance.dm b/code/datums/diseases/advance/advance.dm new file mode 100644 index 00000000000..73ef6649988 --- /dev/null +++ b/code/datums/diseases/advance/advance.dm @@ -0,0 +1,404 @@ +GLOBAL_LIST_EMPTY(archive_diseases) + +GLOBAL_LIST_INIT(advance_cures, list( + "sodiumchloride", "sugar", "orangejuice", + "spaceacilin", "glucose", "ethanol", + "dyloteane", "impedrezene", "hepanephrodaxon", + "gold", "silver" +)) + +/datum/disease/advance + name = "Unknown" + desc = "An engineered disease which can contain a multitude of symptoms." + form = "Advance Disease" + agent = "advance microbes" + max_stages = 5 + spread_text = "Unknown" + viable_mobtypes = list(/mob/living/carbon/human) + + var/list/symptoms = list() + var/id = "" + +/datum/disease/advance/New(process = 1, datum/disease/advance/D) + if(!istype(D)) + D = null + + if(!symptoms || !length(symptoms)) + + if(!D || !D.symptoms || !length(D.symptoms)) + symptoms = GenerateSymptoms(0, 2) + else + for(var/datum/symptom/S in D.symptoms) + symptoms += new S.type + + Refresh() + ..(process, D) + return + +/datum/disease/advance/Destroy() + if(processing) + for(var/datum/symptom/S in symptoms) + S.End(src) + return ..() + +/datum/disease/advance/stage_act() + if(!..()) + return FALSE + if(symptoms && length(symptoms)) + + if(!processing) + processing = TRUE + for(var/datum/symptom/S in symptoms) + S.Start(src) + + for(var/datum/symptom/S in symptoms) + S.Activate(src) + else + CRASH("We do not have any symptoms during stage_act()!") + return TRUE + +/datum/disease/advance/IsSame(datum/disease/advance/D) + if(ispath(D)) + return FALSE + + if(!istype(D, /datum/disease/advance)) + return FALSE + + if(GetDiseaseID() != D.GetDiseaseID()) + return FALSE + + return TRUE + +/datum/disease/advance/cure(resistance=1) + if(affected_mob) + var/id = "[GetDiseaseID()]" + if(resistance && !(id in affected_mob.GetResistances())) + affected_mob.GetResistances()[id] = id + remove_virus() + qdel(src) + +/datum/disease/advance/Copy(process = 0) + return new /datum/disease/advance(process, src, 1) + +/datum/disease/advance/proc/Mix(datum/disease/advance/D) + if(!(IsSame(D))) + var/list/possible_symptoms = shuffle(D.symptoms) + for(var/datum/symptom/S in possible_symptoms) + AddSymptom(new S.type) + +/datum/disease/advance/proc/HasSymptom(datum/symptom/S) + for(var/datum/symptom/symp in symptoms) + if(symp.id == S.id) + return 1 + return 0 + +/datum/disease/advance/proc/GenerateSymptomsBySeverity(sev_min, sev_max, amount = 1) + + var/list/generated = list() + + var/list/possible_symptoms = list() + for(var/symp in GLOB.list_symptoms) + var/datum/symptom/S = new symp + if(S.severity >= sev_min && S.severity <= sev_max) + if(!HasSymptom(S)) + possible_symptoms += S + + if(!length(possible_symptoms)) + return generated + + for(var/i = 1 to amount) + generated += pick_n_take(possible_symptoms) + + return generated + +/datum/disease/advance/proc/GenerateSymptoms(level_min, level_max, amount_get = 0) + + var/list/generated = list() + + // Generate symptoms. By default, we only choose non-deadly symptoms. + var/list/possible_symptoms = list() + for(var/symp in GLOB.list_symptoms) + var/datum/symptom/S = new symp + if(S.level >= level_min && S.level <= level_max) + if(!HasSymptom(S)) + possible_symptoms += S + + if(!length(possible_symptoms)) + return generated + + // Random chance to get more than one symptom + var/number_of = amount_get + if(!amount_get) + number_of = 1 + while(prob(20)) + number_of += 1 + + for(var/i = 1; number_of >= i && length(possible_symptoms); i++) + generated += pick_n_take(possible_symptoms) + + return generated + +/datum/disease/advance/proc/Refresh(new_name = FALSE, archive = FALSE) + var/list/properties = GenerateProperties() + AssignProperties(properties) + id = null + + if(!GLOB.archive_diseases[GetDiseaseID()]) + if(new_name) + AssignName() + GLOB.archive_diseases[GetDiseaseID()] = src // So we don't infinite loop + GLOB.archive_diseases[GetDiseaseID()] = new /datum/disease/advance(0, src, 1) + + var/datum/disease/advance/A = GLOB.archive_diseases[GetDiseaseID()] + AssignName(A.name) + +/datum/disease/advance/proc/GenerateProperties() + + if(!symptoms || !length(symptoms)) + CRASH("We did not have any symptoms before generating properties.") + + var/list/properties = list("resistance" = 1, "stealth" = 0, "stage rate" = 1, "transmittable" = 1, "severity" = 0) + + for(var/datum/symptom/S in symptoms) + + properties["resistance"] += S.resistance + properties["stealth"] += S.stealth + properties["stage rate"] += S.stage_speed + properties["transmittable"] += S.transmittable + properties["severity"] = max(properties["severity"], S.severity) // severity is based on the highest severity symptom + + return properties + +/datum/disease/advance/proc/AssignProperties(list/properties = list()) + + if(properties && length(properties)) + switch(properties["stealth"]) + if(2) + visibility_flags = HIDDEN_SCANNER + if(3 to INFINITY) + visibility_flags = HIDDEN_SCANNER|HIDDEN_PANDEMIC + + // The more symptoms we have, the less transmittable it is but some symptoms can make up for it. + SetSpread(clamp(2 ** (properties["transmittable"] - length(symptoms)), BLOOD, AIRBORNE)) + permeability_mod = max(CEILING(0.4 * properties["transmittable"], 1), 1) + cure_chance = 15 - clamp(properties["resistance"], -5, 5) // can be between 10 and 20 + stage_prob = max(properties["stage rate"], 2) + SetSeverity(properties["severity"]) + GenerateCure(properties) + else + CRASH("Our properties were empty or null!") + +/datum/disease/advance/proc/SetSpread(spread_id) + switch(spread_id) + if(NON_CONTAGIOUS, SPECIAL) + spread_text = "Non-contagious" + if(CONTACT_GENERAL, CONTACT_HANDS, CONTACT_FEET) + spread_text = "On contact" + if(AIRBORNE) + spread_text = "Airborne" + if(BLOOD) + spread_text = "Blood" + + spread_flags = spread_id + +/datum/disease/advance/proc/SetSeverity(level_sev) + + switch(level_sev) + + if(-INFINITY to 0) + severity = NONTHREAT + if(1) + severity = MINOR + if(2) + severity = MEDIUM + if(3) + severity = HARMFUL + if(4) + severity = DANGEROUS + if(5 to INFINITY) + severity = BIOHAZARD + else + severity = "Unknown" + +/datum/disease/advance/proc/GenerateCure(list/properties = list()) + if(properties && length(properties)) + var/res = clamp(properties["resistance"] - (length(symptoms) / 2), 1, length(GLOB.advance_cures)) + cures = list(GLOB.advance_cures[res]) + cure_text = cures[1] + return + +// Randomly generate a symptom, has a chance to lose or gain a symptom. +/datum/disease/advance/proc/Evolve(min_level, max_level) + var/s = safepick(GenerateSymptoms(min_level, max_level, 1)) + if(s) + AddSymptom(s) + Refresh(1) + return + +// Randomly remove a symptom. +/datum/disease/advance/proc/Devolve() + if(length(symptoms) > 1) + var/s = safepick(symptoms) + if(s) + RemoveSymptom(s) + Refresh(1) + return + +// Name the disease. +/datum/disease/advance/proc/AssignName(name = "Unknown") + src.name = name + return + +// Return a unique ID of the disease. +/datum/disease/advance/GetDiseaseID() + if(!id) + var/list/L = list() + for(var/datum/symptom/S in symptoms) + L += S.id + L = sortList(L) // Sort the list so it doesn't matter which order the symptoms are in. + var/result = jointext(L, ":") + id = result + return id + +// Add a symptom, if it is over the limit (with a small chance to be able to go over) +// we take a random symptom away and add the new one. +/datum/disease/advance/proc/AddSymptom(datum/symptom/S) + + if(HasSymptom(S)) + return + + if(length(symptoms) < (VIRUS_SYMPTOM_LIMIT - 1) + rand(-1, 1)) + symptoms += S + else + RemoveSymptom(pick(symptoms)) + symptoms += S + return + +// Simply removes the symptom. +/datum/disease/advance/proc/RemoveSymptom(datum/symptom/S) + symptoms -= S + return + +// Mix a list of advance diseases and return the mixed result. +/proc/Advance_Mix(list/D_list) + + var/list/diseases = list() + + for(var/datum/disease/advance/A in D_list) + diseases += A.Copy() + + if(!length(diseases)) + return null + if(length(diseases) <= 1) + return pick(diseases) // Just return the only entry. + + var/i = 0 + // Mix our diseases until we are left with only one result. + while(i < 20 && length(diseases) > 1) + + i++ + + var/datum/disease/advance/D1 = pick(diseases) + diseases -= D1 + + var/datum/disease/advance/D2 = pick(diseases) + D2.Mix(D1) + + // Should be only 1 entry left, but if not let's only return a single entry + var/datum/disease/advance/to_return = pick(diseases) + to_return.Refresh(1) + return to_return + +/proc/SetViruses(datum/reagent/R, list/data) + if(data) + var/list/preserve = list() + if(istype(data) && data["viruses"]) + for(var/datum/disease/A in data["viruses"]) + preserve += A.Copy() + R.data = data.Copy() + if(length(preserve)) + R.data["viruses"] = preserve + +/client/proc/AdminCreateVirus() + set category = "Fun.Event Kit" + set name = "Create Advanced Virus" + set desc = "Create an advanced virus and release it." + + if(!is_admin()) + return FALSE + + var/i = VIRUS_SYMPTOM_LIMIT + var/mob/living/carbon/human/H = null + + var/datum/disease/advance/D = new(0, null) + D.symptoms = list() + + var/list/symptoms = list() + symptoms += "Done" + symptoms += GLOB.list_symptoms.Copy() + do + if(usr) + var/symptom = tgui_input_list(usr, "Choose a symptom to add ([i] remaining)", "Choose a Symptom", symptoms) + if(isnull(symptom)) + return + else if(istext(symptom)) + i = 0 + else if(ispath(symptom)) + var/datum/symptom/S = new symptom + if(!D.HasSymptom(S)) + D.symptoms += S + i -= 1 + while(i > 0) + + if(length(D.symptoms) > 0) + + var/new_name = tgui_input_text(usr, "Name your new disease.", "New Name") + if(!new_name) + return + D.AssignName(new_name) + D.Refresh() + + for(var/datum/disease/advance/AD in active_diseases) + AD.Refresh() + + for(var/thing in shuffle(human_mob_list)) + H = thing + if(H.stat == DEAD) + continue + if(!H.HasDisease(D)) + H.ForceContractDisease(D) + break + + var/list/name_symptoms = list() + for(var/datum/symptom/S in D.symptoms) + name_symptoms += S.name + message_admins("[key_name_admin(usr)] has triggered a custom virus outbreak of [D.name]! It has these symptoms: [english_list(name_symptoms)]") + log_admin("[key_name_admin(usr)] infected [key_name_admin(H)] with [D.name]. It has these symptoms: [english_list(name_symptoms)]") + +/datum/disease/advance/proc/totalStageSpeed() + var/total_stage_speed = 0 + for(var/i in symptoms) + var/datum/symptom/S = i + total_stage_speed += S.stage_speed + return total_stage_speed + +/datum/disease/advance/proc/totalStealth() + var/total_stealth = 0 + for(var/i in symptoms) + var/datum/symptom/S = i + total_stealth += S.stealth + return total_stealth + +/datum/disease/advance/proc/totalResistance() + var/total_resistance = 0 + for(var/i in symptoms) + var/datum/symptom/S = i + total_resistance += S.resistance + return total_resistance + +/datum/disease/advance/proc/totalTransmittable() + var/total_transmittable = 0 + for(var/i in symptoms) + var/datum/symptom/S = i + total_transmittable += S.transmittable + return total_transmittable diff --git a/code/datums/diseases/advance/disease_preset.dm b/code/datums/diseases/advance/disease_preset.dm new file mode 100644 index 00000000000..d30bbf2ebb5 --- /dev/null +++ b/code/datums/diseases/advance/disease_preset.dm @@ -0,0 +1,16 @@ +// Cold + +/datum/disease/advance/cold/New(process = 1, datum/disease/advance/D, copy = 0) + if(!D) + name = "Cold" + symptoms = list(new /datum/symptom/sneeze) + ..(process, D, copy) + + +// Flu + +/datum/disease/advance/flu/New(process = 1, datum/disease/advance/D, copy = 0) + if(!D) + name = "Flu" + symptoms = list(new /datum/symptom/cough) + ..(process, D, copy) diff --git a/code/datums/diseases/advance/symptoms/choking.dm b/code/datums/diseases/advance/symptoms/choking.dm new file mode 100644 index 00000000000..24be1c1a153 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/choking.dm @@ -0,0 +1,52 @@ +/* +////////////////////////////////////// + +Choking + + Very very noticable. + Lowers resistance. + Decreases stage speed. + Decreases transmittablity tremendously. + Moderate Level. + +Bonus + Inflicts spikes of oxyloss + +////////////////////////////////////// +*/ + +/datum/symptom/choking + name = "Choking" + stealth = -3 + resistance = -2 + stage_speed = -2 + transmittable = -4 + level = 3 + severity = 3 + +/datum/symptom/choking/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(1, 2) + to_chat(M, span_warning(pick("You're having difficulty breathing.", "Your breathing becomes heavy."))) + if(3, 4) + to_chat(M, span_boldwarning(pick("Your windpipe feels like a straw.", "Your breathing becomes tremendously difficult."))) + Choke_stage_3_4(M, A) + M.emote("gasp") + else + to_chat(M, span_userdanger(pick("You're choking!", "You can't breathe!"))) + Choke(M, A) + M.emote("gasp") + return + +/datum/symptom/choking/proc/Choke_stage_3_4(mob/living/M, datum/disease/advance/A) + var/get_damage = sqrtor0(21+A.totalStageSpeed()*0.5)+sqrtor0(16+A.totalStealth()) + M.adjustOxyLoss(get_damage) + return 1 + +/datum/symptom/choking/proc/Choke(mob/living/M, datum/disease/advance/A) + var/get_damage = sqrtor0(21+A.totalStageSpeed()*0.5)+sqrtor0(16+A.totalStealth()*5) + M.adjustOxyLoss(get_damage) + return 1 diff --git a/code/datums/diseases/advance/symptoms/confusion.dm b/code/datums/diseases/advance/symptoms/confusion.dm new file mode 100644 index 00000000000..039d9ad8db6 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/confusion.dm @@ -0,0 +1,40 @@ +/* +////////////////////////////////////// + +Confusion + + Little bit hidden. + Lowers resistance. + Decreases stage speed. + Not very transmittable. + Intense Level. + +Bonus + Makes the affected mob be confused for short periods of time. + +////////////////////////////////////// +*/ + +/datum/symptom/confusion + + name = "Confusion" + stealth = 1 + resistance = -1 + stage_speed = -3 + transmittable = 0 + level = 4 + severity = 2 + + +/datum/symptom/confusion/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/carbon/M = A.affected_mob + switch(A.stage) + if(1, 2, 3, 4) + to_chat(M, span_warning(pick("Your head hurts.", "Your mind blanks for a moment."))) + else + to_chat(M, span_userdanger("You can't think straight!")) + M.AdjustConfused(rand(16, 200)) + + return diff --git a/code/datums/diseases/advance/symptoms/cough.dm b/code/datums/diseases/advance/symptoms/cough.dm new file mode 100644 index 00000000000..bdf04a9fdf4 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/cough.dm @@ -0,0 +1,39 @@ +/* +////////////////////////////////////// + +Coughing + + Noticable. + Little Resistance. + Doesn't increase stage speed much. + Transmittable. + Low Level. + +BONUS + Will force the affected mob to drop small items! + +////////////////////////////////////// +*/ + +/datum/symptom/cough + name = "Cough" + stealth = -1 + resistance = 3 + stage_speed = 1 + transmittable = 2 + level = 1 + severity = 1 + +/datum/symptom/cough/Activate(var/datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(1, 2, 3) + to_chat(M, span_warning(pick("You swallow excess mucus", "You lightly cough."))) + else + M.emote("cough") + var/obj/item/I = M.get_active_hand() + if(I && I.w_class == ITEMSIZE_SMALL) + M.drop_item() + return diff --git a/code/datums/diseases/advance/symptoms/damage_converter.dm b/code/datums/diseases/advance/symptoms/damage_converter.dm new file mode 100644 index 00000000000..f2a299469b1 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/damage_converter.dm @@ -0,0 +1,59 @@ +/* +////////////////////////////////////// + +Damage Converter + + Little bit hidden. + Lowers resistance tremendously. + Decreases stage speed tremendously. + Reduced transmittablity + Intense Level. + +Bonus + Slowly converts brute/fire damage to toxin. + +////////////////////////////////////// +*/ + +/datum/symptom/damage_converter + name = "Toxic Compensation" + stealth = 1 + resistance = -4 + stage_speed = -4 + transmittable = -2 + level = 4 + +/datum/symptom/damage_converter/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB * 10)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(4, 5) + Convert(M) + return + +/datum/symptom/damage_converter/proc/Convert(mob/living/M) + + var/get_damage = rand(1, 2) + + if(ishuman(M)) + var/mob/living/carbon/human/H = M + + var/list/parts = H.get_damaged_organs(TRUE, TRUE) + + if(!length(parts)) + return + var/healed = 0 + for(var/obj/item/organ/external/E in parts) + healed += min(E.brute_dam, get_damage) + min(E.burn_dam, get_damage) + E.heal_damage(get_damage, get_damage, 0, 0) + M.adjustToxLoss(healed) + + else + if(M.getFireLoss() > 0 || M.getBruteLoss() > 0) + M.adjustFireLoss(-get_damage) + M.adjustBruteLoss(-get_damage) + M.adjustToxLoss(get_damage) + else + return + return TRUE diff --git a/code/datums/diseases/advance/symptoms/dizzy.dm b/code/datums/diseases/advance/symptoms/dizzy.dm new file mode 100644 index 00000000000..fdedcba79c0 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/dizzy.dm @@ -0,0 +1,38 @@ +/* +////////////////////////////////////// + +Dizziness + + Hidden. + Lowers resistance considerably. + Decreases stage speed. + Reduced transmittability + Intense Level. + +Bonus + Shakes the affected mob's screen for short periods. + +////////////////////////////////////// +*/ + +/// Not the egg +/datum/symptom/dizzy + name = "Dizziness" + stealth = 2 + resistance = -2 + stage_speed = -3 + transmittable = -1 + level = 4 + severity = 2 + +/datum/symptom/dizzy/Activate(var/datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(1, 2, 3, 4) + to_chat(M, span_warning(pick("You feel dizzy.", "Your head spins."))) + else + to_chat(M, span_userdanger("A wave of dizziness washes over you!")) + M.make_dizzy(10) + return diff --git a/code/datums/diseases/advance/symptoms/fever.dm b/code/datums/diseases/advance/symptoms/fever.dm new file mode 100644 index 00000000000..a9e027da9cd --- /dev/null +++ b/code/datums/diseases/advance/symptoms/fever.dm @@ -0,0 +1,40 @@ +/* +////////////////////////////////////// + +Fever + + No change to hidden. + Increases resistance. + Increases stage speed. + Little transmittable. + Low level. + +Bonus + Heats up your body. + +////////////////////////////////////// +*/ + +/datum/symptom/fever + name = "Fever" + stealth = 0 + resistance = 3 + stage_speed = 3 + transmittable = 2 + level = 2 + severity = 2 + +/datum/symptom/fever/Activate(var/datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/carbon/M = A.affected_mob + to_chat(M, span_warning(pick("You feel hot.", "You feel like you're burning."))) + if(M.bodytemperature < BODYTEMP_HEAT_DAMAGE_LIMIT) + Heat(M, A) + + return + +/datum/symptom/fever/proc/Heat(var/mob/living/M, var/datum/disease/advance/A) + var/get_heat = (sqrt(21+A.totalTransmittable()*2))+(sqrt(20+A.totalStageSpeed()*3)) + M.bodytemperature = min(M.bodytemperature + (get_heat * A.stage), BODYTEMP_HEAT_DAMAGE_LIMIT - 1) + return TRUE diff --git a/code/datums/diseases/advance/symptoms/fire.dm b/code/datums/diseases/advance/symptoms/fire.dm new file mode 100644 index 00000000000..956d778f5d5 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/fire.dm @@ -0,0 +1,56 @@ +/* +////////////////////////////////////// + +Spontaneous Combustion + + Slightly hidden. + Lowers resistance tremendously. + Decreases stage tremendously. + Decreases transmittablity tremendously. + Fatal Level. + +Bonus + Ignites infected mob. + +////////////////////////////////////// +*/ + +/datum/symptom/fire + name = "Spontaneous Combustion" + stealth = 1 + resistance = -4 + stage_speed = -4 + transmittable = -4 + level = 6 + severity = 5 + +/datum/symptom/fire/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(3) + to_chat(M, span_warning(pick("You feel hot.", "You hear a crackling noise.", "You smell smoke."))) + if(4) + Firestacks_stage_4(M, A) + M.IgniteMob() + to_chat(M, span_userdanger("Your skin bursts into flames!")) + M.emote("scream") + if(5) + Firestacks_stage_5(M, A) + M.IgniteMob() + to_chat(M, span_userdanger("Your skin erupts into an inferno!")) + M.emote("scream") + return + +/datum/symptom/fire/proc/Firestacks_stage_4(mob/living/M, datum/disease/advance/A) + var/get_stacks = max((sqrtor0(20 + A.totalStageSpeed() * 2)) - (sqrtor0(16 + A.totalStealth())), 1) + M.adjust_fire_stacks(get_stacks) + M.adjustFireLoss(get_stacks * 0.5) + return 1 + +/datum/symptom/fire/proc/Firestacks_stage_5(mob/living/M, datum/disease/advance/A) + var/get_stacks = max((sqrtor0(20 + A.totalStageSpeed() * 3))-(sqrtor0(16 + A.totalStealth())), 1) + M.adjust_fire_stacks(get_stacks) + M.adjustFireLoss(get_stacks) + return 1 diff --git a/code/datums/diseases/advance/symptoms/flesh_eating.dm b/code/datums/diseases/advance/symptoms/flesh_eating.dm new file mode 100644 index 00000000000..28c9002c3a1 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/flesh_eating.dm @@ -0,0 +1,42 @@ +/* +////////////////////////////////////// + +Necrotizing Fasciitis (AKA Flesh-Eating Disease) + + Very very noticable. + Lowers resistance tremendously. + No changes to stage speed. + Decreases transmittablity temrendously. + Fatal Level. + +Bonus + Deals brute damage over time. + +////////////////////////////////////// +*/ + +/datum/symptom/flesh_eating + name = "Necrotizing Fasciitis" + stealth = -3 + resistance = -4 + stage_speed = 0 + transmittable = -4 + level = 6 + severity = 5 + +/datum/symptom/flesh_eating/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(2,3) + to_chat(M, span_warning(pick("You feel a sudden pain across your body.", "Drops of blood appear suddenly on your skin."))) + if(4,5) + to_chat(M, span_userdanger(pick("You cringe as a violent pain takes over your body.", "It feels like your body is eating itself inside out.", "IT HURTS."))) + Flesheat(M, A) + return + +/datum/symptom/flesh_eating/proc/Flesheat(mob/living/M, datum/disease/advance/A) + var/get_damage = ((sqrt(16-A.totalStealth()))*5) + M.adjustBruteLoss(get_damage) + return 1 diff --git a/code/datums/diseases/advance/symptoms/hallucigen.dm b/code/datums/diseases/advance/symptoms/hallucigen.dm new file mode 100644 index 00000000000..4bd1e44401d --- /dev/null +++ b/code/datums/diseases/advance/symptoms/hallucigen.dm @@ -0,0 +1,40 @@ +/* +////////////////////////////////////// + +Hallucigen + + Very noticable. + Lowers resistance considerably. + Decreases stage speed. + Reduced transmittable. + Critical Level. + +Bonus + Makes the affected mob be hallucinated for short periods of time. + +////////////////////////////////////// +*/ + +/datum/symptom/hallucigen + name = "Hallucigen" + stealth = -2 + resistance = -3 + stage_speed = -3 + transmittable = -1 + level = 5 + severity = 3 + +/datum/symptom/hallucigen/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/carbon/M = A.affected_mob + switch(A.stage) + if(1, 2) + to_chat(M, span_warning(pick("Something appears in your peripheral vision, then winks out.", "You hear a faint whisper with no source.", "Your head aches."))) + if(3, 4) + to_chat(M, span_boldwarning(pick("Something is following you.", "You are being watched.", "You hear a whisper in your ear.", "Thumping footsteps slam toward you from nowhere."))) + else + to_chat(M, span_userdanger(pick("Oh, your head...", "Your head pounds.", "They're everywhere! Run!", "Something in the shadows..."))) + M.hallucination = rand(5, 10) + + return diff --git a/code/datums/diseases/advance/symptoms/headache.dm b/code/datums/diseases/advance/symptoms/headache.dm new file mode 100644 index 00000000000..431ed9b6703 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/headache.dm @@ -0,0 +1,33 @@ +/* +////////////////////////////////////// + +Headache + + Noticable. + Highly resistant. + Increases stage speed. + Not transmittable. + Low Level. + +BONUS + Displays an annoying message! + Should be used for buffing your disease. + +////////////////////////////////////// +*/ + +/datum/symptom/headache + name = "Headache" + stealth = -1 + resistance = 4 + stage_speed = 2 + transmittable = 0 + level = 1 + severity = 1 + +/datum/symptom/headache/Activate(var/datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + to_chat(M, span_warning(pick("Your head hurts.", "Your head starts pounding."))) + return diff --git a/code/datums/diseases/advance/symptoms/heal.dm b/code/datums/diseases/advance/symptoms/heal.dm new file mode 100644 index 00000000000..1c219598722 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/heal.dm @@ -0,0 +1,150 @@ +/* +////////////////////////////////////// + +Healing + + Little bit hidden. + Lowers resistance tremendously. + Decreases stage speed tremendously. + Decreases transmittablity temrendously. + Fatal Level. + +Bonus + Heals toxins in the affected mob's blood stream. + +////////////////////////////////////// +*/ + +/datum/symptom/heal + name = "Toxic Filter" + stealth = 1 + resistance = -4 + stage_speed = -4 + transmittable = -4 + level = 6 + +/datum/symptom/heal/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB * 10)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(4, 5) + Heal(M, A) + return + +/datum/symptom/heal/proc/Heal(mob/living/M, datum/disease/advance/A) + var/get_damage = (sqrt(20+A.totalStageSpeed())*(1+rand())) + M.adjustToxLoss(-get_damage) + return TRUE + +/* +////////////////////////////////////// + +Metabolism + + Little bit hidden. + Lowers resistance. + Decreases stage speed. + Decreases transmittablity temrendously. + High Level. + +Bonus + Cures all diseases (except itself) and creates anti-bodies for them until the symptom dies. + +////////////////////////////////////// +*/ + +/datum/symptom/heal/metabolism + name = "Anti-Bodies Metabolism" + stealth = -1 + resistance = -1 + stage_speed = -1 + transmittable = -4 + level = 3 + var/list/cured_diseases = list() + +/datum/symptom/heal/metabolism/Heal(mob/living/M, datum/disease/advance/A) + var/cured = 0 + for(var/thing in M.GetViruses()) + var/datum/disease/D = thing + if(D.virus_heal_resistant) + continue + if(D != A) + cured = TRUE + cured_diseases += D.GetDiseaseID() + D.cure() + if(cured) + to_chat(M, span_notice("You feel much better.")) + +/datum/symptom/heal/metabolism/End(datum/disease/advance/A) + var/mob/living/M = A.affected_mob + if(istype(M)) + if(length(cured_diseases)) + for(var/res in M.GetResistances()) + M.resistances -= res + to_chat(M, span_warning("You feel weaker.")) + +/* +////////////////////////////////////// + +Longevity + + Medium hidden boost. + Large resistance boost. + Large stage speed boost. + Large transmittablity boost. + High Level. + +Bonus + After a certain amount of time the symptom will cure itself. + +////////////////////////////////////// +*/ + +/datum/symptom/heal/longevity + name = "Longevity" + stealth = 3 + resistance = 4 + stage_speed = 4 + transmittable = 4 + level = 3 + var/longevity = 30 + +/datum/symptom/heal/longevity/Heal(mob/living/M, datum/disease/advance/A) + longevity -= 1 + if(!longevity) + A.cure() + +/datum/symptom/heal/longevity/Start(datum/disease/advance/A) + longevity = rand(initial(longevity) - 5, initial(longevity) + 5) + +/* +////////////////////////////////////// + + DNA Restoration + + Not well hidden. + Lowers resistance minorly. + Does not affect stage speed. + Decreases transmittablity greatly. + Very high level. + +Bonus + Heals brain damage, treats radiation. + +////////////////////////////////////// +*/ + +/datum/symptom/heal/dna + name = "Deoxyribonucleic Acid Restoration" + stealth = -1 + resistance = -1 + stage_speed = 0 + transmittable = -3 + level = 5 + +/datum/symptom/heal/dna/Heal(var/mob/living/carbon/M, var/datum/disease/advance/A) + var/amt_healed = (sqrt(20+A.totalStageSpeed()*(3+rand())))-(sqrt(16+A.totalStealth()*rand())) + M.adjustBrainLoss(-amt_healed) + M.radiation = max(M.radiation - 3, 0) + return TRUE diff --git a/code/datums/diseases/advance/symptoms/itching.dm b/code/datums/diseases/advance/symptoms/itching.dm new file mode 100644 index 00000000000..fdf2f5f5e4f --- /dev/null +++ b/code/datums/diseases/advance/symptoms/itching.dm @@ -0,0 +1,33 @@ +/* +////////////////////////////////////// + +Itching + + Not noticable or unnoticable. + Resistant. + Increases stage speed. + Little transmittable. + Low Level. + +BONUS + Displays an annoying message! + Should be used for buffing your disease. + +////////////////////////////////////// +*/ + +/datum/symptom/itching + name = "Itching" + stealth = 0 + resistance = 3 + stage_speed = 3 + transmittable = 1 + level = 1 + severity = 1 + +/datum/symptom/itching/Activate(var/datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + to_chat(M, span_warning("Your [pick("back", "arm", "leg", "elbow", "head")] itches.")) + return diff --git a/code/datums/diseases/advance/symptoms/language.dm b/code/datums/diseases/advance/symptoms/language.dm new file mode 100644 index 00000000000..3ffa7c06bb6 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/language.dm @@ -0,0 +1,31 @@ +/* +////////////////////////////////////// + +Lingual Disocation + + Improves stealth. + Increases resistance. + Decreases stage speed. + Slightly decreases transmissibility. + Moderate Level. + +Bonus + Forces the affected mob to vomit + +////////////////////////////////////// +*/ + +/datum/symptom/language + name = "Lingual Disocation" + stealth = 3 + resistance = 2 + stage_speed = -2 + transmittable = -1 + level = 3 + +/datum/symptom/language/Activate(var/datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/carbon/human/H = A.affected_mob + H.apply_default_language(pick(H.languages)) + return diff --git a/code/datums/diseases/advance/symptoms/macrophage.dm b/code/datums/diseases/advance/symptoms/macrophage.dm new file mode 100644 index 00000000000..5769fadaa6c --- /dev/null +++ b/code/datums/diseases/advance/symptoms/macrophage.dm @@ -0,0 +1,73 @@ +/* +////////////////////////////////////// + +Macrophages + + Very noticeable. + Lowers resistance slightly. + Decreases stage speed. + Increases transmittablity + Fatal leve. + +BONUS + The virus grows and ceases to be microscopic. + +////////////////////////////////////// +*/ + +/datum/symptom/macrophage + name = "Macrophage" + stealth = -4 + resistance = -1 + stage_speed = -2 + transmittable = 2 + level = 6 + severity = 2 + + var/gigagerms = FALSE + var/netspeed = 0 + var/phagecounter = 10 + +/datum/symptom/macrophage/Start(datum/disease/advance/A) + netspeed = max(1, A.stage) + if(A.severity >= HARMFUL) + gigagerms = TRUE + +/datum/symptom/macrophage/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(1, 2, 3) + to_chat(M, span_notice("Your skin crawls.")) + if(4) + M.visible_message(span_danger("Lumps form on [M]'s skin!"), span_userdanger("You cringe in pain as lumps form and move around on your skin!")) + if(5) + phagecounter -= max(2, A.totalStageSpeed()) + if(gigagerms && phagecounter <= 0) + Burst(A, M, TRUE) + phagecounter += 10 + while(phagecounter <= 0) + phagecounter += 5 + Burst(A, M) + +/datum/symptom/macrophage/proc/Burst(datum/disease/advance/A, var/mob/living/M, var/gigagerms = FALSE) + var/mob/living/simple_mob/vore/aggressive/macrophage/phage + phage = new(M.loc) + M.apply_damage(rand(1, 7)) + phage.viruses = A.Copy() + phage.health += A.totalResistance() + phage.maxHealth += A.totalResistance() + phage.infections += A + phage.base_disease = A + + if(A.spread_flags & CONTACT_GENERAL) + for(var/datum/disease/D in M.GetViruses()) + if((D.spread_flags & SPECIAL) || (D.spread_flags & NON_CONTAGIOUS)) + continue + if(D == A) + continue + phage.viruses += D + + M.visible_message(span_danger("A strange crearure bursts out of [M]!"), span_userdanger("A slimy creature bursts forth from your flesh!")) + addtimer(CALLBACK(phage, TYPE_PROC_REF(/mob/living/simple_mob/vore/aggressive/macrophage, dust)), 3000) diff --git a/code/datums/diseases/advance/symptoms/mlem.dm b/code/datums/diseases/advance/symptoms/mlem.dm new file mode 100644 index 00000000000..fdb8672c276 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/mlem.dm @@ -0,0 +1,33 @@ +/* +////////////////////////////////////// + +Mlemingtong + + Not noticable or unnoticable. + Resistant. + Increases stage speed. + Little transmittable. + Low Level. + +BONUS + Mlem. Mlem. Mlem. + Should be used for buffing your disease. + +////////////////////////////////////// +*/ + +/datum/symptom/mlem + name = "Mlemington" + stealth = 0 + resistance = 3 + stage_speed = 3 + transmittable = 1 + level = 1 + severity = 1 + +/datum/symptom/itching/Activate(var/datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + M.emote("mlem") + return diff --git a/code/datums/diseases/advance/symptoms/necrotic_agent.dm b/code/datums/diseases/advance/symptoms/necrotic_agent.dm new file mode 100644 index 00000000000..24a3e9ff065 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/necrotic_agent.dm @@ -0,0 +1,31 @@ +/* +////////////////////////////////////// + +Necrotic Agent + + Very Noticable. + Lowers resistance resistance considerably. + Decreases stage speed. + Reduced transmittable. + Critical Level. + +Bonus + Makes the disease work on corpses + +////////////////////////////////////// +*/ + +/datum/symptom/necrotic_agent + name = "Necrotic Agent" + stealth = -2 + resistance = -3 + stage_speed = -3 + transmittable = 0 + level = 6 + severity = 3 + +/datum/symptom/necrotic_agent/Start(datum/disease/advance/A) + A.allow_dead = TRUE + +/datum/symptom/necrotic_agent/End(datum/disease/advance/A) + A.allow_dead = FALSE diff --git a/code/datums/diseases/advance/symptoms/oxygen.dm b/code/datums/diseases/advance/symptoms/oxygen.dm new file mode 100644 index 00000000000..3f9fbd8eee5 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/oxygen.dm @@ -0,0 +1,37 @@ +/* +////////////////////////////////////// + +Self-Respiration + + Slightly hidden. + Lowers resistance significantly. + Decreases stage speed significantly. + Decreases transmittablity tremendously. + Fatal Level. + +Bonus + The body generates dexalin. + +////////////////////////////////////// +*/ + +/datum/symptom/oxygen + name = "Self-Respiration" + stealth = 1 + resistance = -3 + stage_speed = -3 + transmittable = -4 + level = 6 + +/datum/symptom/oxygen/Activate(var/datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB * 5)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(4, 5) + if(M.reagents.get_reagent_amount("dexalin") < 10) + M.reagents.add_reagent("dexalin", 10) + else + if(prob(SYMPTOM_ACTIVATION_PROB * 5)) + to_chat(M, span_notice(pick("Your lungs feel great.", "You realize you haven't been breathing.", "You don't feel the need to breathe."))) + return diff --git a/code/datums/diseases/advance/symptoms/sensory.dm b/code/datums/diseases/advance/symptoms/sensory.dm new file mode 100644 index 00000000000..6f1f3ac9d36 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/sensory.dm @@ -0,0 +1,63 @@ +/* +////////////////////////////////////// +Sensory-Restoration + Very very very very noticable. + Lowers resistance tremendously. + Decreases stage speed tremendously. + Decreases transmittablity tremendously. + Fatal. +Bonus + The body generates Sensory restorational chemicals. + imidazoline for eyes + removes alcohol + removes hallucinogens + alkysine to kickstart the mind + +////////////////////////////////////// +*/ +/datum/symptom/mind_restoration + name = "Mind Restoration" + stealth = -3 + resistance = -4 + stage_speed = -4 + transmittable = -3 + level = 5 + severity = 0 + +/datum/symptom/mind_restoration/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB * 3)) + var/mob/living/M = A.affected_mob + + if(A.stage >= 3) + M.slurring = min(0, M.slurring-4) + M.druggy = min(0, M.druggy-4) + M.reagents.remove_reagent("ethanol", 3) + if(A.stage >= 4) + M.drowsyness = min(0, M.drowsyness-4) + if(M.reagents.has_reagent("bliss")) + M.reagents.del_reagent("bliss") + M.hallucination = min(0, M.hallucination-4) + if(A.stage >= 5) + if(M.reagents.get_reagent_amount("alkysine") < 10) + M.reagents.add_reagent("alkysine", 5) + +/datum/symptom/sensory_restoration + name = "Sensory Restoration" + stealth = -1 + resistance = -3 + stage_speed = -2 + transmittable = -4 + level = 4 + +/datum/symptom/sensory_restoration/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB * 5)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(4, 5) + if(M.reagents.get_reagent_amount("imidazoline") < 10) + M.reagents.add_reagent("imidazoline", 5) + else + if(prob(SYMPTOM_ACTIVATION_PROB)) + to_chat(M, span_notice(pick("Your eyes feel great.","You feel like your eyes can focus more clearly.", "You don't feel the need to blink."))) diff --git a/code/datums/diseases/advance/symptoms/shivering.dm b/code/datums/diseases/advance/symptoms/shivering.dm new file mode 100644 index 00000000000..375850ef40f --- /dev/null +++ b/code/datums/diseases/advance/symptoms/shivering.dm @@ -0,0 +1,39 @@ +/* +////////////////////////////////////// + +Shivering + + No change to hidden. + Increases resistance. + Increases stage speed. + Little transmittable. + Low level. + +Bonus + Cools down your body. + +////////////////////////////////////// +*/ + +/datum/symptom/shivering + name = "Shivering" + stealth = 0 + resistance = 2 + stage_speed = 2 + transmittable = 2 + level = 2 + severity = 2 + +/datum/symptom/shivering/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/carbon/M = A.affected_mob + to_chat(M, span_warning(pick("You feel cold.", "You start shivering."))) + if(M.bodytemperature > BODYTEMP_COLD_DAMAGE_LIMIT) + Chill(M, A) + return + +/datum/symptom/shivering/proc/Chill(mob/living/M, datum/disease/advance/A) + var/get_cold = (sqrt(16+A.totalStealth()*2))+(sqrt(21+A.totalResistance()*2)) + M.bodytemperature = max(M.bodytemperature - (get_cold * A.stage), BODYTEMP_COLD_DAMAGE_LIMIT + 1) + return 1 diff --git a/code/datums/diseases/advance/symptoms/sneeze.dm b/code/datums/diseases/advance/symptoms/sneeze.dm new file mode 100644 index 00000000000..d60baaa11a2 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/sneeze.dm @@ -0,0 +1,42 @@ +/* +////////////////////////////////////// + +Sneezing + + Very Noticable. + Increases resistance. + Doesn't increase stage speed. + Very transmittable. + Low Level. + +Bonus + Forces a spread type of AIRBORNE + with extra range! + +////////////////////////////////////// +*/ + +/datum/symptom/sneeze + name = "Sneezing" + stealth = -2 + resistance = 3 + stage_speed = 0 + transmittable = 4 + level = 1 + severity = 1 + +/datum/symptom/sneeze/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(1, 2, 3) + M.emote("sniff") + else + M.emote("sneeze") + A.spread(5) + if(prob(30)) + var/obj/effect/decal/cleanable/mucus/icky = new(get_turf(M)) + icky.viruses |= A.Copy() + + return diff --git a/code/datums/diseases/advance/symptoms/spin.dm b/code/datums/diseases/advance/symptoms/spin.dm new file mode 100644 index 00000000000..995be34071b --- /dev/null +++ b/code/datums/diseases/advance/symptoms/spin.dm @@ -0,0 +1,40 @@ +/* +////////////////////////////////////// + +Spyndrome + + Slightly hidden. + No change to resistance. + Increases stage speed. + Little transmittable. + Low Level. + +BONUS + Makes the host spin. + Should be used for buffing your disease. + +////////////////////////////////////// +*/ + +/datum/symptom/mlem + name = "Spyndrome" + stealth = 2 + resistance = 0 + stage_speed = 3 + transmittable = 1 + level = 1 + severity = 1 + var/list/directions = list(2,4,1,8,2,4,1,8,2,4,1,8,2,4,1,8,2,4,1,8) + +/datum/symptom/mlem/Activate(var/datum/disease/advance/A) + ..() + + if(prob(SYMPTOM_ACTIVATION_PROB)) + if(A.affected_mob.buckled()) + to_chat(viewers(A.affected_mob), span_warning("[A.affected_mob.name] struggles violently against their restraints!")) + else + to_chat(viewers(A.affected_mob), span_warning("[A.affected_mob.name] spins around violently!")) + for(var/D in directions) + A.affected_mob.dir = D + A.affected_mob.dir = pick(2,4,1,8) + return diff --git a/code/datums/diseases/advance/symptoms/symptoms.dm b/code/datums/diseases/advance/symptoms/symptoms.dm new file mode 100644 index 00000000000..90b39fab3bd --- /dev/null +++ b/code/datums/diseases/advance/symptoms/symptoms.dm @@ -0,0 +1,36 @@ +// Symptoms are the effects that engineered advanced diseases do. + +GLOBAL_LIST_INIT(list_symptoms, subtypesof(/datum/symptom)) + +/datum/symptom + // Buffs/Debuffs the symptom has to the overall engineered disease. + var/name = "" + var/stealth = 0 + var/resistance = 0 + var/stage_speed = 0 + var/transmittable = 0 + // The type level of the symptom. Higher is harder to generate. + var/level = 0 + // The severity level of the symptom. Higher is more dangerous. + var/severity = 0 + // The hash tag for our diseases, we will add it up with our other symptoms to get a unique id! ID MUST BE UNIQUE!!! + var/id = "" + +/datum/symptom/New() + var/list/S = GLOB.list_symptoms + for(var/i = 1; i <= length(S); i++) + if(type == S[i]) + id = "[i]" + return + CRASH("We couldn't assign an ID!") + +// Called when processing of the advance disease, which holds this symptom, starts. +/datum/symptom/proc/Start(datum/disease/advance/A) + return + +// Called when the advance disease is going to be deleted or when the advance disease stops processing. +/datum/symptom/proc/End(datum/disease/advance/A) + return + +/datum/symptom/proc/Activate(datum/disease/advance/A) + return diff --git a/code/datums/diseases/advance/symptoms/synthetic_infection.dm b/code/datums/diseases/advance/symptoms/synthetic_infection.dm new file mode 100644 index 00000000000..cb17d88c812 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/synthetic_infection.dm @@ -0,0 +1,32 @@ +/* +////////////////////////////////////// + +Sneezing + + Slightly hidden. + Increases resistance. + Doesn't increase stage speed. + Slightly transmittable. + High Level. + +Bonus + Allows the disease to infect synthetics + +////////////////////////////////////// +*/ + +/datum/symptom/infect_synthetics + name = "Synthetic Infection" + stealth = 1 + resistance = 2 + stage_speed = 0 + transmittable = 1 + level = 5 + severity = 3 + id = "synthetic_infection" + +/datum/symptom/infect_synthetics/Start(datum/disease/advance/A) + A.infect_synthetics = TRUE + +/datum/symptom/infect_synthetics/End(datum/disease/advance/A) + A.infect_synthetics = FALSE diff --git a/code/datums/diseases/advance/symptoms/telepathy.dm b/code/datums/diseases/advance/symptoms/telepathy.dm new file mode 100644 index 00000000000..3e02ec94d83 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/telepathy.dm @@ -0,0 +1,36 @@ +/* +////////////////////////////////////// + +Telepathy + + Hidden. + Decreases resistance. + Decreases stage speed significantly. + Decreases transmittablity tremendously. + Critical Level. + +Bonus + The user gains telepathy. + +////////////////////////////////////// +*/ + +/datum/symptom/telepathy + name = "Pineal Gland Decalcification" + stealth = 2 + resistance = -2 + stage_speed = -3 + transmittable = -4 + level = 5 + +/datum/symptom/telepathy/Start(datum/disease/advance/A) + var/mob/living/carbon/human/H = A.affected_mob + H.dna.SetSEState(REMOTETALKBLOCK, 1) + domutcheck(H, null, TRUE) + to_chat(H, span_notice("Your mind expands...")) + +/datum/symptom/telepathy/End(datum/disease/advance/A) + var/mob/living/carbon/human/H = A.affected_mob + H.dna.SetSEState(REMOTETALKBLOCK, 0) + domutcheck(H, null, TRUE) + to_chat(H, span_notice("Everything feels... Normal.")) diff --git a/code/datums/diseases/advance/symptoms/viral.dm b/code/datums/diseases/advance/symptoms/viral.dm new file mode 100644 index 00000000000..3da1de698ca --- /dev/null +++ b/code/datums/diseases/advance/symptoms/viral.dm @@ -0,0 +1,65 @@ +/* +////////////////////////////////////// +Viral adaptation + + Moderate stealth boost. + Major Increases to resistance. + Reduces stage speed. + No change to transmission + Critical Level. + +BONUS + Extremely useful for buffing viruses + +////////////////////////////////////// +*/ +/datum/symptom/viraladaptation + name = "Viral self-adaptation" + stealth = 3 + resistance = 5 + stage_speed = -3 + transmittable = 0 + level = 3 + +/datum/symptom/viraladaptation/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(1) + to_chat(M, span_notice("You feel off, but no different from before.")) + if(5) + to_chat(M, span_notice("You feel better, but nothing interesting happens.")) + +/* +////////////////////////////////////// +Viral evolution + + Moderate stealth reductopn. + Major decreases to resistance. + increases stage speed. + increase to transmission + Critical Level. + +BONUS + Extremely useful for buffing viruses + +////////////////////////////////////// +*/ +/datum/symptom/viralevolution + name = "Viral evolutionary acceleration" + stealth = -2 + resistance = -3 + stage_speed = 5 + transmittable = 3 + level = 3 + +/datum/symptom/viralevolution/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(1) + to_chat(M, span_notice("You feel better, but no different from before.")) + if(5) + to_chat(M,span_notice("You feel off, but nothing interesting happens.")) diff --git a/code/datums/diseases/advance/symptoms/vision.dm b/code/datums/diseases/advance/symptoms/vision.dm new file mode 100644 index 00000000000..d74b0c6a5dc --- /dev/null +++ b/code/datums/diseases/advance/symptoms/vision.dm @@ -0,0 +1,50 @@ +/* +////////////////////////////////////// + +Hyphema (Eye bleeding) + + Slightly noticable. + Lowers resistance tremendously. + Decreases stage speed tremendously. + Decreases transmittablity. + Critical Level. + +Bonus + Causes blindness. + +////////////////////////////////////// +*/ + +/datum/symptom/visionloss + name = "Hyphema" + stealth = -1 + resistance = -4 + stage_speed = -4 + transmittable = -3 + level = 5 + severity = 4 + +/datum/symptom/visionloss/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/carbon/M = A.affected_mob + var/obj/item/organ/internal/eyes/eyes = M.internal_organs_by_name[O_EYES] + if(!eyes) + return + switch(A.stage) + if(1, 2) + to_chat(M, span_warning("Your eyes itch.")) + if(3, 4) + to_chat(M, span_boldwarning("Your eyes burn!")) + M.eye_blurry = 20 + eyes.take_damage(1) + else + to_chat(M, span_userdanger("Your eyes burn horrificly!")) + M.eye_blurry = 40 + eyes.take_damage(5) + if(eyes.damage >= 10) + M.disabilities |= NEARSIGHTED + if(prob(eyes.damage - 10 + 1)) + if(!M.eye_blind) + to_chat(M, span_userdanger("You go blind!")) + M.Blind(20) diff --git a/code/datums/diseases/advance/symptoms/vomit.dm b/code/datums/diseases/advance/symptoms/vomit.dm new file mode 100644 index 00000000000..06c2b0fafbf --- /dev/null +++ b/code/datums/diseases/advance/symptoms/vomit.dm @@ -0,0 +1,34 @@ +/* +////////////////////////////////////// + +Vomiting + + Noticeable. + No change to resistance. + Slightly increases stage speed. + Increases transmissibility. + Medium Level. + +Bonus + Forces the affected mob to vomit + +////////////////////////////////////// +*/ + +/datum/symptom/vomit + name = "Vomiting" + stealth = -2 + resistance = 0 + stage_speed = 1 + transmittable = 2 + level = 3 + severity = 1 + +/datum/symptom/vomit/Activate(datum/disease/advance/A) + if(!..()) + return + var/mob/living/M = A.affected_mob + if(prob(2)) + to_chat(M, span_warning(pick("you feel nauseated.", "You feel like you're going to throw up!"))) + if(prob(SYMPTOM_ACTIVATION_PROB)) + M.vomit() diff --git a/code/datums/diseases/advance/symptoms/weakness.dm b/code/datums/diseases/advance/symptoms/weakness.dm new file mode 100644 index 00000000000..917be5a46ce --- /dev/null +++ b/code/datums/diseases/advance/symptoms/weakness.dm @@ -0,0 +1,43 @@ +/* +////////////////////////////////////// + +Weakness + + Slightly noticeable. + Lowers resistance slightly. + Decreases stage speed moderately. + Decreases transmittablity moderately. + Moderate Level. + +Bonus + Weakens the host + +////////////////////////////////////// +*/ + +/datum/symptom/weakness + name = "Weakness" + stealth = -1 + resistance = -1 + stage_speed = -2 + transmittable = -2 + level = 3 + severity = 3 + +/datum/symptom/weakness/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(1, 2) + to_chat(M, span_warning(pick("You feel weak.", "You feel lazy."))) + if(3, 4) + to_chat(M, span_boldwarning(pick("You feel very frail.", "You think you might faint."))) + M.Weaken(10) + else + to_chat(M, span_userdanger(pick("You feel tremendously weak!", "Your body trembles as exhaustion creeps over you."))) + M.Weaken(20) + if(M.weakened > 60 && !M.stat) + M.visible_message(span_warning("[M] faints!"), span_userdanger("You swoon and faint...")) + M.AdjustSleeping(10) + return diff --git a/code/datums/diseases/advance/symptoms/weigh.dm b/code/datums/diseases/advance/symptoms/weigh.dm new file mode 100644 index 00000000000..ceca8a77f59 --- /dev/null +++ b/code/datums/diseases/advance/symptoms/weigh.dm @@ -0,0 +1,37 @@ +/* +////////////////////////////////////// + +Weight Loss + + Very Very Noticable. + Decreases resistance. + Decreases stage speed. + Reduced Transmittable. + High level. + +Bonus + Decreases the weight of the mob, + forcing it to be skinny. + +////////////////////////////////////// +*/ + +/datum/symptom/weight_loss + name = "Weight Loss" + stealth = -3 + resistance = -2 + stage_speed = -2 + transmittable = -2 + level = 3 + severity = 1 + +/datum/symptom/weight_loss/Activate(datum/disease/advance/A) + ..() + if(prob(SYMPTOM_ACTIVATION_PROB)) + var/mob/living/M = A.affected_mob + switch(A.stage) + if(1, 2, 3, 4) + to_chat(M, span_warning(pick("You feel hungry.", "You crave for food."))) + else + to_chat(M, span_warning(pick("So hungry...", "You'd kill someone for a bite of food...", "Hunger cramps seize you..."))) + M.adjust_nutrition(-20) diff --git a/code/datums/diseases/anxiety.dm b/code/datums/diseases/anxiety.dm new file mode 100644 index 00000000000..78b630bc152 --- /dev/null +++ b/code/datums/diseases/anxiety.dm @@ -0,0 +1,53 @@ +/datum/disease/anxiety + name = "Severe Anxiety" + form = "Infection" + max_stages = 4 + spread_text = "On contact" + spread_flags = CONTACT_GENERAL + cure_text = "Ethanol" + cures = list("ethanol") + agent = "Excess Lepdopticides" + viable_mobtypes = list(/mob/living/carbon/human, /mob/living/carbon/human/monkey) + desc = "If left untreated subject will regurgitate butterflies." + severity = MINOR + +/datum/disease/anxiety/stage_act() + if(!..()) + return FALSE + switch(stage) + if(2) + if(prob(15)) + to_chat(affected_mob, span_notice("You feel anxious.")) + if(3) + if(prob(10)) + to_chat(affected_mob, span_notice("Your stomach flutters.")) + if(prob(5)) + to_chat(affected_mob, span_notice("You feel panicky.")) + if(prob(2)) + to_chat(affected_mob, span_danger("You're overtaken with panic!")) + affected_mob.AdjustConfused(rand(4, 6)) + if(4) + if(prob(10)) + to_chat(affected_mob, span_danger("You feel butterflies in your stomach.")) + if(prob(5)) + affected_mob.visible_message( + span_danger("[affected_mob] stumbles around in a panic"), + span_userdanger("You have a panic attack!") + ) + affected_mob.AdjustConfused(rand(12, 16)) + affected_mob.jitteriness = rand(12, 16) + if(prob(2)) + affected_mob.visible_message( + span_danger("[affected_mob] coughs up butterflies!"), + span_userdanger("You cough up butterflies!") + ) + affected_mob.emote("cough") + for(var/i in 1 to 2) + var/mob/living/simple_mob/animal/sif/glitterfly/B = new(affected_mob.loc) + addtimer(CALLBACK(B, TYPE_PROC_REF(/mob/living/simple_mob/animal/sif/glitterfly, decompose)), rand(5, 25) SECONDS) + +/mob/living/simple_mob/animal/sif/glitterfly/proc/decompose() + visible_message( + span_notice("[src] decomposes due to being outside of its original habitat for too long!"), + span_userdanger("You decompose for being too long out of your habitat!")) + dust() diff --git a/code/datums/diseases/beesease.dm b/code/datums/diseases/beesease.dm new file mode 100644 index 00000000000..a867c8d9d97 --- /dev/null +++ b/code/datums/diseases/beesease.dm @@ -0,0 +1,36 @@ +/datum/disease/beesease + name = "Beesease" + form = "Infection" + max_stages = 4 + spread_text = "On contact" + spread_flags = CONTACT_GENERAL + cure_text = "Sugar" + cures = list("sugar") + agent = "Apidae Infection" + viable_mobtypes = list(/mob/living/carbon/human, /mob/living/carbon/human/monkey) + desc = "If left untreated, subject will regurgitate bees." + severity = BIOHAZARD + +/datum/disease/beesease/stage_act() + if(!..()) + return FALSE + switch(stage) + if(2) + if(prob(2)) + to_chat(affected_mob, span_notice("You tastey hone in your mouth.")) + if(3) + if(prob(10)) + to_chat(affected_mob, span_notice("Your stomach rumbles")) + if(prob(2)) + to_chat(affected_mob, span_notice("Your stomach stings painfully.")) + if(prob(20)) + affected_mob.adjustToxLoss(2) + if(4) + if(prob(10)) + affected_mob.visible_message(span_danger("[affected_mob] buzzles loudly"), span_userdanger("Your stomach buzzles violently!")) + if(prob(5)) + to_chat(affected_mob, span_danger("You feel something moving in your throat.")) + if(prob(1)) + affected_mob.visible_message(span_danger("[affected_mob] coughs up a swarm of bees!"), span_userdanger("You cough up a swarm of bees!")) + new /mob/living/simple_mob/vore/bee(affected_mob.loc) + return diff --git a/code/datums/diseases/brainrot.dm b/code/datums/diseases/brainrot.dm new file mode 100644 index 00000000000..57899ef2014 --- /dev/null +++ b/code/datums/diseases/brainrot.dm @@ -0,0 +1,43 @@ +/datum/disease/brainrot + name = "Brainrot" + max_stages = 4 + spread_text = "On contact" + spread_flags = CONTACT_GENERAL + cure_text = "Alkysine" + cures = list("alkysine") + agent = "Cryptococcus Cosmosis" + viable_mobtypes = list(/mob/living/carbon/human) + cure_chance = 15 + desc = "This disease destroys the braincells, causing brain fever, brain necrosis and general intoxication." + required_organs = list(/obj/item/organ/internal/brain) + severity = HARMFUL + +/datum/disease/brainrot/stage_act() + if(!..()) + return FALSE + switch(stage) + if(2) + if(prob(2)) + affected_mob.say("*blink") + if(prob(2)) + affected_mob.say("*yawn") + if(prob(2)) + to_chat(affected_mob, span_danger("You don't feel like yourself.")) + if(prob(5)) + affected_mob.adjustBrainLoss(1) + if(3) + if(prob(2)) + affected_mob.say("*stare") + if(prob(3)) + affected_mob.say("*drool") + if(prob(10) && affected_mob.getBrainLoss() < 100) + affected_mob.adjustBrainLoss(3) + if(prob(2)) + to_chat(affected_mob, span_danger("Strange buzzing fills your head, removing all thoughts.")) + if(prob(3)) + to_chat(affected_mob, span_danger("You lose consciousness...")) + affected_mob.Sleeping(rand(5, 10)) + if(prob(1)) + affected_mob.emote("snore") + if(prob(15)) + affected_mob.apply_effect(5, STUTTER) diff --git a/code/datums/diseases/choreomania.dm b/code/datums/diseases/choreomania.dm new file mode 100644 index 00000000000..9fd41c4cd6f --- /dev/null +++ b/code/datums/diseases/choreomania.dm @@ -0,0 +1,38 @@ +/datum/disease/choreomania + name = "Choreomania" + max_stages = 3 + spread_text = "Airborne" + cure_text = "Adranol" + cures = list("adranol") + cure_chance = 10 + agent = "TAP-DAnC3" + viable_mobtypes = list(/mob/living/carbon/human) + permeability_mod = 0.75 + desc = "If left untreated the subject... Won't stop dancing!" + severity = MINOR + + var/list/dance = list(2,4,8,2,4,8,2,4,8,2,4,8,1,4,1,4,1,4,2,4,8,2) + +/datum/disease/choreomania/stage_act() + if(!..()) + return FALSE + switch(stage) + if(2) + if(prob(1)) + to_chat(affected_mob, span_notice("You feel like dancing like a maniac, maniac...")) + if(prob(1)) + affected_mob.emote("whistle") + if(3) + if(prob(1)) + to_chat(affected_mob, span_notice("You feel like dancing like a maniac, maniac...")) + if(prob(1)) + to_chat(affected_mob, span_notice("You really want to start a conga line!")) + if(prob(2)) + for(var/D in dance) + affected_mob.dir = D + animate(affected_mob, pixel_x = 5, time = 5) + sleep(3) + animate(affected_mob, pixel_x = -5, time = 5) + animate(pixel_x = affected_mob.default_pixel_x, pixel_y = affected_mob.default_pixel_x, time = 2) + sleep(3) + return diff --git a/code/datums/diseases/cold.dm b/code/datums/diseases/cold.dm new file mode 100644 index 00000000000..c6b6cf0f17e --- /dev/null +++ b/code/datums/diseases/cold.dm @@ -0,0 +1,64 @@ +/datum/disease/cold + name = "The Cold" + max_stages = 3 + spread_text = "Airborne" + spread_flags = AIRBORNE + cure_text = "Rest & Spaceacilin" + cures = list("spaceacilin") + agent = "XY-rhinovirus" + viable_mobtypes = list(/mob/living/carbon/human, /mob/living/carbon/human/monkey) + permeability_mod = 0.5 + desc = "If left untreated the subject will contract the flu." + severity = MINOR + +/datum/disease/cold/stage_act() + if(!..()) + return FALSE + switch(stage) + if(2) + if(affected_mob.stat == UNCONSCIOUS && prob(40)) + to_chat(affected_mob, span_notice("You feel better.")) + cure() + return + if(affected_mob.lying && prob(10)) + to_chat(affected_mob, span_notice("You feel better.")) + cure() + return + if(prob(1) && prob(5)) + to_chat(affected_mob, span_notice("You feel better.")) + cure() + return + if(prob(1)) + affected_mob.emote("sneeze") + if(prob(1)) + affected_mob.emote("cough") + if(prob(1)) + to_chat(affected_mob, span_notice("Your throat feels sore.")) + if(prob(1)) + to_chat(affected_mob, span_notice("Mucous runs down the back of your throat.")) + if(3) + if(affected_mob.stat == UNCONSCIOUS && prob(25)) + to_chat(affected_mob, span_notice("You feel better.")) + cure() + return + if(affected_mob.lying && prob(5)) + to_chat(affected_mob, span_notice("You feel better.")) + cure() + return + if(prob(1) && prob(1)) + to_chat(affected_mob, span_notice("You feel better.")) + cure() + return + if(prob(1)) + affected_mob.emote("sneeze") + if(prob(1)) + affected_mob.emote("cough") + if(prob(1)) + to_chat(affected_mob, span_notice("Your throat feels sore.")) + if(prob(1)) + to_chat(affected_mob, span_notice("Mucous runs down the back of your throat.")) + if(prob(1) && prob(50)) + if(!affected_mob.resistances.Find(/datum/disease/flu)) + var/datum/disease/Flu = new /datum/disease/flu(0) + affected_mob.ContractDisease(Flu) + cure() diff --git a/code/datums/diseases/cold9.dm b/code/datums/diseases/cold9.dm new file mode 100644 index 00000000000..a0fa6919764 --- /dev/null +++ b/code/datums/diseases/cold9.dm @@ -0,0 +1,30 @@ +/datum/disease/cold9 + name = "The Cold" + medical_name = "ICE9 Cold" + max_stages = 3 + spread_text = "On contact" + spread_flags = CONTACT_GENERAL + cure_text = "Spaceacillin" + cures = list("spaceacillin") + agent = "ICE9-rhinovirus" + viable_mobtypes = list(/mob/living/carbon/human) + desc = "If left untreated the subject will slow, as if partly frozen." + severity = HARMFUL + +/datum/disease/cold9/stage_act() + if(!..()) + return FALSE + if(stage < 2) + return + + var/stage_factor = stage - 1 + affected_mob.bodytemperature -= 7.5 * stage_factor + if(prob(2 * stage_factor)) + affected_mob.say("*sneeze") + if(prob(2 * stage_factor)) + affected_mob.say("*cough") + if(prob(3 * stage_factor)) + to_chat(affected_mob, span_danger("Your throat feels sore.")) + if(prob(5 * stage_factor)) + to_chat(affected_mob, span_danger("You feel stiff.")) + affected_mob.adjustFireLoss(1) diff --git a/code/datums/diseases/darkness.dm b/code/datums/diseases/darkness.dm new file mode 100644 index 00000000000..b340ca5d45d --- /dev/null +++ b/code/datums/diseases/darkness.dm @@ -0,0 +1,10 @@ +/datum/disease/darkness + name = "Dark Exposure" + form = "Bluespace Micro-fissures" + max_stages = 4 + spread = NON_CONTAGIOUS + cure_text = "Exposure to light and the real world" + agent = "Bluespace Exposure" + viable_mobtypes = list(/mob/living/carbon/human) + desc = "If left untreated, subject will lose grip on reality." + severity = HARMFUL diff --git a/code/datums/diseases/flu.dm b/code/datums/diseases/flu.dm new file mode 100644 index 00000000000..6a30af6f859 --- /dev/null +++ b/code/datums/diseases/flu.dm @@ -0,0 +1,50 @@ +/datum/disease/flu + name = "The Flu" + max_stages = 3 + spread_text = "Airborne" + cure_text = "Spaceacilin" + cures = list("spaceacilin") + cure_chance = 10 + agent = "H13N1 flu virion" + viable_mobtypes = list(/mob/living/carbon/human, /mob/living/carbon/human/monkey) + permeability_mod = 0.75 + desc = "If left untreated the subject will feel quite unwell." + severity = MINOR + +/datum/disease/flu/stage_act() + if(!..()) + return FALSE + switch(stage) + if(2) + if(affected_mob.lying && prob(20)) + to_chat(affected_mob, span_notice("You feel better.")) + stage-- + return + if(prob(1)) + affected_mob.emote("sneeze") + if(prob(1)) + affected_mob.emote("cough") + if(prob(1)) + to_chat(affected_mob, span_danger("Your muscles ache.")) + if(prob(20)) + affected_mob.apply_damage(1) + if(prob(1)) + to_chat(affected_mob, span_danger("Your stomach hurts.")) + affected_mob.adjustToxLoss(1) + if(3) + if(affected_mob.lying && prob(15)) + to_chat(affected_mob, span_notice("You feel better.")) + stage-- + return + if(prob(1)) + affected_mob.emote("sneeze") + if(prob(1)) + affected_mob.emote("cough") + if(prob(1)) + to_chat(affected_mob, span_danger("Your muscles ache.")) + if(prob(20)) + affected_mob.apply_damage(1) + if(prob(1)) + to_chat(affected_mob, span_danger("Your stomach hurts.")) + affected_mob.adjustToxLoss(1) + return diff --git a/code/datums/diseases/food_poisoning.dm b/code/datums/diseases/food_poisoning.dm new file mode 100644 index 00000000000..cbb7a0c8046 --- /dev/null +++ b/code/datums/diseases/food_poisoning.dm @@ -0,0 +1,67 @@ +/datum/disease/food_poisoning + name = "Food Poisoning" + max_stages = 3 + stage_prob = 5 + spread_text = "Non-Contagious" + spread_flags = NON_CONTAGIOUS + cure_text = "Sleep" + agent = "Salmonella" + cures = list("chicken_soup") + cure_chance = 10 + viable_mobtypes = list(/mob/living/carbon/human) + desc = "Nausea, sickness, and vomitting." + severity = MINOR + disease_flags = CURABLE + virus_heal_resistant = TRUE + +/datum/disease/food_poisoning/stage_act() + if(!..()) + return FALSE + if(affected_mob.stat == UNCONSCIOUS && prob(33)) + to_chat(affected_mob, span_notice("You feel better.")) + cure() + return + switch(stage) + if(1) + if(prob(5)) + to_chat(affected_mob, span_danger("Your stomach feels weird.")) + if(prob(5)) + to_chat(affected_mob, span_danger("You feel queasy.")) + if(2) + if(affected_mob.stat == UNCONSCIOUS && prob(40)) + to_chat(affected_mob, span_notice("You feel better.")) + cure() + return + if(prob(1) && prob(10)) + to_chat(affected_mob, span_notice("You feel better.")) + if(prob(10)) + affected_mob.emote("groan") + if(prob(5)) + to_chat(affected_mob, span_danger("Your stomach aches.")) + if(prob(5)) + to_chat(affected_mob, span_danger("You feel nauseous")) + if(3) + if(affected_mob.stat == UNCONSCIOUS && prob(25)) + to_chat(affected_mob, span_notice("You feel better.")) + cure() + return + if(prob(1) && prob(10)) + to_chat(affected_mob, span_notice("You feel better.")) + cure() + return + if(prob(10)) + affected_mob.emote("moan") + if(prob(10)) + affected_mob.emote("groan") + if(prob(1)) + to_chat(affected_mob, span_danger("Your stomach hurts.")) + if(prob(1)) + to_chat(affected_mob, span_danger("You feel sick.")) + if(prob(5)) + if(affected_mob.nutrition > 10) + affected_mob.emote("vomit") + else + to_chat(affected_mob, span_danger("Your stomach lurches painfully")) + affected_mob.visible_message(span_danger("[affected_mob] gags and retches!")) + affected_mob.Stun(rand(4, 8)) + affected_mob.Weaken(rand(4, 8)) diff --git a/code/datums/diseases/lycancoughy.dm b/code/datums/diseases/lycancoughy.dm new file mode 100644 index 00000000000..6d8f1061638 --- /dev/null +++ b/code/datums/diseases/lycancoughy.dm @@ -0,0 +1,64 @@ +/datum/disease/lycan + name = "Lycancoughy" + form = "Infection" + max_stages = 4 + spread_text = "On contact" + spread_flags = CONTACT_GENERAL + cure_text = "Ethanol" + cures = list("ethanol") + agent = "Excess Snuggles" + viable_mobtypes = list(/mob/living/carbon/human, /mob/living/carbon/human/monkey) + desc = "If left untreated subject will regurgitate... puppies." + severity = HARMFUL + var/barklimit + var/list/puppy_types = list(/mob/living/simple_mob/animal/passive/dog/corgi/puppy) + var/list/plush_types = list(/obj/item/toy/plushie/orange_fox, /obj/item/toy/plushie/corgi, /obj/item/toy/plushie/robo_corgi, /obj/item/toy/plushie/pink_fox) + +/datum/disease/lycan/stage_act() + if(!..()) + return FALSE + + var/mob/living/carbon/human/H = affected_mob + + switch(stage) + if(2) + if(prob(2)) + H.emote("cough") + if(prob(3)) + to_chat(H, span_notice("You itch.")) + H.adjustBruteLoss(rand(4, 6)) + if(3) + var/obj/item/organ/external/stomach = H.organs_by_name[pick("torso", "groin")] + + if(prob(3)) + H.emote("cough") + stomach.take_damage(BRUTE, rand(0, 5)) + if(prob(3)) + to_chat(H, span_notice("You hear a faint barking.")) + stomach.take_damage(BRUTE, rand(4, 6)) + if(prob(2)) + to_chat(H, span_notice("You crave meat.")) + if(prob(3)) + to_chat(H, span_danger("Your stomach growls!")) + stomach.take_damage(BRUTE, rand(5, 10)) + if(4) + var/obj/item/organ/external/stomach = H.organs_by_name[pick("torso", "groin")] + + if(prob(5)) + H.emote("cough") + stomach.take_damage(BRUTE, rand(0, 5)) + if(prob(5)) + H.emote("awoo2") + H.Confuse(rand(12, 16)) + stomach.take_damage(rand(0, 5)) + if(prob(5)) + if(!barklimit) + to_chat(H, span_danger("Your stomach growls!")) + stomach.take_damage(BRUTE, rand(5, 10)) + else + var/atom/hairball = pick(prob(50) ? puppy_types : plush_types) + H.visible_message(span_danger("[H] coughs up \a [initial(hairball.name)]!"), span_userdanger("You cough up \a [initial(hairball.name)]?!")) + H.emote("cough") + new hairball(H.loc) + barklimit-- + stomach.take_damage(BRUTE, rand(10, 15)) diff --git a/code/datums/diseases/magnitis.dm b/code/datums/diseases/magnitis.dm new file mode 100644 index 00000000000..24b2261cdaa --- /dev/null +++ b/code/datums/diseases/magnitis.dm @@ -0,0 +1,63 @@ +/datum/disease/magnitis + name = "Magnitis" + max_stages = 4 + spread_text = "Airbone" + cure_text = "Iron" + cures = list("iron") + agent = "Fukkos Miracos" + viable_mobtypes = list(/mob/living/carbon/human) + permeability_mod = 0.75 + desc = "This disease disrupts the magnetic field of your body, making it act as if a powerful magnet. Injections of iron help stabilize the field." + severity = MINOR + +/datum/disease/magnitis/stage_act() + if(!..()) + return FALSE + switch(stage) + if(2) + if(prob(2)) + to_chat(affected_mob, span_danger("You feel a slight shock course through your body.")) + if(prob(2)) + for(var/obj/M in orange(2, affected_mob)) + if(!M.anchored && prob(5)) + INVOKE_ASYNC(M, TYPE_PROC_REF(/atom/movable, throw_at), affected_mob, rand(3, 10), rand(1, 3), src) + for(var/mob/living/silicon/S in orange(2, affected_mob)) + if(isAI(S)) continue + INVOKE_ASYNC(S, TYPE_PROC_REF(/atom/movable, throw_at), affected_mob, rand(3, 10), rand(1, 3), src) + if(3) + if(prob(2)) + to_chat(affected_mob, span_danger("You feel a strong shock course through your body.")) + if(prob(2)) + to_chat(affected_mob, span_danger("You feel like clowning aound.")) + if(prob(4)) + for(var/obj/M in orange(4, affected_mob)) + if(!M.anchored && prob(5)) + var/i + var/iter = rand(1,2) + for(i=0,i#[tm.number][details]" /client/verb/showrevinfo() - set category = "OOC" + set category = "OOC.Game" set name = "Show Server Revision" set desc = "Check the current server code revision" diff --git a/code/datums/managed_browsers/feedback_viewer.dm b/code/datums/managed_browsers/feedback_viewer.dm index 078e2ca8511..eca1fff099f 100644 --- a/code/datums/managed_browsers/feedback_viewer.dm +++ b/code/datums/managed_browsers/feedback_viewer.dm @@ -2,7 +2,7 @@ var/datum/managed_browser/feedback_viewer/feedback_viewer = null /datum/admins/proc/view_feedback() - set category = "Admin" + set category = "Admin.Misc" set name = "View Feedback" set desc = "Open the Feedback Viewer" diff --git a/code/datums/mind.dm b/code/datums/mind.dm index 43f41708764..17b39256456 100644 --- a/code/datums/mind.dm +++ b/code/datums/mind.dm @@ -105,6 +105,7 @@ if(new_character.client) new_character.client.init_verbs() // re-initialize character specific verbs + new_character.set_listed_turf(null) /datum/mind/proc/store_memory(new_text) memory += "[new_text]
" diff --git a/code/datums/mutable_appearance.dm b/code/datums/mutable_appearance.dm index 98ece935a6d..56faf42469f 100644 --- a/code/datums/mutable_appearance.dm +++ b/code/datums/mutable_appearance.dm @@ -4,7 +4,7 @@ // Mutable appearances are children of images, just so you know. -/image/mutable_appearance/New(copy_from, ...) +/mutable_appearance/New(copy_from, ...) ..() if(!copy_from) plane = FLOAT_PLANE // No clue why this is 0 by default yet images are on FLOAT_PLANE diff --git a/code/datums/supplypacks/contraband.dm b/code/datums/supplypacks/contraband.dm index bf763f33ec5..8bc4a190fae 100644 --- a/code/datums/supplypacks/contraband.dm +++ b/code/datums/supplypacks/contraband.dm @@ -97,7 +97,7 @@ /obj/item/clothing/glasses/thermal/syndi, /obj/item/ammo_magazine/m45/ap, /obj/item/material/knife/tacknife/combatknife, - /obj/item/multitool/hacktool + /obj/item/multitool/hacktool/modified ), list( //the professional, /obj/item/gun/projectile/silenced, diff --git a/code/datums/supplypacks/medical.dm b/code/datums/supplypacks/medical.dm index 5621c37d02b..0c099b32318 100644 --- a/code/datums/supplypacks/medical.dm +++ b/code/datums/supplypacks/medical.dm @@ -329,11 +329,11 @@ access = access_medical_equip /datum/supply_pack/med/virus - name = "Virus sample crate" - contains = list(/obj/item/virusdish/random = 4) + name = "Virus culture crate" + contains = list(/obj/item/reagent_containers/glass/bottle/culture/cold = 1, /obj/item/reagent_containers/glass/bottle/culture/flu = 1) cost = 25 containertype = /obj/structure/closet/crate/secure/zenghu - containername = "Virus sample crate" + containername = "Virus culture crate" access = access_cmo /datum/supply_pack/med/defib @@ -410,11 +410,11 @@ access = access_medical_equip /datum/supply_pack/med/virus - name = "Virus sample crate" - contains = list(/obj/item/virusdish/random = 4) + name = "Virus culture crate" + contains = list(/obj/item/reagent_containers/glass/bottle/culture/cold = 1, /obj/item/reagent_containers/glass/bottle/culture/flu = 1) cost = 25 containertype = /obj/structure/closet/crate/secure - containername = "Virus sample crate" + containername = "Virus culture crate" access = access_medical_equip diff --git a/code/game/antagonist/antagonist_factions.dm b/code/game/antagonist/antagonist_factions.dm index b16179f292e..b1ee3e16e5b 100644 --- a/code/game/antagonist/antagonist_factions.dm +++ b/code/game/antagonist/antagonist_factions.dm @@ -1,6 +1,6 @@ /mob/living/proc/convert_to_rev(mob/M as mob in oview(src)) set name = "Convert Bourgeoise" - set category = "Abilities" + set category = "Abilities.Antag" if(!M.mind) return convert_to_faction(M.mind, revs) @@ -44,7 +44,7 @@ /mob/living/proc/convert_to_loyalist(mob/M as mob in oview(src)) set name = "Convert Recidivist" - set category = "Abilities" + set category = "Abilities.Antag" if(!M.mind) return convert_to_faction(M.mind, loyalists) diff --git a/code/game/antagonist/antagonist_objectives.dm b/code/game/antagonist/antagonist_objectives.dm index b8a5af5adaa..f05219465a2 100644 --- a/code/game/antagonist/antagonist_objectives.dm +++ b/code/game/antagonist/antagonist_objectives.dm @@ -32,7 +32,7 @@ /mob/living/proc/write_ambition() set name = "Set Ambition" - set category = "IC" + set category = "IC.Antag" set src = usr if(!mind) diff --git a/code/game/antagonist/antagonist_panel.dm b/code/game/antagonist/antagonist_panel.dm index 0f42ad5893f..8fa2d060f03 100644 --- a/code/game/antagonist/antagonist_panel.dm +++ b/code/game/antagonist/antagonist_panel.dm @@ -17,7 +17,7 @@ /datum/antagonist/proc/get_extra_panel_options() return -/datum/antagonist/proc/get_check_antag_output(var/datum/admins/caller) +/datum/antagonist/proc/get_check_antag_output(var/datum/admins/requester) if(!current_antagonists || !current_antagonists.len) return "" @@ -31,7 +31,7 @@ if(!M.client) dat += " (logged out)" if(M.stat == DEAD) dat += " (DEAD)" dat += "" - dat += "\[PP]\[PM\]\[TP\]" + dat += "\[PP]\[PM\]\[TP\]" else dat += "[player.key] Mob not found!" dat += "" @@ -45,17 +45,17 @@ while(!istype(disk_loc, /turf)) if(istype(disk_loc, /mob)) var/mob/M = disk_loc - dat += "carried by [M.real_name] " + dat += "carried by [M.real_name] " if(istype(disk_loc, /obj)) var/obj/O = disk_loc dat += "in \a [O.name] " disk_loc = disk_loc.loc dat += "in [disk_loc.loc] at ([disk_loc.x], [disk_loc.y], [disk_loc.z])" dat += "" - dat += get_additional_check_antag_output(caller) + dat += get_additional_check_antag_output(requester) dat += "
" return dat //Overridden elsewhere. -/datum/antagonist/proc/get_additional_check_antag_output(var/datum/admins/caller) +/datum/antagonist/proc/get_additional_check_antag_output(var/datum/admins/requester) return "" diff --git a/code/game/atoms.dm b/code/game/atoms.dm index 9f00c1613af..e428aae3a7e 100644 --- a/code/game/atoms.dm +++ b/code/game/atoms.dm @@ -478,7 +478,9 @@ /atom/proc/add_vomit_floor(mob/living/carbon/M as mob, var/toxvomit = 0) if( istype(src, /turf/simulated) ) var/obj/effect/decal/cleanable/vomit/this = new /obj/effect/decal/cleanable/vomit(src) - this.virus2 = virus_copylist(M.virus2) + + for(var/datum/disease/D in M.GetViruses()) + this.viruses |= D.Copy() // Make toxins vomit look different if(toxvomit) diff --git a/code/game/gamemodes/cult/ritual.dm b/code/game/gamemodes/cult/ritual.dm index 597813550b2..6883220bac6 100644 --- a/code/game/gamemodes/cult/ritual.dm +++ b/code/game/gamemodes/cult/ritual.dm @@ -6,7 +6,7 @@ var/global/list/engwords = list("travel", "blood", "join", "hell", "destroy", "t var/global/list/rnwords = list("ire","ego","nahlizet","certum","veri","jatkaa","mgar","balaq", "karazet", "geeri") /client/proc/check_words() // -- Urist - set category = "Special Verbs" + set category = "Admin.Secrets" set name = "Check Rune Words" set desc = "Check the rune-word meaning" if(!cultwords["travel"]) diff --git a/code/game/gamemodes/events/holidays/Holidays.dm b/code/game/gamemodes/events/holidays/Holidays.dm index 7efae68f8d1..68b9a0cdf82 100644 --- a/code/game/gamemodes/events/holidays/Holidays.dm +++ b/code/game/gamemodes/events/holidays/Holidays.dm @@ -239,7 +239,7 @@ var/global/list/Holiday = list() //Holidays are lists now, so we can have more t //Allows GA and GM to set the Holiday variable /client/proc/Set_Holiday() set name = "Set Holiday" - set category = "Fun" + set category = "Fun.Event Kit" set desc = "Force-set the Holiday variable to make the game think it's a certain day." if(!check_rights(R_SERVER)) return diff --git a/code/game/gamemodes/game_mode.dm b/code/game/gamemodes/game_mode.dm index 63da8cc3343..51e3a508acf 100644 --- a/code/game/gamemodes/game_mode.dm +++ b/code/game/gamemodes/game_mode.dm @@ -546,7 +546,7 @@ var/global/list/additional_antag_types = list() /mob/verb/check_round_info() set name = "Check Round Info" - set category = "OOC" + set category = "OOC.Game" if(!ticker || !ticker.mode) to_chat(usr, span_warning("Something is terribly wrong; there is no gametype.")) diff --git a/code/game/jobs/job/engineering_vr.dm b/code/game/jobs/job/engineering_vr.dm index ed872fd85b8..17b70731dbd 100644 --- a/code/game/jobs/job/engineering_vr.dm +++ b/code/game/jobs/job/engineering_vr.dm @@ -30,7 +30,7 @@ /datum/job/engineer pto_type = PTO_ENGINEERING alt_titles = list(JOB_ALT_MAINTENANCE_TECHNICIAN = /datum/alt_title/maint_tech, JOB_ALT_ENGINE_TECHNICIAN = /datum/alt_title/engine_tech, - JOB_ALT_ELECTRICIAN = /datum/alt_title/electrician, JOB_ALT_CONSTRUCTION_ENGINEER = /datum/alt_title/construction_engi, JOB_ALT_ENGINEERING_CONTRACTOR = /datum/alt_title/engineering_contractor) + JOB_ALT_ELECTRICIAN = /datum/alt_title/electrician, JOB_ALT_CONSTRUCTION_ENGINEER = /datum/alt_title/construction_engi, JOB_ALT_ENGINEERING_CONTRACTOR = /datum/alt_title/engineering_contractor, JOB_ALT_COMPUTER_TECHNICIAN = /datum/alt_title/computer_tech) /datum/alt_title/construction_engi title = JOB_ALT_CONSTRUCTION_ENGINEER @@ -44,8 +44,9 @@ /datum/job/engineer/get_request_reasons() return list("Engine setup", "Construction project", "Repairs necessary", "Assembling expedition team") - - +/datum/alt_title/computer_tech + title = JOB_ALT_COMPUTER_TECHNICIAN + title_blurb = "A " + JOB_ALT_COMPUTER_TECHNICIAN + " fulfills similar duties to other engineers, but specializes in working with software and computers. They also often deal with integrated circuits." /datum/job/atmos spawn_positions = 3 diff --git a/code/game/jobs/job/science_vr.dm b/code/game/jobs/job/science_vr.dm index bb5285e16ef..c0505e4109e 100644 --- a/code/game/jobs/job/science_vr.dm +++ b/code/game/jobs/job/science_vr.dm @@ -86,7 +86,15 @@ /datum/job/roboticist total_positions = 3 pto_type = PTO_SCIENCE - alt_titles = list(JOB_ALT_ASSEMBLY_TECHNICIAN = /datum/alt_title/assembly_tech, JOB_ALT_BIOMECHANICAL_ENGINEER = /datum/alt_title/biomech, JOB_ALT_MECHATRONIC_ENGINEER = /datum/alt_title/mech_tech) + alt_titles = list( + JOB_ALT_ASSEMBLY_TECHNICIAN = /datum/alt_title/assembly_tech, + JOB_ALT_BIOMECHANICAL_ENGINEER = /datum/alt_title/biomech, + JOB_ALT_MECHATRONIC_ENGINEER = /datum/alt_title/mech_tech, + JOB_ALT_SOFTWARE_ENGINEER = /datum/alt_title/software_engi) + +/datum/alt_title/software_engi + title = JOB_ALT_SOFTWARE_ENGINEER + title_blurb = "A " + JOB_ALT_SOFTWARE_ENGINEER + " specializes in working with software and firmware. They also often deal with integrated circuits." /datum/alt_title/assembly_tech title = JOB_ALT_ASSEMBLY_TECHNICIAN diff --git a/code/game/machinery/adv_med.dm b/code/game/machinery/adv_med.dm index 05b7b67273b..2d4ca00ab48 100644 --- a/code/game/machinery/adv_med.dm +++ b/code/game/machinery/adv_med.dm @@ -189,7 +189,7 @@ occupantData["health"] = H.health occupantData["maxHealth"] = H.getMaxHealth() - occupantData["hasVirus"] = H.virus2.len + occupantData["hasVirus"] = H.viruses.len occupantData["bruteLoss"] = H.getBruteLoss() occupantData["oxyLoss"] = H.getOxyLoss() @@ -379,8 +379,12 @@ dat += (occupant.health > (occupant.getMaxHealth() / 2) ? span_blue(health_text) : span_red(health_text)) dat += "
" - if(occupant.virus2.len) - dat += span_red("Viral pathogen detected in blood stream.") + "
" + if(occupant.viruses.len) + for(var/datum/disease/D in occupant.GetViruses()) + if(D.visibility_flags & HIDDEN_SCANNER) + continue + else + dat += span_red("Viral pathogen detected in blood stream.") + "
" var/damage_string = null damage_string = "\t-Brute Damage %: [occupant.getBruteLoss()]" diff --git a/code/game/machinery/camera/tracking.dm b/code/game/machinery/camera/tracking.dm index 501acc84813..54fdfbdba46 100644 --- a/code/game/machinery/camera/tracking.dm +++ b/code/game/machinery/camera/tracking.dm @@ -26,7 +26,7 @@ /mob/living/silicon/ai/proc/ai_camera_list(var/camera in get_camera_list()) - set category = "AI Commands" + set category = "AI.Camera Control" set name = "Show Camera List" if(check_unable()) @@ -41,7 +41,7 @@ return /mob/living/silicon/ai/proc/ai_store_location(loc as text) - set category = "AI Commands" + set category = "AI.Camera Control" set name = "Store Camera Location" set desc = "Stores your current camera location by the given name" @@ -70,7 +70,7 @@ return sortList(stored_locations) /mob/living/silicon/ai/proc/ai_goto_location(loc in sorted_stored_locations()) - set category = "AI Commands" + set category = "AI.Camera Control" set name = "Goto Camera Location" set desc = "Returns to the selected camera location" @@ -82,7 +82,7 @@ src.eyeobj.setLoc(L) /mob/living/silicon/ai/proc/ai_remove_location(loc in sorted_stored_locations()) - set category = "AI Commands" + set category = "AI.Camera Control" set name = "Delete Camera Location" set desc = "Deletes the selected camera location" @@ -129,7 +129,7 @@ return targets /mob/living/silicon/ai/proc/ai_camera_track(var/target_name in trackable_mobs()) - set category = "AI Commands" + set category = "AI.Camera Control" set name = "Follow With Camera" set desc = "Select who you would like to track." diff --git a/code/game/machinery/computer/ai_core.dm b/code/game/machinery/computer/ai_core.dm index af3a5af05c5..2808be538a9 100644 --- a/code/game/machinery/computer/ai_core.dm +++ b/code/game/machinery/computer/ai_core.dm @@ -262,7 +262,7 @@ GLOBAL_LIST_BOILERPLATE(all_deactivated_AI_cores, /obj/structure/AIcore/deactiva /client/proc/empty_ai_core_toggle_latejoin() set name = "Toggle AI Core Latejoin" - set category = "Admin" + set category = "Admin.Silicon" var/list/cores = list() for(var/obj/structure/AIcore/deactivated/D in all_deactivated_AI_cores) diff --git a/code/game/machinery/computer/medical.dm b/code/game/machinery/computer/medical.dm index 1fb04554760..00339ac2737 100644 --- a/code/game/machinery/computer/medical.dm +++ b/code/game/machinery/computer/medical.dm @@ -172,8 +172,10 @@ medical["empty"] = 1 if(MED_DATA_V_DATA) data["virus"] = list() - for(var/ID in virusDB) - var/datum/data/record/v = virusDB[ID] + for(var/datum/disease/D in active_diseases) + if(!D.discovered) + continue + var/datum/data/record/v = active_diseases[D] data["virus"] += list(list("name" = v.fields["name"], "D" = "\ref[v]")) if(MED_DATA_MEDBOT) data["medbots"] = list() diff --git a/code/game/machinery/door_control.dm b/code/game/machinery/door_control.dm index 23e19a54a01..0c29400e73e 100644 --- a/code/game/machinery/door_control.dm +++ b/code/game/machinery/door_control.dm @@ -221,3 +221,23 @@ spawn(0) if(SG?.anchored) SG.toggle() + +/obj/machinery/button/remote/airlock/release + icon = 'icons/obj/door_release.dmi' + name = "emergency door release" + desc = "Forces the opening of doors in an emergency, regardless of whether they're powered." + + use_power = USE_POWER_OFF + idle_power_usage = 0 + active_power_usage = 0 + +/obj/machinery/button/remote/airlock/release/trigger() + for(var/obj/machinery/door/airlock/D in machines) + if(D.id_tag == id) + if(D.locked) + D.unlock(1) + if(D.density) + D.open(1) + +/obj/machinery/button/remote/airlock/release/powered() + return 1 //Is always able to be used diff --git a/code/game/machinery/pandemic.dm b/code/game/machinery/pandemic.dm new file mode 100644 index 00000000000..ae8687d6657 --- /dev/null +++ b/code/game/machinery/pandemic.dm @@ -0,0 +1,377 @@ +/obj/machinery/computer/pandemic + name = "PanD.E.M.I.C 2200" + desc = "Used to work with viruses." + density = TRUE + anchored = TRUE + icon = 'icons/obj/pandemic.dmi' + icon_state = "pandemic0" + var/temp_html = "" + var/printing = null + var/wait = null + var/selected_strain_index = 1 + var/obj/item/reagent_containers/beaker = null + +/obj/machinery/computer/pandemic/Initialize(mapload) + . = ..() + update_icon() + +/obj/machinery/computer/pandemic/set_broken() + stat |= BROKEN + update_icon() + +/obj/machinery/computer/pandemic/proc/GetViruses() + if(beaker && beaker.reagents) + if(length(beaker.reagents.reagent_list)) + var/datum/reagent/blood/BL = locate() in beaker.reagents.reagent_list + if(BL) + if(BL.data && BL.data["viruses"]) + var/list/viruses = BL.data["viruses"] + return viruses + +/obj/machinery/computer/pandemic/proc/GetVirusByIndex(index) + var/list/viruses = GetViruses() + if(viruses && index > 0 && index <= length(viruses)) + return viruses[index] + +/obj/machinery/computer/pandemic/proc/GetResistances() + if(beaker && beaker.reagents) + if(length(beaker.reagents.reagent_list)) + var/datum/reagent/blood/BL = locate() in beaker.reagents.reagent_list + if(BL) + if(BL.data && BL.data["resistances"]) + var/list/resistances = BL.data["resistances"] + return resistances + +/obj/machinery/computer/pandemic/proc/GetResistancesByIndex(index) + var/list/resistances = GetResistances() + if(resistances && index > 0 && index <= length(resistances)) + return resistances[index] + +/obj/machinery/computer/pandemic/proc/GetVirusTypeByIndex(index) + var/datum/disease/D = GetVirusByIndex(index) + if(D) + return D.GetDiseaseID() + +/obj/machinery/computer/pandemic/proc/replicator_cooldown(waittime) + wait = 1 + update_icon() + spawn(waittime) + wait = null + update_icon() + playsound(loc, 'sound/machines/ping.ogg', 30, 1) + +/obj/machinery/computer/pandemic/update_icon() + if(stat & BROKEN) + icon_state = (beaker ? "pandemic1_b" : "pandemic0_b") + return + icon_state = "pandemic[(beaker)?"1":"0"][!(stat & NOPOWER) ? "" : "_nopower"]" + +/obj/machinery/computer/pandemic/proc/create_culture(name, bottle_type = "culture", cooldown = 50) + var/obj/item/reagent_containers/glass/bottle/B = new/obj/item/reagent_containers/glass/bottle(loc) + B.icon_state = "bottle10" + B.pixel_x = rand(-3, 3) + B.pixel_y = rand(-3, 3) + replicator_cooldown(cooldown) + B.name = "[name] [bottle_type] bottle" + return B + +/obj/machinery/computer/pandemic/tgui_act(action, params, datum/tgui/ui, datum/tgui_state/state) + if(..()) + return + if(inoperable()) + return + + . = TRUE + + switch(action) + if("clone_strain") + if(wait) + atom_say("The replicator is not ready yet.") + return + + var/strain_index = text2num(params["strain_index"]) + if(isnull(strain_index)) + atom_say("Unable to respond to command.") + return + var/datum/disease/virus = GetVirusByIndex(strain_index) + var/datum/disease/D = null + if(!virus) + atom_say("Unable to find requested strain.") + return + var/type = virus.GetDiseaseID() + if(!ispath(type)) + var/datum/disease/advance/A = GLOB.archive_diseases[type] + if(A) + D = new A.type(0, A) + else if(type) + if(type in GLOB.diseases) // Make sure this is a disease + D = new type(0, null) + if(!D) + atom_say("Unable to synthesize requested strain.") + return + var/default_name = "" + if(D.name == "Unknown" || D.name == "") + default_name = replacetext(beaker.name, new/regex(" culture bottle\\Z", "g"), "") + else + default_name = D.name + var/name = tgui_input_text(usr, "Name:", "Name the culture", default_name, MAX_NAME_LEN) + if(name == null || wait) + return + var/obj/item/reagent_containers/glass/bottle/B = create_culture(name) + B.desc = "A small bottle. Contains [D.agent] culture in synthblood medium." + B.reagents.add_reagent("blood", 20, list("viruses" = list(D))) + if("clone_vaccine") + if(wait) + atom_say("The replicator is not ready yet.") + return + + var/resistance_index = text2num(params["resistance_index"]) + if(isnull(resistance_index)) + atom_say("Unable to find requested antibody.") + return + var/vaccine_type = GetResistancesByIndex(resistance_index) + var/vaccine_name = "Unknown" + if(!ispath(vaccine_type)) + if(GLOB.archive_diseases[vaccine_type]) + var/datum/disease/D = GLOB.archive_diseases[vaccine_type] + if(D) + vaccine_name = D.name + else if(vaccine_type) + var/datum/disease/D = new vaccine_type(0, null) + if(D) + vaccine_name = D.name + + if(!vaccine_type) + atom_say("Unable to synthesize requested antibody.") + return + + var/obj/item/reagent_containers/glass/bottle/B = create_culture(vaccine_name, "vaccine", 200) + B.reagents.add_reagent("vaccine", 15, list(vaccine_type)) + if("eject_beaker") + eject_beaker() + update_tgui_static_data(ui.user) + if("destroy_eject_beaker") + beaker.reagents.clear_reagents() + eject_beaker() + update_tgui_static_data(ui.user) + if("print_release_forms") + var/strain_index = text2num(params["strain_index"]) + if(isnull(strain_index)) + atom_say("Unable to respond to command.") + return + var/type = GetVirusTypeByIndex(strain_index) + if(!type) + atom_say("Unable to find requested strain.") + return + var/datum/disease/advance/A = GLOB.archive_diseases[type] + if(!A) + atom_say("Unable to find requested strain.") + return + print_form(A, usr) + if("name_strain") + var/strain_index = text2num(params["strain_index"]) + if(isnull(strain_index)) + atom_say("Unable to respond to command.") + return + var/type = GetVirusTypeByIndex(strain_index) + if(!type) + atom_say("Unable to find requested strain.") + return + var/datum/disease/advance/A = GLOB.archive_diseases[type] + if(!A) + atom_say("Unable to find requested strain.") + return + if(A.name != "Unknown") + atom_say("Request rejected. Strain already has a name.") + return + var/new_name = tgui_input_text(usr, "Name the Strain", "New Name", max_length = MAX_NAME_LEN) + if(!new_name) + return + A.AssignName(new_name) + for(var/datum/disease/advance/AD in active_diseases) + AD.Refresh() + update_tgui_static_data(ui.user) + if("switch_strain") + var/strain_index = text2num(params["strain_index"]) + if(isnull(strain_index) || strain_index < 1) + atom_say("Unable to respond to command.") + return + var/list/viruses = GetViruses() + if(strain_index > length(viruses)) + atom_say("Unable to find requested strain.") + return + selected_strain_index = strain_index; + else + return FALSE + +/obj/machinery/computer/pandemic/tgui_state(mob/user) + return GLOB.tgui_default_state + +/obj/machinery/computer/pandemic/tgui_interact(mob/user, datum/tgui/ui, datum/tgui/parent_ui = null) + ui = SStgui.try_update_ui(user, src, ui) + if(!ui) + ui = new(user, src, "PanDEMIC", name) + ui.open() + +/obj/machinery/computer/pandemic/tgui_data(mob/user) + var/datum/reagent/blood/Blood = null + if(beaker) + var/datum/reagents/R = beaker.reagents + for(var/datum/reagent/blood/B in R.reagent_list) + if(B) + Blood = B + break + + var/list/data = list( + "synthesisCooldown" = wait ? TRUE : FALSE, + "beakerLoaded" = beaker ? TRUE : FALSE, + "beakerContainsBlood" = Blood ? TRUE : FALSE, + "beakerContainsVirus" = length(Blood?.data["viruses"]) != 0, + "selectedStrainIndex" = selected_strain_index, + ) + + return data + +/obj/machinery/computer/pandemic/tgui_static_data(mob/user) + var/list/data = list() + . = data + + var/datum/reagent/blood/Blood = null + if(beaker) + var/datum/reagents/R = beaker.reagents + for(var/datum/reagent/blood/B in R.reagent_list) + if(B) + Blood = B + break + + var/list/strains = list() + for(var/datum/disease/D in GetViruses()) + if(D.visibility_flags & HIDDEN_PANDEMIC) + continue + + var/list/symptoms = list() + if(istype(D, /datum/disease/advance)) + var/datum/disease/advance/A = D + D = GLOB.archive_diseases[A.GetDiseaseID()] + if(!D) + CRASH("We weren't able to get the advance disease from the archive.") + for(var/datum/symptom/S in A.symptoms) + symptoms += list(list( + "name" = S.name, + "stealth" = S.stealth, + "resistance" = S.resistance, + "stageSpeed" = S.stage_speed, + "transmissibility" = S.transmittable, + "complexity" = S.level, + )) + + strains += list(list( + "commonName" = D.name, + "description" = D.desc, + "bloodDNA" = Blood.data["blood_DNA"], + "bloodType" = Blood.data["blood_type"], + "diseaseAgent" = D.agent, + "possibleTreatments" = D.cure_text, + "transmissionRoute" = D.spread_text, + "symptoms" = symptoms, + "isAdvanced" = istype(D, /datum/disease/advance), + )) + data["strains"] = strains + + var/list/resistances = list() + for(var/resistance in GetResistances()) + if(!ispath(resistance)) + var/datum/disease/D = GLOB.archive_diseases[resistance] + if(D) + resistances += list(D.name) + else if(resistance) + var/datum/disease/D = new resistance(0, null) + if(D) + resistances += list(D.name) + data["resistances"] = resistances + +/obj/machinery/computer/pandemic/proc/eject_beaker() + set name = "Eject Beaker" + set category = "Object" + set src in oview(1) + + if(usr.stat != 0) + return + + beaker.forceMove(loc) + beaker = null + icon_state = "pandemic0" + selected_strain_index = 1 + +/obj/machinery/computer/pandemic/proc/print_form(datum/disease/advance/D, mob/living/user) + D = GLOB.archive_diseases[D.GetDiseaseID()] + if(!(printing) && D) + var/reason = tgui_input_text(user,"Enter a reason for the release", "Write", multiline = TRUE) + if(!reason) + return + reason += "" + var/english_symptoms = list() + for(var/I in D.symptoms) + var/datum/symptom/S = I + english_symptoms += S.name + var/symtoms = english_list(english_symptoms) + + var/signature + if(tgui_alert(user, "Would you like to add your signature?", "Signature", list("Yes","No")) == "Yes") + signature = "[user ? user.real_name : "Anonymous"]" + else + signature = "" + + printing = 1 + var/obj/item/paper/P = new /obj/item/paper(loc) + visible_message(span_notice("[src] rattles and prints out a sheet of paper.")) + // playsound(loc, 'sound/goonstation/machines/printer_dotmatrix.ogg', 50, 1) + + P.info = "
Releasing Virus
" + P.info += "
" + P.info += "Name of the Virus: [D.name]
" + P.info += "Symptoms: [symtoms]
" + P.info += "Spreads by: [D.spread_text]
" + P.info += "Cured by: [D.cure_text]
" + P.info += "
" + P.info += "Reason for releasing: [reason]" + P.info += "
" + P.info += "The Virologist is responsible for any biohazards caused by the virus released.
" + P.info += "Virologist's sign: [signature]
" + P.info += "If approved, stamp below with the Chief Medical Officer's stamp, and/or the Captain's stamp if required:" + P.updateinfolinks() + P.name = "Releasing Virus - [D.name]" + printing = null + +/obj/machinery/computer/pandemic/attack_ai(mob/user) + return attack_hand(user) + +/obj/machinery/computer/pandemic/attack_hand(mob/user) + if(..()) + return + tgui_interact(user) + +/obj/machinery/computer/pandemic/attack_ghost(mob/user) + tgui_interact(user) + +/obj/machinery/computer/pandemic/attackby(obj/item/I, mob/user, params) + if(default_unfasten_wrench(user, I, 4 SECONDS)) + return + if(I.has_tool_quality(TOOL_SCREWDRIVER)) + eject_beaker() + return + if(istype(I, /obj/item/reagent_containers/glass) && I.is_open_container()) + if(stat & (NOPOWER|BROKEN)) + return + if(beaker) + to_chat(user, span_warning("A beaker is already loaded into the machine!")) + return + + user.drop_item() + beaker = I + beaker.loc = src + to_chat(user, span_notice("You add the beaker to the machine.")) + update_tgui_static_data(user) + icon_state = "pandemic1" + else + return ..() diff --git a/code/game/machinery/partslathe_vr.dm b/code/game/machinery/partslathe_vr.dm index cc277d70d24..8693642de76 100644 --- a/code/game/machinery/partslathe_vr.dm +++ b/code/game/machinery/partslathe_vr.dm @@ -174,8 +174,9 @@ return /obj/machinery/partslathe/proc/removeFromQueue(var/index) - queue.Cut(index, index + 1) - return + if(queue.len >= index) + queue.Cut(index, index + 1) + return /obj/machinery/partslathe/proc/canBuild(var/datum/category_item/partslathe/D) for(var/M in D.resources) diff --git a/code/game/magic/archived_book.dm b/code/game/magic/archived_book.dm index d41689661d8..665f585f96e 100644 --- a/code/game/magic/archived_book.dm +++ b/code/game/magic/archived_book.dm @@ -34,7 +34,7 @@ var/global/datum/book_manager/book_mgr = new() /client/proc/delbook() set name = "Delete Book" set desc = "Permamently deletes a book from the database." - set category = "Admin" + set category = "Admin.Moderation" if(!src.holder) to_chat(src, "Only administrators may use this command.") return diff --git a/code/game/mecha/micro/mecha_construction_paths_vr.dm b/code/game/mecha/micro/mecha_construction_paths_vr.dm index 60ed08cac13..9f6b58ff5da 100644 --- a/code/game/mecha/micro/mecha_construction_paths_vr.dm +++ b/code/game/mecha/micro/mecha_construction_paths_vr.dm @@ -252,7 +252,7 @@ if(3) if(diff==FORWARD) user.visible_message("[user] installs external reinforced armor layer to [holder].", "You install external reinforced armor layer to [holder].") - qdel(used_atom)//CHOMPedit upstream port. Fixes polecat not useing it's armor plates up. + qdel(used_atom)// upstream port. Fixes polecat not useing it's armor plates up. holder.icon_state = "polecat18" else user.visible_message("[user] cuts internal armor layer from [holder].", "You cut the internal armor layer from [holder].") diff --git a/code/game/objects/effects/decals/Cleanable/humans.dm b/code/game/objects/effects/decals/Cleanable/humans.dm index 18660273f7d..84b47051aa1 100644 --- a/code/game/objects/effects/decals/Cleanable/humans.dm +++ b/code/game/objects/effects/decals/Cleanable/humans.dm @@ -19,7 +19,7 @@ var/global/list/image/splatter_cache=list() blood_DNA = list() var/basecolor="#A10808" // Color when wet. var/synthblood = 0 - var/list/datum/disease2/disease/virus2 = list() + var/list/datum/disease/viruses = list() var/amount = 5 generic_filth = TRUE persistent = FALSE @@ -242,7 +242,7 @@ var/global/list/image/splatter_cache=list() icon_state = "mucus" random_icon_states = list("mucus") - var/list/datum/disease2/disease/virus2 = list() + var/list/datum/disease/viruses = list() var/dry = 0 // Keeps the lag down /obj/effect/decal/cleanable/mucus/Initialize() @@ -252,11 +252,10 @@ var/global/list/image/splatter_cache=list() //This version should be used for admin spawns and pre-mapped virus vectors (e.g. in PoIs), this version does not dry /obj/effect/decal/cleanable/mucus/mapped/Initialize() . = ..() - virus2 |= new /datum/disease2/disease - virus2[1].makerandom() + viruses |= new /datum/disease/advance /obj/effect/decal/cleanable/mucus/mapped/Destroy() - virus2.Cut() + viruses.Cut() return ..() #undef DRYING_TIME diff --git a/code/game/objects/effects/decals/Cleanable/misc.dm b/code/game/objects/effects/decals/Cleanable/misc.dm index c15734b89d4..e8a6083fed9 100644 --- a/code/game/objects/effects/decals/Cleanable/misc.dm +++ b/code/game/objects/effects/decals/Cleanable/misc.dm @@ -113,7 +113,7 @@ icon = 'icons/effects/blood.dmi' icon_state = "vomit_1" random_icon_states = list("vomit_1", "vomit_2", "vomit_3", "vomit_4") - var/list/datum/disease2/disease/virus2 = list() + var/list/datum/disease/viruses = list() /obj/effect/decal/cleanable/tomato_smudge name = "tomato smudge" diff --git a/code/game/objects/effects/spawners/bombspawner.dm b/code/game/objects/effects/spawners/bombspawner.dm index 511df962db2..08d2ec96c33 100644 --- a/code/game/objects/effects/spawners/bombspawner.dm +++ b/code/game/objects/effects/spawners/bombspawner.dm @@ -1,5 +1,5 @@ /client/proc/spawn_tanktransferbomb() - set category = "Debug" + set category = "Debug.Game" set desc = "Spawn a tank transfer valve bomb" set name = "Instant TTV" @@ -139,5 +139,3 @@ new type(src.loc) qdel(src) - - diff --git a/code/game/objects/items/devices/communicator/communicator.dm b/code/game/objects/items/devices/communicator/communicator.dm index 56209fc53c1..cb0b7e7b7a4 100644 --- a/code/game/objects/items/devices/communicator/communicator.dm +++ b/code/game/objects/items/devices/communicator/communicator.dm @@ -279,11 +279,10 @@ var/global/list/obj/item/communicator/all_communicators = list() // Parameters: None // Description: Removes the ghost's address and nulls the exonet datum, to allow qdel()ing. /mob/observer/dead/Destroy() - . = ..() if(exonet) exonet.remove_address() qdel_null(exonet) - return ..() + . = ..() // Proc: register_device() // Parameters: 1 (user - the person to use their name for) diff --git a/code/game/objects/items/devices/communicator/integrated.dm b/code/game/objects/items/devices/communicator/integrated.dm index 41990e30f2e..78066c5d17e 100644 --- a/code/game/objects/items/devices/communicator/integrated.dm +++ b/code/game/objects/items/devices/communicator/integrated.dm @@ -20,7 +20,7 @@ // Parameters: None // Description: Lets synths use their communicators without hands. /obj/item/communicator/integrated/verb/activate() - set category = "Abilities.AI_IM" + set category = "Abilities.AI" set name = "Use Communicator" set desc = "Utilizes your built-in communicator." set src in usr diff --git a/code/game/objects/items/devices/communicator/messaging.dm b/code/game/objects/items/devices/communicator/messaging.dm index a9c07241600..9339b3f84bc 100644 --- a/code/game/objects/items/devices/communicator/messaging.dm +++ b/code/game/objects/items/devices/communicator/messaging.dm @@ -114,7 +114,7 @@ // Parameters: None // Description: Allows a ghost to send a text message to a communicator. /mob/observer/dead/verb/text_communicator() - set category = "Ghost" + set category = "Ghost.Message" set name = "Text Communicator" set desc = "If there is a communicator available, send a text message to it." @@ -174,7 +174,7 @@ // Parameters: None // Description: Lets ghosts review messages they've sent or received. /mob/observer/dead/verb/show_text_messages() - set category = "Ghost" + set category = "Ghost.Settings" set name = "Show Text Messages" set desc = "Allows you to see exonet text messages you've sent and received." diff --git a/code/game/objects/items/devices/communicator/phone.dm b/code/game/objects/items/devices/communicator/phone.dm index 41b665535ab..dc46930913d 100644 --- a/code/game/objects/items/devices/communicator/phone.dm +++ b/code/game/objects/items/devices/communicator/phone.dm @@ -272,7 +272,7 @@ // Parameters: None // Description: Allows ghosts to call communicators, if they meet all the requirements. /mob/observer/dead/verb/join_as_voice() - set category = "Ghost" + set category = "Ghost.Message" set name = "Call Communicator" set desc = "If there is a communicator available, send a request to speak through it. This will reset your respawn timer, if someone picks up." diff --git a/code/game/objects/items/devices/hacktool.dm b/code/game/objects/items/devices/hacktool.dm index ce097cdfd69..3545ff34867 100644 --- a/code/game/objects/items/devices/hacktool.dm +++ b/code/game/objects/items/devices/hacktool.dm @@ -1,8 +1,8 @@ /obj/item/multitool/hacktool var/is_hacking = 0 var/max_known_targets - var/hackspeed = 1 - var/max_level = 4 //what's the max door security_level we can handle? + var/hackspeed = 1 //time taken to hack: lower is faster + var/max_level = 4 //what's the max door security_level we can handle? default is 1, med/eng/atmos are 1.5, sec/sci are 2, command is 3, vault is 5 var/full_override = FALSE //can we override door bolts too? defaults to false for event/safety reasons var/in_hack_mode = 0 @@ -155,3 +155,16 @@ if(!hacktool || !hacktool.in_hack_mode || !(src_object in hacktool.known_targets)) return STATUS_CLOSE return ..() + +/obj/item/multitool/hacktool/modified + name = "modified multitool" + desc = "Used for pulsing wires to test which to cut. Not recommended by doctors. This ones seems a bit larger and heavier than the usual model, for some reason. Maybe it's an older version?" + description_info = "You can use this on airlocks or APCs to try to hack them without cutting wires." + icon_state = "multitool_modified" + +/obj/item/multitool/hacktool/obvious + name = "non-standard multitool" + desc = "Used for pulsing wires to test which to cut. Not recommended by doctors. This one doesn't look like the usual model at all!" + description_info = "You can use this on airlocks or APCs to try to hack them without cutting wires." + icon_state = "multitool_suspicious" + in_hack_mode = 1 //start in hackmode diff --git a/code/game/objects/items/devices/scanners/guide.dm b/code/game/objects/items/devices/scanners/guide.dm index de728cd8544..403a81f9747 100644 --- a/code/game/objects/items/devices/scanners/guide.dm +++ b/code/game/objects/items/devices/scanners/guide.dm @@ -97,8 +97,12 @@ dat += span_bold("Genetic damage") + " - Utilize cryogenic pod with appropriate chemicals (i.e. Cryoxadone) and below 70 K, or give Rezadone.
" if(bone) dat += span_bold("Bone fracture") + " - Splint damaged area. Treat with bone repair surgery or Osteodaxon after treating brute damage.
" - if(M.virus2.len) - dat += span_bold("Viral infection") + " - Proceed with virology pathogen curing procedures or apply antiviral chemicals (i.e. Corophizine).
" + if(M.viruses.len) + for(var/datum/disease/D in M.GetViruses()) + if(D.visibility_flags & HIDDEN_SCANNER) + continue + else + dat += span_bold("Viral Infection") + " - Inform a Virologist or the Chief Medical Officer and administer antiviral chemicals such as Spaceacilin. Limit exposure to other personnel.
" if(robotparts) dat += span_bold("Robotic body parts") + " - Should not be repaired by medical personnel, refer to robotics if damaged." diff --git a/code/game/objects/items/devices/scanners/health.dm b/code/game/objects/items/devices/scanners/health.dm index ec9a6b257ce..c9927024305 100644 --- a/code/game/objects/items/devices/scanners/health.dm +++ b/code/game/objects/items/devices/scanners/health.dm @@ -248,14 +248,14 @@ else dat += span_warning("Unknown substance[(unknown > 1)?"s":""] found in subject's dermis.") dat += "
" - if(C.virus2.len) - for (var/ID in C.virus2) - if (ID in virusDB) - var/datum/data/record/V = virusDB[ID] - dat += span_warning("Warning: Pathogen [V.fields["name"]] detected in subject's blood. Known antigen : [V.fields["antigen"]]") + if(C.resistances.len) + for (var/datum/disease/virus in C.GetViruses()) + if(virus.visibility_flags & HIDDEN_SCANNER || virus.visibility_flags & HIDDEN_PANDEMIC) + continue + if(virus.discovered) + dat += span_warning("Warning: [virus.name] detected in subject's blood.") dat += "
" - else - dat += span_warning("Warning: Unknown pathogen detected in subject's blood.") + dat += span_warning("Severity: [virus.severity]") dat += "
" if (M.getCloneLoss()) dat += span_warning("Subject appears to have been imperfectly cloned.") diff --git a/code/game/objects/items/devices/whistle.dm b/code/game/objects/items/devices/whistle.dm index f989f6110b5..372cde80c66 100644 --- a/code/game/objects/items/devices/whistle.dm +++ b/code/game/objects/items/devices/whistle.dm @@ -1,6 +1,7 @@ /obj/item/hailer name = "hailer" desc = "Used by obese officers to save their breath for running." + icon = 'icons/obj/device.dmi' icon_state = "voice0" item_state = "flashbang" //looks exactly like a flash (and nothing like a flashbang) w_class = ITEMSIZE_TINY diff --git a/code/game/objects/items/weapons/circuitboards/computer/computer.dm b/code/game/objects/items/weapons/circuitboards/computer/computer.dm index c340f4958a7..09535b45f54 100644 --- a/code/game/objects/items/weapons/circuitboards/computer/computer.dm +++ b/code/game/objects/items/weapons/circuitboards/computer/computer.dm @@ -154,14 +154,6 @@ build_path = /obj/machinery/computer/operating origin_tech = list(TECH_DATA = 2, TECH_BIO = 2) -/obj/item/circuitboard/curefab - name = T_BOARD("cure fabricator") - build_path = /obj/machinery/computer/curer - -/obj/item/circuitboard/splicer - name = T_BOARD("disease splicer") - build_path = /obj/machinery/computer/diseasesplicer - /obj/item/circuitboard/mining_shuttle name = T_BOARD("mining shuttle console") build_path = /obj/machinery/computer/shuttle_control/mining @@ -226,4 +218,4 @@ /obj/item/circuitboard/stockexchange name = T_BOARD("stock exchange console") build_path = /obj/machinery/computer/stockexchange - origin_tech = list(TECH_DATA = 2, TECH_MAGNET = 1) \ No newline at end of file + origin_tech = list(TECH_DATA = 2, TECH_MAGNET = 1) diff --git a/code/game/objects/items/weapons/circuitboards/machinery/fluidpump.dm b/code/game/objects/items/weapons/circuitboards/machinery/fluidpump.dm index 3e702a7e6fc..497c55eb14c 100644 --- a/code/game/objects/items/weapons/circuitboards/machinery/fluidpump.dm +++ b/code/game/objects/items/weapons/circuitboards/machinery/fluidpump.dm @@ -10,5 +10,6 @@ origin_tech = list(TECH_DATA = 1) req_components = list( /obj/item/stock_parts/matter_bin = 2, + /obj/item/cell = 1, /obj/item/stock_parts/motor = 2, /obj/item/stock_parts/manipulator = 1) diff --git a/code/game/objects/items/weapons/material/ashtray.dm b/code/game/objects/items/weapons/material/ashtray.dm index 33c4c82e9e9..847ddd6efa2 100644 --- a/code/game/objects/items/weapons/material/ashtray.dm +++ b/code/game/objects/items/weapons/material/ashtray.dm @@ -3,7 +3,7 @@ var/global/list/ashtray_cache = list() /obj/item/material/ashtray name = "ashtray" icon = 'icons/obj/objects.dmi' - icon_state = "blank" + icon_state = "ashtray" randpixel = 5 force_divisor = 0.1 thrown_force_divisor = 0.1 @@ -16,6 +16,7 @@ var/global/list/ashtray_cache = list() if(!material) qdel(src) return + icon_state = "blank" max_butts = round(material.hardness/5) //This is arbitrary but whatever. randpixel_xy() update_icon() diff --git a/code/game/objects/items/weapons/storage/bags.dm b/code/game/objects/items/weapons/storage/bags.dm index e27d9ade0cc..0e51b19eec8 100644 --- a/code/game/objects/items/weapons/storage/bags.dm +++ b/code/game/objects/items/weapons/storage/bags.dm @@ -453,7 +453,7 @@ max_storage_space = ITEMSIZE_COST_SMALL * 12 max_w_class = ITEMSIZE_NORMAL w_class = ITEMSIZE_SMALL - can_hold = list(/obj/item/reagent_containers/glass/beaker/vial/,/obj/item/virusdish/) + can_hold = list(/obj/item/reagent_containers/glass/beaker/vial/) // ----------------------------- // Food Bag diff --git a/code/game/objects/items/weapons/storage/belt.dm b/code/game/objects/items/weapons/storage/belt.dm index 4412b8af019..36f22f6f452 100644 --- a/code/game/objects/items/weapons/storage/belt.dm +++ b/code/game/objects/items/weapons/storage/belt.dm @@ -244,7 +244,6 @@ /obj/item/flashlight, /obj/item/cell/device, /obj/item/extinguisher/mini, - /obj/item/antibody_scanner, // VOREstation edit start /obj/item/sleevemate, /obj/item/mass_spectrometer, /obj/item/surgical, diff --git a/code/game/objects/items/weapons/storage/uplink_kits.dm b/code/game/objects/items/weapons/storage/uplink_kits.dm index 3704524cf12..d1df4043337 100644 --- a/code/game/objects/items/weapons/storage/uplink_kits.dm +++ b/code/game/objects/items/weapons/storage/uplink_kits.dm @@ -300,7 +300,7 @@ /obj/item/storage/box/syndie_kit/viral starts_with = list( - /obj/item/virusdish/random = 3 + // /obj/item/virusdish/random = 3 ) /obj/item/storage/secure/briefcase/rifle diff --git a/code/game/objects/structures/railing.dm b/code/game/objects/structures/railing.dm index 7f7f57c1f00..69167f859cf 100644 --- a/code/game/objects/structures/railing.dm +++ b/code/game/objects/structures/railing.dm @@ -222,7 +222,7 @@ // Install if(W.has_tool_quality(TOOL_SCREWDRIVER)) - user.visible_message(span_info(anchored ? span_bold("\The [user]") + " begins unscrewing \the [src]." : span_bold("\The [user]") + "begins fasten \the [src]." )) + user.visible_message(span_info((anchored ? (span_bold("\The [user]") + " begins unscrewing \the [src].") : (span_bold("\The [user]") + "begins fasten \the [src].")))) playsound(src, W.usesound, 75, 1) if(do_after(user, 10, src)) to_chat(user, (anchored ? span_notice("You have unfastened \the [src] from the floor.") : span_notice("You have fastened \the [src] to the floor."))) diff --git a/code/game/response_team.dm b/code/game/response_team.dm index d80fa0861b7..39bed0f177a 100644 --- a/code/game/response_team.dm +++ b/code/game/response_team.dm @@ -9,7 +9,7 @@ var/silent_ert = 0 /client/proc/response_team() set name = "Dispatch Emergency Response Team" - set category = "Special Verbs" + set category = "Fun.Event Kit" set desc = "Send an emergency response team to the station" if(!holder) @@ -43,7 +43,7 @@ var/silent_ert = 0 /client/verb/JoinResponseTeam() set name = "Join Response Team" - set category = "IC" + set category = "IC.Event" if(!MayRespawn(1)) to_chat(usr, span_warning("You cannot join the response team at this time.")) diff --git a/code/game/trader_visit.dm b/code/game/trader_visit.dm index ceb90b4675c..8f52110f534 100644 --- a/code/game/trader_visit.dm +++ b/code/game/trader_visit.dm @@ -5,7 +5,7 @@ var/can_call_traders = 1 /client/proc/trader_ship() set name = "Dispatch Beruang Trader Ship" - set category = "Special Verbs" + set category = "Fun.Event Kit" set desc = "Invite players to join the Beruang." if(!holder) @@ -36,7 +36,7 @@ var/can_call_traders = 1 /client/verb/JoinTraders() set name = "Join Trader Visit" - set category = "IC" + set category = "IC.Event" if(!MayRespawn(1)) to_chat(usr, span_warning("You cannot join the traders.")) diff --git a/code/game/turfs/simulated.dm b/code/game/turfs/simulated.dm index 841ab7286ba..6b46ba2acbe 100644 --- a/code/game/turfs/simulated.dm +++ b/code/game/turfs/simulated.dm @@ -174,7 +174,7 @@ B.blood_DNA = list() if(!B.blood_DNA[M.dna.unique_enzymes]) B.blood_DNA[M.dna.unique_enzymes] = M.dna.b_type - B.virus2 = virus_copylist(M.virus2) + B.viruses = M.viruses.Copy() return 1 //we bloodied the floor blood_splatter(src,M.get_blood(M.vessel),1) return 1 //we bloodied the floor diff --git a/code/modules/admin/DB ban/functions.dm b/code/modules/admin/DB ban/functions.dm index 8b7f6cf01fa..76aa32b9b05 100644 --- a/code/modules/admin/DB ban/functions.dm +++ b/code/modules/admin/DB ban/functions.dm @@ -250,7 +250,7 @@ /client/proc/DB_ban_panel() - set category = "Admin" + set category = "Admin.Moderation" set name = "Banning Panel" set desc = "Edit admin permissions" diff --git a/code/modules/admin/ToRban.dm b/code/modules/admin/ToRban.dm index 939755222b5..932dedf5daf 100644 --- a/code/modules/admin/ToRban.dm +++ b/code/modules/admin/ToRban.dm @@ -45,7 +45,7 @@ /client/proc/ToRban(task in list("update","toggle","show","remove","remove all","find")) set name = "ToRban" - set category = "Server" + set category = "Server.Config" if(!holder) return switch(task) if("update") diff --git a/code/modules/admin/admin.dm b/code/modules/admin/admin.dm index 359e64b0db6..f7e33d15d3a 100644 --- a/code/modules/admin/admin.dm +++ b/code/modules/admin/admin.dm @@ -32,7 +32,7 @@ var/global/floorIsLava = 0 ///////////////////////////////////////////////////////////////////////////////////////////////Panels /datum/admins/proc/show_player_panel(var/mob/M in mob_list) - set category = "Admin" + set category = "Admin.Game" set name = "Show Player Panel" set desc="Edit player (respawn, ban, heal, etc)" @@ -224,7 +224,7 @@ var/global/floorIsLava = 0 /datum/player_info/var/timestamp // Because this is bloody annoying /datum/admins/proc/PlayerNotes() - set category = "Admin" + set category = "Admin.Logs" set name = "Player Notes" if (!istype(src,/datum/admins)) src = usr.client.holder @@ -264,7 +264,7 @@ var/global/floorIsLava = 0 /datum/admins/proc/show_player_info(var/key as text) - set category = "Admin" + set category = "Admin.Investigate" set name = "Show Player Info" if (!istype(src,/datum/admins)) src = usr.client.holder @@ -278,7 +278,7 @@ var/global/floorIsLava = 0 /datum/admins/proc/access_news_network() //MARKER - set category = "Fun" + set category = "Fun.Event Kit" set name = "Access Newscaster Network" set desc = "Allows you to view, add and edit news feeds." @@ -594,7 +594,7 @@ var/global/floorIsLava = 0 /datum/admins/proc/restart() - set category = "Server" + set category = "Server.Game" set name = "Restart" set desc="Restarts the world" if (!usr.client.holder) @@ -617,7 +617,7 @@ var/global/floorIsLava = 0 /datum/admins/proc/announce() - set category = "Special Verbs" + set category = "Admin.Chat" set name = "Announce" set desc="Announce your desires to the world" if(!check_rights(0)) return @@ -635,7 +635,7 @@ var/global/floorIsLava = 0 var/datum/announcement/priority/admin_pri_announcer = new var/datum/announcement/minor/admin_min_announcer = new /datum/admins/proc/intercom() - set category = "Fun" + set category = "Fun.Event Kit" set name = "Intercom Msg" set desc = "Send an intercom message, like an arrivals announcement." if(!check_rights(0)) return @@ -663,7 +663,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","IN") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/intercom_convo() - set category = "Fun" + set category = "Fun.Event Kit" set name = "Intercom Convo" set desc = "Send an intercom conversation, like several uses of the Intercom Msg verb." set waitfor = FALSE //Why bother? We have some sleeps. You can leave tho! @@ -750,7 +750,7 @@ var/datum/announcement/minor/admin_min_announcer = new sleep(this_wait SECONDS) /datum/admins/proc/toggleooc() - set category = "Server" + set category = "Server.Chat" set desc="Globally Toggles OOC" set name="Toggle Player OOC" @@ -766,7 +766,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TOOC") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/togglelooc() - set category = "Server" + set category = "Server.Chat" set desc="Globally Toggles LOOC" set name="Toggle Player LOOC" @@ -783,7 +783,7 @@ var/datum/announcement/minor/admin_min_announcer = new /datum/admins/proc/toggledsay() - set category = "Server" + set category = "Server.Chat" set desc="Globally Toggles DSAY" set name="Toggle DSAY" @@ -800,7 +800,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TDSAY") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc /datum/admins/proc/toggleoocdead() - set category = "Server" + set category = "Server.Chat" set desc="Toggle Dead OOC." set name="Toggle Dead OOC" @@ -813,7 +813,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TDOOC") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/togglehubvisibility() - set category = "Server" + set category = "Server.Config" set desc="Globally Toggles Hub Visibility" set name="Toggle Hub Visibility" @@ -826,7 +826,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","THUB") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc /datum/admins/proc/toggletraitorscaling() - set category = "Server" + set category = "Server.Game" set desc="Toggle traitor scaling" set name="Toggle Traitor Scaling" CONFIG_SET(flag/traitor_scaling, !CONFIG_GET(flag/traitor_scaling)) @@ -835,7 +835,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TTS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/startnow() - set category = "Server" + set category = "Server.Game" set desc="Start the round ASAP" set name="Start Now" @@ -858,7 +858,7 @@ var/datum/announcement/minor/admin_min_announcer = new log_and_message_admins("cancelled immediate game start.") /datum/admins/proc/toggleenter() - set category = "Server" + set category = "Server.Game" set desc="People can't enter" set name="Toggle Entering" CONFIG_SET(flag/enter_allowed, !CONFIG_GET(flag/enter_allowed)) @@ -872,7 +872,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TE") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/toggleAI() - set category = "Server" + set category = "Server.Game" set desc="People can't be AI" set name="Toggle AI" CONFIG_SET(flag/allow_ai, !CONFIG_GET(flag/allow_ai)) @@ -885,7 +885,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TAI") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/toggleaban() - set category = "Server" + set category = "Server.Game" set desc="Respawn basically" set name="Toggle Respawn" CONFIG_SET(flag/abandon_allowed, !CONFIG_GET(flag/abandon_allowed)) @@ -899,7 +899,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TR") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/togglepersistence() - set category = "Server" + set category = "Server.Config" set desc="Whether persistent data will be saved from now on." set name="Toggle Persistent Data" CONFIG_SET(flag/persistence_disabled, !CONFIG_GET(flag/persistence_disabled)) @@ -913,7 +913,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TPD") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/togglemaploadpersistence() - set category = "Server" + set category = "Server.Config" set desc="Whether mapload persistent data will be saved from now on." set name="Toggle Mapload Persistent Data" CONFIG_SET(flag/persistence_ignore_mapload, !CONFIG_GET(flag/persistence_ignore_mapload)) @@ -927,7 +927,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TMPD") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/toggle_aliens() - set category = "Server" + set category = "Server.Game" set desc="Toggle alien mobs" set name="Toggle Aliens" CONFIG_SET(flag/aliens_allowed, !CONFIG_GET(flag/aliens_allowed)) @@ -936,7 +936,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TA") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/toggle_space_ninja() - set category = "Server" + set category = "Server.Game" set desc="Toggle space ninjas spawning." set name="Toggle Space Ninjas" CONFIG_SET(flag/ninjas_allowed, !CONFIG_GET(flag/ninjas_allowed)) @@ -945,7 +945,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TSN") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/delay() - set category = "Server" + set category = "Server.Game" set desc="Delay the game start/end" set name="Delay" @@ -965,7 +965,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","DELAY") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/adjump() - set category = "Server" + set category = "Server.Game" set desc="Toggle admin jumping" set name="Toggle Jump" CONFIG_SET(flag/allow_admin_jump, !CONFIG_GET(flag/allow_admin_jump)) @@ -973,7 +973,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TJ") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/adspawn() - set category = "Server" + set category = "Server.Game" set desc="Toggle admin spawning" set name="Toggle Spawn" CONFIG_SET(flag/allow_admin_spawning, !CONFIG_GET(flag/allow_admin_spawning)) @@ -981,7 +981,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TAS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/adrev() - set category = "Server" + set category = "Server.Game" set desc="Toggle admin revives" set name="Toggle Revive" CONFIG_SET(flag/allow_admin_rev, !CONFIG_GET(flag/allow_admin_rev)) @@ -989,7 +989,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TAR") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/immreboot() - set category = "Server" + set category = "Server.Game" set desc="Reboots the server post haste" set name="Immediate Reboot" if(!usr.client.holder) return @@ -1007,7 +1007,7 @@ var/datum/announcement/minor/admin_min_announcer = new world.Reboot() /datum/admins/proc/unprison(var/mob/M in mob_list) - set category = "Admin" + set category = "Admin.Moderation" set name = "Unprison" if (M.z == 2) if (CONFIG_GET(flag/allow_admin_jump)) @@ -1048,7 +1048,7 @@ var/datum/announcement/minor/admin_min_announcer = new return 0 /datum/admins/proc/spawn_fruit(seedtype in SSplants.seeds) - set category = "Debug" + set category = "Debug.Game" set desc = "Spawn the product of a seed." set name = "Spawn Fruit" @@ -1063,7 +1063,7 @@ var/datum/announcement/minor/admin_min_announcer = new log_admin("[key_name(usr)] spawned [seedtype] fruit at ([usr.x],[usr.y],[usr.z])") /datum/admins/proc/spawn_custom_item() - set category = "Debug" + set category = "Debug.Game" set desc = "Spawn a custom item." set name = "Spawn Custom Item" @@ -1081,8 +1081,7 @@ var/datum/announcement/minor/admin_min_announcer = new item_to_spawn.spawn_item(get_turf(usr)) /datum/admins/proc/check_custom_items() - - set category = "Debug" + set category = "Debug.Investigate" set desc = "Check the custom item list." set name = "Check Custom Items" @@ -1103,7 +1102,7 @@ var/datum/announcement/minor/admin_min_announcer = new to_chat(usr, "- name: [item.name] icon: [item.item_icon] path: [item.item_path] desc: [item.item_desc]") /datum/admins/proc/spawn_plant(seedtype in SSplants.seeds) - set category = "Debug" + set category = "Debug.Game" set desc = "Spawn a spreading plant effect." set name = "Spawn Plant" @@ -1116,7 +1115,7 @@ var/datum/announcement/minor/admin_min_announcer = new /datum/admins/proc/spawn_atom(var/object as text) set name = "Spawn" - set category = "Debug" + set category = "Debug.Game" set desc = "(atom path) Spawn an atom" if(!check_rights(R_SPAWN)) return @@ -1150,7 +1149,7 @@ var/datum/announcement/minor/admin_min_announcer = new /datum/admins/proc/show_traitor_panel(var/mob/M in mob_list) - set category = "Admin" + set category = "Admin.Events" set desc = "Edit mobs's memory and role" set name = "Show Traitor Panel" @@ -1165,7 +1164,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","STP") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/show_game_mode() - set category = "Admin" + set category = "Admin.Game" set desc = "Show the current round configuration." set name = "Show Game Mode" @@ -1239,7 +1238,7 @@ var/datum/announcement/minor/admin_min_announcer = new /datum/admins/proc/toggletintedweldhelmets() - set category = "Debug" + set category = "Server.Config" set desc="Reduces view range when wearing welding helmets" set name="Toggle tinted welding helmets." CONFIG_SET(flag/welder_vision, !CONFIG_GET(flag/welder_vision)) @@ -1252,7 +1251,7 @@ var/datum/announcement/minor/admin_min_announcer = new feedback_add_details("admin_verb","TTWH") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /datum/admins/proc/toggleguests() - set category = "Server" + set category = "Server.Config" set desc="Guests can't enter" set name="Toggle guests" CONFIG_SET(flag/guests_allowed, !CONFIG_GET(flag/guests_allowed)) @@ -1286,7 +1285,7 @@ var/datum/announcement/minor/admin_min_announcer = new to_chat(usr, span_bold("No AIs located")) //Just so you know the thing is actually working and not just ignoring you. /datum/admins/proc/show_skills() - set category = "Admin" + set category = "Admin.Investigate" set name = "Show Skills" if (!istype(src,/datum/admins)) @@ -1303,7 +1302,7 @@ var/datum/announcement/minor/admin_min_announcer = new return /client/proc/update_mob_sprite(mob/living/carbon/human/H as mob) - set category = "Admin" + set category = "Admin.Game" set name = "Update Mob Sprite" set desc = "Should fix any mob sprite update errors." @@ -1402,7 +1401,7 @@ var/datum/announcement/minor/admin_min_announcer = new return 1 /datum/admins/proc/force_antag_latespawn() - set category = "Admin" + set category = "Admin.Events" set name = "Force Template Spawn" set desc = "Force an antagonist template to spawn." @@ -1426,7 +1425,7 @@ var/datum/announcement/minor/admin_min_announcer = new antag.attempt_late_spawn() /datum/admins/proc/force_mode_latespawn() - set category = "Admin" + set category = "Admin.Events" set name = "Force Mode Spawn" set desc = "Force autotraitor to proc." @@ -1444,7 +1443,7 @@ var/datum/announcement/minor/admin_min_announcer = new ticker.mode.try_latespawn() /datum/admins/proc/paralyze_mob(mob/living/H as mob) - set category = "Admin" + set category = "Admin.Events" set name = "Toggle Paralyze" set desc = "Paralyzes a player. Or unparalyses them." @@ -1462,7 +1461,7 @@ var/datum/announcement/minor/admin_min_announcer = new log_and_message_admins(msg) /datum/admins/proc/set_tcrystals(mob/living/carbon/human/H as mob) - set category = "Debug" + set category = "Debug.Game" set name = "Set Telecrystals" set desc = "Allows admins to change telecrystals of a user." set popup_menu = FALSE //VOREStation Edit - Declutter. @@ -1478,7 +1477,7 @@ var/datum/announcement/minor/admin_min_announcer = new to_chat(usr, "You do not have access to this command.") /datum/admins/proc/add_tcrystals(mob/living/carbon/human/H as mob) - set category = "Debug" + set category = "Debug.Game" set name = "Add Telecrystals" set desc = "Allows admins to change telecrystals of a user by addition." set popup_menu = FALSE //VOREStation Edit - Declutter. @@ -1495,7 +1494,7 @@ var/datum/announcement/minor/admin_min_announcer = new /datum/admins/proc/sendFax() - set category = "Special Verbs" + set category = "Fun.Event Kit" set name = "Send Fax" set desc = "Sends a fax to this machine" var/department = tgui_input_list(usr, "Choose a fax", "Fax", alldepartments) diff --git a/code/modules/admin/admin_investigate.dm b/code/modules/admin/admin_investigate.dm index c2317542fb5..eed6315ef02 100644 --- a/code/modules/admin/admin_investigate.dm +++ b/code/modules/admin/admin_investigate.dm @@ -28,7 +28,7 @@ //ADMINVERBS /client/proc/investigate_show( subject in list("hrefs","notes","singulo","telesci") ) set name = "Investigate" - set category = "Admin" + set category = "Admin.Investigate" if(!holder) return switch(subject) if("singulo", "telesci") //general one-round-only stuff diff --git a/code/modules/admin/admin_memo.dm b/code/modules/admin/admin_memo.dm index 23ce2bc7e86..b230031cf20 100644 --- a/code/modules/admin/admin_memo.dm +++ b/code/modules/admin/admin_memo.dm @@ -4,7 +4,7 @@ //switch verb so we don't spam up the verb lists with like, 3 verbs for this feature. /client/proc/admin_memo(task in list("write","show","delete")) set name = "Memo" - set category = "Server" + set category = "Server.Admin" #ifndef ENABLE_MEMOS return #endif diff --git a/code/modules/admin/admin_report.dm b/code/modules/admin/admin_report.dm index d265f2cd1e3..002d702654e 100644 --- a/code/modules/admin/admin_report.dm +++ b/code/modules/admin/admin_report.dm @@ -91,7 +91,7 @@ world/New() // display only the reports that haven't been handled /client/proc/display_admin_reports() - set category = "Admin" + set category = "Admin.Moderation" set name = "Display Admin Reports" if(!src.holder) return @@ -119,7 +119,7 @@ world/New() /client/proc/Report(mob/M as mob in world) - set category = "Admin" + set category = "Admin.Moderation" if(!src.holder) return diff --git a/code/modules/admin/admin_tools.dm b/code/modules/admin/admin_tools.dm index 323d046a8d8..73d065bcc0c 100644 --- a/code/modules/admin/admin_tools.dm +++ b/code/modules/admin/admin_tools.dm @@ -1,5 +1,5 @@ /client/proc/cmd_admin_check_player_logs(mob/living/M as mob in mob_list) - set category = "Admin" + set category = "Admin.Logs" set name = "Check Player Attack Logs" set desc = "Check a player's attack logs." @@ -30,7 +30,7 @@ feedback_add_details("admin_verb","PL") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_admin_check_dialogue_logs(mob/living/M as mob in mob_list) - set category = "Admin" + set category = "Admin.Logs" set name = "Check Player Dialogue Logs" set desc = "Check a player's dialogue logs." diff --git a/code/modules/admin/admin_verb_lists_vr.dm b/code/modules/admin/admin_verb_lists_vr.dm index 28c9550ef81..4b29645516b 100644 --- a/code/modules/admin/admin_verb_lists_vr.dm +++ b/code/modules/admin/admin_verb_lists_vr.dm @@ -187,7 +187,6 @@ var/list/admin_verbs_spawn = list( /client/proc/cmd_admin_droppod_spawn, /client/proc/respawn_character, /client/proc/spawn_character_mob, //VOREStation Add, - /client/proc/virus2_editor, /client/proc/spawn_chemdisp_cartridge, /client/proc/map_template_load, /client/proc/map_template_upload, @@ -196,7 +195,9 @@ var/list/admin_verbs_spawn = list( /client/proc/generic_structure, //VOREStation Add /client/proc/generic_item, //VOREStation Add /client/proc/create_gm_message, - /client/proc/remove_gm_message + /client/proc/remove_gm_message, + /client/proc/AdminCreateVirus, + /client/proc/ReleaseVirus ) var/list/admin_verbs_server = list( @@ -563,8 +564,9 @@ var/list/admin_verbs_event_manager = list( /client/proc/toggle_random_events, /client/proc/modify_server_news, /client/proc/toggle_spawning_with_recolour, - /client/proc/start_vote - + /client/proc/start_vote, + /client/proc/AdminCreateVirus, + /client/proc/ReleaseVirus ) /client/proc/add_admin_verbs() diff --git a/code/modules/admin/admin_verbs.dm b/code/modules/admin/admin_verbs.dm index 5e2685917ee..7bd3b1e4c15 100644 --- a/code/modules/admin/admin_verbs.dm +++ b/code/modules/admin/admin_verbs.dm @@ -1,6 +1,6 @@ /client/proc/hide_most_verbs()//Allows you to keep some functionality while hiding some verbs set name = "Adminverbs - Hide Most" - set category = "Admin" + set category = "Admin.Misc" remove_verb(src, list(/client/proc/hide_most_verbs, admin_verbs_hideable)) add_verb(src, /client/proc/show_verbs) @@ -11,7 +11,7 @@ /client/proc/hide_verbs() set name = "Adminverbs - Hide All" - set category = "Admin" + set category = "Admin.Misc" remove_admin_verbs() add_verb(src, /client/proc/show_verbs) @@ -22,7 +22,7 @@ /client/proc/show_verbs() set name = "Adminverbs - Show" - set category = "Admin" + set category = "Admin.Misc" remove_verb(src, /client/proc/show_verbs) add_admin_verbs() @@ -98,7 +98,7 @@ /client/proc/player_panel() set name = "Player Panel" - set category = "Admin" + set category = "Admin.Game" if(holder) holder.player_panel_old() feedback_add_details("admin_verb","PP") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! @@ -106,7 +106,7 @@ /client/proc/player_panel_new() set name = "Player Panel New" - set category = "Admin" + set category = "Admin.Game" if(holder) holder.player_panel_new() feedback_add_details("admin_verb","PPN") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! @@ -114,7 +114,7 @@ /client/proc/check_antagonists() set name = "Check Antagonists" - set category = "Admin" + set category = "Admin.Investigate" if(holder) holder.check_antagonists() log_admin("[key_name(usr)] checked antagonists.") //for tsar~ @@ -123,7 +123,7 @@ /client/proc/jobbans() set name = "Display Job bans" - set category = "Admin" + set category = "Admin.Investigate" if(holder) if(CONFIG_GET(flag/ban_legacy_system)) holder.Jobbans() @@ -134,7 +134,7 @@ /client/proc/unban_panel() set name = "Unban Panel" - set category = "Admin" + set category = "Admin.Game" if(holder) if(CONFIG_GET(flag/ban_legacy_system)) holder.unbanpanel() @@ -153,14 +153,14 @@ /client/proc/secrets() set name = "Secrets" - set category = "Admin" + set category = "Admin.Secrets" if (holder) holder.Secrets() feedback_add_details("admin_verb","S") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! return /client/proc/colorooc() - set category = "Fun" + set category = "Admin.Misc" set name = "OOC Text Color" if(!holder) return var/response = tgui_alert(src, "Please choose a distinct color that is easy to read and doesn't mix with all the other chat and radio frequency colors.", "Change own OOC color", list("Pick new color", "Reset to default", "Cancel")) @@ -193,7 +193,7 @@ GLOB.stealthminID["[ckey]"] = "@[num2text(num)]" /client/proc/stealth() - set category = "Admin" + set category = "Admin.Game" set name = "Stealth Mode" if(holder) if(holder.fakekey) @@ -256,7 +256,7 @@ #undef AUTOBANTIME /client/proc/drop_bomb() // Some admin dickery that can probably be done better -- TLE - set category = "Special Verbs.Fun" + set category = "Fun.Do Not" set name = "Drop Bomb" set desc = "Cause an explosion of varying strength at your location." @@ -283,39 +283,8 @@ message_admins(span_blue("[ckey] creating an admin explosion at [epicenter.loc].")) feedback_add_details("admin_verb","DB") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! -/client/proc/give_disease2(mob/T as mob in mob_list) // -- Giacom - set category = "Fun" - set name = "Give Disease" - set desc = "Gives a Disease to a mob." - - var/datum/disease2/disease/D = new /datum/disease2/disease() - - var/severity = 1 - var/greater = tgui_input_list(usr, "Is this a lesser, greater, or badmin disease?", "Give Disease", list("Lesser", "Greater", "Badmin")) - switch(greater) - if ("Lesser") severity = 1 - if ("Greater") severity = 2 - if ("Badmin") severity = 99 - - D.makerandom(severity) - D.infectionchance = tgui_input_number(usr, "How virulent is this disease? (1-100)", "Give Disease", D.infectionchance, 100, 1) - - if(istype(T,/mob/living/carbon/human)) - var/mob/living/carbon/human/H = T - if (H.species) - D.affected_species = list(H.species.get_bodytype()) - if(H.species.primitive_form) - D.affected_species |= H.species.primitive_form - if(H.species.greater_form) - D.affected_species |= H.species.greater_form - infect_virus2(T,D,1) - - feedback_add_details("admin_verb","GD2") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! - log_admin("[key_name(usr)] gave [key_name(T)] a [greater] disease2 with infection chance [D.infectionchance].") - message_admins(span_blue("[key_name_admin(usr)] gave [key_name(T)] a [greater] disease2 with infection chance [D.infectionchance]."), 1) - /client/proc/admin_give_modifier(var/mob/living/L) - set category = "Debug" + set category = "Debug.Game" set name = "Give Modifier" set desc = "Makes a mob weaker or stronger by adding a specific modifier to them." set popup_menu = FALSE //VOREStation Edit - Declutter. @@ -339,7 +308,7 @@ log_and_message_admins("has given [key_name(L)] the modifer [new_modifier_type], with a duration of [duration ? "[duration / 600] minutes" : "forever"].") /client/proc/make_sound(var/obj/O in world) // -- TLE - set category = "Special Verbs.Events" + set category = "Fun.Sounds" set name = "Make Sound" set desc = "Display a message to everyone who can hear the target" if(O) @@ -354,13 +323,13 @@ /client/proc/togglebuildmodeself() set name = "Toggle Build Mode Self" - set category = "Special Verbs.Events" + set category = "Debug.Events" if(src.mob) togglebuildmode(src.mob) feedback_add_details("admin_verb","TBMS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/object_talk(var/msg as text) // -- TLE - set category = "Special Verbs.Events" + set category = "Fun.Narrate" set name = "oSay" set desc = "Display a message to everyone who can hear the target" if(mob.control_object) @@ -371,7 +340,7 @@ feedback_add_details("admin_verb","OT") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/kill_air() // -- TLE - set category = "Debug" + set category = "Debug.Dangerous" set name = "Kill Air" set desc = "Toggle Air Processing" SSair.can_fire = !SSair.can_fire @@ -382,7 +351,7 @@ /client/proc/readmin_self() set name = "Re-Admin self" - set category = "Admin" + set category = "Admin.Misc" if(deadmin_holder) deadmin_holder.reassociate() @@ -393,7 +362,7 @@ /client/proc/deadmin_self() set name = "De-admin self" - set category = "Admin" + set category = "Admin.Misc" if(holder) if(tgui_alert(usr, "Confirm self-deadmin for the round? You can't re-admin yourself without someone promoting you.","Deadmin",list("Yes","No")) == "Yes") @@ -406,7 +375,7 @@ /client/proc/toggle_log_hrefs() set name = "Toggle href logging" - set category = "Server" + set category = "Server.Config" if(!holder) return if(config) CONFIG_SET(flag/log_hrefs, !CONFIG_GET(flag/log_hrefs)) @@ -414,13 +383,13 @@ /client/proc/check_ai_laws() set name = "Check AI Laws" - set category = "Admin.Game" + set category = "Admin.Silicon" if(holder) src.holder.output_ai_laws() /client/proc/rename_silicon() set name = "Rename Silicon" - set category = "Admin" + set category = "Admin.Silicon" if(!check_rights(R_ADMIN|R_FUN|R_EVENT)) return @@ -435,7 +404,7 @@ /client/proc/manage_silicon_laws() set name = "Manage Silicon Laws" - set category = "Admin" + set category = "Admin.Silicon" if(!check_rights(R_ADMIN|R_EVENT)) return @@ -462,7 +431,7 @@ /client/proc/shuttle_panel() set name = "Shuttle Control Panel" - set category = "Admin" + set category = "Admin.Events" if(!check_rights(R_ADMIN | R_EVENT)) return @@ -476,7 +445,7 @@ /client/proc/mod_panel() set name = "Moderator Panel" - set category = "Admin" + set category = "Admin.Moderation" /* if(holder) holder.mod_panel()*/ // feedback_add_details("admin_verb","MP") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! @@ -484,14 +453,14 @@ /client/proc/playernotes() set name = "Show Player Info" - set category = "Admin" + set category = "Admin.Moderation" if(holder) holder.PlayerNotes() return /client/proc/free_slot() set name = "Free Job Slot" - set category = "Admin" + set category = "Admin.Game" if(holder) var/list/jobs = list() for (var/datum/job/J in job_master.occupations) @@ -508,7 +477,7 @@ /client/proc/toggleghostwriters() set name = "Toggle ghost writers" - set category = "Server" + set category = "Server.Game" if(!holder) return if(config) CONFIG_SET(flag/cult_ghostwriter, !CONFIG_GET(flag/cult_ghostwriter)) @@ -516,14 +485,14 @@ /client/proc/toggledrones() set name = "Toggle maintenance drones" - set category = "Server" + set category = "Server.Game" if(!holder) return if(config) CONFIG_SET(flag/allow_drone_spawn, !CONFIG_GET(flag/allow_drone_spawn)) message_admins("Admin [key_name_admin(usr)] has [CONFIG_GET(flag/allow_drone_spawn) ? "en" : "dis"]abled maintenance drones.", 1) /client/proc/man_up(mob/T as mob in mob_list) - set category = "Fun" + set category = "Fun.Do Not" set name = "Man Up" set desc = "Tells mob to man up and deal with it." set popup_menu = FALSE //VOREStation Edit - Declutter. @@ -537,7 +506,7 @@ message_admins(span_blue("[key_name_admin(usr)] told [key_name(T)] to man up and deal with it."), 1) /client/proc/global_man_up() - set category = "Fun" + set category = "Fun.Do Not" set name = "Man Up Global" set desc = "Tells everyone to man up and deal with it." @@ -551,7 +520,7 @@ message_admins(span_blue("[key_name_admin(usr)] told everyone to man up and deal with it."), 1) /client/proc/give_spell(mob/T as mob in mob_list) // -- Urist - set category = "Fun" + set category = "Fun.Event Kit" set name = "Give Spell" set desc = "Gives a spell to a mob." var/spell/S = tgui_input_list(usr, "Choose the spell to give to that guy", "ABRAKADABRA", spells) @@ -563,6 +532,6 @@ /client/proc/debugstatpanel() set name = "Debug Stat Panel" - set category = "Debug" + set category = "Debug.Misc" src.stat_panel.send_message("create_debug") diff --git a/code/modules/admin/admin_verbs_vr.dm b/code/modules/admin/admin_verbs_vr.dm index d6552d1e560..a04c4bddbdf 100644 --- a/code/modules/admin/admin_verbs_vr.dm +++ b/code/modules/admin/admin_verbs_vr.dm @@ -1,5 +1,5 @@ /client/proc/adminorbit() - set category = "Fun" + set category = "Fun.Event Kit" set name = "Orbit Things" set desc = "Makes something orbit around something else." set popup_menu = FALSE @@ -57,7 +57,7 @@ /client/proc/removetickets() set name = "Security Tickets" - set category = "Admin" + set category = "Admin.Investigate" set desc = "Allows one to remove tickets from the global list." if(!check_rights(R_ADMIN)) @@ -77,7 +77,7 @@ /client/proc/delbook() set name = "Delete Book" set desc = "Permamently deletes a book from the database." - set category = "Admin" + set category = "Admin.Game" if(!src.holder) to_chat(src, "Only administrators may use this command.") return @@ -124,7 +124,7 @@ /client/proc/toggle_spawning_with_recolour() set name = "Toggle Simple/Robot recolour verb" set desc = "Makes it so new robots/simple_mobs spawn with a verb to recolour themselves for this round. You must set them separately." - set category = "Server" + set category = "Server.Game" if(!check_rights(R_ADMIN|R_EVENT|R_FUN)) return diff --git a/code/modules/admin/admin_vr.dm b/code/modules/admin/admin_vr.dm index e40db3f525a..9076957fa65 100644 --- a/code/modules/admin/admin_vr.dm +++ b/code/modules/admin/admin_vr.dm @@ -1,5 +1,5 @@ /datum/admins/proc/set_uplink(mob/living/carbon/human/H as mob) - set category = "Debug" + set category = "Debug.Events" set name = "Set Uplink" set desc = "Allows admins to set up an uplink on a character. This will be required for a character to use telecrystals." set popup_menu = FALSE @@ -11,4 +11,4 @@ var/msg = "[key_name(usr)] has given [H.ckey] an uplink." message_admins(msg) else - to_chat(usr, "You do not have access to this command.") \ No newline at end of file + to_chat(usr, "You do not have access to this command.") diff --git a/code/modules/admin/callproc/callproc.dm b/code/modules/admin/callproc/callproc.dm index 3400098afe7..f1bb2833fb9 100644 --- a/code/modules/admin/callproc/callproc.dm +++ b/code/modules/admin/callproc/callproc.dm @@ -1,5 +1,5 @@ /client/proc/callproc() - set category = "Debug" + set category = "Debug.Events" set name = "Advanced ProcCall" set waitfor = 0 @@ -131,7 +131,7 @@ GLOBAL_PROTECT(AdminProcCallSpamPrevention) #endif /client/proc/callproc_datum(datum/A as null|area|mob|obj|turf) - set category = "Debug" + set category = "Debug.Events" set name = "Atom ProcCall" set waitfor = 0 diff --git a/code/modules/admin/ckey_vr.dm b/code/modules/admin/ckey_vr.dm index 1ae417a1c18..f0801e8b78e 100644 --- a/code/modules/admin/ckey_vr.dm +++ b/code/modules/admin/ckey_vr.dm @@ -1,6 +1,6 @@ // Command to set the ckey of a mob without requiring VV permission /client/proc/SetCKey(var/mob/M in mob_list) - set category = "Admin" + set category = "Admin.Game" set name = "Set CKey" set desc = "Mob to teleport" if(!src.holder) diff --git a/code/modules/admin/holder2.dm b/code/modules/admin/holder2.dm index 9c8f05ceea6..2727ec15bee 100644 --- a/code/modules/admin/holder2.dm +++ b/code/modules/admin/holder2.dm @@ -118,7 +118,7 @@ NOTE: It checks usr by default. Supply the "user" argument if you wish to check vv_update_display(D, "marked", VV_MSG_MARKED) /client/proc/mark_datum_mapview(datum/D as mob|obj|turf|area in view(view)) - set category = "Debug" + set category = "Debug.Game" set name = "Mark Object" mark_datum(D) diff --git a/code/modules/admin/map_capture.dm b/code/modules/admin/map_capture.dm index 431ec7f637f..e1573358297 100644 --- a/code/modules/admin/map_capture.dm +++ b/code/modules/admin/map_capture.dm @@ -1,5 +1,5 @@ /datum/admins/proc/capture_map(tx as null|num, ty as null|num, tz as null|num, range as null|num) - set category = "Server" + set category = "Server.Game" set name = "Capture Map Part" set desc = "Usage: Capture-Map-Part target_x_cord target_y_cord target_z_cord range (captures part of a map originating from bottom left corner)" diff --git a/code/modules/admin/modify_robot.dm b/code/modules/admin/modify_robot.dm index 9166f3be293..f2847943f35 100644 --- a/code/modules/admin/modify_robot.dm +++ b/code/modules/admin/modify_robot.dm @@ -89,6 +89,13 @@ .["target"]["components"] = get_components() .["cell"] = list("name" = target.cell?.name, "charge" = target.cell?.charge, "maxcharge" = target.cell?.maxcharge) .["cell_options"] = get_cells() + .["camera_options"] = get_component("camera") + .["radio_options"] = get_component("radio") + .["actuator_options"] = get_component("actuator") + .["diagnosis_options"] = get_component("diagnosis") + .["comms_options"] = get_component("comms") + .["armour_options"] = get_component("armour") + .["current_gear"] = get_gear() // Access .["id_icon"] = icon2html(target.idcard, user, sourceonly=TRUE) var/list/active_access = list() @@ -198,7 +205,7 @@ target.module.contents.Add(add_item) spawn(0) SEND_SIGNAL(add_item, COMSIG_OBSERVER_MOVED) - target.hud_used.update_robot_modules_display() + target.hud_used?.update_robot_modules_display() if(istype(add_item, /obj/item/stack/)) var/obj/item/stack/item_with_synth = add_item for(var/synth in item_with_synth.synths) @@ -243,7 +250,7 @@ if("rem_module") var/obj/item/rem_item = locate(params["module"]) target.uneq_all() - target.hud_used.update_robot_modules_display(TRUE) + target.hud_used?.update_robot_modules_display(TRUE) target.module.emag.Remove(rem_item) target.module.modules.Remove(rem_item) target.module.contents.Remove(rem_item) @@ -262,14 +269,14 @@ source.emag_items = 1 // Target target.uneq_all() - target.hud_used.update_robot_modules_display(TRUE) + target.hud_used?.update_robot_modules_display(TRUE) qdel(target.module) target.modtype = mod_type module_type = robot_modules[mod_type] target.transform_with_anim() new module_type(target) target.hands.icon_state = target.get_hud_module_icon() - target.hud_used.update_robot_modules_display() + target.hud_used?.update_robot_modules_display() return TRUE if("ert_toggle") target.crisis_override = !target.crisis_override @@ -299,7 +306,7 @@ if(!U.action(target)) return FALSE U.loc = target - target.hud_used.update_robot_modules_display() + target.hud_used?.update_robot_modules_display() return TRUE if("install_modkit") var/new_modkit = text2path(params["modkit"]) @@ -348,22 +355,34 @@ var/datum/robot_component/C = locate(params["component"]) if(C.wrapped) qdel(C.wrapped) + var/new_component = text2path(params["new_part"]) if(istype(C, /datum/robot_component/actuator)) - C.wrapped = new /obj/item/robot_parts/robot_component/actuator(target) + if(!new_component) + new_component = /obj/item/robot_parts/robot_component/actuator + C.wrapped = new new_component(target) else if(istype(C, /datum/robot_component/radio)) - C.wrapped = new /obj/item/robot_parts/robot_component/radio(target) + if(!new_component) + new_component = /obj/item/robot_parts/robot_component/radio + C.wrapped = new new_component(target) else if(istype(C, /datum/robot_component/cell)) - var/new_cell = text2path(params["cell"]) - target.cell = new new_cell(target) + target.cell = new new_component(target) C.wrapped = target.cell else if(istype(C, /datum/robot_component/diagnosis_unit)) - C.wrapped = new /obj/item/robot_parts/robot_component/diagnosis_unit(target) + if(!new_component) + new_component = /obj/item/robot_parts/robot_component/diagnosis_unit + C.wrapped = new new_component(target) else if(istype(C, /datum/robot_component/camera)) - C.wrapped = new /obj/item/robot_parts/robot_component/camera(target) + if(!new_component) + new_component = /obj/item/robot_parts/robot_component/camera + C.wrapped = new new_component(target) else if(istype(C, /datum/robot_component/binary_communication)) - C.wrapped = new /obj/item/robot_parts/robot_component/binary_communication_device(target) + if(!new_component) + new_component = /obj/item/robot_parts/robot_component/binary_communication_device + C.wrapped = new new_component(target) else if(istype(C, /datum/robot_component/armour)) - C.wrapped = new /obj/item/robot_parts/robot_component/armour(target) + if(!new_component) + new_component = /obj/item/robot_parts/robot_component/armour + C.wrapped = new new_component(target) C.brute_damage = 0 C.electronics_damage = 0 C.install() @@ -533,7 +552,7 @@ target.clear_inherent_laws() target.laws = new global.using_map.default_law_type target.laws.show_laws(target) - target.hud_used.update_robot_modules_display() + target.hud_used?.update_robot_modules_display() else target.emagged = 1 target.lawupdate = 0 @@ -545,7 +564,7 @@ if(!target.bolt.malfunction) target.bolt.malfunction = MALFUNCTION_PERMANENT target.laws.show_laws(target) - target.hud_used.update_robot_modules_display() + target.hud_used?.update_robot_modules_display() return TRUE /datum/eventkit/modify_robot/proc/get_target_items(var/mob/user) @@ -672,14 +691,59 @@ continue if(cell_options[initial(C.name)]) // empty cells are defined after normal cells! continue - cell_options += list(initial(C.name) = list("path" = "[C]", "charge" = initial(C.maxcharge), "max_charge" = initial(C.maxcharge), "charge_amount" = initial(C.charge_amount) , "self_charge" = initial(C.self_recharge))) // our cells do not have their charge predefined, they do it on init, so both maaxcharge for now + cell_options += list(initial(C.name) = list("path" = "[C]", "charge" = initial(C.maxcharge), "max_charge" = initial(C.maxcharge), "charge_amount" = initial(C.charge_amount) , "self_charge" = initial(C.self_recharge), "max_damage" = initial(C.robot_durability))) // our cells do not have their charge predefined, they do it on init, so both maaxcharge for now return cell_options +/datum/eventkit/modify_robot/proc/get_component(var/type) + var/path + switch(type) + if("camera") + path = /obj/item/robot_parts/robot_component/camera + if("radio") + path = /obj/item/robot_parts/robot_component/radio + if("actuator") + path = /obj/item/robot_parts/robot_component/actuator + if("diagnosis") + path = /obj/item/robot_parts/robot_component/diagnosis_unit + if("comms") + path = /obj/item/robot_parts/robot_component/binary_communication_device + if("armour") + path = /obj/item/robot_parts/robot_component/armour + if(!path) + return + var/list/components = list() + for(var/component in typesof(path)) + var/obj/item/robot_parts/robot_component/C = component + components += list("[initial(C.name)]" = list("path" = "[component]", "idle_usage" = "[C.idle_usage]", "active_usage" = "[C.active_usage]", "max_damage" = "[C.max_damage]")) + return components + +/datum/eventkit/modify_robot/proc/get_gear() + var/list/equip = list() + for (var/V in target.components) + var/datum/robot_component/C = target.components[V] + var/component_name + if(istype(C.wrapped, /obj/item/robot_parts/robot_component)) + component_name = C.wrapped?.name + switch(V) + if("actuator") + equip += list("[lowertext(C.name)]" = "[component_name]") + if("radio") + equip += list("[lowertext(C.name)]" = "[component_name]") + if("diagnosis unit") + equip += list("[lowertext(C.name)]" = "[component_name]") + if("camera") + equip += list("[lowertext(C.name)]" = "[component_name]") + if("comms") + equip += list("[lowertext(C.name)]" = "[component_name]") + if("armour") + equip += list("[lowertext(C.name)]" = "[component_name]") + return equip + /datum/eventkit/modify_robot/proc/get_components() var/list/components = list() for(var/entry in target.components) var/datum/robot_component/C = target.components[entry] - components += list(list("name" = C.name, "ref" = "\ref[C]", "brute_damage" = C.brute_damage, "electronics_damage" = C.electronics_damage, "max_damage" = C.max_damage, "installed" = C.installed, "exists" = (C.wrapped ? TRUE : FALSE))) + components += list(list("name" = C.name, "ref" = "\ref[C]", "brute_damage" = C.brute_damage, "electronics_damage" = C.electronics_damage, "max_damage" = C.max_damage, "idle_usage" = C.idle_usage, "active_usage" = C.active_usage, "installed" = C.installed, "exists" = (C.wrapped ? TRUE : FALSE))) return components /datum/eventkit/modify_robot/proc/package_laws(var/list/data, var/field, var/list/datum/ai_law/laws) diff --git a/code/modules/admin/news.dm b/code/modules/admin/news.dm index c0812b818e5..30defc11c29 100644 --- a/code/modules/admin/news.dm +++ b/code/modules/admin/news.dm @@ -13,7 +13,7 @@ /client/proc/modify_server_news() set name = "Modify Public News" - set category = "Server" + set category = "Server.Game" if(!check_rights(0)) return @@ -118,4 +118,4 @@ text = replacetext(text, "", "\[sglogo\]") return text -#undef NEWSFILE \ No newline at end of file +#undef NEWSFILE diff --git a/code/modules/admin/permissionverbs/permissionedit.dm b/code/modules/admin/permissionverbs/permissionedit.dm index d94aec94bde..34adf5c3abe 100644 --- a/code/modules/admin/permissionverbs/permissionedit.dm +++ b/code/modules/admin/permissionverbs/permissionedit.dm @@ -1,5 +1,5 @@ /client/proc/edit_admin_permissions() - set category = "Admin" + set category = "Admin.Secrets" set name = "Permissions Panel" set desc = "Edit admin permissions" if(!check_rights(R_PERMISSIONS)) return diff --git a/code/modules/admin/persistence.dm b/code/modules/admin/persistence.dm index 8405f8d101f..79a93b8c0f1 100644 --- a/code/modules/admin/persistence.dm +++ b/code/modules/admin/persistence.dm @@ -1,6 +1,6 @@ /datum/admins/proc/view_persistent_data() - set category = "Admin" + set category = "Admin.Game" set name = "View Persistent Data" set desc = "Shows a list of persistent data for this round. Allows modification by admins." - SSpersistence.show_info(usr) \ No newline at end of file + SSpersistence.show_info(usr) diff --git a/code/modules/admin/player_effects.dm b/code/modules/admin/player_effects.dm index e5c7457edf8..921795beb73 100644 --- a/code/modules/admin/player_effects.dm +++ b/code/modules/admin/player_effects.dm @@ -339,6 +339,32 @@ M.forceMove(new_mob) new_mob.tf_mob_holder = M + if("item_tf") + var/mob/living/M = target + + if(!istype(M)) + return + + if(!M.ckey) + return + + var/obj/item/spawning = user.client.get_path_from_partial_text() + + to_chat(user,span_warning("spawning is: [spawning]")) + + if(!ispath(spawning, /obj/item/)) + to_chat(user,span_warning("Can only spawn items.")) + return + + var/obj/item/spawned_obj = new spawning(M.loc) + var/obj/item/original_name = spawned_obj.name + spawned_obj.inhabit_item(M, original_name, M) + var/mob/living/possessed_voice = spawned_obj.possessed_voice + spawned_obj.trash_eatable = M.devourable + spawned_obj.unacidable = !M.digestable + M.forceMove(possessed_voice) + + ////////MEDICAL////////////// if("appendicitis") diff --git a/code/modules/admin/verbs/SDQL2/SDQL_2.dm b/code/modules/admin/verbs/SDQL2/SDQL_2.dm index 86ff00b5337..dc8d8ae15f9 100644 --- a/code/modules/admin/verbs/SDQL2/SDQL_2.dm +++ b/code/modules/admin/verbs/SDQL2/SDQL_2.dm @@ -188,7 +188,7 @@ Example: USING PROCCALL = BLOCKING, SELECT = FORCE_NULLS, PRIORITY = HIGH SELECT CRASH("SDQL2 fatal error");}; /client/proc/SDQL2_query(query_text as message) - set category = "Debug" + set category = "Debug.Misc" if(!check_rights(R_DEBUG)) //Shouldn't happen... but just to be safe. message_admins(span_danger("ERROR: Non-admin [key_name(usr)] attempted to execute a SDQL query!")) log_admin("Non-admin [key_name(usr)] attempted to execute a SDQL query!") diff --git a/code/modules/admin/verbs/adminhelp.dm b/code/modules/admin/verbs/adminhelp.dm index 6c3da08252c..d543c9e64c5 100644 --- a/code/modules/admin/verbs/adminhelp.dm +++ b/code/modules/admin/verbs/adminhelp.dm @@ -639,7 +639,7 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new) //admin proc /client/proc/cmd_admin_ticket_panel() set name = "Show Ticket List" - set category = "Admin" + set category = "Admin.Misc" if(!check_rights(R_ADMIN|R_MOD|R_DEBUG|R_EVENT, TRUE)) return diff --git a/code/modules/admin/verbs/adminjump.dm b/code/modules/admin/verbs/adminjump.dm index 7b902c675da..aead36bbc74 100644 --- a/code/modules/admin/verbs/adminjump.dm +++ b/code/modules/admin/verbs/adminjump.dm @@ -7,7 +7,7 @@ /client/proc/Jump(areaname as null|anything in return_sorted_areas()) set name = "Jump to Area" set desc = "Area to jump to" - set category = "Admin" + set category = "Admin.Game" if(!check_rights(R_ADMIN|R_MOD|R_DEBUG|R_EVENT)) return @@ -33,7 +33,7 @@ /client/proc/jumptoturf(var/turf/T in world) set name = "Jump to Turf" - set category = "Admin" + set category = "Admin.Game" if(!check_rights(R_ADMIN|R_MOD|R_DEBUG|R_EVENT)) return if(CONFIG_GET(flag/allow_admin_jump)) @@ -48,7 +48,7 @@ /// Verb wrapper around do_jumptomob() /client/proc/jumptomob(mob as null|anything in mob_list) - set category = "Admin" + set category = "Admin.Game" set name = "Jump to Mob" set popup_menu = FALSE //VOREStation Edit - Declutter. @@ -80,7 +80,7 @@ to_chat(A, span_filter_adminlog("This mob is not located in the game world.")) /client/proc/jumptocoord(tx as num, ty as num, tz as num) - set category = "Admin" + set category = "Admin.Game" set name = "Jump to Coordinate" if(!check_rights(R_ADMIN|R_MOD|R_DEBUG|R_EVENT)) @@ -102,7 +102,7 @@ tgui_alert_async(usr, "Admin jumping disabled") /client/proc/jumptokey() - set category = "Admin" + set category = "Admin.Game" set name = "Jump to Key" if(!check_rights(R_ADMIN|R_MOD|R_DEBUG|R_EVENT)) @@ -125,7 +125,7 @@ tgui_alert_async(usr, "Admin jumping disabled") /client/proc/Getmob(mob/living/M as null|anything in mob_list) //VOREStation Edit - set category = "Admin" + set category = "Admin.Game" set name = "Get Mob" set desc = "Mob to teleport" set popup_menu = TRUE //VOREStation Edit @@ -148,7 +148,7 @@ tgui_alert_async(usr, "Admin jumping disabled") /client/proc/Getkey() - set category = "Admin" + set category = "Admin.Game" set name = "Get Key" set desc = "Key to teleport" @@ -178,7 +178,7 @@ tgui_alert_async(usr, "Admin jumping disabled") /client/proc/sendmob() - set category = "Admin" + set category = "Admin.Game" set name = "Send Mob" if(!check_rights(R_ADMIN|R_MOD|R_DEBUG|R_EVENT)) return @@ -202,7 +202,7 @@ tgui_alert_async(usr, "Admin jumping disabled") /client/proc/cmd_admin_move_atom(var/atom/movable/AM, tx as num, ty as num, tz as num) - set category = "Admin" + set category = "Admin.Game" set name = "Move Atom to Coordinate" if(!check_rights(R_ADMIN|R_DEBUG|R_EVENT)) diff --git a/code/modules/admin/verbs/adminsay.dm b/code/modules/admin/verbs/adminsay.dm index 9c9dff4c7bb..911ad029e8a 100644 --- a/code/modules/admin/verbs/adminsay.dm +++ b/code/modules/admin/verbs/adminsay.dm @@ -1,5 +1,5 @@ /client/proc/cmd_admin_say(msg as text) - set category = "Special Verbs" + set category = "Admin.Chat" set name = "Asay" //Gave this shit a shorter name so you only have to time out "asay" rather than "admin say" to use it --NeoFite set hidden = 1 if(!check_rights(R_ADMIN)) //VOREStation Edit @@ -18,7 +18,7 @@ feedback_add_details("admin_verb","M") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_mod_say(msg as text) - set category = "Special Verbs" + set category = "Admin.Chat" set name = "Msay" set hidden = 1 @@ -41,7 +41,7 @@ feedback_add_details("admin_verb","MS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_event_say(msg as text) - set category = "Special Verbs" + set category = "Admin.Chat" set name = "Esay" set hidden = 1 diff --git a/code/modules/admin/verbs/antag-ooc.dm b/code/modules/admin/verbs/antag-ooc.dm index 59f21a15aee..0d2b6e4fe8b 100644 --- a/code/modules/admin/verbs/antag-ooc.dm +++ b/code/modules/admin/verbs/antag-ooc.dm @@ -1,5 +1,5 @@ /client/proc/aooc(msg as text) - set category = "OOC" + set category = "OOC.Chat" set name = "AOOC" set desc = "Antagonist OOC" diff --git a/code/modules/admin/verbs/change_appearance.dm b/code/modules/admin/verbs/change_appearance.dm index c27b658503c..ed0f3266f20 100644 --- a/code/modules/admin/verbs/change_appearance.dm +++ b/code/modules/admin/verbs/change_appearance.dm @@ -1,7 +1,7 @@ /client/proc/change_human_appearance_admin() set name = "Change Mob Appearance - Admin" set desc = "Allows you to change the mob appearance" - set category = "Admin" + set category = "Admin.Events" if(!check_rights(R_FUN)) return @@ -15,7 +15,7 @@ /client/proc/change_human_appearance_self() set name = "Change Mob Appearance - Self" set desc = "Allows the mob to change its appearance" - set category = "Admin" + set category = "Admin.Events" if(!check_rights(R_FUN)) return @@ -37,7 +37,7 @@ /client/proc/editappear() set name = "Edit Appearance" - set category = "Fun" + set category = "Fun.Event Kit" if(!check_rights(R_FUN)) return diff --git a/code/modules/admin/verbs/check_customitem_activity.dm b/code/modules/admin/verbs/check_customitem_activity.dm index cb3bfa45dc2..796a48368dc 100644 --- a/code/modules/admin/verbs/check_customitem_activity.dm +++ b/code/modules/admin/verbs/check_customitem_activity.dm @@ -2,7 +2,7 @@ var/checked_for_inactives = 0 var/inactive_keys = "None
" /client/proc/check_customitem_activity() - set category = "Admin" + set category = "Admin.Investigate" set name = "Check activity of players with custom items" var/dat = span_bold("Inactive players with custom items") + "
" diff --git a/code/modules/admin/verbs/cinematic.dm b/code/modules/admin/verbs/cinematic.dm index 4b370a925be..db6e44be73e 100644 --- a/code/modules/admin/verbs/cinematic.dm +++ b/code/modules/admin/verbs/cinematic.dm @@ -1,6 +1,6 @@ /client/proc/cinematic(var/cinematic as anything in list("explosion",null)) set name = "Cinematic" - set category = "Fun" + set category = "Fun.Do Not" set desc = "Shows a cinematic." // Intended for testing but I thought it might be nice for events on the rare occasion Feel free to comment it out if it's not wanted. if(!check_rights(R_FUN)) diff --git a/code/modules/admin/verbs/custom_event.dm b/code/modules/admin/verbs/custom_event.dm index ef0b32bb8b3..dc699dfa573 100644 --- a/code/modules/admin/verbs/custom_event.dm +++ b/code/modules/admin/verbs/custom_event.dm @@ -1,6 +1,6 @@ // verb for admins to set custom event /client/proc/cmd_admin_change_custom_event() - set category = "Fun" + set category = "Fun.Event Kit" set name = "Change Custom Event" if(!holder) @@ -33,7 +33,7 @@ // normal verb for players to view info /client/verb/cmd_view_custom_event() - set category = "OOC" + set category = "OOC.Game" set name = "Custom Event Info" if(!custom_event_msg || custom_event_msg == "") diff --git a/code/modules/admin/verbs/deadsay.dm b/code/modules/admin/verbs/deadsay.dm index 20334999b36..24ad107d411 100644 --- a/code/modules/admin/verbs/deadsay.dm +++ b/code/modules/admin/verbs/deadsay.dm @@ -1,5 +1,5 @@ /client/proc/dsay(msg as text) - set category = "Special Verbs" + set category = "Admin.Chat" set name = "Dsay" //Gave this shit a shorter name so you only have to time out "dsay" rather than "dead say" to use it --NeoFite set hidden = 1 if(!src.holder) diff --git a/code/modules/admin/verbs/debug.dm b/code/modules/admin/verbs/debug.dm index 685e1fd1757..18ff612d9ad 100644 --- a/code/modules/admin/verbs/debug.dm +++ b/code/modules/admin/verbs/debug.dm @@ -1,5 +1,5 @@ /client/proc/Debug2() - set category = "Debug" + set category = "Debug.Investigate" set name = "Debug-Game" if(!check_rights(R_DEBUG)) return @@ -18,7 +18,7 @@ /client/proc/simple_DPS() set name = "Simple DPS" - set category = "Debug" + set category = "Debug.Investigate" set desc = "Gives a really basic idea of how much hurt something in-hand does." var/obj/item/I = null @@ -73,7 +73,7 @@ return /client/proc/Cell() - set category = "Debug" + set category = "Debug.Investigate" set name = "Cell" if(!mob) return @@ -94,7 +94,7 @@ feedback_add_details("admin_verb","ASL") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_admin_robotize(var/mob/M in mob_list) - set category = "Fun" + set category = "Fun.Event Kit" set name = "Make Robot" if(!ticker) @@ -109,7 +109,7 @@ tgui_alert_async(usr, "Invalid mob") /client/proc/cmd_admin_animalize(var/mob/M in mob_list) - set category = "Fun" + set category = "Fun.Event Kit" set name = "Make Simple Animal" if(!ticker) @@ -130,7 +130,7 @@ /client/proc/makepAI() - set category = "Fun" + set category = "Fun.Event Kit" set name = "Make pAI" set desc = "Spawn someone in as a pAI!" if(!check_rights(R_ADMIN|R_EVENT|R_DEBUG)) @@ -161,7 +161,7 @@ feedback_add_details("admin_verb","MPAI") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_admin_alienize(var/mob/M in mob_list) - set category = "Fun" + set category = "Fun.Event Kit" set name = "Make Alien" if(!ticker) @@ -180,7 +180,7 @@ //TODO: merge the vievars version into this or something maybe mayhaps /client/proc/cmd_debug_del_all() - set category = "Debug" + set category = "Debug.Dangerous" set name = "Del-All" // to prevent REALLY stupid deletions @@ -195,7 +195,7 @@ feedback_add_details("admin_verb","DELA") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_debug_make_powernets() - set category = "Debug" + set category = "Debug.Dangerous" set name = "Make Powernets" SSmachines.makepowernets() log_admin("[key_name(src)] has remade the powernet. SSmachines.makepowernets() called.") @@ -203,7 +203,7 @@ feedback_add_details("admin_verb","MPWN") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_debug_tog_aliens() - set category = "Server" + set category = "Server.Game" set name = "Toggle Aliens" CONFIG_SET(flag/aliens_allowed, !CONFIG_GET(flag/aliens_allowed)) @@ -212,7 +212,7 @@ feedback_add_details("admin_verb","TAL") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_display_del_log() - set category = "Debug" + set category = "Debug.Investigate" set name = "Display del() Log" set desc = "Display del's log of everything that's passed through it." @@ -242,7 +242,7 @@ usr << browse(dellog.Join(), "window=dellog") /client/proc/cmd_display_init_log() - set category = "Debug" + set category = "Debug.Investigate" set name = "Display Initialize() Log" set desc = "Displays a list of things that didn't handle Initialize() properly" @@ -251,7 +251,7 @@ /* /client/proc/cmd_display_overlay_log() - set category = "Debug" + set category = "Debug.Investigate" set name = "Display overlay Log" set desc = "Display SSoverlays log of everything that's passed through it." @@ -273,7 +273,7 @@ . = lines.Join("\n") /client/proc/cmd_admin_grantfullaccess(var/mob/M in mob_list) - set category = "Admin" + set category = "Admin.Events" set name = "Grant Full Access" if (!ticker) @@ -304,7 +304,7 @@ message_admins(span_blue("[key_name_admin(usr)] has granted [M.key] full access."), 1) /client/proc/cmd_assume_direct_control(var/mob/M in mob_list) - set category = "Admin" + set category = "Admin.Game" set name = "Assume direct control" set desc = "Direct intervention" @@ -325,7 +325,7 @@ /client/proc/take_picture(var/atom/A in world) set name = "Save PNG" - set category = "Debug" + set category = "Debug.Misc" set desc = "Opens a dialog to save a PNG of any object in the game." if(!check_rights(R_DEBUG)) @@ -422,7 +422,7 @@ to_world("* [areatype]") /datum/admins/proc/cmd_admin_dress(input in getmobs()) - set category = "Fun" + set category = "Fun.Event Kit" set name = "Select equipment" if(!check_rights(R_FUN)) @@ -454,7 +454,7 @@ /client/proc/startSinglo() - set category = "Debug" + set category = "Debug.Game" set name = "Start Singularity" set desc = "Sets up the singularity and all machines to get power flowing through the station" @@ -498,7 +498,7 @@ Rad.toggle_power() /client/proc/setup_supermatter_engine() - set category = "Debug" + set category = "Debug.Game" set name = "Setup supermatter" set desc = "Sets up the supermatter engine" @@ -581,7 +581,7 @@ /client/proc/cmd_debug_mob_lists() - set category = "Debug" + set category = "Debug.Investigate" set name = "Debug Mob Lists" set desc = "For when you just gotta know" @@ -600,7 +600,7 @@ to_chat(usr, span_filter_debuglogs(jointext(GLOB.clients,","))) /client/proc/cmd_debug_using_map() - set category = "Debug" + set category = "Debug.Investigate" set name = "Debug Map Datum" set desc = "Debug the map metadata about the currently compiled in map." @@ -625,7 +625,7 @@ tgui_alert_async(usr, "Invalid mob") /datum/admins/proc/view_runtimes() - set category = "Debug" + set category = "Debug.Investigate" set name = "View Runtimes" set desc = "Open the Runtime Viewer" @@ -635,7 +635,7 @@ error_cache.showTo(usr) /datum/admins/proc/change_weather() - set category = "Debug" + set category = "Debug.Events" set name = "Change Weather" set desc = "Changes the current weather." @@ -653,7 +653,7 @@ log_admin(log) /datum/admins/proc/toggle_firework_override() - set category = "Fun" + set category = "Fun.Event Kit" set name = "Toggle Weather Firework Override" set desc = "Toggles ability for weather fireworks to affect weather on planet of choice." @@ -668,7 +668,7 @@ log_admin(log) /datum/admins/proc/change_time() - set category = "Debug" + set category = "Debug.Events" set name = "Change Planet Time" set desc = "Changes the time of a planet." diff --git a/code/modules/admin/verbs/debug_vr.dm b/code/modules/admin/verbs/debug_vr.dm index 051bbf64924..60e5c5d6366 100644 --- a/code/modules/admin/verbs/debug_vr.dm +++ b/code/modules/admin/verbs/debug_vr.dm @@ -1,5 +1,5 @@ /datum/admins/proc/quick_nif() - set category = "Fun" + set category = "Fun.Add Nif" set name = "Quick NIF" set desc = "Spawns a NIF into someone in quick-implant mode." diff --git a/code/modules/admin/verbs/diagnostics.dm b/code/modules/admin/verbs/diagnostics.dm index 1ce73a7f742..63b18ab07b8 100644 --- a/code/modules/admin/verbs/diagnostics.dm +++ b/code/modules/admin/verbs/diagnostics.dm @@ -1,5 +1,5 @@ /client/proc/air_report() - set category = "Debug" + set category = "Debug.Investigate" set name = "Show Air Report" if(!master_controller || !air_master) @@ -42,7 +42,7 @@ usr << browse(output,"window=airreport") /client/proc/fix_next_move() - set category = "Debug" + set category = "Debug.Game" set name = "Unfreeze Everyone" var/largest_move_time = 0 var/largest_click_time = 0 @@ -73,7 +73,7 @@ return /client/proc/radio_report() - set category = "Debug" + set category = "Debug.Game" set name = "Radio report" var/output = "Radio Report
" @@ -100,7 +100,7 @@ /client/proc/reload_admins() set name = "Reload Admins" - set category = "Debug" + set category = "Debug.Server" if(!check_rights(R_SERVER)) return @@ -110,7 +110,7 @@ /client/proc/reload_eventMs() set name = "Reload Event Managers" - set category = "Debug" + set category = "Debug.Server" if(!check_rights(R_SERVER)) return @@ -121,7 +121,7 @@ //todo: /client/proc/jump_to_dead_group() set name = "Jump to dead group" - set category = "Debug" + set category = "Debug.Game" /* if(!holder) to_chat(src, "Only administrators may use this command.") @@ -143,7 +143,7 @@ /client/proc/kill_airgroup() set name = "Kill Local Airgroup" set desc = "Use this to allow manual manupliation of atmospherics." - set category = "Debug" + set category = "Debug.Dangerous" /* if(!holder) to_chat(src, "Only administrators may use this command.") @@ -166,7 +166,7 @@ /client/proc/print_jobban_old() set name = "Print Jobban Log" set desc = "This spams all the active jobban entries for the current round to standard output." - set category = "Debug" + set category = "Debug.Investigate" to_chat(usr, span_bold("Jobbans active in this round.")) for(var/t in jobban_keylist) @@ -175,7 +175,7 @@ /client/proc/print_jobban_old_filter() set name = "Search Jobban Log" set desc = "This searches all the active jobban entries for the current round and outputs the results to standard output." - set category = "Debug" + set category = "Debug.Investigate" var/job_filter = tgui_input_text(usr, "Contains what?","Job Filter") if(!job_filter) diff --git a/code/modules/admin/verbs/dice.dm b/code/modules/admin/verbs/dice.dm index cc21521859d..09e171eafd4 100644 --- a/code/modules/admin/verbs/dice.dm +++ b/code/modules/admin/verbs/dice.dm @@ -1,5 +1,5 @@ /client/proc/roll_dices() - set category = "Fun" + set category = "Fun.Event Kit" set name = "Roll Dice" if(!check_rights(R_FUN)) return @@ -21,4 +21,4 @@ if(tgui_alert(usr, "Do you want to inform the world about the result?","Show world?",list("Yes", "No")) == "Yes") to_world("

Gods rolled [dice], result is [result]

") - message_admins("[key_name_admin(src)] rolled dice [dice], result is [result]", 1) \ No newline at end of file + message_admins("[key_name_admin(src)] rolled dice [dice], result is [result]", 1) diff --git a/code/modules/admin/verbs/entity_narrate.dm b/code/modules/admin/verbs/entity_narrate.dm index f88dbb192cd..d8322e93b83 100644 --- a/code/modules/admin/verbs/entity_narrate.dm +++ b/code/modules/admin/verbs/entity_narrate.dm @@ -27,7 +27,7 @@ /client/proc/add_mob_for_narration(E as obj|mob|turf in orange(world.view)) set name = "Narrate Entity (Add ref)" set desc = "Saves a reference of target mob to be called when narrating." - set category = "Fun" + set category = "Fun.Narrate" if(!check_rights(R_FUN)) return @@ -77,7 +77,7 @@ /client/proc/remove_mob_for_narration() set name = "Narrate Entity (Remove ref)" set desc = "Remove mobs you're no longer narrating from your list for easier work." - set category = "Fun" + set category = "Fun.Narrate" if(!check_rights(R_FUN)) return @@ -107,7 +107,7 @@ /client/proc/narrate_mob() set name = "Narrate Entity (Interface)" set desc = "Send either a visible or audiable message through your chosen entities using an interface" - set category = "Fun" + set category = "Fun.Narrate" if(!check_rights(R_FUN)) return @@ -138,7 +138,7 @@ /client/proc/narrate_mob_args(name as text, mode as text, message as text) set name = "Narrate Entity" set desc = "Narrate entities using positional arguments. Name should be as saved in ref list, mode should be Speak or Emote, follow with message" - set category = "Fun" + set category = "Fun.Narrate" diff --git a/code/modules/admin/verbs/event_triggers.dm b/code/modules/admin/verbs/event_triggers.dm index bf7596656ea..fe843855aef 100644 --- a/code/modules/admin/verbs/event_triggers.dm +++ b/code/modules/admin/verbs/event_triggers.dm @@ -4,7 +4,7 @@ Eventkit verb to be used to spawn the obj/effect/landmarks defined under code\ga /client/proc/manage_event_triggers() set name = "Manage Event Triggers" set desc = "Open dialogue to create or delete narration/notification triggers" - set category = "EventKit" + set category = "Fun.Event Kit" if(!check_rights(R_FUN)) return diff --git a/code/modules/admin/verbs/fps.dm b/code/modules/admin/verbs/fps.dm index 76f177535ad..b997c863fe5 100644 --- a/code/modules/admin/verbs/fps.dm +++ b/code/modules/admin/verbs/fps.dm @@ -1,7 +1,7 @@ //Merged Doohl's and the existing ticklag as they both had good elements about them ~ //Replaces the old Ticklag verb, fps is easier to understand /client/proc/set_server_fps() - set category = "Debug" + set category = "Debug.Server" set name = "Set Server FPS" set desc = "Sets game speed in frames-per-second. Can potentially break the game" diff --git a/code/modules/admin/verbs/get_player_status.dm b/code/modules/admin/verbs/get_player_status.dm index b55f5483cf7..2e57317ec95 100644 --- a/code/modules/admin/verbs/get_player_status.dm +++ b/code/modules/admin/verbs/get_player_status.dm @@ -6,7 +6,7 @@ /client/proc/getPlayerStatus() set name = "Report Player Status" set desc = "Get information on all active players in-game." - set category = "EventKit" + set category = "Fun.Event Kit" if(!check_rights(R_FUN)) return diff --git a/code/modules/admin/verbs/getlogs.dm b/code/modules/admin/verbs/getlogs.dm index 236fbef7a6b..d7ad8ed13c4 100644 --- a/code/modules/admin/verbs/getlogs.dm +++ b/code/modules/admin/verbs/getlogs.dm @@ -81,7 +81,7 @@ //Shows today's server log /datum/admins/proc/view_txt_log() - set category = "Admin" + set category = "Admin.Logs" set name = "Show Server Log" set desc = "Shows today's server log." @@ -96,7 +96,7 @@ //Shows today's attack log /datum/admins/proc/view_atk_log() - set category = "Admin" + set category = "Admin.Logs" set name = "Show Server Attack Log" set desc = "Shows today's server attack log." diff --git a/code/modules/admin/verbs/grief_fixers.dm b/code/modules/admin/verbs/grief_fixers.dm index 1dcf54b9bf8..1aa8f349f17 100644 --- a/code/modules/admin/verbs/grief_fixers.dm +++ b/code/modules/admin/verbs/grief_fixers.dm @@ -1,5 +1,5 @@ /client/proc/fixatmos() - set category = "Admin" + set category = "Admin.Game" set name = "Fix Atmospherics Grief" if(!check_rights(R_ADMIN|R_DEBUG|R_EVENT)) return diff --git a/code/modules/admin/verbs/lightning_strike.dm b/code/modules/admin/verbs/lightning_strike.dm index ce500bb9d74..57191c32358 100644 --- a/code/modules/admin/verbs/lightning_strike.dm +++ b/code/modules/admin/verbs/lightning_strike.dm @@ -1,7 +1,7 @@ /client/proc/admin_lightning_strike() set name = "Lightning Strike" set desc = "Causes lightning to strike on your tile. This can be made to hurt things on or nearby it severely." - set category = "Fun" + set category = "Fun.Do Not" if(!check_rights(R_FUN)) return diff --git a/code/modules/admin/verbs/map_template_loadverb.dm b/code/modules/admin/verbs/map_template_loadverb.dm index d49c3ba7398..c9dc93d3ef4 100644 --- a/code/modules/admin/verbs/map_template_loadverb.dm +++ b/code/modules/admin/verbs/map_template_loadverb.dm @@ -1,5 +1,5 @@ /client/proc/map_template_load() - set category = "Debug" + set category = "Debug.Events" set name = "Map template - Place At Loc" var/datum/map_template/template @@ -32,7 +32,7 @@ usr.client.images -= preview /client/proc/map_template_load_on_new_z() - set category = "Debug" + set category = "Debug.Events" set name = "Map template - New Z" var/datum/map_template/template @@ -55,7 +55,7 @@ /client/proc/map_template_upload() - set category = "Debug" + set category = "Debug.Events" set name = "Map Template - Upload" var/map = input(usr, "Choose a Map Template to upload to template storage","Upload Map Template") as null|file diff --git a/code/modules/admin/verbs/mapping.dm b/code/modules/admin/verbs/mapping.dm index c51b131b8e2..22be10769d9 100644 --- a/code/modules/admin/verbs/mapping.dm +++ b/code/modules/admin/verbs/mapping.dm @@ -167,7 +167,7 @@ var/list/debug_verbs = list ( /client/proc/enable_debug_verbs() - set category = "Debug" + set category = "Debug.Misc" set name = "Debug verbs" if(!check_rights(R_DEBUG)) return @@ -177,7 +177,7 @@ var/list/debug_verbs = list ( feedback_add_details("admin_verb","mDV") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/hide_debug_verbs() - set category = "Debug" + set category = "Debug.Misc" set name = "Hide Debug verbs" if(!check_rights(R_DEBUG)) return @@ -209,7 +209,7 @@ var/list/debug_verbs = list ( /client/proc/testZAScolors() - set category = "ZAS" + set category = "Mapping.ZAS" set name = "Check ZAS connections" if(!check_rights(R_DEBUG)) return @@ -258,7 +258,7 @@ var/list/debug_verbs = list ( testZAScolors_turfs += T /client/proc/testZAScolors_remove() - set category = "ZAS" + set category = "Mapping.ZAS" set name = "Remove ZAS connection colors" testZAScolors_turfs.Cut() @@ -270,7 +270,7 @@ var/list/debug_verbs = list ( images.Remove(i) /client/proc/rebootAirMaster() - set category = "ZAS" + set category = "Mapping.ZAS" set name = "Reboot ZAS" if(tgui_alert(usr, "This will destroy and remake all zone geometry on the whole map.","Reboot ZAS",list("Reboot ZAS","Nevermind")) == "Reboot ZAS") diff --git a/code/modules/admin/verbs/modify_robot.dm b/code/modules/admin/verbs/modify_robot.dm index b1531f88903..2524f1b50ba 100644 --- a/code/modules/admin/verbs/modify_robot.dm +++ b/code/modules/admin/verbs/modify_robot.dm @@ -2,7 +2,7 @@ /client/proc/modify_robot(var/mob/living/silicon/robot/target in silicon_mob_list) set name = "Modify Robot Module" set desc = "Allows to add or remove modules to/from robots." - set category = "Admin" + set category = "Admin.Silicon" if(!check_rights(R_ADMIN|R_FUN|R_VAREDIT|R_EVENT)) return @@ -90,8 +90,8 @@ robot.module.contents.Remove(add_item) target.module.modules.Add(add_item) target.module.contents.Add(add_item) - spawn(0) //ChompEDIT Must be after to allow the movement to finish - SEND_SIGNAL(add_item, COMSIG_OBSERVER_MOVED)//ChompEDIT - report the movement since setting loc doesn't call Move or Moved + spawn(0) Must be after to allow the movement to finish + SEND_SIGNAL(add_item, COMSIG_OBSERVER_MOVED) target.hud_used.update_robot_modules_display() to_chat(usr, span_danger("You added \"[add_item]\" to [target].")) if(istype(add_item, /obj/item/stack/)) diff --git a/code/modules/admin/verbs/panicbunker.dm b/code/modules/admin/verbs/panicbunker.dm index f4fdc3612e1..0e736696b12 100644 --- a/code/modules/admin/verbs/panicbunker.dm +++ b/code/modules/admin/verbs/panicbunker.dm @@ -1,5 +1,5 @@ /client/proc/panicbunker() - set category = "Server" + set category = "Server.Config" set name = "Toggle Panic Bunker" if(!check_rights(R_ADMIN)) @@ -17,7 +17,7 @@ feedback_add_details("admin_verb","PANIC") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/paranoia_logging() - set category = "Server" + set category = "Server.Config" set name = "New Player Warnings" if(!check_rights(R_ADMIN)) @@ -31,7 +31,7 @@ feedback_add_details("admin_verb","PARLOG") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/ip_reputation() - set category = "Server" + set category = "Server.Config" set name = "Toggle IP Rep Checks" if(!check_rights(R_ADMIN)) diff --git a/code/modules/admin/verbs/playsound.dm b/code/modules/admin/verbs/playsound.dm index c3b5673442e..4fb01a3b313 100644 --- a/code/modules/admin/verbs/playsound.dm +++ b/code/modules/admin/verbs/playsound.dm @@ -6,7 +6,7 @@ var/list/sounds_cache = list() /client/proc/play_sound(S as sound) - set category = "Fun" + set category = "Fun.Sounds" set name = "Play Global Sound" if(!check_rights(R_SOUNDS)) return @@ -50,7 +50,7 @@ var/list/sounds_cache = list() feedback_add_details("admin_verb", "Play Global Sound") /client/proc/play_local_sound(S as sound) - set category = "Fun" + set category = "Fun.Sounds" set name = "Play Local Sound" if(!check_rights(R_SOUNDS)) return @@ -61,7 +61,7 @@ var/list/sounds_cache = list() feedback_add_details("admin_verb", "Play Local Sound") /client/proc/play_direct_mob_sound(S as sound, mob/M) - set category = "Fun" + set category = "Fun.Sounds" set name = "Play Direct Mob Sound" if(!check_rights(R_SOUNDS)) return @@ -76,7 +76,7 @@ var/list/sounds_cache = list() feedback_add_details("admin_verb", "Play Direct Mob Sound") /client/proc/play_z_sound(S as sound) - set category = "Fun" + set category = "Fun.Sounds" set name = "Play Z Sound" if(!check_rights(R_SOUNDS)) return var/target_z = mob.z @@ -98,7 +98,7 @@ var/list/sounds_cache = list() /client/proc/play_server_sound() - set category = "Fun" + set category = "Fun.Sounds" set name = "Play Server Sound" if(!check_rights(R_SOUNDS)) return @@ -215,7 +215,7 @@ var/list/sounds_cache = list() feedback_add_details("admin_verb", "Play Internet Sound") /client/proc/play_web_sound() - set category = "Fun" + set category = "Fun.Sounds" set name = "Play Internet Sound" if(!check_rights(R_SOUNDS)) return @@ -243,7 +243,7 @@ var/list/sounds_cache = list() web_sound(usr, null) /client/proc/stop_sounds() - set category = "Debug" + set category = "Debug.Dangerous" set name = "Stop All Playing Sounds" if(!src.holder) return @@ -264,8 +264,8 @@ var/list/sounds_cache = list() #undef SHELLEO_STDERR /* -/client/proc/cuban_pete() - set category = "Fun" +/client/proc/cuban_pete()" + set category = "Fun.Sounds" set name = "Cuban Pete Time" message_admins("[key_name_admin(usr)] has declared Cuban Pete Time!", 1) @@ -280,8 +280,8 @@ var/list/sounds_cache = list() CP.gib() -/client/proc/bananaphone() - set category = "Fun" +/client/proc/bananaphone()" + set category = "Fun.Sounds" set name = "Banana Phone" message_admins("[key_name_admin(usr)] has activated Banana Phone!", 1) @@ -291,8 +291,8 @@ var/list/sounds_cache = list() M << 'bananaphone.ogg' -/client/proc/space_asshole() - set category = "Fun" +/client/proc/space_asshole()" + set category = "Fun.Sounds" set name = "Space Asshole" message_admins("[key_name_admin(usr)] has played the Space Asshole Hymn.", 1) @@ -302,8 +302,8 @@ var/list/sounds_cache = list() M << 'sound/music/space_asshole.ogg' -/client/proc/honk_theme() - set category = "Fun" +/client/proc/honk_theme()" + set category = "Fun.Sounds" set name = "Honk" message_admins("[key_name_admin(usr)] has creeped everyone out with Blackest Honks.", 1) diff --git a/code/modules/admin/verbs/pray.dm b/code/modules/admin/verbs/pray.dm index 9b056896a08..a33d77a4054 100644 --- a/code/modules/admin/verbs/pray.dm +++ b/code/modules/admin/verbs/pray.dm @@ -1,5 +1,5 @@ /mob/verb/pray() - set category = "IC" + set category = "IC.Game" set name = "Pray" if(say_disabled) //This is here to try to identify lag problems diff --git a/code/modules/admin/verbs/randomverbs.dm b/code/modules/admin/verbs/randomverbs.dm index 31da1afe1b1..bc0547c4b5a 100644 --- a/code/modules/admin/verbs/randomverbs.dm +++ b/code/modules/admin/verbs/randomverbs.dm @@ -18,7 +18,7 @@ feedback_add_details("admin_verb","DEVR") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_admin_prison(mob/M as mob in mob_list) - set category = "Admin" + set category = "Admin.Game" set name = "Prison" if(!holder) return @@ -46,7 +46,7 @@ //Allows staff to determine who the newer players are. /client/proc/cmd_check_new_players() - set category = "Admin" + set category = "Admin.Investigate" set name = "Check new Players" if(!holder) return @@ -80,7 +80,7 @@ to_chat(src, "No matches for that age range found.") /client/proc/cmd_admin_subtle_message(mob/M as mob in mob_list) - set category = "Special Verbs" + set category = "Admin" set name = "Subtle Message" if(!ismob(M)) return @@ -107,7 +107,7 @@ feedback_add_details("admin_verb","SMS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_admin_world_narrate() // Allows administrators to fluff events a little easier -- TLE - set category = "Special Verbs" + set category = "Fun.Narrate" set name = "Global Narrate" if (!holder) @@ -128,7 +128,7 @@ feedback_add_details("admin_verb","GLN") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_admin_direct_narrate(var/mob/M) // Targetted narrate -- TLE - set category = "Special Verbs" + set category = "Fun.Narrate" set name = "Direct Narrate" if(!holder) @@ -155,7 +155,7 @@ feedback_add_details("admin_verb","DIRN") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_admin_godmode(mob/M as mob in mob_list) - set category = "Special Verbs" + set category = "Admin.Game" set name = "Godmode" if(!holder) @@ -225,7 +225,7 @@ feedback_add_details("admin_verb","MUTE") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_admin_add_random_ai_law() - set category = "Fun" + set category = "Fun.Silicon" set name = "Add Random AI Law" if(!holder) @@ -276,7 +276,7 @@ Ccomp's first proc. /client/proc/allow_character_respawn() - set category = "Special Verbs" + set category = "Admin.Game" set name = "Allow player to respawn" set desc = "Let a player bypass the wait to respawn or allow them to re-enter their corpse." @@ -313,7 +313,7 @@ Ccomp's first proc. /client/proc/toggle_antagHUD_use() - set category = "Server" + set category = "Server.Game" set name = "Toggle antagHUD usage" set desc = "Toggles antagHUD usage for observers" @@ -348,7 +348,7 @@ Ccomp's first proc. /client/proc/toggle_antagHUD_restrictions() - set category = "Server" + set category = "Server.Game" set name = "Toggle antagHUD Restrictions" set desc = "Restricts players that have used antagHUD from being able to join this round." @@ -381,7 +381,7 @@ Works kind of like entering the game with a new character. Character receives a Traitors and the like can also be revived with the previous role mostly intact. /N */ /client/proc/respawn_character() - set category = "Special Verbs" + set category = "Fun.Event Kit" set name = "Spawn Character" set desc = "(Re)Spawn a client's loaded character." @@ -594,7 +594,7 @@ Traitors and the like can also be revived with the previous role mostly intact. return new_character /client/proc/cmd_admin_add_freeform_ai_law() - set category = "Fun" + set category = "Fun.Silicon" set name = "Add Custom AI law" if(!holder) @@ -623,7 +623,7 @@ Traitors and the like can also be revived with the previous role mostly intact. feedback_add_details("admin_verb","IONC") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_admin_rejuvenate(mob/living/M as mob in mob_list) - set category = "Special Verbs" + set category = "Admin.Game" set name = "Rejuvenate" if(!holder) @@ -646,7 +646,7 @@ Traitors and the like can also be revived with the previous role mostly intact. feedback_add_details("admin_verb","REJU") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_admin_create_centcom_report() - set category = "Special Verbs" + set category = "Fun.Event Kit" set name = "Create Command Report" if(!holder) @@ -674,7 +674,7 @@ Traitors and the like can also be revived with the previous role mostly intact. feedback_add_details("admin_verb","CCR") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_admin_delete(atom/O as obj|mob|turf in _validate_atom(O)) // I don't understand precisely how this fixes the string matching against a substring, but it does - Ater - set category = "Admin" + set category = "Admin.Game" set name = "Delete" if (!holder) @@ -683,7 +683,7 @@ Traitors and the like can also be revived with the previous role mostly intact. admin_delete(O) /client/proc/cmd_admin_list_open_jobs() - set category = "Admin" + set category = "Admin.Investigate" set name = "List free slots" if (!holder) @@ -695,7 +695,7 @@ Traitors and the like can also be revived with the previous role mostly intact. feedback_add_details("admin_verb","LFS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_admin_explosion(atom/O as obj|mob|turf in world) - set category = "Special Verbs" + set category = "Fun.Do Not" set name = "Explosion" if(!check_rights(R_DEBUG|R_FUN)) return //VOREStation Edit @@ -723,7 +723,7 @@ Traitors and the like can also be revived with the previous role mostly intact. return /client/proc/cmd_admin_emp(atom/O as obj|mob|turf in world) - set category = "Special Verbs" + set category = "Fun.Do Not" set name = "EM Pulse" if(!check_rights(R_DEBUG|R_FUN)) return //VOREStation Edit @@ -749,7 +749,7 @@ Traitors and the like can also be revived with the previous role mostly intact. return /client/proc/cmd_admin_gib(mob/M as mob in mob_list) - set category = "Special Verbs" + set category = "Fun.Do Not" set name = "Gib" if(!check_rights(R_ADMIN|R_FUN)) return //VOREStation Edit @@ -771,7 +771,7 @@ Traitors and the like can also be revived with the previous role mostly intact. /client/proc/cmd_admin_gib_self() set name = "Gibself" - set category = "Fun" + set category = "Fun.Do Not" if(!holder) return @@ -791,7 +791,7 @@ Traitors and the like can also be revived with the previous role mostly intact. /* /client/proc/cmd_manual_ban() set name = "Manual Ban" - set category = "Special Verbs" + set category = "Admin.Moderation" if(!authenticated || !holder) to_chat(src, "Only administrators may use this command.") return @@ -851,7 +851,7 @@ Traitors and the like can also be revived with the previous role mostly intact. return /client/proc/cmd_admin_check_contents(mob/living/M as mob in mob_list) - set category = "Special Verbs" + set category = "Admin.Investigate" set name = "Check Contents" set popup_menu = FALSE //VOREStation Edit - Declutter. @@ -865,7 +865,7 @@ Traitors and the like can also be revived with the previous role mostly intact. /* This proc is DEFERRED. Does not do anything. /client/proc/cmd_admin_remove_phoron() - set category = "Debug" + set category = "Debug.Game" set name = "Stabilize Atmos." if(!holder) to_chat(src, "Only administrators may use this command.") @@ -895,7 +895,7 @@ Traitors and the like can also be revived with the previous role mostly intact. */ /client/proc/toggle_view_range() - set category = "Special Verbs" + set category = "Admin.Game" set name = "Change View Range" set desc = "switches between 1x and custom views" @@ -915,7 +915,7 @@ Traitors and the like can also be revived with the previous role mostly intact. feedback_add_details("admin_verb","CVRA") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/admin_call_shuttle() - set category = "Admin" + set category = "Admin.Events" set name = "Call Shuttle" if ((!( ticker ) || !emergency_shuttle.location())) @@ -947,7 +947,7 @@ Traitors and the like can also be revived with the previous role mostly intact. return /client/proc/admin_cancel_shuttle() - set category = "Admin" + set category = "Admin.Events" set name = "Cancel Shuttle" if(!check_rights(R_ADMIN)) return //VOREStation Edit @@ -965,7 +965,7 @@ Traitors and the like can also be revived with the previous role mostly intact. return /client/proc/admin_deny_shuttle() - set category = "Admin" + set category = "Admin.Events" set name = "Toggle Deny Shuttle" if (!ticker) @@ -979,7 +979,7 @@ Traitors and the like can also be revived with the previous role mostly intact. message_admins("[key_name_admin(usr)] has [emergency_shuttle.deny_shuttle ? "denied" : "allowed"] the shuttle to be called.") /client/proc/cmd_admin_attack_log(mob/M as mob in mob_list) - set category = "Special Verbs" + set category = "Admin.Logs" set name = "Attack Log" to_chat(usr, span_red(span_bold("Attack Log for [mob]"))) @@ -989,7 +989,7 @@ Traitors and the like can also be revived with the previous role mostly intact. /client/proc/everyone_random() - set category = "Fun" + set category = "Fun.Do Not" set name = "Make Everyone Random" set desc = "Make everyone have a random appearance. You can only use this before rounds!" @@ -1023,7 +1023,7 @@ Traitors and the like can also be revived with the previous role mostly intact. /client/proc/toggle_random_events() - set category = "Server" + set category = "Server.Game" set name = "Toggle random events on/off" set desc = "Toggles random events such as meteors, black holes, blob (but not space dust) on/off" @@ -1041,7 +1041,7 @@ Traitors and the like can also be revived with the previous role mostly intact. /client/proc/despawn_player(var/mob/M in living_mob_list) set name = "Cryo Player" - set category = "Admin" + set category = "Admin.Game" set desc = "Removes a player from the round as if they'd cryo'd." set popup_menu = FALSE @@ -1104,7 +1104,7 @@ Traitors and the like can also be revived with the previous role mostly intact. /client/proc/cmd_admin_droppod_spawn(var/object as text) set name = "Drop Pod Atom" set desc = "Spawn a new atom/movable in a drop pod where you are." - set category = "Fun" + set category = "Fun.Drop Pod" if(!check_rights(R_SPAWN)) return @@ -1146,7 +1146,7 @@ Traitors and the like can also be revived with the previous role mostly intact. /client/proc/cmd_admin_droppod_deploy() set name = "Drop Pod Deploy" set desc = "Drop an existing mob where you are in a drop pod." - set category = "Fun" + set category = "Fun.Drop Pod" if(!check_rights(R_SPAWN)) return diff --git a/code/modules/admin/verbs/randomverbs_vr.dm b/code/modules/admin/verbs/randomverbs_vr.dm index 8b045ffaf92..8cd3c50604f 100644 --- a/code/modules/admin/verbs/randomverbs_vr.dm +++ b/code/modules/admin/verbs/randomverbs_vr.dm @@ -1,5 +1,5 @@ /client/proc/spawn_character_mob() - set category = "Special Verbs" + set category = "Fun.Event Kit" set name = "Spawn Character As Mob" set desc = "Spawn a specified ckey as a chosen mob." @@ -76,7 +76,7 @@ return new_mob /client/proc/cmd_admin_z_narrate() // Allows administrators to fluff events a little easier -- TLE - set category = "Special Verbs" + set category = "Fun.Narrate" set name = "Z Narrate" set desc = "Narrates to your Z level." @@ -84,6 +84,10 @@ return var/msg = tgui_input_text(usr, "Message:", text("Enter the text you wish to appear to everyone:")) + + if (!msg) + return + if(!(msg[1] == "<" && msg[length(msg)] == ">")) //You can use HTML but only if the whole thing is HTML. Tries to prevent admin 'accidents'. msg = sanitize(msg) @@ -101,7 +105,7 @@ feedback_add_details("admin_verb","GLNA") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/toggle_vantag_hud(var/mob/target as mob) - set category = "Fun" + set category = "Fun.Event Kit" set name = "Give/Remove Event HUD" set desc = "Give a mob the event hud, which shows them other people's event preferences, or remove it from them" diff --git a/code/modules/admin/verbs/resize.dm b/code/modules/admin/verbs/resize.dm index 85b7943397f..eb4267aee44 100644 --- a/code/modules/admin/verbs/resize.dm +++ b/code/modules/admin/verbs/resize.dm @@ -1,7 +1,7 @@ /client/proc/resize(var/mob/living/L in mob_list) set name = "Resize" set desc = "Resizes any living mob without any restrictions on size." - set category = "Fun" + set category = "Fun.Event Kit" if(!check_rights(R_ADMIN|R_FUN|R_VAREDIT)) return diff --git a/code/modules/admin/verbs/smite.dm b/code/modules/admin/verbs/smite.dm index 497f8f43ad6..82a9b7996d6 100644 --- a/code/modules/admin/verbs/smite.dm +++ b/code/modules/admin/verbs/smite.dm @@ -1,7 +1,7 @@ /client/proc/smite(var/mob/living/carbon/human/target in player_list) set name = "Smite" set desc = "Abuse a player with various 'special treatments' from a list." - set category = "Fun" + set category = "Fun.Do Not" if(!check_rights(R_FUN)) return diff --git a/code/modules/admin/verbs/striketeam.dm b/code/modules/admin/verbs/striketeam.dm index af7e42c872b..a3eea5b9b64 100644 --- a/code/modules/admin/verbs/striketeam.dm +++ b/code/modules/admin/verbs/striketeam.dm @@ -2,7 +2,7 @@ var/const/commandos_possible = 6 //if more Commandos are needed in the future /client/proc/strike_team() - set category = "Fun" + set category = "Fun.Event Kit" set name = "Spawn Strike Team" set desc = "Spawns a strike team if you want to run an admin event." diff --git a/code/modules/admin/verbs/tripAI.dm b/code/modules/admin/verbs/tripAI.dm index b932729d983..2e31e7418b0 100644 --- a/code/modules/admin/verbs/tripAI.dm +++ b/code/modules/admin/verbs/tripAI.dm @@ -1,5 +1,5 @@ /client/proc/triple_ai() - set category = "Fun" + set category = "Fun.Event Kit" set name = "Create AI Triumvirate" if(ticker.current_state > GAME_STATE_PREGAME) diff --git a/code/modules/admin/view_variables/topic.dm b/code/modules/admin/view_variables/topic.dm index fc2b9189894..e59daf02ef6 100644 --- a/code/modules/admin/view_variables/topic.dm +++ b/code/modules/admin/view_variables/topic.dm @@ -129,18 +129,6 @@ href_list["datumrefresh"] = href_list["give_wound_internal"] - - else if(href_list["give_disease2"]) - if(!check_rights(R_ADMIN|R_FUN|R_EVENT)) return - - var/mob/M = locate(href_list["give_disease2"]) - if(!istype(M)) - to_chat(usr, "This can only be used on instances of type /mob") - return - - src.give_disease2(M) - href_list["datumrefresh"] = href_list["give_spell"] - else if(href_list["godmode"]) if(!check_rights(R_REJUVINATE)) return diff --git a/code/modules/admin/view_variables/view_variables.dm b/code/modules/admin/view_variables/view_variables.dm index c2af0624d1a..fd15cd54a18 100644 --- a/code/modules/admin/view_variables/view_variables.dm +++ b/code/modules/admin/view_variables/view_variables.dm @@ -1,5 +1,5 @@ /client/proc/debug_variables(datum/D in world) - set category = "Debug" + set category = "Debug.Investigate" set name = "View Variables" //set src in world var/static/cookieoffset = rand(1, 9999) //to force cookies to reset after the round. diff --git a/code/modules/ai/ai_holder_subtypes/simple_mob_ai.dm b/code/modules/ai/ai_holder_subtypes/simple_mob_ai.dm index 4455b47072b..b2d4a896589 100644 --- a/code/modules/ai/ai_holder_subtypes/simple_mob_ai.dm +++ b/code/modules/ai/ai_holder_subtypes/simple_mob_ai.dm @@ -98,6 +98,23 @@ step_rand(holder) holder.face_atom(AM) +// Only attacks you if you're in front of it. +/datum/ai_holder/simple_mob/ranged/guard_limit + guard_limit = TRUE + returns_home = TRUE + +/datum/ai_holder/simple_mob/ranged/guard_limit/pointblank + pointblank = TRUE + +/datum/ai_holder/simple_mob/ranged/guard_limit/aggressive + pointblank = TRUE + var/closest_distance = 1 + +/datum/ai_holder/simple_mob/ranged/guard_limit/kiting + pointblank = TRUE // So we don't need to copypaste post_melee_attack(). + var/run_if_this_close = 4 // If anything gets within this range, it'll try to move away. + var/moonwalk = TRUE // If true, mob turns to face the target while kiting, otherwise they turn in the direction they moved towards. + // Switches intents based on specific criteria. // Used for special mobs who do different things based on intents (and aren't slimes). // Intent switching is generally done in pre_[ranged/special]_attack(), so that the mob can use the right attack for the right time. @@ -142,6 +159,14 @@ return TRUE // We're out in the open, uncloaked, and our target isn't stunned, so lets flee. return FALSE +// Can only target people in view range, will return home +/datum/ai_holder/simple_mob/melee/guard_limit + guard_limit = TRUE + returns_home = TRUE + +/datum/ai_holder/simple_mob/melee/evasive/guard_limit + guard_limit = TRUE + returns_home = TRUE // Simple mobs that aren't hostile, but will fight back. /datum/ai_holder/simple_mob/retaliate @@ -197,3 +222,7 @@ /datum/ai_holder/simple_mob/passive/speedy base_wander_delay = 1 + +// For setting up possible stealth missions +/datum/ai_holder/simple_mob/humanoid/hostile/guard_limit + guard_limit = TRUE diff --git a/code/modules/ai/ai_holder_targeting.dm b/code/modules/ai/ai_holder_targeting.dm index b918321f8b3..0525ee59515 100644 --- a/code/modules/ai/ai_holder_targeting.dm +++ b/code/modules/ai/ai_holder_targeting.dm @@ -10,6 +10,7 @@ var/micro_hunt = FALSE // Will target mobs at or under the micro_hunt_size size, requires vore_hostile to be true var/micro_hunt_size = 0.25 var/belly_attack = TRUE //Mobs attack if they are in a belly! + var/guard_limit = FALSE //Mobs will not acquire targets unless they are in front of them. var/atom/movable/target = null // The thing (mob or object) we're trying to kill. var/atom/movable/preferred_target = null// If set, and if given the chance, we will always prefer to target this over other options. @@ -49,7 +50,10 @@ . = list() if(!has_targets_list) possible_targets = list_targets() - for(var/possible_target in possible_targets) + for(var/atom/possible_target as anything in possible_targets) + if(guard_limit) + if((holder.dir == 1 && holder.y >= possible_target.y) || (holder.dir == 2 && holder.y <= possible_target.y) || (holder.dir == 4 && holder.x >= possible_target.x) || (holder.dir == 8 && holder.x <= possible_target.x)) //Ignore targets that are behind you + continue if(can_attack(possible_target)) // Can we attack it? . += possible_target diff --git a/code/modules/asset_cache/asset_list.dm b/code/modules/asset_cache/asset_list.dm index 5971a753c39..bdc062e0664 100644 --- a/code/modules/asset_cache/asset_list.dm +++ b/code/modules/asset_cache/asset_list.dm @@ -1,4 +1,4 @@ -#define ASSET_CROSS_ROUND_CACHE_DIRECTORY "tmp/assets" +#define ASSET_CROSS_ROUND_CACHE_DIRECTORY "cache/assets" //These datums are used to populate the asset cache, the proc "register()" does this. //Place any asset datums you create in asset_list_items.dm diff --git a/code/modules/client/client defines.dm b/code/modules/client/client defines.dm index 155950ae431..5b9adc2330b 100644 --- a/code/modules/client/client defines.dm +++ b/code/modules/client/client defines.dm @@ -106,6 +106,11 @@ var/last_asset_job = 0 var/last_completed_asset_job = 0 + ///Last ping of the client + var/lastping = 0 + ///Average ping of the client + var/avgping = 0 + ///world.time they connected var/connection_time ///world.realtime they connected diff --git a/code/modules/client/client procs.dm b/code/modules/client/client procs.dm index d4eff6fd9a1..86dffce176b 100644 --- a/code/modules/client/client procs.dm +++ b/code/modules/client/client procs.dm @@ -164,6 +164,10 @@ //CONNECT// /////////// /client/New(TopicData) + // TODO: Remove version check with 516 + if(byond_version >= 516) // Enable 516 compat browser storage mechanisms + winset(src, null, "browser-options=[DEFAULT_CLIENT_BROWSER_OPTIONS]") + TopicData = null //Prevent calls to client.Topic from connect if(!(connection in list("seeker", "web"))) //Invalid connection type. @@ -295,6 +299,12 @@ fully_created = TRUE attempt_auto_fit_viewport() + // TODO: Remove version check with 516 + if(byond_version >= 516) + // Now that we're fully initialized, use our prefs + if(prefs?.read_preference(/datum/preference/toggle/browser_dev_tools)) + winset(src, null, "browser-options=[DEFAULT_CLIENT_BROWSER_OPTIONS],devtools") + ////////////// //DISCONNECT// ////////////// @@ -502,13 +512,13 @@ /client/verb/character_setup() set name = "Character Setup" - set category = "Preferences" + set category = "Preferences.Character" if(prefs) prefs.ShowChoices(usr) /client/verb/game_options() set name = "Game Options" - set category = "Preferences" + set category = "Preferences.Game" if(prefs) prefs.tgui_interact(usr) @@ -610,7 +620,7 @@ /client/verb/toggle_fullscreen() set name = "Toggle Fullscreen" - set category = "OOC" + set category = "OOC.Client Settings" fullscreen = !fullscreen @@ -631,7 +641,7 @@ /client/verb/toggle_verb_panel() set name = "Toggle Verbs" - set category = "OOC" + set category = "OOC.Client Settings" show_verb_panel = !show_verb_panel @@ -640,7 +650,7 @@ /* /client/verb/toggle_status_bar() set name = "Toggle Status Bar" - set category = "OOC" + set category = "OOC.Client Settings" show_status_bar = !show_status_bar @@ -652,7 +662,7 @@ /client/verb/show_active_playtime() set name = "Active Playtime" - set category = "IC" + set category = "OOC.Game" if(!play_hours.len) to_chat(src, span_warning("Persistent playtime disabled!")) diff --git a/code/modules/client/movement.dm b/code/modules/client/movement.dm index efcf51c02ee..c04cf26c30c 100644 --- a/code/modules/client/movement.dm +++ b/code/modules/client/movement.dm @@ -5,11 +5,10 @@ /client/verb/spinleft() set name = "Spin View CCW" - set category = "OOC" + set category = "OOC.Game" dir = turn(dir, 90) /client/verb/spinright() set name = "Spin View CW" - set category = "OOC" + set category = "OOC.Game" dir = turn(dir, -90) - diff --git a/code/modules/client/preference_setup/volume_sliders/01_volume.dm b/code/modules/client/preference_setup/volume_sliders/01_volume.dm index 46a38bbb92a..219a4750cb2 100644 --- a/code/modules/client/preference_setup/volume_sliders/01_volume.dm +++ b/code/modules/client/preference_setup/volume_sliders/01_volume.dm @@ -97,7 +97,7 @@ /client/verb/volume_panel() set name = "Volume Panel" - set category = "Preferences" + set category = "Preferences.Sounds" set desc = "Allows you to adjust volume levels on the fly." if(!volume_panel) diff --git a/code/modules/client/preferences/types/misc.dm b/code/modules/client/preferences/types/misc.dm index 54a85477e30..3efea588934 100644 --- a/code/modules/client/preferences/types/misc.dm +++ b/code/modules/client/preferences/types/misc.dm @@ -81,3 +81,15 @@ savefile_key = "AutoPunctuation" default_value = FALSE savefile_identifier = PREFERENCE_PLAYER + +/datum/preference/toggle/browser_dev_tools + category = PREFERENCE_CATEGORY_GAME_PREFERENCES + savefile_key = "BrowserDevTools" + default_value = FALSE + savefile_identifier = PREFERENCE_PLAYER + +/datum/preference/toggle/browser_dev_tools/apply_to_client(client/client, value) + if(value) + winset(client, null, "browser-options=[DEFAULT_CLIENT_BROWSER_OPTIONS],devtools") + else + winset(client, null, "browser-options=[DEFAULT_CLIENT_BROWSER_OPTIONS]") diff --git a/code/modules/client/preferences_toggle_procs.dm b/code/modules/client/preferences_toggle_procs.dm index 73a3c1045de..fbd61f46eab 100644 --- a/code/modules/client/preferences_toggle_procs.dm +++ b/code/modules/client/preferences_toggle_procs.dm @@ -1,7 +1,7 @@ //Toggles for preferences, normal clients /client/verb/toggle_be_special(role in be_special_flags) set name = "Toggle Special Role Candidacy" - set category = "Preferences" + set category = "Preferences.Character" set desc = "Toggles which special roles you would like to be a candidate for, during events." var/role_flag = be_special_flags[role] @@ -16,7 +16,7 @@ /client/verb/toggle_chat_timestamps() set name = "Toggle Chat Timestamps" - set category = "Preferences" + set category = "Preferences.Chat" set desc = "Toggles whether or not messages in chat will display timestamps. Enabling this will not add timestamps to messages that have already been sent." prefs.chat_timestamp = !prefs.chat_timestamp //There is no preference datum for tgui input lock, nor for any TGUI prefs. @@ -27,7 +27,7 @@ // Not attached to a pref datum because those are strict binary toggles /client/verb/toggle_examine_mode() set name = "Toggle Examine Mode" - set category = "Preferences" + set category = "Preferences.Game" set desc = "Toggle the additional behaviour of examining things." prefs.examine_text_mode++ @@ -44,7 +44,7 @@ /client/verb/toggle_multilingual_mode() set name = "Toggle Multilingual Mode" - set category = "Preferences" + set category = "Preferences.Character" set desc = "Toggle the behaviour of multilingual speech parsing." prefs.multilingual_mode++ diff --git a/code/modules/client/preferences_vr.dm b/code/modules/client/preferences_vr.dm index 9ee5ed0b24a..8453d0f16a3 100644 --- a/code/modules/client/preferences_vr.dm +++ b/code/modules/client/preferences_vr.dm @@ -16,7 +16,7 @@ //Why weren't these in game toggles already? /client/verb/toggle_capture_crystal() set name = "Toggle Catchable" - set category = "Preferences" + set category = "Preferences.Character" set desc = "Toggles being catchable with capture crystals." var/mob/living/L = mob diff --git a/code/modules/client/ui_style.dm b/code/modules/client/ui_style.dm index 653242dabcb..9cd68b86068 100644 --- a/code/modules/client/ui_style.dm +++ b/code/modules/client/ui_style.dm @@ -37,7 +37,7 @@ var/global/list/all_tooltip_styles = list( /client/verb/change_ui() set name = "Change UI" - set category = "Preferences" + set category = "Preferences.Game" set desc = "Configure your user interface" if(!ishuman(usr)) diff --git a/code/modules/client/verbs/advanced_who.dm b/code/modules/client/verbs/advanced_who.dm index a8acf146ce2..4c4af542a48 100644 --- a/code/modules/client/verbs/advanced_who.dm +++ b/code/modules/client/verbs/advanced_who.dm @@ -1,7 +1,7 @@ /client/verb/who_advanced() set name = "Advanced Who" - set category = "OOC" + set category = "OOC.Resources" var/msg = span_bold("Current Players:") + "\n" diff --git a/code/modules/client/verbs/character_directory.dm b/code/modules/client/verbs/character_directory.dm index 8155adab8df..c35b2954696 100644 --- a/code/modules/client/verbs/character_directory.dm +++ b/code/modules/client/verbs/character_directory.dm @@ -2,7 +2,7 @@ GLOBAL_DATUM(character_directory, /datum/character_directory) /client/verb/show_character_directory() set name = "Character Directory" - set category = "OOC" + set category = "OOC.Game" set desc = "Shows a listing of all active characters, along with their associated OOC notes, flavor text, and more." // This is primarily to stop malicious users from trying to lag the server by spamming this verb diff --git a/code/modules/client/verbs/ignore.dm b/code/modules/client/verbs/ignore.dm index 1e5237d3b1f..9981348f2b1 100644 --- a/code/modules/client/verbs/ignore.dm +++ b/code/modules/client/verbs/ignore.dm @@ -1,6 +1,6 @@ /client/verb/ignore(key_to_ignore as text) set name = "Ignore" - set category = "OOC" + set category = "OOC.Chat Settings" set desc = "Makes OOC and Deadchat messages from a specific player not appear to you." if(!key_to_ignore) @@ -20,7 +20,7 @@ /client/verb/unignore() set name = "Unignore" - set category = "OOC" + set category = "OOC.Chat Settings" set desc = "Reverts your ignoring of a specific player." if(!prefs) diff --git a/code/modules/client/verbs/ooc.dm b/code/modules/client/verbs/ooc.dm index 5e6d1b5f5da..63d7793ce86 100644 --- a/code/modules/client/verbs/ooc.dm +++ b/code/modules/client/verbs/ooc.dm @@ -1,7 +1,7 @@ /client/verb/ooc(msg as text) set name = "OOC" - set category = "OOC" + set category = "OOC.Chat" if(say_disabled) //This is here to try to identify lag problems to_chat(usr, span_warning("Speech is currently admin-disabled.")) @@ -84,7 +84,7 @@ /client/verb/looc(msg as text) set name = "LOOC" set desc = "Local OOC, seen only by those in view." - set category = "OOC" + set category = "OOC.Chat" if(say_disabled) //This is here to try to identify lag problems to_chat(usr, span_danger("Speech is currently admin-disabled.")) @@ -198,7 +198,7 @@ /client/verb/fit_viewport() set name = "Fit Viewport" - set category = "OOC" + set category = "OOC.Client Settings" set desc = "Fit the width of the map window to match the viewport" // Fetch aspect ratio diff --git a/code/modules/client/verbs/ping.dm b/code/modules/client/verbs/ping.dm index 706edc02f64..32c8f8244e5 100644 --- a/code/modules/client/verbs/ping.dm +++ b/code/modules/client/verbs/ping.dm @@ -1,5 +1,16 @@ + +/client/verb/update_ping(time as num) + set instant = TRUE + set name = ".update_ping" + var/ping = pingfromtime(time) + lastping = ping + if (!avgping) + avgping = ping + else + avgping = MC_AVERAGE_SLOW(avgping, ping) + /client/proc/pingfromtime(time) - return ((world.time+world.tick_lag*world.tick_usage/100)-time)*100 + return ((world.time+world.tick_lag*TICK_USAGE_REAL/100)-time)*100 /client/verb/display_ping(time as num) set instant = TRUE @@ -8,5 +19,5 @@ /client/verb/ping() set name = "Ping" - set category = "OOC" - winset(src, null, "command=.display_ping+[world.time+world.tick_lag*world.tick_usage/100]") + set category = "OOC.Debug" + winset(src, null, "command=.display_ping+[world.time+world.tick_lag*TICK_USAGE_REAL/100]") diff --git a/code/modules/client/verbs/suicide.dm b/code/modules/client/verbs/suicide.dm index 050d663787c..21eb9a135d4 100644 --- a/code/modules/client/verbs/suicide.dm +++ b/code/modules/client/verbs/suicide.dm @@ -80,7 +80,7 @@ /* /mob/living/silicon/pai/verb/suicide() - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set desc = "Kill yourself and become a ghost (You will receive a confirmation prompt)" set name = "pAI Suicide" var/answer = tgui_alert(usr, "REALLY kill yourself? This action can't be undone.", "Suicide", list("Yes","No")) diff --git a/code/modules/client/verbs/who.dm b/code/modules/client/verbs/who.dm index a2b789af6ac..942ecd5e52d 100644 --- a/code/modules/client/verbs/who.dm +++ b/code/modules/client/verbs/who.dm @@ -1,6 +1,6 @@ /client/verb/who() set name = "Who" - set category = "OOC" + set category = "OOC.Resources" var/msg = span_bold("Current Players:") + "\n" diff --git a/code/modules/clothing/clothing.dm b/code/modules/clothing/clothing.dm index 125b70ac82e..a69ddf2ab0e 100644 --- a/code/modules/clothing/clothing.dm +++ b/code/modules/clothing/clothing.dm @@ -465,7 +465,6 @@ var/light_overlay = "helmet_light" var/image/helmet_light - var/overhead = 0 //Used by spacesuit helmets sprite_sheets = list( SPECIES_TESHARI = 'icons/inventory/head/mob_teshari.dmi', @@ -636,7 +635,7 @@ /obj/item/clothing/shoes/proc/draw_knife() set name = "Draw Boot Knife" set desc = "Pull out your boot knife." - set category = "IC" + set category = "IC.Game" set src in usr if(usr.stat || usr.restrained() || usr.incapacitated()) diff --git a/code/modules/clothing/head/helmet.dm b/code/modules/clothing/head/helmet.dm index 7af35979289..4106d577af7 100644 --- a/code/modules/clothing/head/helmet.dm +++ b/code/modules/clothing/head/helmet.dm @@ -16,7 +16,6 @@ ear_protection = 1 drop_sound = 'sound/items/drop/helm.ogg' pickup_sound = 'sound/items/pickup/helm.ogg' - overhead = TRUE /obj/item/clothing/head/helmet/solgov name = "\improper Solar Confederate Government helmet" diff --git a/code/modules/clothing/masks/monitor.dm b/code/modules/clothing/masks/monitor.dm index 9e25521dd90..5efb8fb6d51 100644 --- a/code/modules/clothing/masks/monitor.dm +++ b/code/modules/clothing/masks/monitor.dm @@ -47,7 +47,7 @@ /obj/item/clothing/mask/monitor/verb/set_monitor_state() set name = "Set Monitor State" set desc = "Choose an icon for your monitor." - set category = "IC" + set category = "IC.Game" set src in usr var/mob/living/carbon/human/H = loc diff --git a/code/modules/clothing/spacesuits/spacesuits.dm b/code/modules/clothing/spacesuits/spacesuits.dm index 0a434e3b65c..b70ddc6a571 100644 --- a/code/modules/clothing/spacesuits/spacesuits.dm +++ b/code/modules/clothing/spacesuits/spacesuits.dm @@ -31,44 +31,6 @@ light_overlay = "helmet_light" light_range = 4 - overhead = TRUE // prevents stacking helmets indefinitely - var/obj/item/clothing/head/stored_under_head = null // under head - var/mob/living/carbon/human/wearer = null // Used to restore our under when we're dropped - -/obj/item/clothing/head/helmet/space/mob_can_equip(mob/user, slot, disable_warning = FALSE) - var/mob/living/carbon/human/H = user - if(H.head) - stored_under_head = H.head - if(!istype(stored_under_head)) - to_chat(user, "You are unable to wear \the [src] as \the [H.head] is in the way.") - stored_under_head = null - return 0 - if(stored_under_head.overhead) - to_chat(user, "You are unable to wear \the [src] as \the [H.head] is in the way.") - stored_under_head = null - return 0 - H.drop_from_inventory(stored_under_head) - stored_under_head.forceMove(src) - - if(!..()) - if(stored_under_head) - if(H.equip_to_slot_if_possible(stored_under_head, slot_head)) - stored_under_head = null - return 0 - if(stored_under_head) - to_chat(user, "You slip \the [src] on over \the [stored_under_head].") - wearer = H - return 1 - -/obj/item/clothing/head/helmet/space/dropped() - ..() - var/mob/living/carbon/human/H = wearer - if(stored_under_head) - if(!H.equip_to_slot_if_possible(stored_under_head, slot_head)) - stored_under_head.forceMove(get_turf(src)) - src.stored_under_head = null - wearer = null - /obj/item/clothing/head/helmet/space/Initialize() . = ..() if(camera_networks) diff --git a/code/modules/clothing/spacesuits/void/void.dm b/code/modules/clothing/spacesuits/void/void.dm index ce32a5cddb3..a8c4c0f53d7 100644 --- a/code/modules/clothing/spacesuits/void/void.dm +++ b/code/modules/clothing/spacesuits/void/void.dm @@ -91,11 +91,11 @@ boots.canremove = FALSE if(helmet) - if(H.equip_to_slot_if_possible(helmet, slot_head)) + if(H.head) + to_chat(M, "You are unable to deploy your suit's helmet as \the [H.head] is in the way.") + else if (H.equip_to_slot_if_possible(helmet, slot_head)) to_chat(M, "Your suit's helmet deploys with a hiss.") helmet.canremove = FALSE - else - to_chat(M, "You are unable to deploy your suit's helmet[H.head ? " because [H.head] is in the way." : ""].") if(tank) if(H.s_store) //In case someone finds a way. @@ -190,12 +190,13 @@ helmet.forceMove(src) playsound(src.loc, 'sound/machines/click2.ogg', 75, 1) else + if(H.head) + to_chat(H, span_danger("You cannot deploy your helmet while wearing \the [H.head].")) + return if(H.equip_to_slot_if_possible(helmet, slot_head)) helmet.canremove = FALSE to_chat(H, span_info("You deploy your suit helmet, sealing you off from the world.")) playsound(src.loc, 'sound/machines/click2.ogg', 75, 1) - else - to_chat(H, span_danger("You cannot deploy your helmet[H.head ? " while wearing \the [H.head]." : ""]")) /obj/item/clothing/suit/space/void/AltClick(mob/living/user) eject_tank() diff --git a/code/modules/detectivework/tools/uvlight.dm b/code/modules/detectivework/tools/uvlight.dm index 28afb25655a..29aca9fe31a 100644 --- a/code/modules/detectivework/tools/uvlight.dm +++ b/code/modules/detectivework/tools/uvlight.dm @@ -1,6 +1,7 @@ /obj/item/uv_light name = "\improper UV light" desc = "A small handheld black light." + icon = 'icons/obj/device.dmi' icon_state = "uv_off" slot_flags = SLOT_BELT w_class = ITEMSIZE_SMALL diff --git a/code/modules/economy/vending_machines_vr.dm b/code/modules/economy/vending_machines_vr.dm index d6a58e71665..800c386d9d1 100644 --- a/code/modules/economy/vending_machines_vr.dm +++ b/code/modules/economy/vending_machines_vr.dm @@ -1,40 +1,40 @@ //Tweaked existing vendors -/obj/machinery/vending/hydroseeds/New() +/obj/machinery/vending/hydroseeds/Initialize() + . = ..() products += list(/obj/item/seeds/shrinkshroom = 3,/obj/item/seeds/megashroom = 3) - ..() -/obj/machinery/vending/security/New() +/obj/machinery/vending/security/Initialize() + . = ..() products += list(/obj/item/gun/energy/taser = 8,/obj/item/gun/energy/stunrevolver = 4, /obj/item/reagent_containers/spray/pepper = 6,/obj/item/taperoll/police = 6, /obj/item/clothing/glasses/omnihud/sec = 6) contraband += list(/obj/item/implanter/compliance = 1) - ..() -/obj/machinery/vending/tool/New() +/obj/machinery/vending/tool/Initialize() + . = ..() products += list(/obj/item/reagent_containers/spray/windowsealant = 5) - ..() -/obj/machinery/vending/engivend/New() +/obj/machinery/vending/engivend/Initialize() + . = ..() products += list(/obj/item/clothing/glasses/omnihud/eng = 6) contraband += list(/obj/item/rms = 5) - ..() -/obj/machinery/vending/medical/New() +/obj/machinery/vending/medical/Initialize() + . = ..() products += list(/obj/item/storage/box/khcrystal = 4,/obj/item/backup_implanter = 3, /obj/item/clothing/glasses/omnihud/med = 4, /obj/item/glasses_kit = 1, /obj/item/storage/quickdraw/syringe_case = 4) - ..() -/obj/machinery/vending/wallmed1/New() +/obj/machinery/vending/wallmed1/Initialize() + . = ..() products += list(/obj/item/bodybag/cryobag = 2) - ..() -/obj/machinery/vending/wallmed2/New() +/obj/machinery/vending/wallmed2/Initialize() + . = ..() products += list(/obj/item/bodybag/cryobag = 3) - ..() -/obj/machinery/vending/wallmed1/public/New() +/obj/machinery/vending/wallmed1/public/Initialize() + . = ..() products += list(/obj/item/bodybag/cryobag = 4) - ..() // Food Machines (for event/away maps) diff --git a/code/modules/eventkit/gm_interfaces/fake_pda_conversations.dm b/code/modules/eventkit/gm_interfaces/fake_pda_conversations.dm index accd006fe18..b54ec0a7804 100644 --- a/code/modules/eventkit/gm_interfaces/fake_pda_conversations.dm +++ b/code/modules/eventkit/gm_interfaces/fake_pda_conversations.dm @@ -5,7 +5,7 @@ /client/proc/fake_pdaconvos() - set category = "EventKit" + set category = "Fun.Event Kit" set name = "Manage PDA identities" set desc = "Creates fake identities for use in setting up PDA props" diff --git a/code/modules/eventkit/gm_interfaces/mob_spawner.dm b/code/modules/eventkit/gm_interfaces/mob_spawner.dm index 8e6cc6e8c78..85adcecc3fd 100644 --- a/code/modules/eventkit/gm_interfaces/mob_spawner.dm +++ b/code/modules/eventkit/gm_interfaces/mob_spawner.dm @@ -193,7 +193,7 @@ qdel(src) /client/proc/eventkit_open_mob_spawner() - set category = "EventKit" + set category = "Fun.Event Kit" set name = "Open Mob Spawner" set desc = "Opens an advanced version of the mob spawner." diff --git a/code/modules/events/disease_outbreak.dm b/code/modules/events/disease_outbreak.dm new file mode 100644 index 00000000000..25e1ea5c4f1 --- /dev/null +++ b/code/modules/events/disease_outbreak.dm @@ -0,0 +1,98 @@ +GLOBAL_LIST_EMPTY(current_pending_diseases) +/datum/event/disease_outbreak + var/datum/disease/chosen_disease + var/list/disease_blacklist = list( + /datum/disease/advance, + /datum/disease/food_poisoning + ) + var/static/list/transmissable_symptoms = list() + var/static/list/diseases_minor = list() + var/static/list/diseases_moderate_major = list() + +/datum/event/disease_outbreak/setup() + if(isemptylist(diseases_minor) && isemptylist(diseases_moderate_major)) + populate_diseases() + if(isemptylist(transmissable_symptoms)) + populate_symptoms() + var/datum/disease/virus + if(prob(50)) + switch(severity) + if(EVENT_LEVEL_MODERATE) + virus = pick(diseases_minor) + if(EVENT_LEVEL_MAJOR) + virus = pick(diseases_moderate_major) + else + stack_trace("Disease Outbreak: Invalid Event Level [severity]. Expected: 1-2") + virus = /datum/disease/cold + chosen_disease = new virus() + else + if(severity == EVENT_LEVEL_MAJOR) + chosen_disease = create_virus(severity * pick(2,3)) //50% chance for a major disease instead of a moderate one + else + chosen_disease = create_virus(severity * 2) + + chosen_disease.carrier = TRUE + +/datum/event/disease_outbreak/start() + GLOB.current_pending_diseases += chosen_disease + + var/list/candidates = list() + for(var/mob/living/carbon/human/G in player_list) + if(G.mind && G.stat != DEAD && G.is_client_active(5) && !player_is_antag(G.mind)) + var/area/A = get_area(G) + if(!A) + continue + if(!(A.z in using_map.station_levels)) + continue + if(A.flags & RAD_SHIELDED) + continue + if(isbelly(G.loc)) + continue + if(!G.CanContractDisease()) + continue + candidates += G + + var/chosen_infect = rand(3, 5) + + while(chosen_infect) + var/mob/living/carbon/human/H = pick(candidates) + H.ContractDisease(chosen_disease) + candidates -= H + + +//Creates a virus with a harmful effect, guaranteed to be spreadable by contact or airborne +/datum/event/disease_outbreak/proc/create_virus(max_severity = 6) + var/datum/disease/advance/A = new /datum/disease/advance + A.symptoms = A.GenerateSymptomsBySeverity(max_severity - 1, max_severity, 2) //Choose "Payload" symptoms + A.AssignProperties(A.GenerateProperties()) + var/list/symptoms_to_try = transmissable_symptoms.Copy() + while(length(symptoms_to_try)) + if(A.spread_text != "Blood") + break + if(length(A.symptoms) < VIRUS_SYMPTOM_LIMIT) //Ensure the virus is spreadable by adding symptoms that boost transmission + var/datum/symptom/TS = pick_n_take(symptoms_to_try) + A.AddSymptom(new TS) + else + popleft(A.symptoms) //We have a full symptom list but are still not transmittable. Try removing one of the "payloads" + + A.AssignProperties(A.GenerateProperties()) + A.name = pick(alphabet_uppercase) + num2text(rand(1,9)) + pick(alphabet_uppercase) + num2text(rand(1,9)) + pick("v", "V", "-" + num2text(game_year), "") + A.Refresh() + return A + +/datum/event/disease_outbreak/proc/populate_diseases() + for(var/candidate in subtypesof(/datum/disease)) + var/datum/disease/CD = new candidate + if(is_type_in_list(CD, disease_blacklist)) + continue + switch(CD.severity) + if(NONTHREAT, MINOR) + diseases_minor += candidate + if(MEDIUM, HARMFUL, DANGEROUS, BIOHAZARD) + diseases_moderate_major += candidate + +/datum/event/disease_outbreak/proc/populate_symptoms() + for(var/candidate in subtypesof(/datum/symptom)) + var/datum/symptom/CS = candidate + if(initial(CS.transmittable) > 1) + transmissable_symptoms += candidate diff --git a/code/modules/events/event_manager.dm b/code/modules/events/event_manager.dm index cc0972f2082..6416a583a02 100644 --- a/code/modules/events/event_manager.dm +++ b/code/modules/events/event_manager.dm @@ -224,7 +224,7 @@ /client/proc/forceEvent(var/type in SSevents.allEvents) set name = "Trigger Event (Debug Only)" - set category = "Debug" + set category = "Debug.Dangerous" if(!holder) return @@ -235,6 +235,6 @@ /client/proc/event_manager_panel() set name = "Event Manager Panel" - set category = "Admin" + set category = "Admin.Events" SSevents.Interact(usr) feedback_add_details("admin_verb","EMP") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! diff --git a/code/modules/examine/examine.dm b/code/modules/examine/examine.dm index 16f1b305aba..92cefa1ce10 100644 --- a/code/modules/examine/examine.dm +++ b/code/modules/examine/examine.dm @@ -63,7 +63,7 @@ //mob verbs are faster than object verbs. See http://www.byond.com/forum/?post=1326139&page=2#comment8198716 for why this isn't atom/verb/examine() /mob/verb/examinate(atom/A as mob|obj|turf in _validate_atom(A)) set name = "Examine" - set category = "IC" + set category = "IC.Game" if((is_blind(src) || usr.stat) && !isobserver(src)) to_chat(src, span_notice("Something is there but you can't see it.")) @@ -93,7 +93,7 @@ /mob/verb/mob_examine() set name = "Mob Examine" set desc = "Allows one to examine mobs they can see, even from inside of bellies and objects." - set category = "IC" + set category = "IC.Game" set popup_menu = FALSE if((is_blind(src) || src.stat) && !isobserver(src)) diff --git a/code/modules/flufftext/look_up.dm b/code/modules/flufftext/look_up.dm index 1bfcf6898c9..01d0cd69c98 100644 --- a/code/modules/flufftext/look_up.dm +++ b/code/modules/flufftext/look_up.dm @@ -2,7 +2,7 @@ /mob/living/verb/look_up() set name = "Look Up" - set category = "IC" + set category = "IC.Game" set desc = "Look above you, and hope there's no ceiling spiders." to_chat(usr, "You look upwards...") diff --git a/code/modules/food/food/snacks.dm b/code/modules/food/food/snacks.dm index 96c14683b05..08d40416daf 100644 --- a/code/modules/food/food/snacks.dm +++ b/code/modules/food/food/snacks.dm @@ -6892,6 +6892,7 @@ "zombiepowder", "cryptobiolin", "psilocybin")), 5) + reagents.add_reagent("salmonella", 5) /obj/item/reagent_containers/food/snacks/old/pizza name = "\improper Pizza!" diff --git a/code/modules/food/kitchen/smartfridge/medical.dm b/code/modules/food/kitchen/smartfridge/medical.dm index 0e7f17663f0..1f9091bd366 100644 --- a/code/modules/food/kitchen/smartfridge/medical.dm +++ b/code/modules/food/kitchen/smartfridge/medical.dm @@ -31,9 +31,7 @@ icon_contents = "viro" /obj/machinery/smartfridge/virology/accept_check(var/obj/item/O as obj) - if(istype(O,/obj/item/reagent_containers/glass/beaker/vial/)) - return 1 - if(istype(O,/obj/item/virusdish/)) + if(istype(O,/obj/item/storage/pill_bottle) || istype(O,/obj/item/reagent_containers) || istype(O,/obj/item/reagent_containers/glass/)) return 1 return 0 @@ -44,9 +42,7 @@ req_access = list(access_virology) /obj/machinery/smartfridge/secure/virology/accept_check(var/obj/item/O as obj) - if(istype(O,/obj/item/reagent_containers/glass/beaker/vial/)) - return 1 - if(istype(O,/obj/item/virusdish/)) + if(istype(O,/obj/item/storage/pill_bottle) || istype(O,/obj/item/reagent_containers) || istype(O,/obj/item/reagent_containers/glass/)) return 1 return 0 diff --git a/code/modules/food/recipe_dump.dm b/code/modules/food/recipe_dump.dm index 8e1ac105712..21733d96b62 100644 --- a/code/modules/food/recipe_dump.dm +++ b/code/modules/food/recipe_dump.dm @@ -1,6 +1,6 @@ /client/proc/recipe_dump() set name = "Generate Recipe Dump" - set category = "Server" + set category = "Server.Admin" set desc = "Dumps food and drink recipe info and images for wiki or other use." if(!holder) diff --git a/code/modules/food/recipes_microwave.dm b/code/modules/food/recipes_microwave.dm index 9d5ea0cc5e9..90af4ee63f4 100644 --- a/code/modules/food/recipes_microwave.dm +++ b/code/modules/food/recipes_microwave.dm @@ -508,14 +508,6 @@ I said no! ) result = /obj/item/reagent_containers/food/snacks/icecreamsandwich -// Fuck Science! -/datum/recipe/ruinedvirusdish - items = list( - /obj/item/virusdish - ) - result = /obj/item/ruinedvirusdish - - /datum/recipe/onionsoup fruit = list("onion" = 1) reagents = list("water" = 10) diff --git a/code/modules/gamemaster/event2/events/medical/virus.dm b/code/modules/gamemaster/event2/events/medical/virus.dm deleted file mode 100644 index ad221c0d043..00000000000 --- a/code/modules/gamemaster/event2/events/medical/virus.dm +++ /dev/null @@ -1,69 +0,0 @@ -/datum/event2/meta/virus - name = "viral infection" - event_class = "virus" - departments = list(DEPARTMENT_MEDICAL, DEPARTMENT_EVERYONE) - chaos = 40 - chaotic_threshold = EVENT_CHAOS_THRESHOLD_HIGH_IMPACT - event_type = /datum/event2/event/virus - -/datum/event2/meta/virus/superbug - name = "viral superbug" - chaos = 60 - event_type = /datum/event2/event/virus/superbug - -/datum/event2/meta/virus/outbreak - name = "viral outbreak" - chaos = 60 - event_type = /datum/event2/event/virus/outbreak - -/datum/event2/meta/virus/get_weight() - var/list/virologists = metric.get_people_with_alt_title(/datum/job/doctor, /datum/alt_title/virologist) - virologists += metric.get_people_with_job(/datum/job/cmo) - - return virologists.len * 25 - - - -/datum/event2/event/virus - announce_delay_lower_bound = 1 MINUTE - announce_delay_upper_bound = 3 MINUTES - var/number_of_viruses = 1 - var/virus_power = 2 // Ranges from 1 to 3, with 1 being the weakest. - var/list/candidates = list() - -// A single powerful virus. -/datum/event2/event/virus/superbug - virus_power = 3 - -// A lot of weaker viruses. -/datum/event2/event/virus/outbreak - virus_power = 1 - number_of_viruses = 3 - - - -/datum/event2/event/virus/set_up() - for(var/mob/living/carbon/human/H in player_list) - if(H.client && !H.isSynthetic() && H.stat != DEAD && !player_is_antag(H.mind) && !isbelly(H.loc)) - candidates += H - candidates = shuffle(candidates) - -/datum/event2/event/virus/announce() - command_announcement.Announce("Confirmed outbreak of level 7 biohazard aboard \the [location_name()]. \ - All personnel must contain the outbreak.", "Biohazard Alert", new_sound = 'sound/AI/outbreak7.ogg') - -/datum/event2/event/virus/start() - if(!candidates.len) - log_debug("Virus event could not find any valid targets to infect. Aborting.") - abort() - return - - for(var/i = 1 to number_of_viruses) - var/mob/living/carbon/human/H = LAZYACCESS(candidates, 1) - if(!H) - return - var/datum/disease2/disease/D = new() - D.makerandom(virus_power) - log_debug("Virus event is now infecting \the [H] with a new random virus.") - infect_mob(H, D) - candidates -= H diff --git a/code/modules/media/mediamanager.dm b/code/modules/media/mediamanager.dm index f9a24ac630b..e23866e8e9f 100644 --- a/code/modules/media/mediamanager.dm +++ b/code/modules/media/mediamanager.dm @@ -54,7 +54,7 @@ /client/verb/change_volume() set name = "Set Volume" - set category = "OOC" + set category = "OOC.Client Settings" set desc = "Set jukebox volume" set_new_volume(usr) diff --git a/code/modules/mentor/mentor.dm b/code/modules/mentor/mentor.dm index 370d80a3443..c6524130aa0 100644 --- a/code/modules/mentor/mentor.dm +++ b/code/modules/mentor/mentor.dm @@ -43,7 +43,7 @@ var/list/mentor_verbs_default = list( remove_verb(src, mentor_verbs_default) /client/proc/make_mentor() - set category = "Special Verbs" + set category = "Admin.Secrets" set name = "Make Mentor" if(!holder) to_chat(src, span_admin_pm_warning("Error: Only administrators may use this command.")) @@ -66,7 +66,7 @@ var/list/mentor_verbs_default = list( feedback_add_details("admin_verb","Make Mentor") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/unmake_mentor() - set category = "Special Verbs" + set category = "Admin.Secrets" set name = "Unmake Mentor" if(!holder) to_chat(src, span_admin_pm_warning("Error: Only administrators may use this command.")) @@ -85,7 +85,7 @@ var/list/mentor_verbs_default = list( feedback_add_details("admin_verb","Unmake Mentor") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_mentor_say(msg as text) - set category = "Admin" + set category = "Admin.Chat" set name ="Mentorsay" //check rights @@ -126,7 +126,7 @@ var/list/mentor_verbs_default = list( mentor_commands(href, href_list, usr) /client/proc/cmd_dementor() - set category = "Admin" + set category = "Admin.Misc" set name = "De-mentor" if(tgui_alert(usr, "Confirm self-dementor for the round? You can't re-mentor yourself without someone promoting you.","Dementor",list("Yes","No")) == "Yes") @@ -167,12 +167,15 @@ var/list/mentor_verbs_default = list( set name = "Request help" set hidden = 1 - var/mhelp = tgui_alert(usr, "Select the help you need.","Request for Help",list("Adminhelp","Mentorhelp")) == "Mentorhelp" + var/mhelp = tgui_alert(usr, "Select the help you need.","Request for Help",list("Adminhelp","Mentorhelp")) if(!mhelp) return - var/msg = tgui_input_text(usr, "Input your request for help.", "Request for Help", multiline = TRUE) - if (mhelp) + var/msg = tgui_input_text(usr, "Input your request for help.", "Request for Help ([mhelp])", multiline = TRUE) + if(!msg) + return + + if (mhelp == "Mentorhelp") mentorhelp(msg) return diff --git a/code/modules/mentor/mentorhelp.dm b/code/modules/mentor/mentorhelp.dm index cbf457083ad..d801effd6eb 100644 --- a/code/modules/mentor/mentorhelp.dm +++ b/code/modules/mentor/mentorhelp.dm @@ -480,7 +480,7 @@ GLOBAL_DATUM_INIT(mhelp_tickets, /datum/mentor_help_tickets, new) //admin proc /client/proc/cmd_mentor_ticket_panel() set name = "Mentor Ticket List" - set category = "Admin" + set category = "Admin.Misc" var/browse_to diff --git a/code/modules/mining/abandonedcrates_vr.dm b/code/modules/mining/abandonedcrates_vr.dm index e57c911f408..a443839f9b5 100644 --- a/code/modules/mining/abandonedcrates_vr.dm +++ b/code/modules/mining/abandonedcrates_vr.dm @@ -30,6 +30,7 @@ list(/obj/item/melee/classic_baton, 6) = 3, list(/obj/item/rig/industrial, 6) = 3, list(/obj/item/multitool/hacktool, 5) = 3, + list(/obj/item/multitool/hacktool/modified, 4) = 4, list(/obj/item/toy/katana, 1) = 2, list(/obj/item/clothing/head/kitty, 1) = 2, list(pick(subtypesof(/obj/item/soap)), 1) = 2, @@ -41,7 +42,7 @@ list(/obj/item/toy/syndicateballoon, 3) = 2, list(/obj/item/clothing/suit/ianshirt, 3) = 2, list(/obj/item/clothing/head/bearpelt, 4) = 2, - //list(/obj/item/archaeological_find, 3) = 2, //ChompREMOVE - causes runtimes + //list(/obj/item/archaeological_find, 3) = 2, // Removed, causes runtimes list(pick(subtypesof(/obj/item/toy/mecha)), 4) = 2, list(pick(subtypesof(/obj/item/toy/figure)), 4) = 2, list(pick(subtypesof(/obj/item/toy/plushie)), 4) = 2, diff --git a/code/modules/mob/autowhisper.dm b/code/modules/mob/autowhisper.dm index 03584e93ea7..e667c639311 100644 --- a/code/modules/mob/autowhisper.dm +++ b/code/modules/mob/autowhisper.dm @@ -1,7 +1,7 @@ /mob/living/verb/toggle_autowhisper() set name = "Autowhisper Toggle" set desc = "Toggle whether you will automatically whisper/subtle" - set category = "IC" + set category = "IC.Settings" autowhisper = !autowhisper if(autowhisper_display) @@ -24,7 +24,7 @@ /mob/living/verb/autowhisper_mode() set name = "Autowhisper Mode" set desc = "Set the mode your emotes will default to while using Autowhisper" - set category = "IC" + set category = "IC.Settings" var/choice = tgui_input_list(src, "Select Custom Subtle Mode", "Custom Subtle Mode", list("Adjacent Turfs (Default)", "My Turf", "My Table", "Current Belly (Prey)", "Specific Belly (Pred)", "Specific Person", "Psay/Pme")) diff --git a/code/modules/mob/dead/observer/free_vr.dm b/code/modules/mob/dead/observer/free_vr.dm index e57bfd36782..811a535ab1e 100644 --- a/code/modules/mob/dead/observer/free_vr.dm +++ b/code/modules/mob/dead/observer/free_vr.dm @@ -8,7 +8,7 @@ var/global/list/prevent_respawns = list() /mob/observer/dead/verb/cleanup() set name = "Quit This Round" - set category = "OOC" + set category = "OOC.Game" set desc = "Free your job slot, remove yourself from the manifest, and prevent respawning as this character for this round." var/confirm = tgui_alert(usr, "This will free up your job slot, remove you from the manifest, and allow you to respawn as this character. You can rejoin as another \ diff --git a/code/modules/mob/dead/observer/observer.dm b/code/modules/mob/dead/observer/observer.dm index dea1e3ea13e..83a81d2c36d 100644 --- a/code/modules/mob/dead/observer/observer.dm +++ b/code/modules/mob/dead/observer/observer.dm @@ -215,7 +215,7 @@ Works together with spawning an observer, noted above. This is the proc mobs get to turn into a ghost. Forked from ghostize due to compatibility issues. */ /mob/living/verb/ghost() - set category = "OOC" + set category = "OOC.Game" set name = "Ghost" set desc = "Relinquish your life and enter the land of the dead." @@ -258,7 +258,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp . += "[eta_status]" /mob/observer/dead/verb/reenter_corpse() - set category = "Ghost" + set category = "Ghost.Game" set name = "Re-enter Corpse" if(!client) return if(!(mind && mind.current && can_reenter_corpse)) @@ -295,7 +295,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp return 1 /mob/observer/dead/verb/toggle_medHUD() - set category = "Ghost" + set category = "Ghost.Settings" set name = "Toggle MedicHUD" set desc = "Toggles Medical HUD allowing you to see how everyone is doing" @@ -305,7 +305,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp to_chat(src, span_boldnotice("Medical HUD [medHUD ? "Enabled" : "Disabled"]")) /mob/observer/dead/verb/toggle_secHUD() - set category = "Ghost" + set category = "Ghost.Settings" set name = "Toggle Security HUD" set desc = "Toggles Security HUD allowing you to see people's displayed ID's job, wanted status, etc" @@ -318,7 +318,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp to_chat(src, span_boldnotice("Security HUD [secHUD ? "Enabled" : "Disabled"]")) /mob/observer/dead/verb/toggle_antagHUD() - set category = "Ghost" + set category = "Ghost.Settings" set name = "Toggle AntagHUD" set desc = "Toggles AntagHUD allowing you to see who is the antagonist" @@ -370,7 +370,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp /mob/observer/dead/verb/dead_tele(areaname as anything in jumpable_areas()) set name = "Teleport" - set category = "Ghost" + set category = "Ghost.Game" set desc = "Teleport to a location." if(!istype(usr, /mob/observer/dead)) @@ -379,12 +379,10 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp var/area/A - if(!areaname) - var/list/areas = jumpable_areas() - var/input = tgui_input_list(usr, "Select an area:", "Ghost Teleport", areas) - if(!input) - return - A = areas[input] + if(areaname) + A = return_sorted_areas()[areaname] + else + A = return_sorted_areas()[tgui_input_list(usr, "Select an area:", "Ghost Teleport", jumpable_areas())] if(!A) return @@ -392,12 +390,12 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp to_chat(usr, "Not when you're not dead!") return - usr.forceMove(pick(get_area_turfs(A || jumpable_areas()[areaname]))) + usr.forceMove(pick(get_area_turfs(A))) usr.on_mob_jump() /mob/observer/dead/verb/follow(mobname as anything in jumpable_mobs()) set name = "Follow" - set category = "Ghost" + set category = "Ghost.Game" set desc = "Follow and haunt a mob." if(!istype(usr, /mob/observer/dead)) @@ -571,7 +569,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp return (T && T.holy) && (is_manifest || (mind in cult.current_antagonists)) /mob/observer/dead/verb/jumptomob() //Moves the ghost instead of just changing the ghosts's eye -Nodrak - set category = "Ghost" + set category = "Ghost.Game" set name = "Jump to Mob" set desc = "Teleport to a mob" set popup_menu = FALSE @@ -610,7 +608,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp /mob/observer/dead/verb/analyze_air() set name = "Analyze Air" - set category = "Ghost" + set category = "Ghost.Game" if(!istype(usr, /mob/observer/dead)) return @@ -637,7 +635,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp /mob/observer/dead/verb/check_radiation() set name = "Check Radiation" - set category = "Ghost" + set category = "Ghost.Game" var/turf/t = get_turf(src) if(t) @@ -647,7 +645,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp /mob/observer/dead/verb/become_mouse() set name = "Become mouse" - set category = "Ghost" + set category = "Ghost.Join" if(CONFIG_GET(flag/disable_player_mice)) to_chat(src, span_warning("Spawning as a mouse is currently disabled.")) @@ -701,7 +699,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp /mob/observer/dead/verb/view_manfiest() set name = "Show Crew Manifest" - set category = "Ghost" + set category = "Ghost.Game" var/datum/tgui_module/crew_manifest/self_deleting/S = new(src) S.tgui_interact(src) @@ -718,7 +716,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp //Used for drawing on walls with blood puddles as a spooky ghost. /mob/observer/dead/verb/bloody_doodle() - set category = "Ghost" + set category = "Ghost.Game" set name = "Write in blood" set desc = "If the round is sufficiently spooky, write a short message in blood on the floor or a wall. Remember, no IC in OOC or OOC in IC." @@ -829,7 +827,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp client.images += J /mob/observer/dead/proc/toggle_visibility(var/forced = 0) - set category = "Ghost" + set category = "Ghost.Settings" set name = "Toggle Visibility" set desc = "Allows you to turn (in)visible (almost) at will." @@ -851,7 +849,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp toggle_icon("cult") /mob/observer/dead/verb/toggle_anonsay() - set category = "Ghost" + set category = "Ghost.Settings" set name = "Toggle Anonymous Chat" set desc = "Toggles showing your key in dead chat." @@ -870,7 +868,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp /mob/observer/dead/verb/toggle_ghostsee() set name = "Toggle Ghost Vision" set desc = "Toggles your ability to see things only ghosts can see, like other ghosts" - set category = "Ghost" + set category = "Ghost.Settings" ghostvision = !ghostvision updateghostsight() to_chat(src, span_filter_notice("You [ghostvision ? "now" : "no longer"] have ghost vision.")) @@ -878,7 +876,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp /mob/observer/dead/verb/toggle_darkness() set name = "Toggle Darkness" set desc = "Toggles your ability to see lighting overlays, and the darkness they create." - set category = "Ghost" + set category = "Ghost.Settings" var/static/list/darkness_names = list("normal darkness levels", "30% darkness removed", "70% darkness removed", "no darkness") var/static/list/darkness_levels = list(255, 178, 76, 0) @@ -931,7 +929,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp /mob/observer/dead/proc/ghost_whisper() set name = "Spectral Whisper" - set category = "IC" + set category = "IC.Subtle" if(is_manifest) //Only able to whisper if it's hit with a tome. var/list/options = list() @@ -952,7 +950,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp to_chat(src, span_danger("You have not been pulled past the veil!")) /mob/observer/dead/verb/choose_ghost_sprite() - set category = "Ghost" + set category = "Ghost.Settings" set name = "Choose Sprite" var/choice @@ -986,7 +984,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp return FALSE /mob/observer/dead/verb/paialert() - set category = "Ghost" + set category = "Ghost.Message" set name = "Blank pAI alert" set desc = "Flash an indicator light on available blank pAI devices for a smidgen of hope." @@ -1042,5 +1040,5 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp /mob/observer/dead/verb/respawn() set name = "Respawn" - set category = "Ghost" + set category = "Ghost.Join" src.abandon_mob() diff --git a/code/modules/mob/dead/observer/observer_vr.dm b/code/modules/mob/dead/observer/observer_vr.dm index 078ea96cdd5..fad743e5c5d 100644 --- a/code/modules/mob/dead/observer/observer_vr.dm +++ b/code/modules/mob/dead/observer/observer_vr.dm @@ -1,5 +1,5 @@ /mob/observer/dead/verb/nifjoin() - set category = "Ghost" + set category = "Ghost.Join" set name = "Join Into Soulcatcher" set desc = "Select a player with a working NIF + Soulcatcher NIFSoft to join into it." @@ -58,7 +58,7 @@ SC.catch_mob(src) //This will result in us being deleted so... /mob/observer/dead/verb/backup_ping() - set category = "Ghost" + set category = "Ghost.Join" set name = "Notify Transcore" set desc = "If your past-due backup notification was missed or ignored, you can use this to send a new one." @@ -86,7 +86,7 @@ to_chat(src,span_warning("No backup record could be found, sorry.")) /* /mob/observer/dead/verb/backup_delay() - set category = "Ghost" + set category = "Ghost.Settings" set name = "Cancel Transcore Notification" set desc = "You can use this to avoid automatic backup notification happening. Manual notification can still be used." @@ -105,7 +105,7 @@ to_chat(src,span_warning("No backup record could be found, sorry.")) */ /mob/observer/dead/verb/findghostpod() //Moves the ghost instead of just changing the ghosts's eye -Nodrak - set category = "Ghost" + set category = "Ghost.Join" set name = "Find Ghost Pod" set desc = "Find an active ghost pod" set popup_menu = FALSE @@ -132,7 +132,7 @@ to_chat(src, span_filter_notice("This ghost pod is not located in the game world.")) /mob/observer/dead/verb/findautoresleever() - set category = "Ghost" + set category = "Ghost.Join" set name = "Find Auto Resleever" set desc = "Find a Auto Resleever" set popup_menu = FALSE diff --git a/code/modules/mob/freelook/ai/eye.dm b/code/modules/mob/freelook/ai/eye.dm index fa3fb311f0e..679d02c37ca 100644 --- a/code/modules/mob/freelook/ai/eye.dm +++ b/code/modules/mob/freelook/ai/eye.dm @@ -10,7 +10,7 @@ /mob/observer/eye/aiEye/New() ..() visualnet = cameranet - + /mob/observer/eye/aiEye/Destroy() if(owner) var/mob/living/silicon/ai/ai = owner @@ -105,7 +105,7 @@ src.eyeobj.setLoc(src) /mob/living/silicon/ai/proc/toggle_acceleration() - set category = "AI Settings" + set category = "AI.Settings" set name = "Toggle Camera Acceleration" if(!eyeobj) diff --git a/code/modules/mob/language/language.dm b/code/modules/mob/language/language.dm index f6d433a391a..41f1b65066a 100644 --- a/code/modules/mob/language/language.dm +++ b/code/modules/mob/language/language.dm @@ -285,7 +285,7 @@ /mob/verb/check_languages() set name = "Check Known Languages" - set category = "IC" + set category = "IC.Game" set src = usr var/datum/browser/popup = new(src, "checklanguage", "Known Languages", 420, 470) diff --git a/code/modules/mob/language/snowflake.dm b/code/modules/mob/language/snowflake.dm index 7c8160c5c1b..9524fb638cc 100644 --- a/code/modules/mob/language/snowflake.dm +++ b/code/modules/mob/language/snowflake.dm @@ -4,7 +4,7 @@ /mob/proc/adjust_hive_range() set name = "Adjust Special Language Range" set desc = "Changes the range you will transmit your hive language to!" - set category = "IC" + set category = "IC.Settings" var/option = tgui_alert(src, "What range?", "Adjust special language range", list("Global","This Z level","Local", "Subtle")) diff --git a/code/modules/mob/living/autohiss.dm b/code/modules/mob/living/autohiss.dm index dd63c80415b..618c0a32256 100644 --- a/code/modules/mob/living/autohiss.dm +++ b/code/modules/mob/living/autohiss.dm @@ -20,7 +20,7 @@ /client/verb/toggle_autohiss() set name = "Toggle Auto-Hiss" set desc = "Toggle automatic hissing as Unathi and r-rolling as Taj" - set category = "OOC" + set category = "OOC.Game Settings" autohiss_mode = (autohiss_mode + 1) % AUTOHISS_NUM switch(autohiss_mode) diff --git a/code/modules/mob/living/carbon/alien/diona/diona_powers.dm b/code/modules/mob/living/carbon/alien/diona/diona_powers.dm index 492a590793b..a2b33f7973b 100644 --- a/code/modules/mob/living/carbon/alien/diona/diona_powers.dm +++ b/code/modules/mob/living/carbon/alien/diona/diona_powers.dm @@ -1,7 +1,7 @@ //Verbs after this point. /mob/living/carbon/alien/diona/proc/merge() - set category = "Abilities" + set category = "Abilities.Diona" set name = "Merge with gestalt" set desc = "Merge with another diona." @@ -41,7 +41,7 @@ /mob/living/carbon/alien/diona/proc/split() - set category = "Abilities" + set category = "Abilities.Diona" set name = "Split from gestalt" set desc = "Split away from your gestalt as a lone nymph." diff --git a/code/modules/mob/living/carbon/alien/progression.dm b/code/modules/mob/living/carbon/alien/progression.dm index e59688646e8..af26a44221a 100644 --- a/code/modules/mob/living/carbon/alien/progression.dm +++ b/code/modules/mob/living/carbon/alien/progression.dm @@ -2,7 +2,7 @@ set name = "Evolve" set desc = "Evolve into your adult form." - set category = "Abilities" + set category = "Abilities.General" if(stat != CONSCIOUS) return diff --git a/code/modules/mob/living/carbon/brain/brain.dm b/code/modules/mob/living/carbon/brain/brain.dm index f25f41cc7a2..6f98a878044 100644 --- a/code/modules/mob/living/carbon/brain/brain.dm +++ b/code/modules/mob/living/carbon/brain/brain.dm @@ -54,7 +54,7 @@ // Vorestation edit start /mob/living/carbon/brain/verb/backup_ping() - set category = "IC" + set category = "IC.Game" set name = "Notify Transcore" set desc = "Your body is gone. Notify robotics to be resleeved!" var/datum/transcore_db/db = SStranscore.db_by_mind_name(mind.name) diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm index fbf72f59bb5..9b6f1210c81 100644 --- a/code/modules/mob/living/carbon/carbon.dm +++ b/code/modules/mob/living/carbon/carbon.dm @@ -11,8 +11,6 @@ /mob/living/carbon/Life() ..() - handle_viruses() - // Increase germ_level regularly if(germ_level < GERM_LEVEL_AMBIENT && prob(30)) //if you're just standing there, you shouldn't get more germs beyond an ambient level germ_level++ @@ -398,7 +396,10 @@ return ..() if(istype(A, /mob/living/carbon) && prob(10)) - spread_disease_to(A, "Contact") + var/mob/living/carbon/human/H = A + for(var/datum/disease/D in GetViruses()) + if(D.spread_flags & CONTACT_GENERAL) + H.ContractDisease(D) /mob/living/carbon/cannot_use_vents() return @@ -542,3 +543,12 @@ if(allergen_type in species.food_preference) return species.food_preference_bonus return 0 + +/mob/living/carbon/handle_diseases() + for(var/thing in GetViruses()) + var/datum/disease/D = thing + if(prob(D.infectivity)) + D.spread() + + if(stat != DEAD || D.allow_dead) + D.stage_act() diff --git a/code/modules/mob/living/carbon/carbon_defines.dm b/code/modules/mob/living/carbon/carbon_defines.dm index 8dc29e6d3b8..24a03592974 100644 --- a/code/modules/mob/living/carbon/carbon_defines.dm +++ b/code/modules/mob/living/carbon/carbon_defines.dm @@ -3,7 +3,6 @@ blocks_emissive = EMISSIVE_BLOCK_UNIQUE // BLEH, this could be improved for transparent species and stuff! And blocks glowing eyes?! var/datum/species/species //Contains icon generation and language information, set during New(). var/list/stomach_contents = list() - var/list/datum/disease2/disease/virus2 = list() var/list/antibodies = list() var/last_eating = 0 //Not sure what this does... I found it hidden in food.dm @@ -29,4 +28,4 @@ //these two help govern taste. The first is the last time a taste message was shown to the plaer. //the second is the message in question. var/last_taste_time = 0 - var/last_taste_text = "" \ No newline at end of file + var/last_taste_text = "" diff --git a/code/modules/mob/living/carbon/carbon_powers.dm b/code/modules/mob/living/carbon/carbon_powers.dm index f805968d40d..d6fdc94788b 100644 --- a/code/modules/mob/living/carbon/carbon_powers.dm +++ b/code/modules/mob/living/carbon/carbon_powers.dm @@ -1,7 +1,7 @@ //Brain slug proc for voluntary removal of control. /mob/living/carbon/proc/release_control() - set category = "Abilities" + set category = "Abilities.Brainslug" set name = "Release Control" set desc = "Release control of your host's body." @@ -21,7 +21,7 @@ //Brain slug proc for tormenting the host. /mob/living/carbon/proc/punish_host() - set category = "Abilities" + set category = "Abilities.Brainslug" set name = "Torment host" set desc = "Punish your host with agony." @@ -39,7 +39,7 @@ to_chat(B.host_brain, span_danger("Horrific, burning agony lances through you, ripping a soundless scream from your trapped mind!")) /mob/living/carbon/proc/spawn_larvae() - set category = "Abilities" + set category = "Abilities.Brainslug" set name = "Reproduce" set desc = "Spawn several young." diff --git a/code/modules/mob/living/carbon/give.dm b/code/modules/mob/living/carbon/give.dm index fa60a104984..93559fbd982 100644 --- a/code/modules/mob/living/carbon/give.dm +++ b/code/modules/mob/living/carbon/give.dm @@ -1,5 +1,5 @@ /mob/living/verb/give(var/mob/living/target in living_mobs(1)) - set category = "IC" + set category = "IC.Game" set name = "Give" do_give(target) diff --git a/code/modules/mob/living/carbon/human/emote.dm b/code/modules/mob/living/carbon/human/emote.dm index 0d9d9d975ed..21e87074bf3 100644 --- a/code/modules/mob/living/carbon/human/emote.dm +++ b/code/modules/mob/living/carbon/human/emote.dm @@ -331,7 +331,7 @@ var/list/_simple_mob_default_emotes = list( /mob/living/carbon/human/verb/pose() set name = "Set Pose" set desc = "Sets a description which will be shown when someone examines you." - set category = "IC" + set category = "IC.Settings" var/datum/gender/T = gender_datums[get_visible_gender()] @@ -340,7 +340,7 @@ var/list/_simple_mob_default_emotes = list( /mob/living/carbon/human/verb/set_flavor() set name = "Set Flavour Text" set desc = "Sets an extended description of your character's features." - set category = "IC" + set category = "IC.Settings" var/HTML = "" HTML += "
" diff --git a/code/modules/mob/living/carbon/human/emote_vr.dm b/code/modules/mob/living/carbon/human/emote_vr.dm index 7339a35cdd4..25669fb6f86 100644 --- a/code/modules/mob/living/carbon/human/emote_vr.dm +++ b/code/modules/mob/living/carbon/human/emote_vr.dm @@ -1,7 +1,7 @@ /mob/living/carbon/human/verb/toggle_resizing_immunity() set name = "Toggle Resizing Immunity" set desc = "Toggles your ability to resist resizing attempts" - set category = "IC" + set category = "IC.Settings" resizable = !resizable to_chat(src, span_notice("You are now [resizable ? "susceptible" : "immune"] to being resized.")) @@ -35,7 +35,7 @@ /mob/living/carbon/human/verb/toggle_gender_identity_vr() set name = "Set Gender Identity" set desc = "Sets the pronouns when examined and performing an emote." - set category = "IC" + set category = "IC.Settings" var/new_gender_identity = tgui_input_list(usr, "Please select a gender Identity:", "Set Gender Identity", list(FEMALE, MALE, NEUTER, PLURAL, HERM)) if(!new_gender_identity) return 0 @@ -44,14 +44,14 @@ /mob/living/carbon/human/verb/switch_tail_layer() set name = "Switch tail layer" - set category = "IC" + set category = "IC.Game" set desc = "Switch tail layer on top." tail_alt = !tail_alt update_tail_showing() /mob/living/carbon/human/verb/hide_wings_vr() set name = "Show/Hide wings" - set category = "IC" + set category = "IC.Settings" set desc = "Hide your wings, or show them if you already hid them." wings_hidden = !wings_hidden update_wing_showing() @@ -64,7 +64,7 @@ /mob/living/carbon/human/verb/hide_tail_vr() set name = "Show/Hide tail" - set category = "IC" + set category = "IC.Settings" set desc = "Hide your tail, or show it if you already hid it." if(!tail_style) //Just some checks. to_chat(src,span_notice("You have no tail to hide!")) diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm index 75c4c2d9ce2..5756af7e0a6 100644 --- a/code/modules/mob/living/carbon/human/human.dm +++ b/code/modules/mob/living/carbon/human/human.dm @@ -70,7 +70,7 @@ /mob/living/carbon/human/Destroy() human_mob_list -= src - /* //Chomp REMOVE - this is done on mob/living/Destroy + /* //REMOVE - this is done on mob/living/Destroy for(var/organ in organs) qdel(organ) */ @@ -947,7 +947,7 @@ /mob/living/carbon/human/proc/remotesay() set name = "Project mind" - set category = "Superpower" + set category = "Abilities.Superpower" if(stat!=CONSCIOUS) reset_view(0) @@ -976,7 +976,7 @@ /mob/living/carbon/human/proc/remoteobserve() set name = "Remote View" - set category = "Superpower" + set category = "Abilities.Superpower" if(stat!=CONSCIOUS) remoteview_target = null @@ -1062,10 +1062,6 @@ sync_organ_dna() // end vorestation addition - for (var/ID in virus2) - var/datum/disease2/disease/V = virus2[ID] - V.cure(src) - losebreath = 0 ..() @@ -1339,7 +1335,7 @@ return 0 /mob/living/carbon/human/proc/bloody_doodle() - set category = "IC" + set category = "IC.Game" set name = "Write in blood" set desc = "Use blood on your hands to write a short message on the floor or a wall, murder mystery style." @@ -1648,7 +1644,7 @@ /mob/living/carbon/human/verb/pull_punches() set name = "Pull Punches" set desc = "Try not to hurt them." - set category = "IC" + set category = "IC.Game" if(stat) return pulling_punches = !pulling_punches diff --git a/code/modules/mob/living/carbon/human/human_attackhand.dm b/code/modules/mob/living/carbon/human/human_attackhand.dm index 34054954e9d..542dafb6f68 100644 --- a/code/modules/mob/living/carbon/human/human_attackhand.dm +++ b/code/modules/mob/living/carbon/human/human_attackhand.dm @@ -44,6 +44,17 @@ if(!temp || !temp.is_usable()) to_chat(H, span_warning("You can't use your hand.")) return + + for(var/thing in GetViruses()) + var/datum/disease/D = thing + if(D.IsSpreadByTouch()) + H.ContractDisease(D) + + for(var/thing in H.GetViruses()) + var/datum/disease/D = thing + if(D.IsSpreadByTouch()) + ContractDisease(D) + if(H.lying) return M.break_cloak() @@ -65,8 +76,9 @@ return FALSE if(istype(M,/mob/living/carbon)) - var/mob/living/carbon/C = M - C.spread_disease_to(src, "Contact") + for(var/datum/disease/D in M.GetViruses()) + if(D.spread_flags & CONTACT_HANDS) + ContractDisease(D) switch(M.a_intent) if(I_HELP) @@ -446,7 +458,7 @@ /mob/living/carbon/human/verb/check_attacks() set name = "Check Attacks" - set category = "IC" + set category = "IC.Game" set src = usr var/dat = span_bold(span_giant("Known Attacks")) + "

" diff --git a/code/modules/mob/living/carbon/human/human_attackhand_vr.dm b/code/modules/mob/living/carbon/human/human_attackhand_vr.dm index bbee7002ac7..7175f645ccd 100644 --- a/code/modules/mob/living/carbon/human/human_attackhand_vr.dm +++ b/code/modules/mob/living/carbon/human/human_attackhand_vr.dm @@ -3,7 +3,7 @@ /mob/living/carbon/human/verb/check_attacks() set name = "Check Attacks" - set category = "IC" + set category = "IC.Game" set src = usr var/dat = span_bold("Known Attacks") + "

" diff --git a/code/modules/mob/living/carbon/human/human_powers.dm b/code/modules/mob/living/carbon/human/human_powers.dm index 1d6746cfc07..9abd6ddf229 100644 --- a/code/modules/mob/living/carbon/human/human_powers.dm +++ b/code/modules/mob/living/carbon/human/human_powers.dm @@ -4,7 +4,7 @@ /mob/living/carbon/human/proc/tie_hair() set name = "Tie Hair" set desc = "Style your hair." - set category = "IC" + set category = "IC.Game" if(incapacitated()) to_chat(src, span_warning("You can't mess with your hair right now!")) @@ -34,7 +34,7 @@ to_chat(src, span_notice("You're already using that style.")) /mob/living/carbon/human/proc/tackle() - set category = "Abilities" + set category = "Abilities.General" set name = "Tackle" set desc = "Tackle someone down." @@ -81,7 +81,7 @@ O.show_message(span_warning(span_red(span_bold("[src] [failed ? "tried to tackle" : "has tackled"] down [T]!"))), 1) /mob/living/carbon/human/proc/commune() - set category = "Abilities" + set category = "Abilities.General" set name = "Commune with creature" set desc = "Send a telepathic message to an unlucky recipient." @@ -119,7 +119,7 @@ /mob/living/carbon/human/proc/regurgitate() set name = "Regurgitate" set desc = "Empties the contents of your stomach" - set category = "Abilities" + set category = "Abilities.General" if(stomach_contents.len) for(var/mob/M in src) @@ -132,7 +132,7 @@ /mob/living/carbon/human/proc/psychic_whisper(mob/M as mob in oview()) set name = "Psychic Whisper" set desc = "Whisper silently to someone over a distance." - set category = "Abilities" + set category = "Abilities.General" var/msg = sanitize(tgui_input_text(usr, "Message:", "Psychic Whisper")) if(msg) @@ -144,7 +144,7 @@ /mob/living/carbon/human/proc/diona_split_nymph() set name = "Split" set desc = "Split your humanoid form into its constituent nymphs." - set category = "Abilities" + set category = "Abilities.Diona" diona_split_into_nymphs(5) // Separate proc to void argments being supplied when used as a verb /mob/living/carbon/human/proc/diona_split_into_nymphs(var/number_of_resulting_nymphs) @@ -204,7 +204,7 @@ /mob/living/carbon/human/proc/self_diagnostics() set name = "Self-Diagnostics" set desc = "Run an internal self-diagnostic to check for damage." - set category = "IC" + set category = "Abilities.General" if(stat == DEAD) return @@ -247,7 +247,7 @@ /mob/living/carbon/human/proc/sonar_ping() set name = "Listen In" set desc = "Allows you to listen in to movement and noises around you." - set category = "Abilities" + set category = "Abilities.General" if(incapacitated()) to_chat(src, span_warning("You need to recover before you can use this ability.")) @@ -291,7 +291,7 @@ /mob/living/carbon/human/proc/regenerate() set name = "Regenerate" set desc = "Allows you to regrow limbs and heal organs after a period of rest." - set category = "Abilities" + set category = "Abilities.General" if(nutrition < 250) to_chat(src, span_warning("You lack the biomass to begin regeneration!")) @@ -355,7 +355,7 @@ /mob/living/carbon/human/proc/setmonitor_state() set name = "Set monitor display" set desc = "Set your monitor display" - set category = "IC" + set category = "IC.Settings" if(stat) to_chat(src,span_warning("You must be awake and standing to perform this action!")) return diff --git a/code/modules/mob/living/carbon/human/human_powers_vr.dm b/code/modules/mob/living/carbon/human/human_powers_vr.dm index a1a0c2b76a8..acc53a7d499 100644 --- a/code/modules/mob/living/carbon/human/human_powers_vr.dm +++ b/code/modules/mob/living/carbon/human/human_powers_vr.dm @@ -1,7 +1,7 @@ /mob/living/carbon/human/proc/reagent_purge() set name = "Purge Reagents" set desc = "Empty yourself of any reagents you may have consumed or come into contact with." - set category = "IC" + set category = "IC.Game" if(stat == DEAD) return @@ -17,7 +17,7 @@ /mob/living/carbon/human/verb/toggle_eyes_layer() set name = "Switch Eyes/Monitor Layer" set desc = "Toggle rendering of eyes/monitor above markings." - set category = "IC" + set category = "IC.Settings" if(stat) to_chat(src, span_warning("You must be awake and standing to perform this action!")) diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm index 7d64ac51cfe..3d071559965 100644 --- a/code/modules/mob/living/carbon/human/life.dm +++ b/code/modules/mob/living/carbon/human/life.dm @@ -504,9 +504,12 @@ /mob/living/carbon/human/handle_post_breath(datum/gas_mixture/breath) ..() //spread some viruses while we are at it - if(breath && virus2.len > 0 && prob(10)) - for(var/mob/living/carbon/M in view(1,src)) - src.spread_disease_to(M) + if(breath && !isnull(viruses) && prob(10)) + for(var/datum/disease/D in GetViruses()) + if((D.spread_flags & SPECIAL) || (D.spread_flags & NON_CONTAGIOUS)) + continue + for(var/mob/living/carbon/M in view(1,src)) + ContractDisease(D) /mob/living/carbon/human/get_breath_from_internal(volume_needed=BREATH_VOLUME) @@ -2031,8 +2034,8 @@ if (BITTEST(hud_updateflag, STATUS_HUD)) var/foundVirus = 0 - for (var/ID in virus2) - if (ID in virusDB) + for (var/datum/disease/D in GetViruses()) + if(D.discovered) foundVirus = 1 break @@ -2054,8 +2057,10 @@ holder2.icon_state = "hudbrainworm" else holder.icon_state = "hudhealthy" - if(virus2.len) - holder2.icon_state = "hudill" + if(viruses.len) + for(var/datum/disease/D in GetViruses()) + if(D.discovered) + holder2.icon_state = "hudill" else holder2.icon_state = "hudhealthy" if(block_hud) diff --git a/code/modules/mob/living/carbon/human/species/species_shapeshift.dm b/code/modules/mob/living/carbon/human/species/species_shapeshift.dm index cac17137eb1..69eee283882 100644 --- a/code/modules/mob/living/carbon/human/species/species_shapeshift.dm +++ b/code/modules/mob/living/carbon/human/species/species_shapeshift.dm @@ -79,7 +79,7 @@ var/list/wrapped_species_by_ref = list() /mob/living/carbon/human/proc/shapeshifter_select_hair() set name = "Select Hair" - set category = "Abilities" + set category = "Abilities.Shapeshift" if(stat || world.time < last_special) return @@ -123,7 +123,7 @@ var/list/wrapped_species_by_ref = list() /mob/living/carbon/human/proc/shapeshifter_select_gender() set name = "Select Gender" - set category = "Abilities" + set category = "Abilities.Shapeshift" if(stat || world.time < last_special) return @@ -145,7 +145,7 @@ var/list/wrapped_species_by_ref = list() /mob/living/carbon/human/proc/shapeshifter_select_shape() set name = "Select Body Shape" - set category = "Abilities" + set category = "Abilities.Shapeshift" if(stat || world.time < last_special) return @@ -172,7 +172,7 @@ var/list/wrapped_species_by_ref = list() /mob/living/carbon/human/proc/shapeshifter_select_colour() set name = "Select Body Colour" - set category = "Abilities" + set category = "Abilities.Shapeshift" if(stat || world.time < last_special) return @@ -210,7 +210,7 @@ var/list/wrapped_species_by_ref = list() /mob/living/carbon/human/proc/shapeshifter_select_hair_colors() set name = "Select Hair Colors" - set category = "Abilities" + set category = "Abilities.Shapeshift" if(stat || world.time < last_special) return @@ -309,7 +309,7 @@ var/list/wrapped_species_by_ref = list() /mob/living/carbon/human/proc/shapeshifter_select_eye_colour() set name = "Select Eye Color" - set category = "Abilities" + set category = "Abilities.Shapeshift" if(stat || world.time < last_special) return diff --git a/code/modules/mob/living/carbon/human/species/species_shapeshift_vr.dm b/code/modules/mob/living/carbon/human/species/species_shapeshift_vr.dm index 58b4a6d0458..5a0d5ce3a63 100644 --- a/code/modules/mob/living/carbon/human/species/species_shapeshift_vr.dm +++ b/code/modules/mob/living/carbon/human/species/species_shapeshift_vr.dm @@ -4,7 +4,7 @@ /mob/living/carbon/human/proc/shapeshifter_select_ears() set name = "Select Ears" - set category = "Abilities" + set category = "Abilities.Shapeshift" if(stat || world.time < last_special) return @@ -89,7 +89,7 @@ /mob/living/carbon/human/proc/shapeshifter_select_tail() set name = "Select Tail" - set category = "Abilities" + set category = "Abilities.Shapeshift" if(stat || world.time < last_special) return @@ -143,7 +143,7 @@ /mob/living/carbon/human/proc/shapeshifter_select_wings() set name = "Select Wings" - set category = "Abilities" + set category = "Abilities.Shapeshift" if(stat || world.time < last_special) return @@ -199,7 +199,7 @@ /mob/living/carbon/human/proc/promethean_select_opaqueness() set name = "Toggle Transparency" - set category = "Abilities" + set category = "Abilities.Shapeshift" if(stat || world.time < last_special) return diff --git a/code/modules/mob/living/carbon/human/species/station/alraune.dm b/code/modules/mob/living/carbon/human/species/station/alraune.dm index 6889cb3bbbc..239f4a4e5a2 100644 --- a/code/modules/mob/living/carbon/human/species/station/alraune.dm +++ b/code/modules/mob/living/carbon/human/species/station/alraune.dm @@ -382,7 +382,7 @@ /mob/living/carbon/human/proc/alraune_fruit_select() //So if someone doesn't want fruit/vegetables, they don't have to select one. set name = "Select fruit" set desc = "Select what fruit/vegetable you wish to grow." - set category = "Abilities" + set category = "Abilities.Alraune" var/obj/item/organ/internal/fruitgland/fruit_gland for(var/F in contents) if(istype(F, /obj/item/organ/internal/fruitgland)) diff --git a/code/modules/mob/living/carbon/human/species/station/prometheans_vr.dm b/code/modules/mob/living/carbon/human/species/station/prometheans_vr.dm index 113c3c73ed3..de24de4936f 100644 --- a/code/modules/mob/living/carbon/human/species/station/prometheans_vr.dm +++ b/code/modules/mob/living/carbon/human/species/station/prometheans_vr.dm @@ -40,7 +40,7 @@ /mob/living/carbon/human/proc/prommie_blobform() set name = "Toggle Blobform" set desc = "Switch between amorphous and humanoid forms." - set category = "Abilities" + set category = "Abilities.Promethean" set hidden = FALSE var/atom/movable/to_locate = temporary_form || src diff --git a/code/modules/mob/living/carbon/human/species/station/prommie_blob.dm b/code/modules/mob/living/carbon/human/species/station/prommie_blob.dm index 9f19887a667..a4bdf523a45 100644 --- a/code/modules/mob/living/carbon/human/species/station/prommie_blob.dm +++ b/code/modules/mob/living/carbon/human/species/station/prommie_blob.dm @@ -235,7 +235,7 @@ /mob/living/simple_mob/slime/promethean/proc/prommie_blobform() set name = "Toggle Blobform" set desc = "Switch between amorphous and humanoid forms." - set category = "Abilities" + set category = "Abilities.Promethean" set hidden = FALSE var/atom/movable/to_locate = src @@ -253,7 +253,7 @@ /mob/living/simple_mob/slime/promethean/proc/toggle_expand() set name = "Toggle Width" set desc = "Switch between smole and lorge." - set category = "Abilities" + set category = "Abilities.Promethean" set hidden = FALSE if(stat || world.time < last_special) @@ -273,7 +273,7 @@ /mob/living/simple_mob/slime/promethean/proc/toggle_shine() set name = "Toggle Shine" set desc = "Shine on you crazy diamond." - set category = "Abilities" + set category = "Abilities.Promethean" set hidden = FALSE if(stat || world.time < last_special) @@ -293,7 +293,7 @@ /mob/living/simple_mob/slime/promethean/proc/prommie_select_colour() set name = "Select Body Colour" - set category = "Abilities" + set category = "Abilities.Promethean" if(stat || world.time < last_special) return diff --git a/code/modules/mob/living/carbon/human/species/station/station_special_abilities_vr.dm b/code/modules/mob/living/carbon/human/species/station/station_special_abilities_vr.dm index 9bca0bcfc7a..0eba8870997 100644 --- a/code/modules/mob/living/carbon/human/species/station/station_special_abilities_vr.dm +++ b/code/modules/mob/living/carbon/human/species/station/station_special_abilities_vr.dm @@ -1,6 +1,6 @@ /mob/living/carbon/human/proc/reconstitute_form() //Scree's race ability.in exchange for: No cloning. set name = "Reconstitute Form" - set category = "Abilities" + set category = "Abilities.General" // Sanity is mostly handled in chimera_regenerate() if(stat == DEAD) @@ -106,7 +106,7 @@ /mob/living/carbon/human/proc/hatch() set name = "Hatch" - set category = "Abilities" + set category = "Abilities.General" if(revive_ready != REVIVING_DONE) //Hwhat? @@ -388,7 +388,7 @@ /mob/living/carbon/human/proc/bloodsuck() set name = "Partially Drain prey of blood" set desc = "Bites prey and drains them of a significant portion of blood, feeding you in the process. You may only do this once per minute." - set category = "Abilities" + set category = "Abilities.General" if(stat || paralysis || stunned || weakened || lying || restrained() || buckled) @@ -510,7 +510,7 @@ /mob/living/carbon/human/proc/succubus_drain() set name = "Drain prey of nutrition" set desc = "Slowly drain prey of all the nutrition in their body, feeding you in the process. You may only do this to one person at a time." - set category = "Abilities" + set category = "Abilities.Succubus" if(!ishuman(src)) return //If you're not a human you don't have permission to do this. var/mob/living/carbon/human/C = src @@ -573,7 +573,7 @@ /mob/living/carbon/human/proc/succubus_drain_lethal() set name = "Lethally drain prey" //Provide a warning that THIS WILL KILL YOUR PREY. set desc = "Slowly drain prey of all the nutrition in their body, feeding you in the process. Once prey run out of nutrition, you will begin to drain them lethally. You may only do this to one person at a time." - set category = "Abilities" + set category = "Abilities.Succubus" if(!ishuman(src)) return //If you're not a human you don't have permission to do this. @@ -665,7 +665,7 @@ /mob/living/carbon/human/proc/slime_feed() set name = "Feed prey with self" set desc = "Slowly feed prey with your body, draining you in the process. You may only do this to one person at a time." - set category = "Abilities" + set category = "Abilities.Vore" if(!ishuman(src)) return //If you're not a human you don't have permission to do this. var/mob/living/carbon/human/C = src @@ -726,7 +726,7 @@ /mob/living/carbon/human/proc/succubus_drain_finalize() set name = "Drain/Feed Finalization" set desc = "Toggle to allow for draining to be prolonged. Turn this on to make it so prey will be knocked out/die while being drained, or you will feed yourself to the prey's selected stomach if you're feeding them. Can be toggled at any time." - set category = "Abilities" + set category = "Abilities.Succubus" var/mob/living/carbon/human/C = src C.drain_finalized = !C.drain_finalized @@ -818,7 +818,7 @@ /mob/living/proc/shred_limb() set name = "Damage/Remove Prey's Organ" set desc = "Severely damages prey's organ. If the limb is already severely damaged, it will be torn off." - set category = "Abilities" + set category = "Abilities.Vore" //can_shred() will return a mob we can shred, if we can shred any. var/mob/living/carbon/human/T = can_shred() @@ -894,13 +894,13 @@ /mob/living/proc/shred_limb_temp() set name = "Damage/Remove Prey's Organ (beartrap)" set desc = "Severely damages prey's organ. If the limb is already severely damaged, it will be torn off." - set category = "Abilities" + set category = "Abilities.Vore" shred_limb() /mob/living/proc/flying_toggle() set name = "Toggle Flight" set desc = "While flying over open spaces, you will use up some nutrition. If you run out nutrition, you will fall." - set category = "Abilities" + set category = "Abilities.General" var/mob/living/carbon/human/C = src if(!C.wing_style) //The species var isn't taken into account here, as it's only purpose is to give this proc to a person. @@ -923,7 +923,7 @@ /mob/living/proc/flying_vore_toggle() set name = "Toggle Flight Vore" set desc = "Allows you to engage in voracious misadventures while flying." - set category = "Abilities" + set category = "Abilities.Vore" flight_vore = !flight_vore if(flight_vore) @@ -935,7 +935,7 @@ /mob/living/proc/start_wings_hovering() set name = "Hover" set desc = "Allows you to stop gliding and hover. This will take a fair amount of nutrition to perform." - set category = "Abilities" + set category = "Abilities.General" var/mob/living/carbon/human/C = src if(!C.wing_style) //The species var isn't taken into account here, as it's only purpose is to give this proc to a person. @@ -967,13 +967,13 @@ /mob/living/proc/toggle_pass_table() set name = "Toggle Agility" //Dunno a better name for this. You have to be pretty agile to hop over stuff!!! set desc = "Allows you to start/stop hopping over things such as hydroponics trays, tables, and railings." - set category = "Abilities" + set category = "Abilities.General" pass_flags ^= PASSTABLE //I dunno what this fancy ^= is but Aronai gave it to me. to_chat(src, "You [pass_flags&PASSTABLE ? "will" : "will NOT"] move over tables/railings/trays!") /mob/living/carbon/human/proc/check_silk_amount() set name = "Check Silk Amount" - set category = "Abilities" + set category = "Abilities.Weaver" if(species.is_weaver) to_chat(src, "Your silk reserves are at [species.silk_reserve]/[species.silk_max_reserve].") @@ -982,7 +982,7 @@ /mob/living/carbon/human/proc/toggle_silk_production() set name = "Toggle Silk Production" - set category = "Abilities" + set category = "Abilities.Weaver" if(species.is_weaver) species.silk_production = !(species.silk_production) @@ -992,7 +992,7 @@ /mob/living/carbon/human/proc/weave_structure() set name = "Weave Structure" - set category = "Abilities" + set category = "Abilities.Weaver" if(!(species.is_weaver)) to_chat(src, span_warning("You are not a weaver! How are you doing this? Tell a developer!")) @@ -1052,7 +1052,7 @@ /mob/living/carbon/human/proc/weave_item() set name = "Weave Item" - set category = "Abilities" + set category = "Abilities.Weaver" if(!(species.is_weaver)) return @@ -1106,7 +1106,7 @@ /mob/living/carbon/human/proc/set_silk_color() set name = "Set Silk Color" - set category = "Abilities" + set category = "Abilities.Weaver" if(!(species.is_weaver)) to_chat(src, span_warning("You are not a weaver! How are you doing this? Tell a developer!")) @@ -1118,7 +1118,7 @@ /mob/living/carbon/human/proc/toggle_eye_glow() set name = "Toggle Eye Glowing" - set category = "Abilities" + set category = "Abilities.General" species.has_glowing_eyes = !species.has_glowing_eyes update_eyes() @@ -1128,7 +1128,7 @@ /mob/living/carbon/human/proc/enter_cocoon() set name = "Spin Cocoon" - set category = "Abilities" + set category = "Abilities.Weaver" if(!isturf(loc)) to_chat(src, "You don't have enough space to spin a cocoon!") return @@ -1153,7 +1153,7 @@ /mob/living/carbon/human/proc/water_stealth() set name = "Dive under water / Resurface" set desc = "Dive under water, allowing for you to be stealthy and move faster." - set category = "Abilities" + set category = "Abilities.General" if(last_special > world.time) return @@ -1185,7 +1185,7 @@ /mob/living/carbon/human/proc/underwater_devour() set name = "Devour From Water" set desc = "Grab something in the water with you and devour them with your selected stomach." - set category = "Abilities" + set category = "Abilities.Vore" if(last_special > world.time) return @@ -1241,7 +1241,7 @@ /mob/living/carbon/human/proc/toggle_pain_module() set name = "Toggle pain simulation." set desc = "Turn on your pain simulation for that organic experience! Or turn it off for repairs, or if it's too much." - set category = "Abilities" + set category = "Abilities.General" if(synth_cosmetic_pain) to_chat(src, span_notice(" You turn off your pain simulators.")) @@ -1256,7 +1256,7 @@ /mob/living/proc/long_vore() // Allows the user to tongue grab a creature in range. Made a /living proc so frogs can frog you. set name = "Grab Prey With Appendage" - set category = "Abilities" + set category = "Abilities.Vore" set desc = "Grab a target with any of your appendages!" if(stat || paralysis || weakened || stunned || world.time < last_special) //No tongue flicking while stunned. @@ -1468,7 +1468,7 @@ /mob/living/proc/target_lunge() //The leaper leap, but usable as an ability set name = "Lunge At Prey" - set category = "Abilities" + set category = "Abilities.Vore" set desc = "Dive atop your prey and gobble them up!" var/leap_warmup = 1 SECOND //Easy to modify @@ -1538,7 +1538,7 @@ /mob/living/proc/injection() // Allows the user to inject reagents into others somehow, like stinging, or biting. set name = "Injection" - set category = "Abilities" + set category = "Abilities.General" set desc = "Inject another being with something!" if(stat || paralysis || weakened || stunned || world.time < last_special) //Epic copypasta from tongue grabbing. diff --git a/code/modules/mob/living/carbon/human/species/station/traits_vr/traits_tutorial.dm b/code/modules/mob/living/carbon/human/species/station/traits_vr/traits_tutorial.dm index 6da754903d1..e5671811fc2 100644 --- a/code/modules/mob/living/carbon/human/species/station/traits_vr/traits_tutorial.dm +++ b/code/modules/mob/living/carbon/human/species/station/traits_vr/traits_tutorial.dm @@ -27,7 +27,7 @@ TGUI frontend path: tgui\packages\tgui\interfaces\TraitTutorial.tsx /mob/living/carbon/human/proc/trait_tutorial() set name = "Explain Custom Traits" set desc = "Click this verb to obtain a detailed tutorial on your selected traits. " - set category = "Abilities" + set category = "Abilities.General" var/datum/tgui_module/trait_tutorial_tgui/fancy_UI if(!fancy_UI) fancy_UI = new /datum/tgui_module/trait_tutorial_tgui/ //Preventing a bunch of instances being spawned all over the place. Hopefully diff --git a/code/modules/mob/living/carbon/human/species/virtual_reality/avatar.dm b/code/modules/mob/living/carbon/human/species/virtual_reality/avatar.dm index 9f72a2621c5..c8d044330bd 100644 --- a/code/modules/mob/living/carbon/human/species/virtual_reality/avatar.dm +++ b/code/modules/mob/living/carbon/human/species/virtual_reality/avatar.dm @@ -54,7 +54,7 @@ /mob/living/carbon/human/proc/shapeshifter_change_opacity() set name = "Toggle Opacity" - set category = "Abilities" + set category = "Abilities.Shapeshifter" if(stat || world.time < last_special) return @@ -88,7 +88,7 @@ // exit_vr is called on the vr mob, and puts the mind back into the original mob /mob/living/carbon/human/proc/exit_vr() set name = "Exit Virtual Reality" - set category = "Abilities" + set category = "Abilities.VR" if(!vr_holder) return diff --git a/code/modules/mob/living/carbon/human/species/xenomorphs/alien_powers.dm b/code/modules/mob/living/carbon/human/species/xenomorphs/alien_powers.dm index 7c69a214c15..346259c449f 100644 --- a/code/modules/mob/living/carbon/human/species/xenomorphs/alien_powers.dm +++ b/code/modules/mob/living/carbon/human/species/xenomorphs/alien_powers.dm @@ -56,7 +56,7 @@ /mob/living/carbon/human/proc/transfer_plasma(mob/living/carbon/human/M as mob in oview()) set name = "Transfer Plasma" set desc = "Transfer Plasma to another alien" - set category = "Abilities" + set category = "Abilities.Alien" if (get_dist(src,M) <= 1) to_chat(src, span_alium("You need to be closer.")) @@ -81,7 +81,7 @@ set name = "Lay Egg (500)" //Cost is entire queen reserve, to compensate being able to reproduce on it's own set desc = "Lay an egg that will eventually hatch into a new xenomorph larva. Life finds a way." - set category = "Abilities" + set category = "Abilities.Alien" if(!CONFIG_GET(flag/aliens_allowed)) to_chat(src, "You begin to lay an egg, but hesitate. You suspect it isn't allowed.") @@ -102,7 +102,7 @@ /mob/living/carbon/human/proc/evolve() set name = "Evolve (500)" set desc = "Produce an internal egg sac capable of spawning children. Only one queen can exist at a time." - set category = "Abilities" + set category = "Abilities.Alien" if(alien_queen_exists()) to_chat(src, span_notice("We already have an active queen.")) @@ -117,7 +117,7 @@ /mob/living/carbon/human/proc/plant() set name = "Plant Weeds (50)" set desc = "Plants some alien weeds" - set category = "Abilities" + set category = "Abilities.Alien" if(check_alien_ability(50,1,O_RESIN)) visible_message(span_alium(span_bold("[src] has planted some alien weeds!"))) @@ -149,7 +149,7 @@ /mob/living/carbon/human/proc/corrosive_acid(O as obj|turf in oview(1)) //If they right click to corrode, an error will flash if its an invalid target./N set name = "Corrosive Acid (200)" set desc = "Drench an object in acid, destroying it over time." - set category = "Abilities" + set category = "Abilities.Alien" if(!(O in oview(1))) to_chat(src, span_alium("[O] is too far away.")) @@ -186,7 +186,7 @@ /mob/living/carbon/human/proc/neurotoxin() set name = "Toggle Neurotoxic Spit (40)" set desc = "Readies a neurotoxic spit, which paralyzes the target for a short time if they are not wearing protective gear." - set category = "Abilities" + set category = "Abilities.Alien" if(spitting) to_chat(src, span_alium("You stop preparing to spit.")) @@ -207,7 +207,7 @@ /mob/living/carbon/human/proc/acidspit() set name = "Toggle Acid Spit (50)" set desc = "Readies an acidic spit, which burns the target if they are not wearing protective gear." - set category = "Abilities" + set category = "Abilities.Alien" if(spitting) to_chat(src, span_alium("You stop preparing to spit.")) @@ -228,7 +228,7 @@ /mob/living/carbon/human/proc/resin() //Gurgs : Refactored resin ability, big thanks to Jon. set name = "Secrete Resin (75)" set desc = "Secrete tough malleable resin." - set category = "Abilities" + set category = "Abilities.Alien" var/list/options = list("resin door","resin wall","resin membrane","nest","resin blob") for(var/option in options) @@ -276,7 +276,7 @@ return /mob/living/carbon/human/proc/leap() - set category = "Abilities" + set category = "Abilities.Alien" set name = "Leap" set desc = "Leap at a target and grab them aggressively." @@ -344,7 +344,7 @@ G.synch() /mob/living/carbon/human/proc/gut() - set category = "Abilities" + set category = "Abilities.Alien" set name = "Slaughter" set desc = "While grabbing someone aggressively, rip their guts out or tear them apart." diff --git a/code/modules/mob/living/carbon/human/update_icons.dm b/code/modules/mob/living/carbon/human/update_icons.dm index e90d7771edd..116c3121763 100644 --- a/code/modules/mob/living/carbon/human/update_icons.dm +++ b/code/modules/mob/living/carbon/human/update_icons.dm @@ -1343,15 +1343,21 @@ var/global/list/damage_icon_parts = list() //see UpdateDamageIcon() if(ear_secondary_style && !(head && (head.flags_inv & BLOCKHEADHAIR))) var/icon/ears_s = new/icon("icon" = ear_secondary_style.icon, "icon_state" = ear_secondary_style.icon_state) if(ear_secondary_style.do_colouration) - ears_s.Blend(LAZYACCESS(ear_secondary_colors, 1), ear_secondary_style.color_blend_mode) + var/color = LAZYACCESS(ear_secondary_colors, 1) + if(color) + ears_s.Blend(color, ear_secondary_style.color_blend_mode) if(ear_secondary_style.extra_overlay) var/icon/overlay = new/icon("icon" = ear_secondary_style.icon, "icon_state" = ear_secondary_style.extra_overlay) - overlay.Blend(LAZYACCESS(ear_secondary_colors, 2), ear_secondary_style.color_blend_mode) + var/color = LAZYACCESS(ear_secondary_colors, 2) + if(color) + overlay.Blend(color, ear_secondary_style.color_blend_mode) ears_s.Blend(overlay, ICON_OVERLAY) qdel(overlay) if(ear_secondary_style.extra_overlay2) //MORE COLOURS IS BETTERER var/icon/overlay = new/icon("icon" = ear_secondary_style.icon, "icon_state" = ear_secondary_style.extra_overlay2) - overlay.Blend(LAZYACCESS(ear_secondary_colors, 3), ear_secondary_style.color_blend_mode) + var/color = LAZYACCESS(ear_secondary_colors, 3) + if(color) + overlay.Blend(color, ear_secondary_style.color_blend_mode) ears_s.Blend(overlay, ICON_OVERLAY) qdel(overlay) if(!rendered) @@ -1371,13 +1377,13 @@ var/global/list/damage_icon_parts = list() //see UpdateDamageIcon() //If you have a custom tail selected if(tail_style && !(wear_suit && wear_suit.flags_inv & HIDETAIL && !istaurtail(tail_style)) && !tail_hidden) - var/icon/tail_s = new/icon("icon" = (tail_style.can_loaf && resting) ? tail_style.icon_loaf : tail_style.icon, "icon_state" = (wagging && tail_style.ani_state ? tail_style.ani_state : tail_style.icon_state)) //CHOMPEdit + var/icon/tail_s = new/icon("icon" = (tail_style.can_loaf && resting) ? tail_style.icon_loaf : tail_style.icon, "icon_state" = (wagging && tail_style.ani_state ? tail_style.ani_state : tail_style.icon_state)) if(tail_style.can_loaf && !is_shifted) pixel_y = (resting) ? -tail_style.loaf_offset*size_multiplier : default_pixel_y //move player down, then taur up, to fit the overlays correctly // VOREStation Edit: Taur Loafing if(tail_style.do_colouration) tail_s.Blend(rgb(src.r_tail, src.g_tail, src.b_tail), tail_style.color_blend_mode) if(tail_style.extra_overlay) - var/icon/overlay = new/icon("icon" = (tail_style?.can_loaf && resting) ? tail_style.icon_loaf : tail_style.icon, "icon_state" = tail_style.extra_overlay) //CHOMPEdit + var/icon/overlay = new/icon("icon" = (tail_style?.can_loaf && resting) ? tail_style.icon_loaf : tail_style.icon, "icon_state" = tail_style.extra_overlay) if(wagging && tail_style.ani_state) overlay = new/icon("icon" = (tail_style?.can_loaf && resting) ? tail_style.icon_loaf : tail_style.icon, "icon_state" = tail_style.extra_overlay_w) //RS EDIT overlay.Blend(rgb(src.r_tail2, src.g_tail2, src.b_tail2), tail_style.color_blend_mode) @@ -1389,7 +1395,7 @@ var/global/list/damage_icon_parts = list() //see UpdateDamageIcon() qdel(overlay) if(tail_style.extra_overlay2) - var/icon/overlay = new/icon("icon" = (tail_style?.can_loaf && resting) ? tail_style.icon_loaf : tail_style.icon, "icon_state" = tail_style.extra_overlay2) //CHOMPEdit + var/icon/overlay = new/icon("icon" = (tail_style?.can_loaf && resting) ? tail_style.icon_loaf : tail_style.icon, "icon_state" = tail_style.extra_overlay2) if(wagging && tail_style.ani_state) overlay = new/icon("icon" = (tail_style?.can_loaf && resting) ? tail_style.icon_loaf : tail_style.icon, "icon_state" = tail_style.extra_overlay2_w) //RS EDIT overlay.Blend(rgb(src.r_tail3, src.g_tail3, src.b_tail3), tail_style.color_blend_mode) diff --git a/code/modules/mob/living/carbon/lick_wounds.dm b/code/modules/mob/living/carbon/lick_wounds.dm index 880e7358b94..68dcae6789f 100644 --- a/code/modules/mob/living/carbon/lick_wounds.dm +++ b/code/modules/mob/living/carbon/lick_wounds.dm @@ -1,6 +1,6 @@ /mob/living/carbon/human/proc/lick_wounds(var/mob/living/carbon/M as mob in view(1)) // Allows the user to lick themselves. Given how rarely this trait is used, I don't see an issue with a slight buff. set name = "Lick Wounds" - set category = "Abilities" + set category = "Abilities.General" set desc = "Disinfect and heal small wounds with your saliva." if(stat || paralysis || weakened || stunned) diff --git a/code/modules/mob/living/carbon/viruses.dm b/code/modules/mob/living/carbon/viruses.dm deleted file mode 100644 index f57bc878a00..00000000000 --- a/code/modules/mob/living/carbon/viruses.dm +++ /dev/null @@ -1,48 +0,0 @@ -/mob/living/carbon/proc/handle_viruses() - - if(status_flags & GODMODE) return 0 //godmode - - if(bodytemperature > 406) - for (var/ID in virus2) - var/datum/disease2/disease/V = virus2[ID] - V.cure(src) - - if(life_tick % 3) //don't spam checks over all objects in view every tick. - for(var/obj/effect/decal/cleanable/O in view(1,src)) - if(istype(O,/obj/effect/decal/cleanable/blood)) - var/obj/effect/decal/cleanable/blood/B = O - if(B.virus2.len) - for (var/ID in B.virus2) - var/datum/disease2/disease/V = B.virus2[ID] - infect_virus2(src,V) - - else if(istype(O,/obj/effect/decal/cleanable/mucus)) - var/obj/effect/decal/cleanable/mucus/M = O - if(M.virus2.len) - for (var/ID in M.virus2) - var/datum/disease2/disease/V = M.virus2[ID] - infect_virus2(src,V) - - else if(istype(O,/obj/effect/decal/cleanable/vomit)) - var/obj/effect/decal/cleanable/vomit/Vom = O - if(Vom.virus2.len) - for (var/ID in Vom.virus2) - var/datum/disease2/disease/V = Vom.virus2[ID] - infect_virus2(src,V) - - if(virus2.len) - for (var/ID in virus2) - var/datum/disease2/disease/V = virus2[ID] - if(isnull(V)) // Trying to figure out a runtime error that keeps repeating - CRASH("virus2 nulled before calling activate()") - else - V.activate(src) - // activate may have deleted the virus - if(!V) continue - - // check if we're immune - var/list/common_antibodies = V.antigen & src.antibodies - if(common_antibodies.len) - V.dead = 1 - - return \ No newline at end of file diff --git a/code/modules/mob/living/default_language.dm b/code/modules/mob/living/default_language.dm index 847f1b221bf..66cdcb28adb 100644 --- a/code/modules/mob/living/default_language.dm +++ b/code/modules/mob/living/default_language.dm @@ -1,10 +1,28 @@ /mob/living var/datum/language/default_language -/mob/living/verb/set_default_language(language as null|anything in languages) +/mob/living/verb/set_default_language() set name = "Set Default Language" - set category = "IC" + set category = "IC.Settings" + var/language = tgui_input_list(usr, "Select your default language", "Available languages", languages) + + apply_default_language(language) + +// Silicons can't neccessarily speak everything in their languages list +/mob/living/silicon/set_default_language() + var/language = tgui_input_list(usr, "Select your default language", "Available languages", speech_synthesizer_langs) + // Silicons have no species language usually. So let's default them to GALCOM + if(!language) + to_chat(src, span_notice("You will now speak your standard default language, common, if you do not specify a language when speaking.")) + for(var/datum/language/lang in speech_synthesizer_langs) + if(lang.name == LANGUAGE_GALCOM) + default_language = lang + break + return + apply_default_language(language) + +/mob/living/proc/apply_default_language(var/language) if (only_species_language && language != GLOB.all_languages[src.species_language]) to_chat(src, span_notice("You can only speak your species language, [src.species_language].")) return 0 @@ -22,13 +40,9 @@ to_chat(src, span_notice("You will now speak whatever your standard default language is if you do not specify one when speaking.")) default_language = language -// Silicons can't neccessarily speak everything in their languages list -/mob/living/silicon/set_default_language(language as null|anything in speech_synthesizer_langs) - ..() - /mob/living/verb/check_default_language() set name = "Check Default Language" - set category = "IC" + set category = "IC.Game" if(default_language) to_chat(src, span_notice("You are currently speaking [default_language] by default.")) diff --git a/code/modules/mob/living/life.dm b/code/modules/mob/living/life.dm index a15b0e115ea..a599ff38e2e 100644 --- a/code/modules/mob/living/life.dm +++ b/code/modules/mob/living/life.dm @@ -51,6 +51,10 @@ //Chemicals in the body, this is moved over here so that blood can be added after death handle_chemicals_in_body() + // Handle viruses - Dead or not! + if(LAZYLEN(viruses)) + handle_diseases() + //Handle temperature/pressure differences between body and environment if(environment) handle_environment(environment) diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm index 256f8d3c030..a81282f3646 100644 --- a/code/modules/mob/living/living.dm +++ b/code/modules/mob/living/living.dm @@ -104,7 +104,7 @@ /mob/living/verb/succumb() set name = "Succumb to death" - set category = "IC" + set category = "IC.Game" set desc = "Press this button if you are in crit and wish to die. Use this sparingly (ending a scene, no medical, etc.)" var/confirm1 = tgui_alert(usr, "Pressing this button will kill you instantenously! Are you sure you wish to proceed?", "Confirm wish to succumb", list("No","Yes")) var/confirm2 = "No" @@ -123,7 +123,7 @@ /mob/living/verb/toggle_afk() set name = "Toggle AFK" - set category = "IC" + set category = "IC.Game" set desc = "Mark yourself as Away From Keyboard, or clear that status!" if(away_from_keyboard) remove_status_indicator("afk") @@ -710,7 +710,7 @@ /mob/living/proc/Examine_OOC() set name = "Examine Meta-Info (OOC)" - set category = "OOC" + set category = "OOC.Game" set src in view() //VOREStation Edit Start - Making it so SSD people have prefs with fallback to original style. if(CONFIG_GET(flag/allow_metadata)) @@ -729,7 +729,7 @@ /mob/living/verb/resist() set name = "Resist" - set category = "IC" + set category = "IC.Game" if(!incapacitated(INCAPACITATION_KNOCKOUT) && (last_resist_time + RESIST_COOLDOWN < world.time)) last_resist_time = world.time @@ -789,7 +789,7 @@ /mob/living/verb/lay_down() set name = "Rest" - set category = "IC" + set category = "IC.Game" resting = !resting to_chat(src, span_notice("You are now [resting ? "resting" : "getting up"].")) @@ -1334,7 +1334,7 @@ /mob/living/verb/mob_sleep() set name = "Sleep" - set category = "IC" + set category = "IC.Game" if(!toggled_sleeping && alert(src, "Are you sure you wish to go to sleep? You will snooze until you use the Sleep verb again.", "Sleepy Time", "No", "Yes") == "No") return toggled_sleeping = !toggled_sleeping diff --git a/code/modules/mob/living/living_powers.dm b/code/modules/mob/living/living_powers.dm index 740cbed0742..3b6806b9f9b 100644 --- a/code/modules/mob/living/living_powers.dm +++ b/code/modules/mob/living/living_powers.dm @@ -8,7 +8,7 @@ /mob/living/proc/hide() set name = "Hide" set desc = "Allows to hide beneath tables or certain items. Toggled on or off." - set category = "Abilities" + set category = "Abilities.General" if(stat == DEAD || paralysis || weakened || stunned || restrained() || buckled || LAZYLEN(grabbed_by) || has_buckled_mobs()) //VORE EDIT: Check for has_buckled_mobs() (taur riding) return diff --git a/code/modules/mob/living/living_vr.dm b/code/modules/mob/living/living_vr.dm index 82850fea56e..fe8b80b5357 100644 --- a/code/modules/mob/living/living_vr.dm +++ b/code/modules/mob/living/living_vr.dm @@ -4,7 +4,7 @@ ..() /mob/living/verb/customsay() - set category = "IC" + set category = "IC.Settings" set name = "Customize Speech Verbs" set desc = "Customize the text which appears when you type- e.g. 'says', 'asks', 'exclaims'." @@ -25,7 +25,7 @@ /mob/living/verb/set_metainfo() set name = "Set OOC Metainfo" set desc = "Sets OOC notes about yourself or your RP preferences or status." - set category = "OOC" + set category = "OOC.Game Settings" if(usr != src) return @@ -100,7 +100,7 @@ /mob/living/verb/set_custom_link() set name = "Set Custom Link" set desc = "Set a custom link to show up with your examine text." - set category = "IC" + set category = "IC.Settings" if(usr != src) return @@ -117,7 +117,7 @@ /mob/living/verb/set_voice_freq() set name = "Set Voice Frequency" set desc = "Sets your voice frequency to be higher or lower pitched!" - set category = "OOC" + set category = "OOC.Game Settings" var/list/preset_voice_freqs = list("high" = MAX_VOICE_FREQ, "middle-high" = 56250, "middle" = 425000, "middle-low"= 28750, "low" = MIN_VOICE_FREQ, "custom" = 1, "random" = 0) var/choice = tgui_input_list(src, "What would you like to set your voice frequency to?", "Voice Frequency", preset_voice_freqs) @@ -138,7 +138,7 @@ /mob/living/verb/set_voice_type() set name = "Set Voice Type" set desc = "Sets your voice style!" - set category = "OOC" + set category = "OOC.Game Settings" var/list/possible_voice_types = list( "beep-boop", diff --git a/code/modules/mob/living/riding.dm b/code/modules/mob/living/riding.dm index 5319895da70..1174ee30753 100644 --- a/code/modules/mob/living/riding.dm +++ b/code/modules/mob/living/riding.dm @@ -1,6 +1,6 @@ /mob/living/proc/toggle_rider_reins() set name = "Give Reins" - set category = "Abilities" + set category = "Abilities.General" set desc = "Let people riding on you control your movement." if(riding_datum) diff --git a/code/modules/mob/living/silicon/ai/ai.dm b/code/modules/mob/living/silicon/ai/ai.dm index 19c7f4bab62..74467c67a9e 100644 --- a/code/modules/mob/living/silicon/ai/ai.dm +++ b/code/modules/mob/living/silicon/ai/ai.dm @@ -347,7 +347,7 @@ var/list/ai_verbs_default = list( update_use_power(USE_POWER_ACTIVE) /mob/living/silicon/ai/proc/pick_icon() - set category = "AI Settings" + set category = "AI.Settings" set name = "Set AI Core Display" if(stat || aiRestorePowerRoutine) return @@ -359,7 +359,7 @@ var/list/ai_verbs_default = list( /mob/living/silicon/ai/var/message_cooldown = 0 /mob/living/silicon/ai/proc/ai_announcement() - set category = "AI Commands" + set category = "AI.Station Commands" set name = "Make Station Announcement" if(check_unable(AI_CHECK_WIRELESS | AI_CHECK_RADIO)) return @@ -380,7 +380,7 @@ var/list/ai_verbs_default = list( message_cooldown = 0 /mob/living/silicon/ai/proc/ai_call_shuttle() - set category = "AI Commands" + set category = "AI.Station Commands" set name = "Call Emergency Shuttle" if(check_unable(AI_CHECK_WIRELESS)) return @@ -401,7 +401,7 @@ var/list/ai_verbs_default = list( post_status(src, "shuttle", user = src) /mob/living/silicon/ai/proc/ai_recall_shuttle() - set category = "AI Commands" + set category = "AI.Station Commands" set name = "Recall Emergency Shuttle" if(check_unable(AI_CHECK_WIRELESS)) @@ -417,7 +417,7 @@ var/list/ai_verbs_default = list( /mob/living/silicon/ai/var/emergency_message_cooldown = 0 /mob/living/silicon/ai/proc/ai_emergency_message() - set category = "AI Commands" + set category = "AI.Station Commands" set name = "Send Emergency Message" if(check_unable(AI_CHECK_WIRELESS)) @@ -538,7 +538,7 @@ var/list/ai_verbs_default = list( return 1 /mob/living/silicon/ai/cancel_camera() - set category = "AI Commands" + set category = "AI.Camera Control" set name = "Cancel Camera View" view_core() @@ -561,7 +561,7 @@ var/list/ai_verbs_default = list( return cameralist /mob/living/silicon/ai/proc/ai_network_change(var/network in get_camera_network_list()) - set category = "AI Commands" + set category = "AI.Camera Control" set name = "Jump To Network" unset_machine() @@ -584,7 +584,7 @@ var/list/ai_verbs_default = list( //End of code by Mord_Sith /mob/living/silicon/ai/proc/ai_statuschange() - set category = "AI Settings" + set category = "AI.Settings" set name = "AI Status" if(check_unable(AI_CHECK_WIRELESS)) @@ -597,7 +597,7 @@ var/list/ai_verbs_default = list( /mob/living/silicon/ai/proc/ai_hologram_change() set name = "Change Hologram" set desc = "Change the default hologram available to AI to something else." - set category = "AI Settings" + set category = "AI.Settings" if(check_unable()) return @@ -725,7 +725,7 @@ var/list/ai_verbs_default = list( /mob/living/silicon/ai/proc/toggle_camera_light() set name = "Toggle Camera Light" set desc = "Toggles the light on the camera the AI is looking through." - set category = "AI Commands" + set category = "AI.Camera Control" if(check_unable()) return @@ -799,7 +799,7 @@ var/list/ai_verbs_default = list( /mob/living/silicon/ai/proc/control_integrated_radio() set name = "Radio Settings" set desc = "Allows you to change settings of your radio." - set category = "AI Settings" + set category = "AI.Settings" if(check_unable(AI_CHECK_RADIO)) return @@ -810,7 +810,7 @@ var/list/ai_verbs_default = list( /mob/living/silicon/ai/proc/sensor_mode() set name = "Toggle Sensor Augmentation" //VOREStation Add - set category = "AI Settings" + set category = "AI.Settings" set desc = "Augment visual feed with internal sensor overlays" sensor_type = !sensor_type //VOREStation Add to_chat(usr, "You [sensor_type ? "enable" : "disable"] your sensors.") //VOREStation Add @@ -818,7 +818,7 @@ var/list/ai_verbs_default = list( /mob/living/silicon/ai/proc/toggle_hologram_movement() set name = "Toggle Hologram Movement" - set category = "AI Settings" + set category = "AI.Settings" set desc = "Toggles hologram movement based on moving with your virtual eye." hologram_follow = !hologram_follow @@ -910,7 +910,7 @@ var/list/ai_verbs_default = list( // Pass lying down or getting up to our pet human, if we're in a rig. /mob/living/silicon/ai/lay_down() set name = "Rest" - set category = "IC" + set category = "IC.Game" resting = 0 var/obj/item/rig/rig = src.get_rig() @@ -993,12 +993,12 @@ var/list/ai_verbs_default = list( /mob/living/silicon/ai/proc/toggle_multicam_verb() set name = "Toggle Multicam" - set category = "AI Commands" + set category = "AI.Camera Control" toggle_multicam() /mob/living/silicon/ai/proc/add_multicam_verb() set name = "Add Multicam Viewport" - set category = "AI Commands" + set category = "AI.Camera Control" drop_new_multicam() //Special subtype kept around for global announcements diff --git a/code/modules/mob/living/silicon/ai/ai_remote_control.dm b/code/modules/mob/living/silicon/ai/ai_remote_control.dm index cfe1d2873a1..c1871a0358f 100644 --- a/code/modules/mob/living/silicon/ai/ai_remote_control.dm +++ b/code/modules/mob/living/silicon/ai/ai_remote_control.dm @@ -67,7 +67,7 @@ target.post_deploy() /mob/living/silicon/ai/proc/deploy_to_shell_act() - set category = "AI Commands" + set category = "AI.Commands" set name = "Deploy to Shell" deploy_to_shell() // This is so the AI is not prompted with a list of all mobs when using the 'real' proc. diff --git a/code/modules/mob/living/silicon/ai/latejoin.dm b/code/modules/mob/living/silicon/ai/latejoin.dm index 4afac25fbc6..37606a56610 100644 --- a/code/modules/mob/living/silicon/ai/latejoin.dm +++ b/code/modules/mob/living/silicon/ai/latejoin.dm @@ -12,7 +12,7 @@ var/global/list/empty_playable_ai_cores = list() /mob/living/silicon/ai/verb/store_core() set name = "Store Core" - set category = "OOC" + set category = "OOC.Game" set desc = "Enter intelligence storage. This is functionally equivalent to cryo or robotic storage, freeing up your job slot." if(ticker && ticker.mode && ticker.mode.name == "AI malfunction") diff --git a/code/modules/mob/living/silicon/ai/laws.dm b/code/modules/mob/living/silicon/ai/laws.dm index ad051cddff6..82874155ba6 100755 --- a/code/modules/mob/living/silicon/ai/laws.dm +++ b/code/modules/mob/living/silicon/ai/laws.dm @@ -1,5 +1,5 @@ /mob/living/silicon/ai/proc/show_laws_verb() - set category = "AI Commands" + set category = "AI.Commands" set name = "Show Laws" src.show_laws() @@ -22,6 +22,6 @@ R.show_laws() /mob/living/silicon/ai/proc/ai_checklaws() - set category = "AI Commands" + set category = "AI.Commands" set name = "State Laws" subsystem_law_manager() diff --git a/code/modules/mob/living/silicon/pai/admin.dm b/code/modules/mob/living/silicon/pai/admin.dm index ebd161c4f22..6620035ffa8 100644 --- a/code/modules/mob/living/silicon/pai/admin.dm +++ b/code/modules/mob/living/silicon/pai/admin.dm @@ -1,7 +1,7 @@ // Originally a debug verb, made it a proper adminverb for ~fun~ /client/proc/makePAI(turf/t in view(), name as text, pai_key as null|text) set name = "Make pAI" - set category = "Admin" + set category = "Admin.Events" if(!check_rights(R_ADMIN|R_EVENT|R_DEBUG)) return diff --git a/code/modules/mob/living/silicon/pai/pai.dm b/code/modules/mob/living/silicon/pai/pai.dm index 98d1a2ee6a8..8d22b5e96d1 100644 --- a/code/modules/mob/living/silicon/pai/pai.dm +++ b/code/modules/mob/living/silicon/pai/pai.dm @@ -227,7 +227,7 @@ return 1 /mob/living/silicon/pai/verb/reset_record_view() - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set name = "Reset Records Software" securityActive1 = null @@ -240,7 +240,7 @@ to_chat(usr, span_notice("You reset your record-viewing software.")) /mob/living/silicon/pai/cancel_camera() - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set name = "Cancel Camera View" src.reset_view(null) src.unset_machine() @@ -251,7 +251,7 @@ // to it. Really this deserves its own file, but for the moment it can sit here. ~ Z /mob/living/silicon/pai/verb/fold_out() - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set name = "Unfold Chassis" if(stat || sleeping || paralysis || weakened) @@ -309,7 +309,7 @@ update_icon() /mob/living/silicon/pai/verb/fold_up() - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set name = "Collapse Chassis" if(stat || sleeping || paralysis || weakened) @@ -326,7 +326,7 @@ /* //VOREStation Removal Start /mob/living/silicon/pai/proc/choose_chassis() - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set name = "Choose Chassis" var/choice @@ -345,7 +345,7 @@ */ /mob/living/silicon/pai/proc/choose_verbs() - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set name = "Choose Speech Verbs" var/choice = tgui_input_list(usr,"What theme would you like to use for your speech verbs?","Theme Choice", possible_say_verbs) @@ -358,7 +358,7 @@ /mob/living/silicon/pai/lay_down() set name = "Rest" - set category = "IC" + set category = "IC.Game" // Pass lying down or getting up to our pet human, if we're in a rig. if(istype(src.loc,/obj/item/paicard)) @@ -522,7 +522,7 @@ /mob/living/silicon/pai/verb/allowmodification() set name = "Change Access Modifcation Permission" - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set desc = "Allows people to modify your access or block people from modifying your access." if(idaccessible == 0) @@ -535,7 +535,7 @@ /mob/living/silicon/pai/verb/wipe_software() set name = "Enter Storage" - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set desc = "Upload your personality to the cloud and wipe your software from the card. This is functionally equivalent to cryo or robotic storage, freeing up your job slot." // Make sure people don't kill themselves accidentally diff --git a/code/modules/mob/living/silicon/pai/pai_vr.dm b/code/modules/mob/living/silicon/pai/pai_vr.dm index 2e3c1ed1fee..eda552040e2 100644 --- a/code/modules/mob/living/silicon/pai/pai_vr.dm +++ b/code/modules/mob/living/silicon/pai/pai_vr.dm @@ -101,7 +101,7 @@ /mob/living/silicon/pai/proc/pai_nom(var/mob/living/T in oview(1)) set name = "pAI Nom" - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set desc = "Allows you to eat someone while unfolded. Can't be used while in card form." if (stat != CONSCIOUS) @@ -173,7 +173,7 @@ //proc override to avoid pAI players being invisible while the chassis selection window is open /mob/living/silicon/pai/proc/choose_chassis() - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set name = "Choose Chassis" var/choice @@ -206,7 +206,7 @@ update_icon() /mob/living/silicon/pai/verb/toggle_eyeglow() - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set name = "Toggle Eye Glow" if(chassis in allows_eye_color) @@ -222,7 +222,7 @@ /mob/living/silicon/pai/verb/pick_eye_color() - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set name = "Pick Eye Color" if(chassis in allows_eye_color) else @@ -408,7 +408,7 @@ return 1 /mob/living/silicon/pai/verb/save_pai_to_slot() - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set name = "Save Configuration" savefile_save(src) to_chat(src, span_filter_notice("[name] configuration saved to global pAI settings.")) @@ -444,7 +444,7 @@ /mob/living/silicon/pai/verb/toggle_gender_identity_vr() set name = "Set Gender Identity" set desc = "Sets the pronouns when examined and performing an emote." - set category = "IC" + set category = "IC.Settings" var/new_gender_identity = tgui_input_list(usr, "Please select a gender Identity:", "Set Gender Identity", list(FEMALE, MALE, NEUTER, PLURAL, HERM)) if(!new_gender_identity) return 0 @@ -454,7 +454,7 @@ /mob/living/silicon/pai/verb/pai_hide() set name = "Hide" set desc = "Allows to hide beneath tables or certain items. Toggled on or off." - set category = "Abilities" + set category = "Abilities.pAI" hide() if(status_flags & HIDING) @@ -464,7 +464,7 @@ update_icon() /mob/living/silicon/pai/verb/screen_message(message as text|null) - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set name = "Screen Message" set desc = "Allows you to display a message on your screen. This will show up in the chat of anyone who is holding your card." diff --git a/code/modules/mob/living/silicon/pai/software.dm b/code/modules/mob/living/silicon/pai/software.dm index 9e52af2bec2..700634ea630 100644 --- a/code/modules/mob/living/silicon/pai/software.dm +++ b/code/modules/mob/living/silicon/pai/software.dm @@ -39,7 +39,7 @@ var/global/list/default_pai_software = list() software = default_pai_software.Copy() /mob/living/silicon/pai/verb/paiInterface() - set category = "pAI Commands" + set category = "Abilities.pAI Commands" set name = "Software Interface" tgui_interact(src) diff --git a/code/modules/mob/living/silicon/robot/component.dm b/code/modules/mob/living/silicon/robot/component.dm index f89061e88ed..d57d1092a6c 100644 --- a/code/modules/mob/living/silicon/robot/component.dm +++ b/code/modules/mob/living/silicon/robot/component.dm @@ -21,7 +21,20 @@ src.owner = R /datum/robot_component/proc/install() + if(istype(wrapped, /obj/item/robot_parts/robot_component)) + var/obj/item/robot_parts/robot_component/comp = wrapped + max_damage = comp.max_damage + idle_usage = comp.idle_usage + active_usage = comp.active_usage + return + if(istype(wrapped, /obj/item/cell)) + var/obj/item/cell/cell = wrapped + max_damage = cell.robot_durability + /datum/robot_component/proc/uninstall() + max_damage = initial(max_damage) + idle_usage = initial(idle_usage) + active_usage = initial(active_usage) /datum/robot_component/proc/destroy() var/brokenstate = "broken" // Generic icon @@ -231,24 +244,34 @@ var/brute = 0 var/burn = 0 var/icon_state_broken = "broken" + var/idle_usage = 0 + var/active_usage = 0 + var/max_damage = 0 /obj/item/robot_parts/robot_component/binary_communication_device name = "binary communication device" desc = "A module used for binary communications over encrypted frequencies, commonly used by synthetic robots." icon_state = "binradio" icon_state_broken = "binradio_broken" + idle_usage = 5 + active_usage = 25 + max_damage = 30 /obj/item/robot_parts/robot_component/actuator name = "actuator" desc = "A modular, hydraulic actuator used by exosuits and robots alike for movement and manipulation." icon_state = "motor" icon_state_broken = "motor_broken" + idle_usage = 0 + active_usage = 200 + max_damage = 50 /obj/item/robot_parts/robot_component/armour name = "armour plating" desc = "A pair of flexible, adaptable armor plates, used to protect the internals of robots." icon_state = "armor" icon_state_broken = "armor_broken" + max_damage = 90 /obj/item/robot_parts/robot_component/armour_platform name = "platform armour plating" @@ -256,21 +279,64 @@ icon_state = "armor" icon_state_broken = "armor_broken" color = COLOR_GRAY80 + max_damage = 140 /obj/item/robot_parts/robot_component/camera name = "camera" desc = "A modified camera module used as a visual receptor for robots and exosuits, also serving as a relay for wireless video feed." icon_state = "camera" icon_state_broken = "camera_broken" + idle_usage = 10 + max_damage = 40 /obj/item/robot_parts/robot_component/diagnosis_unit name = "diagnosis unit" desc = "An internal computer and sensors used by robots and exosuits to accurately diagnose any system discrepancies on their components." icon_state = "analyser" icon_state_broken = "analyser_broken" + active_usage = 1000 + max_damage = 30 /obj/item/robot_parts/robot_component/radio name = "radio" desc = "A modular, multi-frequency radio used by robots and exosuits to enable communication systems. Comes with built-in subspace receivers." icon_state = "radio" - icon_state_broken = "radio_broken" \ No newline at end of file + icon_state_broken = "radio_broken" + idle_usage = 15 + active_usage = 75 + max_damage = 40 + +// Improved components +/obj/item/robot_parts/robot_component/binary_communication_device/upgraded + name = "improved binary communication device" + idle_usage = 2.5 + active_usage = 12.5 + max_damage = 45 + +/obj/item/robot_parts/robot_component/radio/upgraded + name = "improved radio" + idle_usage = 5 + active_usage = 35 + max_damage = 40 + +/obj/item/robot_parts/robot_component/actuator/upgraded + name = "improved actuator" + idle_usage = 0 + active_usage = 100 + max_damage = 75 + +/obj/item/robot_parts/robot_component/diagnosis_unit/upgraded + name = "improved self-diagnosis unit" + active_usage = 500 + max_damage = 45 + +/obj/item/robot_parts/robot_component/camera/upgraded + name = "improved camera" + idle_usage = 5 + max_damage = 60 + +/obj/item/robot_parts/robot_component/armour/armour_titan + name = "prototype armour plating" + desc = "A pair of flexible, adaptable armor plates, used to protect the internals of robots." + max_damage = 220 + color = COLOR_OFF_WHITE diff --git a/code/modules/mob/living/silicon/robot/drone/drone.dm b/code/modules/mob/living/silicon/robot/drone/drone.dm index ba2c6ef4fa6..fd1132d05a8 100644 --- a/code/modules/mob/living/silicon/robot/drone/drone.dm +++ b/code/modules/mob/living/silicon/robot/drone/drone.dm @@ -172,7 +172,7 @@ var/list/mob_hat_cache = list() /mob/living/silicon/robot/drone/verb/pick_shell() set name = "Customize Appearance" - set category = "Abilities.Silicon" + set category = "Abilities.Settings" if(!can_pick_shell) to_chat(src, span_warning("You already selected a shell or this drone type isn't customizable.")) diff --git a/code/modules/mob/living/silicon/robot/drone/drone_manufacturer.dm b/code/modules/mob/living/silicon/robot/drone/drone_manufacturer.dm index 18da1013249..91f4c79b5e6 100644 --- a/code/modules/mob/living/silicon/robot/drone/drone_manufacturer.dm +++ b/code/modules/mob/living/silicon/robot/drone/drone_manufacturer.dm @@ -94,7 +94,7 @@ /mob/observer/dead/verb/join_as_drone() - set category = "Ghost" + set category = "Ghost.Join" set name = "Join As Drone" set desc = "If there is a powered, enabled fabricator in the game world with a prepared chassis, join as a maintenance drone." diff --git a/code/modules/mob/living/silicon/robot/robot.dm b/code/modules/mob/living/silicon/robot/robot.dm index 1610036f16f..a79310c02be 100644 --- a/code/modules/mob/living/silicon/robot/robot.dm +++ b/code/modules/mob/living/silicon/robot/robot.dm @@ -430,7 +430,7 @@ /mob/living/silicon/robot/verb/namepick() set name = "Pick Name" - set category = "Abilities.Silicon" + set category = "Abilities.Settings" if(custom_name) to_chat(usr, "You can't pick another custom name. [isshell(src) ? "" : "Go ask for a name change."]") @@ -448,7 +448,7 @@ /mob/living/silicon/robot/verb/extra_customization() set name = "Customize Appearance" - set category = "Abilities.Silicon" + set category = "Abilities.Settings" set desc = "Customize your appearance (assuming your chosen sprite allows)." if(!sprite_datum || !sprite_datum.has_extra_customization) @@ -502,7 +502,7 @@ // function to toggle VTEC once installed /mob/living/silicon/robot/proc/toggle_vtec() set name = "Toggle VTEC" - set category = "Abilities" + set category = "Abilities.Silicon" vtec_active = !vtec_active hud_used.toggle_vtec_control() to_chat(src, span_filter_notice("VTEC module [vtec_active ? "enabled" : "disabled"].")) @@ -803,7 +803,7 @@ /mob/living/silicon/robot/proc/ColorMate() set name = "Recolour Module" - set category = "Abilities.Silicon" + set category = "Abilities.Settings" set desc = "Allows to recolour once." if(!has_recoloured) @@ -1369,7 +1369,7 @@ /mob/living/silicon/robot/verb/rest_style() set name = "Switch Rest Style" set desc = "Select your resting pose." - set category = "IC" + set category = "IC.Settings" if(!sprite_datum || !sprite_datum.has_rest_sprites || sprite_datum.rest_sprite_options.len < 1) to_chat(src, span_notice("Your current appearance doesn't have any resting styles!")) @@ -1387,7 +1387,7 @@ /mob/living/silicon/robot/verb/robot_nom(var/mob/living/T in living_mobs(1)) set name = "Robot Nom" - set category = "IC" + set category = "Abilities.Vore" set desc = "Allows you to eat someone." if (stat != CONSCIOUS) @@ -1461,7 +1461,7 @@ /mob/living/silicon/robot/proc/robot_mount(var/mob/living/M in living_mobs(1)) set name = "Robot Mount/Dismount" - set category = "Abilities" + set category = "Abilities.General" set desc = "Let people ride on you." if(LAZYLEN(buckled_mobs)) diff --git a/code/modules/mob/living/silicon/robot/robot_damage.dm b/code/modules/mob/living/silicon/robot/robot_damage.dm index 907148e453e..1ad7f5c48f0 100644 --- a/code/modules/mob/living/silicon/robot/robot_damage.dm +++ b/code/modules/mob/living/silicon/robot/robot_damage.dm @@ -6,6 +6,12 @@ health = getMaxHealth() - (getBruteLoss() + getFireLoss()) return +/mob/living/silicon/robot/getMaxHealth() + . = ..() + for(var/V in components) + var/datum/robot_component/C = components[V] + . += C.max_damage - initial(C.max_damage) + /mob/living/silicon/robot/getBruteLoss() var/amount = 0 for(var/V in components) diff --git a/code/modules/mob/living/silicon/silicon.dm b/code/modules/mob/living/silicon/silicon.dm index 3f3d1016687..3f917a15ce3 100644 --- a/code/modules/mob/living/silicon/silicon.dm +++ b/code/modules/mob/living/silicon/silicon.dm @@ -257,14 +257,14 @@ /mob/living/silicon/verb/pose() set name = "Set Pose" set desc = "Sets a description which will be shown when someone examines you." - set category = "IC" + set category = "IC.Settings" pose = strip_html_simple(tgui_input_text(usr, "This is [src]. It is...", "Pose", null)) /mob/living/silicon/verb/set_flavor() set name = "Set Flavour Text" set desc = "Sets an extended description of your character's features." - set category = "IC" + set category = "IC.Settings" var/new_flavortext = strip_html_simple(tgui_input_text(usr, "Please enter your new flavour text.", "Flavour text", flavor_text, multiline = TRUE)) if(new_flavortext) diff --git a/code/modules/mob/living/simple_mob/simple_mob.dm b/code/modules/mob/living/simple_mob/simple_mob.dm index e063e5b94a7..2eff632c3a4 100644 --- a/code/modules/mob/living/simple_mob/simple_mob.dm +++ b/code/modules/mob/living/simple_mob/simple_mob.dm @@ -350,7 +350,7 @@ /mob/living/simple_mob/proc/ColorMate() set name = "Recolour" - set category = "Abilities" + set category = "Abilities.Settings" set desc = "Allows to recolour once." if(!has_recoloured) @@ -363,7 +363,7 @@ /mob/living/simple_mob/proc/hunting_vision() set name = "Track Prey Through Walls" - set category = "Abilities" + set category = "Abilities.Mob" set desc = "Uses you natural predatory instincts to seek out prey even through walls, or your natural survival instincts to spot predators from a distance." if(hunting_cooldown + 5 MINUTES < world.time) @@ -378,7 +378,7 @@ /mob/living/simple_mob/proc/hunting_vision_plus() set name = "Thermal vision toggle" - set category = "Abilities" + set category = "Abilities.Mob" set desc = "Uses you natural predatory instincts to seek out prey even through walls, or your natural survival instincts to spot predators from a distance." if(!isthermal) diff --git a/code/modules/mob/living/simple_mob/simple_mob_vr.dm b/code/modules/mob/living/simple_mob/simple_mob_vr.dm index b4f999bc830..6a4ba095f94 100644 --- a/code/modules/mob/living/simple_mob/simple_mob_vr.dm +++ b/code/modules/mob/living/simple_mob/simple_mob_vr.dm @@ -367,7 +367,7 @@ /mob/living/simple_mob/proc/animal_mount(var/mob/living/M in living_mobs(1)) set name = "Animal Mount/Dismount" - set category = "Abilities" + set category = "Abilities.Mob" set desc = "Let people ride on you." if(LAZYLEN(buckled_mobs)) @@ -402,7 +402,7 @@ /mob/living/simple_mob/proc/leap() set name = "Pounce Target" - set category = "Abilities" + set category = "Abilities.Mob" set desc = "Select a target to pounce at." if(last_special > world.time) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/catslug.dm b/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/catslug.dm index 67fe95dba1b..e951368c32e 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/catslug.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/catslug.dm @@ -284,7 +284,7 @@ /mob/living/simple_mob/vore/alienanimals/catslug/proc/catslug_color() set name = "Pick Color" - set category = "Abilities" + set category = "Abilities.Settings" set desc = "You can set your color!" if(picked_color) to_chat(src, span_notice("You have already picked a color! If you picked the wrong color, ask an admin to change your picked_color variable to 0.")) @@ -1112,7 +1112,7 @@ /mob/living/simple_mob/vore/alienanimals/catslug/suslug/proc/assussinate() set name = "Kill Innocent" - set category = "Abilities" + set category = "Abilities.Catslug" set desc = "Kill an innocent suslug!" if(!is_impostor) to_chat(src, span_notice("You are not an impostor! You can't kill like that!")) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/stardog.dm b/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/stardog.dm index 1fa6963c687..6bf397a3814 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/stardog.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/stardog.dm @@ -187,14 +187,14 @@ /mob/living/simple_mob/vore/overmap/stardog/verb/eject() set name = "Eject" set desc = "Stop controlling the dog and return to your own body." - set category = "Abilities" + set category = "Abilities.Stardog" control_node.eject() /mob/living/simple_mob/vore/overmap/stardog/verb/eat_space_weather() set name = "Eat Space Weather" set desc = "Eat carp or rocks!" - set category = "Abilities" + set category = "Abilities.Stardog" var/obj/effect/overmap/event/E var/nut = 0 @@ -297,7 +297,7 @@ /mob/living/simple_mob/vore/overmap/stardog/verb/transition() //Don't ask how it works. I don't know. I didn't think about it. I just thought it would be cool. set name = "Transition" set desc = "Attempt to go to the location you have arrived at, or return to space!" - set category = "Abilities" + set category = "Abilities.Stardog" if(nutrition <= 500) to_chat(src, span_warning("You're too hungry...")) return @@ -451,7 +451,7 @@ /turf/simulated/floor/outdoors/fur/verb/pet() set name = "Pet Fur" set desc = "Pet the fur!" - set category = "IC" + set category = "IC.Stardog" set src in oview(1) usr.visible_message(span_notice("\The [usr] pets \the [src]."), span_notice("You pet \the [src]."), runemessage = "pet pat...") @@ -466,7 +466,7 @@ /turf/simulated/floor/outdoors/fur/verb/emote_beyond(message as message) //Now even the stars will know your sin. set name = "Emote Beyond" set desc = "Emote to those beyond the fur!" - set category = "IC" + set category = "IC.Chat" set src in oview(1) if(!isliving(usr)) @@ -1139,7 +1139,7 @@ /obj/machinery/computer/ship/navigation/verb/emote_beyond(message as message) //I could have put this into any other file but right here will do set name = "Emote Beyond" set desc = "Emote to those beyond the ship!" - set category = "IC" + set category = "IC.Chat" set src in oview(7) if(!isliving(usr)) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/teppi.dm b/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/teppi.dm index 50704e1fa9c..4f9e9188c28 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/teppi.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/teppi.dm @@ -962,7 +962,7 @@ GLOBAL_VAR_INIT(teppi_count, 0) // How mant teppi DO we have? // /mob/living/simple_mob/vore/alienanimals/teppi/proc/produce_offspring() set name = "Produce Offspring" - set category = "Abilities" + set category = "Abilities.Teppi" set desc = "You can have babies if the conditions are right." if(prevent_breeding) to_chat(src, span_notice("You have elected to not participate in breeding mechanics, and so cannot complete that action.")) @@ -1004,7 +1004,7 @@ GLOBAL_VAR_INIT(teppi_count, 0) // How mant teppi DO we have? /mob/living/simple_mob/vore/alienanimals/teppi/proc/toggle_producing_offspring() set name = "Toggle Producing Offspring" - set category = "Abilities" + set category = "Abilities.Teppi" set desc = "You can toggle whether or not you can produce offspring." if(!prevent_breeding) to_chat(src, span_notice("You disable breeding.")) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/animal.dm b/code/modules/mob/living/simple_mob/subtypes/animal/animal.dm index 51d338364cd..836e4b70410 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/animal.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/animal.dm @@ -31,7 +31,7 @@ /mob/living/simple_mob/animal/verb/set_flavour_text() set name = "Set Flavour Text" - set category = "IC" + set category = "IC.Settings" set desc = "Set your flavour text." set src = usr var/new_flavour_text = sanitize((input("Please describe yourself.", "Flavour Text", flavor_text) as message|null), MAX_MESSAGE_LEN) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/borer/borer_powers.dm b/code/modules/mob/living/simple_mob/subtypes/animal/borer/borer_powers.dm index 160ddbdeff5..85087a9b154 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/borer/borer_powers.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/borer/borer_powers.dm @@ -1,5 +1,5 @@ /mob/living/simple_mob/animal/borer/verb/release_host() - set category = "Abilities" + set category = "Abilities.Borer" set name = "Release Host" set desc = "Slither out of your host." @@ -39,7 +39,7 @@ leave_host() /mob/living/simple_mob/animal/borer/verb/infest() - set category = "Abilities" + set category = "Abilities.Borer" set name = "Infest" set desc = "Infest a suitable humanoid host." @@ -127,7 +127,7 @@ /* /mob/living/simple_mob/animal/borer/verb/devour_brain() - set category = "Abilities" + set category = "Abilities.Borer" set name = "Devour Brain" set desc = "Take permanent control of a dead host." @@ -200,7 +200,7 @@ H.lastKnownIP = s2h_ip /mob/living/simple_mob/animal/borer/verb/secrete_chemicals() - set category = "Abilities" + set category = "Abilities.Borer" set name = "Secrete Chemicals" set desc = "Push some chemicals into your host's bloodstream." @@ -228,7 +228,7 @@ chemicals -= 50 /mob/living/simple_mob/animal/borer/verb/dominate_victim() - set category = "Abilities" + set category = "Abilities.Borer" set name = "Paralyze Victim" set desc = "Freeze the limbs of a potential host with supernatural fear." @@ -268,7 +268,7 @@ used_dominate = world.time /mob/living/simple_mob/animal/borer/verb/bond_brain() - set category = "Abilities" + set category = "Abilities.Borer" set name = "Assume Control" set desc = "Fully connect to the brain of your host." @@ -339,7 +339,7 @@ return /mob/living/carbon/human/proc/jumpstart() - set category = "Abilities" + set category = "Abilities.Borer" set name = "Revive Host" set desc = "Send a jolt of electricity through your host, reviving them." diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/giant_spider/phorogenic.dm b/code/modules/mob/living/simple_mob/subtypes/animal/giant_spider/phorogenic.dm index 439bf98b10b..e67402e0a36 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/giant_spider/phorogenic.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/giant_spider/phorogenic.dm @@ -63,22 +63,16 @@ adjust_scale(1.25) return ..() +/mob/living/simple_mob/animal/giant_spider/phorogenic/proc/explode() + if(src && !exploded) + visible_message(span_danger("\The [src]'s body detonates!")) + exploded = TRUE + explosion(src.loc, explosion_dev_range, explosion_heavy_range, explosion_light_range, explosion_flash_range) + /mob/living/simple_mob/animal/giant_spider/phorogenic/death() visible_message(span_critical("\The [src]'s body begins to rupture!")) var/delay = rand(explosion_delay_lower, explosion_delay_upper) - spawn(0) - // Flash black and red as a warning. - for(var/i = 1 to delay) - if(i % 2 == 0) - color = "#000000" - else - color = "#FF0000" - sleep(1) - - spawn(delay) - // The actual boom. - if(src && !exploded) - visible_message(span_danger("\The [src]'s body detonates!")) - exploded = TRUE - explosion(src.loc, explosion_dev_range, explosion_heavy_range, explosion_light_range, explosion_flash_range) + animate(src, color = "#000000", time = 0.1 SECONDS, loop = ceil(delay/2)) + animate(color = "#FF0000", time = 0.1 SECONDS) + addtimer(CALLBACK(src, PROC_REF(explode)), delay, TIMER_DELETE_ME) return ..() diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/pets/cat.dm b/code/modules/mob/living/simple_mob/subtypes/animal/pets/cat.dm index 33a46f63ac1..5dbc635a9c4 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/pets/cat.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/pets/cat.dm @@ -97,7 +97,7 @@ var/list/_cat_default_emotes = list( /mob/living/simple_mob/animal/passive/cat/verb/become_friends() set name = "Become Friends" - set category = "IC" + set category = "IC.Game" set src in view(1) var/mob/living/L = usr diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/pets/fox_vr.dm b/code/modules/mob/living/simple_mob/subtypes/animal/pets/fox_vr.dm index 9a73a80ac11..d42cb23b098 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/pets/fox_vr.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/pets/fox_vr.dm @@ -108,7 +108,7 @@ /mob/living/simple_mob/animal/passive/fox/renault/verb/become_friends() set name = "Become Friends" - set category = "IC" + set category = "IC.Game" set src in view(1) var/mob/living/L = usr @@ -167,7 +167,7 @@ /mob/living/simple_mob/animal/passive/fox/fluff/verb/friend() set name = "Become Friends" - set category = "IC" + set category = "IC.Game" set src in view(1) if(friend && usr == friend) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/sif/grafadreka.dm b/code/modules/mob/living/simple_mob/subtypes/animal/sif/grafadreka.dm index e0d523d3fac..127295f6156 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/sif/grafadreka.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/sif/grafadreka.dm @@ -103,7 +103,7 @@ Field studies suggest analytical abilities on par with some species of cepholapo /mob/living/simple_mob/animal/sif/grafadreka/verb/sit_down() set name = "Sit Down" - set category = "IC" + set category = "IC.Grafadreka" if(sitting) resting = FALSE @@ -132,7 +132,7 @@ Field studies suggest analytical abilities on par with some species of cepholapo icon_rest = "doggo_lying" projectileverb = "spits" friendly = list("headbutts", "grooms", "play-bites", "rubs against") - bitesize = 10 // chomp + bitesize = 10 gender = NEUTER has_langs = list("Drake") @@ -564,7 +564,7 @@ var/global/list/wounds_being_tended_by_drakes = list() /mob/living/simple_mob/animal/sif/grafadreka/verb/rally_pack() set name = "Rally Pack" set desc = "Tries to command your fellow pack members to follow you." - set category = "Abilities" + set category = "Abilities.Grafadreka" if(!has_modifier_of_type(/datum/modifier/ace)) to_chat(src, span_warning("You aren't the pack leader! Sit down!")) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/sif/kururak.dm b/code/modules/mob/living/simple_mob/subtypes/animal/sif/kururak.dm index d6acfd76d01..b5ead809147 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/sif/kururak.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/sif/kururak.dm @@ -143,7 +143,7 @@ return ..() /mob/living/simple_mob/animal/sif/kururak/verb/do_flash() - set category = "Abilities" + set category = "Abilities.Kururak" set name = "Tail Blind" set desc = "Disorient a creature within range." @@ -229,7 +229,7 @@ R.flash_eyes() /mob/living/simple_mob/animal/sif/kururak/verb/do_strike() - set category = "Abilities" + set category = "Abilities.Kururak" set name = "Rending Strike" set desc = "Strike viciously at an entity within range." @@ -294,7 +294,7 @@ /mob/living/simple_mob/animal/sif/kururak/verb/rally_pack() // Mostly for telling other players to follow you. AI Kururaks will auto-follow, if set to. set name = "Rally Pack" set desc = "Tries to command your fellow pack members to follow you." - set category = "Abilities" + set category = "Abilities.Kururak" if(has_modifier_of_type(/datum/modifier/ace)) for(var/mob/living/simple_mob/animal/sif/kururak/K in hearers(7, src)) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/sif/leech.dm b/code/modules/mob/living/simple_mob/subtypes/animal/sif/leech.dm index 5e455483938..83aba9a0018 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/sif/leech.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/sif/leech.dm @@ -225,7 +225,7 @@ leave_host() /mob/living/simple_mob/animal/sif/leech/verb/infest() - set category = "Abilities" + set category = "Abilities.Leech" set name = "Infest" set desc = "Infest a suitable humanoid host." @@ -312,7 +312,7 @@ return /mob/living/simple_mob/animal/sif/leech/verb/uninfest() - set category = "Abilities" + set category = "Abilities.Leech" set name = "Uninfest" set desc = "Leave your current host." @@ -336,7 +336,7 @@ host = null /mob/living/simple_mob/animal/sif/leech/verb/inject_victim() - set category = "Abilities" + set category = "Abilities.Leech" set name = "Incapacitate Potential Host" set desc = "Inject an organic host with an incredibly painful mixture of chemicals." @@ -384,7 +384,7 @@ H.add_modifier(/datum/modifier/poisoned/paralysis, 15 SECONDS) /mob/living/simple_mob/animal/sif/leech/verb/medicate_host() - set category = "Abilities" + set category = "Abilities.Leech" set name = "Produce Chemicals (50)" set desc = "Inject your host with possibly beneficial chemicals, to keep the blood flowing." @@ -407,7 +407,7 @@ to_chat(src, span_alien("We injected \the [host] with five units of [chem].")) /mob/living/simple_mob/animal/sif/leech/verb/feed_on_organ() - set category = "Abilities" + set category = "Abilities.Leech" set name = "Feed on Organ" set desc = "Extend probosci to feed on a piece of your host's organs." diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/sif/racoon.dm b/code/modules/mob/living/simple_mob/subtypes/animal/sif/racoon.dm index 0798f487d7d..ad9f9623304 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/sif/racoon.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/sif/racoon.dm @@ -72,7 +72,7 @@ /mob/living/simple_mob/animal/sif/sakimm/verb/remove_hat() set name = "Remove Hat" set desc = "Remove the animal's hat. You monster." - set category = "Abilities" + set category = "Abilities.Sakimm" set src in view(1) drop_hat(usr) @@ -95,7 +95,7 @@ /mob/living/simple_mob/animal/sif/sakimm/verb/give_hat() set name = "Give Hat" set desc = "Give the animal a hat. You hero." - set category = "Abilities" + set category = "Abilities.Sakimm" set src in view(1) take_hat(usr) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/sif/savik.dm b/code/modules/mob/living/simple_mob/subtypes/animal/sif/savik.dm index 79ccba68273..934dfebb48a 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/sif/savik.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/sif/savik.dm @@ -78,7 +78,7 @@ /mob/living/simple_mob/animal/sif/savik/verb/berserk() set name = "Berserk" set desc = "Enrage and become vastly stronger for a period of time, however you will be weaker afterwards." - set category = "Abilities" + set category = "Abilities.Savik" add_modifier(/datum/modifier/berserk, 30 SECONDS) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/sif/shantak.dm b/code/modules/mob/living/simple_mob/subtypes/animal/sif/shantak.dm index 37644c4116c..9615b97cd2e 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/sif/shantak.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/sif/shantak.dm @@ -77,7 +77,7 @@ /mob/living/simple_mob/animal/sif/shantak/leader/verb/rally_pack() set name = "Rally Pack" set desc = "Commands your fellow packmembers to follow you, the leader." - set category = "Abilities" + set category = "Abilities.Shantak" for(var/mob/living/simple_mob/animal/sif/shantak/S in hearers(7, src)) if(istype(S, /mob/living/simple_mob/animal/sif/shantak/leader)) // Leaders won't follow other leaders. Also avoids trying to follow ourselves. diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/space/bear.dm b/code/modules/mob/living/simple_mob/subtypes/animal/space/bear.dm index 7270b2c4918..d2b1466df0e 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/space/bear.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/space/bear.dm @@ -44,6 +44,6 @@ /mob/living/simple_mob/animal/space/bear/verb/berserk() set name = "Berserk" set desc = "Enrage and become vastly stronger for a period of time, however you will be weaker afterwards." - set category = "Abilities" + set category = "Abilities.Bear" add_modifier(/datum/modifier/berserk, 30 SECONDS) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/space/goose.dm b/code/modules/mob/living/simple_mob/subtypes/animal/space/goose.dm index 0d5ad98cae0..e6b642b6d80 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/space/goose.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/space/goose.dm @@ -42,7 +42,7 @@ /mob/living/simple_mob/animal/space/goose/verb/berserk() set name = "Berserk" set desc = "Enrage and become vastly stronger for a period of time, however you will be weaker afterwards." - set category = "Abilities" + set category = "Abilities.Goose" add_modifier(/datum/modifier/berserk, 30 SECONDS) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/space/space_vr.dm b/code/modules/mob/living/simple_mob/subtypes/animal/space/space_vr.dm index 082f6342d04..e4ade300323 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/space/space_vr.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/space/space_vr.dm @@ -1,3 +1,3 @@ // Fix for Virgo 2's Surface /mob/living/simple_mob/animal/space - maxbodytemp = 700 \ No newline at end of file + maxbodytemp = 700 diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/space/worm.dm b/code/modules/mob/living/simple_mob/subtypes/animal/space/worm.dm index 47be9833390..9ea34022f96 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/space/worm.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/space/worm.dm @@ -124,7 +124,7 @@ /mob/living/simple_mob/animal/space/space_worm/head/verb/toggle_devour() set name = "Toggle Feeding" set desc = "Extends your teeth for 30 seconds so that you can chew through mobs and structures alike." - set category = "Abilities" + set category = "Abilities.Worm" if(world.time < time_maw_opened + maw_cooldown) if(open_maw) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/squirrel.dm b/code/modules/mob/living/simple_mob/subtypes/animal/squirrel.dm index c6a8f0ac948..ded0cdb570d 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/squirrel.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/squirrel.dm @@ -208,7 +208,7 @@ /mob/living/simple_mob/vore/squirrel/verb/squirrel_color() set name = "Pick Color" - set category = "Abilities" + set category = "Abilities.Settings" set desc = "You can set your color!" if(picked_color) to_chat(src, span_notice("You have already picked a color! If you picked the wrong color, ask an admin to change your picked_color variable to 0.")) diff --git a/code/modules/mob/living/simple_mob/subtypes/humanoid/mercs/mercs.dm b/code/modules/mob/living/simple_mob/subtypes/humanoid/mercs/mercs.dm index 115e0cb4101..eabe9b296ca 100644 --- a/code/modules/mob/living/simple_mob/subtypes/humanoid/mercs/mercs.dm +++ b/code/modules/mob/living/simple_mob/subtypes/humanoid/mercs/mercs.dm @@ -87,14 +87,23 @@ intelligence_level = AI_SMART // Also knows not to walk while confused if it risks death. threaten_delay = 30 SECONDS // Mercs will give you 30 seconds to leave or get shot. +/datum/ai_holder/simple_mob/merc/guard_limit + guard_limit = TRUE + /datum/ai_holder/simple_mob/merc/ranged pointblank = TRUE // They get close? Just shoot 'em! firing_lanes = TRUE // But not your buddies! conserve_ammo = TRUE // And don't go wasting bullets! +/datum/ai_holder/simple_mob/merc/ranged/guard_limit + guard_limit = TRUE + /datum/ai_holder/simple_mob/merc/ranged/sniper vision_range = 14 // We're a person with a long-ranged gun. +/datum/ai_holder/simple_mob/merc/ranged/sniper/guard_limit + guard_limit = TRUE + /datum/ai_holder/simple_mob/merc/ranged/sniper/max_range(atom/movable/AM) return holder.ICheckRangedAttack(AM) ? 14 : 1 @@ -426,3 +435,42 @@ /obj/item/grenade/spawnergrenade/manhacks/mercenary = 50, /obj/item/grenade/spawnergrenade/manhacks/mercenary = 30 ) + + +//////////////////////////////// +// Stealth Mission Mercs +//////////////////////////////// + +// Most likely to drop a broken weapon matching them, if it's a gun. +/mob/living/simple_mob/humanoid/merc/melee/poi/guard_limit + ai_holder_type = /datum/ai_holder/simple_mob/merc/guard_limit + +/mob/living/simple_mob/humanoid/merc/melee/sword/poi/guard_limit + ai_holder_type = /datum/ai_holder/simple_mob/merc/guard_limit + +/mob/living/simple_mob/humanoid/merc/ranged/poi/guard_limit + ai_holder_type = /datum/ai_holder/simple_mob/merc/ranged/guard_limit + +/mob/living/simple_mob/humanoid/merc/ranged/smg/poi/guard_limit + ai_holder_type = /datum/ai_holder/simple_mob/merc/ranged/guard_limit + +/mob/living/simple_mob/humanoid/merc/ranged/laser/poi/guard_limit + ai_holder_type = /datum/ai_holder/simple_mob/merc/ranged/guard_limit + +/mob/living/simple_mob/humanoid/merc/ranged/ionrifle/poi/guard_limit + ai_holder_type = /datum/ai_holder/simple_mob/merc/ranged/guard_limit + +/mob/living/simple_mob/humanoid/merc/ranged/grenadier/poi/guard_limit + ai_holder_type = /datum/ai_holder/simple_mob/merc/ranged/guard_limit + +/mob/living/simple_mob/humanoid/merc/ranged/rifle/poi/guard_limit + ai_holder_type = /datum/ai_holder/simple_mob/merc/ranged/guard_limit + +/mob/living/simple_mob/humanoid/merc/ranged/rifle/mag/poi/guard_limit + ai_holder_type = /datum/ai_holder/simple_mob/merc/ranged/guard_limit + +/mob/living/simple_mob/humanoid/merc/ranged/technician/poi/guard_limit + ai_holder_type = /datum/ai_holder/simple_mob/merc/ranged/guard_limit + +/mob/living/simple_mob/humanoid/merc/ranged/sniper/guard_limit + ai_holder_type = /datum/ai_holder/simple_mob/merc/ranged/sniper/guard_limit diff --git a/code/modules/mob/living/simple_mob/subtypes/mechanical/mecha/durand.dm b/code/modules/mob/living/simple_mob/subtypes/mechanical/mecha/durand.dm index 44a4ba3e326..86a6ad2c659 100644 --- a/code/modules/mob/living/simple_mob/subtypes/mechanical/mecha/durand.dm +++ b/code/modules/mob/living/simple_mob/subtypes/mechanical/mecha/durand.dm @@ -60,7 +60,7 @@ /mob/living/simple_mob/mechanical/mecha/combat/durand/verb/toggle_defense_mode() set name = "Toggle Defense Mode" set desc = "Toggles a special mode which makes you immobile and much more resilient." - set category = "Abilities" + set category = "Abilities.Durand" set_defense_mode(!defense_mode) diff --git a/code/modules/mob/living/simple_mob/subtypes/vore/bigdragon.dm b/code/modules/mob/living/simple_mob/subtypes/vore/bigdragon.dm index d3fc35c3c37..3036edd2f20 100644 --- a/code/modules/mob/living/simple_mob/subtypes/vore/bigdragon.dm +++ b/code/modules/mob/living/simple_mob/subtypes/vore/bigdragon.dm @@ -276,14 +276,14 @@ I think I covered everything. /mob/living/simple_mob/vore/bigdragon/proc/toggle_glow() set name = "Toggle Glow" set desc = "Switch between glowing and not glowing." - set category = "Abilities" + set category = "Abilities.Settings" glow_toggle = !glow_toggle /mob/living/simple_mob/vore/bigdragon/proc/sprite_toggle() set name = "Toggle Small Sprite" set desc = "Switches your sprite to a smaller variant so you can see what you're doing. Others will always see your standard sprite instead. " - set category = "Abilities" + set category = "Abilities.Settings" if(!small) var/image/I = image(icon = small_icon, icon_state = small_icon_state, loc = src) @@ -298,7 +298,7 @@ I think I covered everything. /mob/living/simple_mob/vore/bigdragon/proc/flame_toggle() set name = "Toggle breath attack" set desc = "Toggles whether you will breath attack on harm intent (If you have one)." - set category = "Abilities" + set category = "Abilities.Settings" if(norange) to_chat(src, span_userdanger("You don't have a breath attack!")) @@ -310,7 +310,7 @@ I think I covered everything. /mob/living/simple_mob/vore/bigdragon/proc/special_toggle() set name = "Toggle special attacks" set desc = "Toggles whether you will tail spin and charge (If you have them)." - set category = "Abilities" + set category = "Abilities.Settings" if(nospecial) to_chat(src, span_userdanger("You don't have special attacks!")) @@ -419,7 +419,7 @@ I think I covered everything. /mob/living/simple_mob/vore/bigdragon/proc/set_style() set name = "Set Dragon Style" set desc = "Customise your icons." - set category = "Abilities" + set category = "Abilities.Settings" var/list/options = list("Underbelly","Body","Ears","Mane","Horns","Eyes") for(var/option in options) diff --git a/code/modules/mob/living/simple_mob/subtypes/vore/demon/demon_abilities.dm b/code/modules/mob/living/simple_mob/subtypes/vore/demon/demon_abilities.dm index 73b9cc71ef2..48101c4742a 100644 --- a/code/modules/mob/living/simple_mob/subtypes/vore/demon/demon_abilities.dm +++ b/code/modules/mob/living/simple_mob/subtypes/vore/demon/demon_abilities.dm @@ -1,7 +1,7 @@ /mob/living/simple_mob/vore/demon/verb/blood_crawl() set name = "Bloodcrawl" set desc = "Shift out of reality using blood as your gateway" - set category = "Abilities" + set category = "Abilities.Demon" var/turf/T = get_turf(src) if(!T.CanPass(src,T) || loc != T) @@ -108,7 +108,7 @@ /mob/living/simple_mob/vore/demon/verb/phase_shift() set name = "Phase Shift" set desc = "Shift out of reality temporarily" - set category = "Abilities" + set category = "Abilities.Demon" var/turf/T = get_turf(src) diff --git a/code/modules/mob/living/simple_mob/subtypes/vore/dominated_brain.dm b/code/modules/mob/living/simple_mob/subtypes/vore/dominated_brain.dm index 79f2432c44a..28c9c8fb3ea 100644 --- a/code/modules/mob/living/simple_mob/subtypes/vore/dominated_brain.dm +++ b/code/modules/mob/living/simple_mob/subtypes/vore/dominated_brain.dm @@ -172,7 +172,7 @@ //Welcome to the adapted borer code. /mob/proc/dominate_predator() - set category = "Abilities" + set category = "Abilities.Vore" set name = "Dominate Predator" set desc = "Connect to and dominate the brain of your predator." @@ -271,7 +271,7 @@ qdel(prey) /mob/proc/release_predator() - set category = "Abilities" + set category = "Abilities.Vore" set name = "Restore Control" set desc = "Release control of your predator's body." @@ -289,7 +289,7 @@ remove_verb(src, /mob/proc/release_predator) /mob/living/dominated_brain/proc/resist_control() - set category = "Abilities" + set category = "Abilities.Vore" set name = "Resist Control" set desc = "Attempt to resist control." if(pred_body.ckey == pred_ckey) @@ -308,7 +308,7 @@ to_chat(src, span_warning("\The [pred_body] is already dominated, and cannot be controlled at this time.")) /mob/living/proc/dominate_prey() - set category = "Abilities" + set category = "Abilities.Vore" set name = "Dominate Prey" set desc = "Connect to and dominate the brain of your prey." @@ -378,7 +378,7 @@ to_chat(M, span_warning("Your mind is gathered into \the [src], becoming part of them...")) /mob/living/dominated_brain/proc/cease_this_foolishness() - set category = "Abilities" + set category = "Abilities.Vore" set name = "Return to Body" set desc = "If your body is inside of your predator still, attempts to re-insert yourself into it." @@ -405,7 +405,7 @@ remove_verb(src, /mob/living/dominated_brain/proc/cease_this_foolishness) /mob/living/proc/lend_prey_control() - set category = "Abilities" + set category = "Abilities.Vore" set name = "Give Prey Control" set desc = "Allow prey control of your body." diff --git a/code/modules/mob/living/simple_mob/subtypes/vore/leopardmander.dm b/code/modules/mob/living/simple_mob/subtypes/vore/leopardmander.dm index 5b35207b545..81e756e5277 100644 --- a/code/modules/mob/living/simple_mob/subtypes/vore/leopardmander.dm +++ b/code/modules/mob/living/simple_mob/subtypes/vore/leopardmander.dm @@ -135,7 +135,7 @@ /mob/living/simple_mob/vore/leopardmander/exotic/proc/toggle_glow() set name = "Toggle Glow" set desc = "Switch between glowing and not glowing." - set category = "Abilities" + set category = "Abilities.Leopardmander" glow_toggle = !glow_toggle diff --git a/code/modules/mob/living/simple_mob/subtypes/vore/macrophage.dm b/code/modules/mob/living/simple_mob/subtypes/vore/macrophage.dm new file mode 100644 index 00000000000..dacbebb57da --- /dev/null +++ b/code/modules/mob/living/simple_mob/subtypes/vore/macrophage.dm @@ -0,0 +1,63 @@ +/mob/living/simple_mob/vore/aggressive/macrophage + name = "Germ" + desc = "A giant virus!" + icon = 'icons/mob/macrophage.dmi' + icon_state = "macrophage-1" + + faction = FACTION_MACROBACTERIA + maxHealth = 60 + health = 60 + + var/datum/disease/base_disease = null + var/list/infections = list() + + melee_damage_lower = 1 + melee_damage_upper = 5 + grab_resist = 100 + see_in_dark = 8 + + response_help = "shoos" + response_disarm = "swats away" + response_harm = "squashes" + attacktext = list("squashed") + friendly = list("shoos", "rubs") + + vore_bump_chance = "attempts to absorb" + + vore_active = TRUE + vore_capacity = 1 + + can_be_drop_prey = FALSE + allow_mind_transfer = TRUE + + ai_holder_type = /datum/ai_holder/simple_mob/melee + +/mob/living/simple_mob/vore/aggressive/macrophage/green + icon_state = "macrophage-2" + +/mob/living/simple_mob/vore/aggressive/macrophage/pink + icon_state = "macrophage-3" + +/mob/living/simple_mob/vore/aggressive/macrophage/blue + icon_state = "macrophage-4" + +/obj/belly/macrophage + name = "capsid" + fancy_vore = TRUE + contamination_color = "green" + vore_verb = "absorb" + escapable = TRUE + escapable = 5 + desc = "In an attempt to get away from the giant virus, it's oversized envelope proteins dragged you right past it's matrix, encapsulating you deep inside it's capsid... The strange walls kneading and keeping you tight along within it's nucleoprotein." + belly_fullscreen = "VBO_gematically_angular" + belly_fullscreen_color = "#87d8d8" + digest_mode = DM_ABSORB + affects_vore_sprites = FALSE + +/mob/living/simple_mob/vore/aggressive/macrophage/init_vore() + + if(LAZYLEN(vore_organs)) + return TRUE + + var/obj/belly/B = new /obj/belly/macrophage(src) + vore_selected = B diff --git a/code/modules/mob/living/simple_mob/subtypes/vore/mobs_monsters/clowns/honkelemental.dm b/code/modules/mob/living/simple_mob/subtypes/vore/mobs_monsters/clowns/honkelemental.dm index 2f9f0b578c5..cfd68d41c47 100644 --- a/code/modules/mob/living/simple_mob/subtypes/vore/mobs_monsters/clowns/honkelemental.dm +++ b/code/modules/mob/living/simple_mob/subtypes/vore/mobs_monsters/clowns/honkelemental.dm @@ -24,7 +24,7 @@ emote_see = list("honks") /mob/living/simple_mob/clowns/big/c_shift/honkelemental/verb/spawn_egg() - set category = "Abilities" + set category = "Abilities.Clown" set name = "Spawn Clown Egg" set desc = "Spawns an egg that a player can touch, which will call on ghosts to spawn as clowns." diff --git a/code/modules/mob/living/simple_mob/subtypes/vore/morph/morph.dm b/code/modules/mob/living/simple_mob/subtypes/vore/morph/morph.dm index 6eb6187f49c..a726e5dcb48 100644 --- a/code/modules/mob/living/simple_mob/subtypes/vore/morph/morph.dm +++ b/code/modules/mob/living/simple_mob/subtypes/vore/morph/morph.dm @@ -247,7 +247,7 @@ /mob/living/simple_mob/vore/morph/proc/morph_color() set name = "Pick Color" - set category = "Abilities" + set category = "Abilities.Settings" set desc = "You can set your color!" var/newcolor = input(usr, "Choose a color.", "", color) as color|null if(newcolor) @@ -257,7 +257,7 @@ /mob/living/simple_mob/vore/morph/proc/take_over_prey() set name = "Take Over Prey" - set category = "Abilities" + set category = "Abilities.Morph" set desc = "Take command of your prey's body." if(morphed) to_chat(src, span_warning("You must restore to your original form first!")) diff --git a/code/modules/mob/living/simple_mob/subtypes/vore/sect_drone.dm b/code/modules/mob/living/simple_mob/subtypes/vore/sect_drone.dm index 0c0adcc0a2f..27e6d0e92a4 100644 --- a/code/modules/mob/living/simple_mob/subtypes/vore/sect_drone.dm +++ b/code/modules/mob/living/simple_mob/subtypes/vore/sect_drone.dm @@ -93,7 +93,7 @@ /mob/living/simple_mob/vore/sect_drone/proc/set_abdomen_color() set name = "Set Glow Color" set desc = "Customize your eyes and abdomen glow color." - set category = "Abilities" + set category = "Abilities.Sect Drone" var/new_color = input(src, "Please select color.", "Glow Color", custom_eye_color) as color|null if(new_color) diff --git a/code/modules/mob/living/simple_mob/subtypes/vore/sect_queen.dm b/code/modules/mob/living/simple_mob/subtypes/vore/sect_queen.dm index 15dfcf13687..76ab3b915f6 100644 --- a/code/modules/mob/living/simple_mob/subtypes/vore/sect_queen.dm +++ b/code/modules/mob/living/simple_mob/subtypes/vore/sect_queen.dm @@ -94,7 +94,7 @@ /mob/living/simple_mob/vore/sect_queen/proc/set_abdomen_color() set name = "Set Glow Color" set desc = "Customize your eyes and abdomen glow color." - set category = "Abilities" + set category = "Abilities.Sect Queen" var/new_color = input(src, "Please select color.", "Glow Color", custom_eye_color) as color|null if(new_color) diff --git a/code/modules/mob/living/simple_mob/subtypes/vore/vore.dm b/code/modules/mob/living/simple_mob/subtypes/vore/vore.dm index 62a4ac73b55..f30f34a184c 100644 --- a/code/modules/mob/living/simple_mob/subtypes/vore/vore.dm +++ b/code/modules/mob/living/simple_mob/subtypes/vore/vore.dm @@ -52,7 +52,7 @@ /mob/living/simple_mob/proc/set_name() set name = "Set Name" set desc = "Sets your mobs name. You only get to do this once." - set category = "Abilities" + set category = "Abilities.Settings" if(limit_renames && nameset) to_chat(src, span_userdanger("You've already set your name. Ask an admin to toggle \"nameset\" to 0 if you really must.")) return @@ -66,7 +66,7 @@ /mob/living/simple_mob/proc/set_desc() set name = "Set Description" set desc = "Set your description." - set category = "Abilities" + set category = "Abilities.Settings" var/newdesc newdesc = sanitizeSafe(tgui_input_text(src,"Set your description. Max 4096 chars.", "Description set","", prevent_enter = TRUE), MAX_MESSAGE_LEN) if(newdesc) diff --git a/code/modules/mob/mob.dm b/code/modules/mob/mob.dm index 88247bdd073..9413f822560 100644 --- a/code/modules/mob/mob.dm +++ b/code/modules/mob/mob.dm @@ -288,7 +288,7 @@ /mob/verb/memory() set name = "Notes" - set category = "IC" + set category = "IC.Game" if(mind) mind.show_memory(src) else @@ -296,7 +296,7 @@ /mob/verb/add_memory(msg as message) set name = "Add Note" - set category = "IC" + set category = "IC.Game" msg = sanitize(msg) @@ -384,7 +384,7 @@ /mob/verb/abandon_mob() set name = "Return to Menu" - set category = "OOC" + set category = "OOC.Game" if(stat != DEAD || !ticker) to_chat(usr, span_boldnotice("You must be dead to use this!")) @@ -465,7 +465,7 @@ /client/verb/changes() set name = "Changelog" - set category = "OOC" + set category = "OOC.Resources" src << link("https://wiki.vore-station.net/Changelog") /* @@ -477,7 +477,7 @@ /mob/verb/observe() set name = "Observe" - set category = "OOC" + set category = "OOC.Game" var/is_admin = 0 if(client.holder && (client.holder.rights & R_ADMIN|R_EVENT)) @@ -519,7 +519,7 @@ /mob/verb/cancel_camera() set name = "Cancel Camera View" - set category = "OOC" + set category = "OOC.Game" unset_machine() reset_view(null) @@ -543,7 +543,7 @@ /mob/verb/stop_pulling() set name = "Stop Pulling" - set category = "IC" + set category = "IC.Game" if(pulling) if(ishuman(pulling)) @@ -998,7 +998,7 @@ /mob/verb/face_direction() set name = "Face Direction" - set category = "IC" + set category = "IC.Game" set src = usr set_face_dir() diff --git a/code/modules/mob/mob_defines.dm b/code/modules/mob/mob_defines.dm index d8db6a7394b..1b069023250 100644 --- a/code/modules/mob/mob_defines.dm +++ b/code/modules/mob/mob_defines.dm @@ -208,7 +208,6 @@ //so don't treat them as being SSD even though their client var is null. var/mob/teleop = null - var/turf/listed_turf = null //the current turf being examined in the stat panel var/list/shouldnt_see = list(/mob/observer/eye) //list of objects that this mob shouldn't see in the stat panel. this silliness is needed because of AI alt+click and cult blood runes var/list/active_genes=list() @@ -240,3 +239,6 @@ var/list/list/misc_tabs = list() var/list/datum/action/actions + + var/list/viruses + var/list/resistances diff --git a/code/modules/mob/mob_planes_vr.dm b/code/modules/mob/mob_planes_vr.dm index 9f5b30f5793..9928180070b 100644 --- a/code/modules/mob/mob_planes_vr.dm +++ b/code/modules/mob/mob_planes_vr.dm @@ -21,8 +21,9 @@ my_mob = M /obj/screen/plane_master/augmented/Destroy() + entopic_users -= my_mob my_mob = null - return ..() + . = ..() /obj/screen/plane_master/augmented/set_visibility(var/want = FALSE) . = ..() diff --git a/code/modules/mob/new_player/skill.dm b/code/modules/mob/new_player/skill.dm index 9bf4c4a4978..98361e4bb69 100644 --- a/code/modules/mob/new_player/skill.dm +++ b/code/modules/mob/new_player/skill.dm @@ -207,7 +207,7 @@ var/global/list/SKILL_PRE = list(JOB_ENGINEER = SKILL_ENGINEER, JOB_ROBOTICIST = return /mob/living/carbon/human/verb/show_skills() - set category = "IC" + set category = "IC.Game" set name = "Show Own Skills" show_skill_window(src, src) diff --git a/code/modules/mob/new_player/sprite_accessories_taur.dm b/code/modules/mob/new_player/sprite_accessories_taur.dm index 8994b7ce1cc..6dc5cbb0116 100644 --- a/code/modules/mob/new_player/sprite_accessories_taur.dm +++ b/code/modules/mob/new_player/sprite_accessories_taur.dm @@ -90,7 +90,7 @@ /mob/living/carbon/human/proc/taur_mount(var/mob/living/M in living_mobs(1)) set name = "Taur Mount/Dismount" - set category = "Abilities" + set category = "Abilities.General" set desc = "Let people ride on you." if(LAZYLEN(buckled_mobs)) diff --git a/code/modules/mob/new_player/sprite_accessories_taur_vr.dm b/code/modules/mob/new_player/sprite_accessories_taur_vr.dm index 8ee54f33d98..f9525966645 100644 --- a/code/modules/mob/new_player/sprite_accessories_taur_vr.dm +++ b/code/modules/mob/new_player/sprite_accessories_taur_vr.dm @@ -617,7 +617,7 @@ name = "Drake (Taur)" icon_state = "drake_s" extra_overlay = "drake_markings" -/// suit_sprites = 'icons/mob/taursuits_drake_vr.dmi' ///Chomp edit +/// suit_sprites = 'icons/mob/taursuits_drake_vr.dmi' suit_sprites = 'icons/mob/taursuits_drake_ch.dmi' icon_sprite_tag = "drake" can_loaf = TRUE diff --git a/code/modules/mob/say.dm b/code/modules/mob/say.dm index a5b7a6f00d9..e7b71271632 100644 --- a/code/modules/mob/say.dm +++ b/code/modules/mob/say.dm @@ -3,7 +3,7 @@ /mob/verb/whisper(message as text) set name = "Whisper" - set category = "IC" + set category = "IC.Subtle" set hidden = 1 //VOREStation Addition Start if(forced_psay) @@ -15,7 +15,7 @@ /mob/verb/say_verb(message as text) set name = "Say" - set category = "IC" + set category = "IC.Chat" set hidden = 1 //VOREStation Addition Start if(forced_psay) @@ -28,7 +28,7 @@ /mob/verb/me_verb(message as message) set name = "Me" - set category = "IC" + set category = "IC.Chat" set desc = "Emote to nearby people (and your pred/prey)" set hidden = 1 diff --git a/code/modules/mob/say_vr.dm b/code/modules/mob/say_vr.dm index 0ce22e0ec01..2c2a928deb3 100644 --- a/code/modules/mob/say_vr.dm +++ b/code/modules/mob/say_vr.dm @@ -4,7 +4,7 @@ /mob/verb/me_verb_subtle(message as message) //This would normally go in say.dm set name = "Subtle" - set category = "IC" + set category = "IC.Subtle" set desc = "Emote to nearby people (and your pred/prey)" set hidden = 1 @@ -27,7 +27,7 @@ /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" + set category = "IC.Subtle" set desc = "Emote to nearby people, with ability to choose which specific portion of people you wish to target." if(say_disabled) //This is here to try to identify lag problems @@ -260,7 +260,7 @@ ///// PSAY ///// /mob/verb/psay(message as text) - set category = "IC" + set category = "IC.Subtle" set name = "Psay" set desc = "Talk to people affected by complete absorbed or dominate predator/prey." @@ -358,7 +358,7 @@ ///// PME ///// /mob/verb/pme(message as message) - set category = "IC" + set category = "IC.Subtle" set name = "Pme" set desc = "Emote to people affected by complete absorbed or dominate predator/prey." @@ -454,7 +454,7 @@ M.me_verb(message) /mob/living/verb/player_narrate(message as message) - set category = "IC" + 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!" @@ -500,7 +500,7 @@ /mob/verb/select_speech_bubble() set name = "Select Speech Bubble" - set category = "OOC" + set category = "OOC.Chat Settings" var/new_speech_bubble = tgui_input_list(src, "Pick new voice (default for automatic selection)", "Character Preference", selectable_speech_bubbles) if(new_speech_bubble) diff --git a/code/modules/multiz/movement.dm b/code/modules/multiz/movement.dm index 66fe8d90efe..41c026076f6 100644 --- a/code/modules/multiz/movement.dm +++ b/code/modules/multiz/movement.dm @@ -1,13 +1,13 @@ /mob/verb/up() set name = "Move Upwards" - set category = "IC" + set category = "IC.Game" if(zMove(UP)) to_chat(src, span_notice("You move upwards.")) /mob/verb/down() set name = "Move Down" - set category = "IC" + set category = "IC.Game" if(zMove(DOWN)) to_chat(src, span_notice("You move down.")) diff --git a/code/modules/multiz/movement_vr.dm b/code/modules/multiz/movement_vr.dm index 656d56600e4..ca467e0a146 100644 --- a/code/modules/multiz/movement_vr.dm +++ b/code/modules/multiz/movement_vr.dm @@ -211,7 +211,7 @@ /mob/living/verb/climb_down() set name = "Climb down wall" set desc = "attempt to climb down the wall you are standing on, in direction you're looking" - set category = "IC" + set category = "IC.Game" var/fall_chance = 0 //Increased if we can't actually climb var/turf/our_turf = get_turf(src) //floor we're standing on diff --git a/code/modules/nifsoft/nif.dm b/code/modules/nifsoft/nif.dm index 04dc280ffb5..d3e02a4e1df 100644 --- a/code/modules/nifsoft/nif.dm +++ b/code/modules/nifsoft/nif.dm @@ -688,7 +688,7 @@ You can also set the stat of a NIF to NIF_TEMPFAIL without any issues to disable /mob/living/carbon/human/proc/set_nif_examine() set name = "NIF Appearance" set desc = "If your NIF alters your appearance in some way, describe it here." - set category = "OOC" + set category = "OOC.Game Settings" if(!nif) remove_verb(src, /mob/living/carbon/human/proc/set_nif_examine) diff --git a/code/modules/nifsoft/nif_tgui.dm b/code/modules/nifsoft/nif_tgui.dm index 2c9227e5ad4..35fe90115b9 100644 --- a/code/modules/nifsoft/nif_tgui.dm +++ b/code/modules/nifsoft/nif_tgui.dm @@ -81,7 +81,7 @@ */ /mob/living/carbon/human/proc/nif_menu() set name = "NIF Menu" - set category = "IC" + set category = "IC.Nif" set desc = "Open the NIF user interface." var/obj/item/nif/N = nif diff --git a/code/modules/nifsoft/software/13_soulcatcher.dm b/code/modules/nifsoft/software/13_soulcatcher.dm index 7e5783cb25d..82d506678bd 100644 --- a/code/modules/nifsoft/software/13_soulcatcher.dm +++ b/code/modules/nifsoft/software/13_soulcatcher.dm @@ -396,7 +396,7 @@ /mob/living/carbon/brain/caught_soul/resist() set name = "Resist" - set category = "IC" + set category = "IC.Game" to_chat(src,span_warning("There's no way out! You're stuck in VR.")) @@ -487,7 +487,7 @@ /mob/proc/nsay(message as text) set name = "NSay" set desc = "Speak into your NIF's Soulcatcher." - set category = "IC" + set category = "IC.NiF" src.nsay_act(message) @@ -517,7 +517,7 @@ /mob/proc/nme(message as message) set name = "NMe" set desc = "Emote into your NIF's Soulcatcher." - set category = "IC" + set category = "IC.NiF" src.nme_act(message) diff --git a/code/modules/organs/blood.dm b/code/modules/organs/blood.dm index 74894542c58..72b24602f9e 100644 --- a/code/modules/organs/blood.dm +++ b/code/modules/organs/blood.dm @@ -246,10 +246,19 @@ var/const/CE_STABLE_THRESHOLD = 0.5 //set reagent data B.data["donor"] = src - if (!B.data["virus2"]) - B.data["virus2"] = list() - B.data["virus2"] |= virus_copylist(src.virus2) - B.data["antibodies"] = src.antibodies + if(!B.data["viruses"]) + B.data["viruses"] = list() + + for(var/datum/disease/D in GetViruses()) + if(D.spread_flags & SPECIAL || D.spread_flags & NON_CONTAGIOUS) + continue + B.data["viruses"] |= D.Copy() + + if(!B.data["resistances"]) + B.data["resistances"] = list() + + if(B.data["resistances"]) + B.data["resistances"] |= GetResistances() B.data["blood_DNA"] = copytext(src.dna.unique_enzymes,1,0) B.data["blood_type"] = copytext(src.dna.b_type,1,0) @@ -282,10 +291,14 @@ var/const/CE_STABLE_THRESHOLD = 0.5 /mob/living/carbon/proc/inject_blood(var/datum/reagent/blood/injected, var/amount) if (!injected || !istype(injected)) return - var/list/sniffles = virus_copylist(injected.data["virus2"]) + var/list/sniffles = injected.data["viruses"] for(var/ID in sniffles) - var/datum/disease2/disease/sniffle = sniffles[ID] - infect_virus2(src,sniffle,1) + var/datum/disease/D = ID + if((D.spread_flags & SPECIAL) || (D.spread_flags & NON_CONTAGIOUS)) // You can't put non-contagius diseases in blood, but just in case + continue + ContractDisease(D) + if (injected.data["resistances"] && prob(5)) + antibodies |= injected.data["resistances"] if (injected.data["antibodies"] && prob(5)) antibodies |= injected.data["antibodies"] var/list/chems = list() @@ -426,8 +439,8 @@ var/const/CE_STABLE_THRESHOLD = 0.5 B.blood_DNA[source.data["blood_DNA"]] = "O+" // Update virus information. - if(source.data["virus2"]) - B.virus2 = virus_copylist(source.data["virus2"]) + if(source.data["viruses"]) + B.viruses = source.data["viruses"] B.fluorescent = 0 B.invisibility = 0 diff --git a/code/modules/organs/internal/eyes.dm b/code/modules/organs/internal/eyes.dm index c0fdfb2b65e..c7952314d72 100644 --- a/code/modules/organs/internal/eyes.dm +++ b/code/modules/organs/internal/eyes.dm @@ -33,7 +33,7 @@ /obj/item/organ/internal/eyes/proc/change_eye_color() set name = "Change Eye Color" set desc = "Changes your robotic eye color instantly." - set category = "IC" + set category = "IC.Settings" set src in usr var/current_color = rgb(eye_colour[1],eye_colour[2],eye_colour[3]) diff --git a/code/modules/paperwork/silicon_photography.dm b/code/modules/paperwork/silicon_photography.dm index ce7fee79ecd..5d343961306 100644 --- a/code/modules/paperwork/silicon_photography.dm +++ b/code/modules/paperwork/silicon_photography.dm @@ -95,7 +95,7 @@ injectmasteralbum(p) /mob/living/silicon/ai/proc/take_image() - set category = "AI Commands" + set category = "AI.Commands" set name = "Take Image" set desc = "Takes an image" @@ -103,7 +103,7 @@ aiCamera.toggle_camera_mode() /mob/living/silicon/ai/proc/view_images() - set category = "AI Commands" + set category = "AI.Commands" set name = "View Images" set desc = "View images" @@ -111,7 +111,7 @@ aiCamera.viewpictures() /mob/living/silicon/ai/proc/delete_images() - set category = "AI Commands" + set category = "AI.Commands" set name = "Delete Image" set desc = "Delete image" diff --git a/code/modules/pda/ai.dm b/code/modules/pda/ai.dm index b3f889f02fc..4511f530a3d 100644 --- a/code/modules/pda/ai.dm +++ b/code/modules/pda/ai.dm @@ -22,7 +22,7 @@ //AI verb and proc for sending PDA messages. /obj/item/pda/ai/verb/cmd_pda_open_ui() - set category = "Abilities.AI_IM" + set category = "Abilities.AI" set name = "Use PDA" set src in usr diff --git a/code/modules/player_tips_vr/player_tips_controller_vr.dm b/code/modules/player_tips_vr/player_tips_controller_vr.dm index 6b8ce44414b..e0e856765c2 100644 --- a/code/modules/player_tips_vr/player_tips_controller_vr.dm +++ b/code/modules/player_tips_vr/player_tips_controller_vr.dm @@ -41,7 +41,7 @@ Controlled by the player_tips subsystem under code/controllers/subsystems/player /mob/living/verb/request_automated_advice() set name = "Request Automated Advice" set desc = "Sends you advice from a list of possibilities. You can choose to request a specific topic." - set category = "OOC" + set category = "OOC.Game Settings" var/choice = tgui_input_list(src, "What topic would you like to receive advice on?", "Select Topic", list("none","general","gameplay","roleplay","lore","cancel")) if(choice == "cancel") diff --git a/code/modules/power/cell.dm b/code/modules/power/cell.dm index 2a98049b0bb..5379ab7f423 100644 --- a/code/modules/power/cell.dm +++ b/code/modules/power/cell.dm @@ -18,7 +18,7 @@ var/emp_proof = FALSE var/static/cell_uid = 1 // Unique ID of this power cell. Used to reduce bunch of uglier code in nanoUI. var/c_uid - var/charge = 0 // note %age conveted to actual charge in New + var/charge = 1000 // maximum charge on spawn var/maxcharge = 1000 var/rigged = 0 // true if rigged to explode var/minor_fault = 0 //If not 100% reliable, it will build up faults. @@ -27,6 +27,7 @@ var/last_use = 0 // A tracker for use in self-charging var/connector_type = "standard" //What connector sprite to use when in a cell charger, null if no connectors var/charge_delay = 0 // How long it takes for the cell to start recharging after last use + var/robot_durability = 50 matter = list(MAT_STEEL = 700, MAT_GLASS = 50) drop_sound = 'sound/items/drop/component.ogg' pickup_sound = 'sound/items/pickup/component.ogg' @@ -35,10 +36,9 @@ var/standard_overlays = TRUE var/last_overlay_state = null // Used to optimize update_icon() calls. -/obj/item/cell/New() - ..() +/obj/item/cell/Initialize() + . = ..() c_uid = cell_uid++ - charge = maxcharge update_icon() if(self_recharge) START_PROCESSING(SSobj, src) diff --git a/code/modules/power/cells/device_cells.dm b/code/modules/power/cells/device_cells.dm index fd93e450f14..4179cf6c2db 100644 --- a/code/modules/power/cells/device_cells.dm +++ b/code/modules/power/cells/device_cells.dm @@ -10,15 +10,14 @@ force = 0 throw_speed = 5 throw_range = 7 + charge = 480 maxcharge = 480 charge_amount = 5 matter = list(MAT_STEEL = 350, MAT_GLASS = 50) preserve_item = 1 -/obj/item/cell/device/empty/Initialize() - . = ..() +/obj/item/cell/device/empty charge = 0 - update_icon() /* * Crap Device @@ -29,16 +28,15 @@ description_fluff = "You can't top the rust top." //TOTALLY TRADEMARK INFRINGEMENT origin_tech = list(TECH_POWER = 0) icon_state = "device_crap" + charge = 240 maxcharge = 240 matter = list(MAT_STEEL = 350, MAT_GLASS = 30) /obj/item/cell/device/crap/update_icon() //No visible charge indicator return -/obj/item/cell/device/crap/empty/Initialize() - . = ..() +/obj/item/cell/device/crap/empty charge = 0 - update_icon() /* * Hyper Device @@ -47,13 +45,12 @@ name = "hyper device power cell" desc = "A small power cell designed to power handheld devices. Has a better charge than a standard device cell." icon_state = "hype_device_cell" + charge = 600 maxcharge = 600 matter = list(MAT_STEEL = 400, MAT_GLASS = 60) -/obj/item/cell/device/hyper/empty/Initialize() - . = ..() +/obj/item/cell/device/hyper/empty charge = 0 - update_icon() /* * EMP Proof Device @@ -65,10 +62,8 @@ matter = list(MAT_STEEL = 400, MAT_GLASS = 60) emp_proof = TRUE -/obj/item/cell/device/empproof/empty/Initialize() - . = ..() +/obj/item/cell/device/empproof/empty charge = 0 - update_icon() /* * Weapon @@ -77,13 +72,12 @@ name = "weapon power cell" desc = "A small power cell designed to power handheld weaponry." icon_state = "weapon_cell" + charge = 2400 maxcharge = 2400 charge_amount = 20 -/obj/item/cell/device/weapon/empty/Initialize() - . = ..() +/obj/item/cell/device/weapon/empty charge = 0 - update_icon() /* * EMP Proof Weapon @@ -95,10 +89,8 @@ matter = list(MAT_STEEL = 400, MAT_GLASS = 60) emp_proof = TRUE -/obj/item/cell/device/weapon/empproof/empty/Initialize() - . = ..() +/obj/item/cell/device/weapon/empproof/empty charge = 0 - update_icon() /* * Self-charging Weapon @@ -139,7 +131,7 @@ value = CATALOGUER_REWARD_EASY /obj/item/cell/device/weapon/recharge/alien - name = "void cell" + name = "void cell (device)" desc = "An alien technology that produces energy seemingly out of nowhere. Its small, cylinderal shape means it might be able to be used with human technology, perhaps?" catalogue_data = list(/datum/category_item/catalogue/anomalous/precursor_a/alien_void_cell) icon = 'icons/obj/abductor.dmi' @@ -147,6 +139,24 @@ charge_amount = 120 // 5%. charge_delay = 50 // Every five seconds, bit faster than the default. origin_tech = list(TECH_POWER = 8, TECH_ENGINEERING = 6) + var/swaps_to = /obj/item/cell/void + standard_overlays = FALSE /obj/item/cell/device/weapon/recharge/alien/update_icon() - return // No overlays please. \ No newline at end of file + return // No overlays please. + +/obj/item/cell/device/weapon/recharge/alien/attack_self(var/mob/user) + user.remove_from_mob(src) + to_chat(user, span_notice("You swap [src] to 'machinery cell' mode.")) + var/obj/item/cell/newcell = new swaps_to(null) + user.put_in_active_hand(newcell) + var/percentage = charge/maxcharge + newcell.charge = newcell.maxcharge * percentage + newcell.persist_storable = persist_storable + qdel(src) + +// Bloo friendlier hybrid tech +/obj/item/cell/device/weapon/recharge/alien/hybrid + icon = 'icons/obj/power_vr.dmi' + icon_state = "cellb" + swaps_to = /obj/item/cell/void/hybrid diff --git a/code/modules/power/cells/device_cells_vr.dm b/code/modules/power/cells/device_cells_vr.dm deleted file mode 100644 index f810799f849..00000000000 --- a/code/modules/power/cells/device_cells_vr.dm +++ /dev/null @@ -1,52 +0,0 @@ - -//The device cell -/obj/item/cell/device/weapon/recharge/alien - name = "void cell (device)" - var/swaps_to = /obj/item/cell/void - standard_overlays = FALSE - -/obj/item/cell/device/weapon/recharge/alien/attack_self(var/mob/user) - user.remove_from_mob(src) - to_chat(user, span_notice("You swap [src] to 'machinery cell' mode.")) - var/obj/item/cell/newcell = new swaps_to(null) - user.put_in_active_hand(newcell) - var/percentage = charge/maxcharge - newcell.charge = newcell.maxcharge * percentage - newcell.persist_storable = persist_storable - qdel(src) - -//The machine cell -/obj/item/cell/void - name = "void cell (machinery)" - desc = "An alien technology that produces energy seemingly out of nowhere. Its small, cylinderal shape means it might be able to be used with human technology, perhaps?" - origin_tech = list(TECH_POWER = 8, TECH_ENGINEERING = 6) - icon = 'icons/obj/abductor.dmi' - icon_state = "cell" - maxcharge = 4800 //10x the device version - charge_amount = 1200 //10x the device version - self_recharge = TRUE - charge_delay = 50 - matter = null - standard_overlays = FALSE - var/swaps_to = /obj/item/cell/device/weapon/recharge/alien - -/obj/item/cell/void/attack_self(var/mob/user) - user.remove_from_mob(src) - to_chat(user, span_notice("You swap [src] to 'device cell' mode.")) - var/obj/item/cell/newcell = new swaps_to(null) - user.put_in_active_hand(newcell) - var/percentage = charge/maxcharge - newcell.charge = newcell.maxcharge * percentage - newcell.persist_storable = persist_storable - qdel(src) - -// Bloo friendlier hybrid tech -/obj/item/cell/device/weapon/recharge/alien/hybrid - icon = 'icons/obj/power_vr.dmi' - icon_state = "cellb" - swaps_to = /obj/item/cell/void/hybrid - -/obj/item/cell/void/hybrid - icon = 'icons/obj/power_vr.dmi' - icon_state = "cellb" - swaps_to = /obj/item/cell/device/weapon/recharge/alien/hybrid diff --git a/code/modules/power/cells/esoteric_cells.dm b/code/modules/power/cells/esoteric_cells.dm index aeacc6b3e67..925a8f55437 100644 --- a/code/modules/power/cells/esoteric_cells.dm +++ b/code/modules/power/cells/esoteric_cells.dm @@ -4,6 +4,7 @@ desc = "A modified power cell sitting in a highly conductive chassis." origin_tech = list(TECH_POWER = 2) icon_state = "modded" + charge = 10000 maxcharge = 10000 matter = list(MAT_STEEL = 1000, MAT_GLASS = 80, MAT_SILVER = 100) self_recharge = TRUE diff --git a/code/modules/power/cells/power_cells.dm b/code/modules/power/cells/power_cells.dm index 774c5d88172..3722b6832f5 100644 --- a/code/modules/power/cells/power_cells.dm +++ b/code/modules/power/cells/power_cells.dm @@ -1,8 +1,7 @@ /* * Empty */ -/obj/item/cell/empty/New() - ..() +/obj/item/cell/empty charge = 0 /* @@ -14,14 +13,15 @@ description_fluff = "You can't top the rust top." //TOTALLY TRADEMARK INFRINGEMENT origin_tech = list(TECH_POWER = 0) icon_state = "crap" + charge = 500 maxcharge = 500 matter = list(MAT_STEEL = 700, MAT_GLASS = 40) + robot_durability = 20 /obj/item/cell/crap/update_icon() //No visible charge indicator return -/obj/item/cell/crap/empty/New() - ..() +/obj/item/cell/crap/empty charge = 0 /* @@ -31,6 +31,7 @@ name = "heavy-duty power cell" origin_tech = list(TECH_POWER = 1) icon_state = "apc" + charge = 5000 maxcharge = 5000 matter = list(MAT_STEEL = 700, MAT_GLASS = 50) @@ -39,6 +40,7 @@ */ /obj/item/cell/robot_station name = "standard robot power cell" + charge = 7500 maxcharge = 7500 /* @@ -48,13 +50,13 @@ name = "high-capacity power cell" origin_tech = list(TECH_POWER = 2) icon_state = "high" + charge = 10000 maxcharge = 10000 matter = list(MAT_STEEL = 700, MAT_GLASS = 60) + robot_durability = 55 -/obj/item/cell/high/empty/New() - ..() +/obj/item/cell/high/empty charge = 0 - update_icon() /* * Super @@ -63,13 +65,13 @@ name = "super-capacity power cell" origin_tech = list(TECH_POWER = 5) icon_state = "super" + charge = 20000 maxcharge = 20000 matter = list(MAT_STEEL = 700, MAT_GLASS = 70) + robot_durability = 60 -/obj/item/cell/super/empty/New() - ..() +/obj/item/cell/super/empty charge = 0 - update_icon() /* * Syndicate @@ -78,7 +80,9 @@ name = "syndicate robot power cell" description_fluff = "Almost as good as a hyper." icon_state = "super" //We don't want roboticists confuse it with a low standard cell + charge = 25000 maxcharge = 25000 + robot_durability = 65 /* * Hyper @@ -87,13 +91,13 @@ name = "hyper-capacity power cell" origin_tech = list(TECH_POWER = 6) icon_state = "hyper" + charge = 30000 maxcharge = 30000 matter = list(MAT_STEEL = 700, MAT_GLASS = 80) + robot_durability = 70 -/obj/item/cell/hyper/empty/New() - ..() +/obj/item/cell/hyper/empty charge = 0 - update_icon() /* * Mecha @@ -141,8 +145,10 @@ name = "infinite-capacity power cell!" icon_state = "infinity" origin_tech = null + charge = 30000 maxcharge = 30000 //determines how badly mobs get shocked matter = list(MAT_STEEL = 700, MAT_GLASS = 80) + robot_durability = 200 /obj/item/cell/infinite/check_charge() return 1 @@ -161,6 +167,7 @@ charge = 100 maxcharge = 300 minor_fault = 1 + robot_durability = 30 /* * Slime @@ -173,6 +180,7 @@ icon_state = "yellow slime extract" //"potato_battery" connector_type = "slime" description_info = "This 'cell' holds a max charge of 10k and self recharges over time." + charge = 10000 maxcharge = 10000 matter = null self_recharge = TRUE @@ -184,6 +192,7 @@ /obj/item/cell/emergency_light name = "miniature power cell" desc = "A tiny power cell with a very low power capacity. Used in light fixtures to power them in the event of an outage." + charge = 120 maxcharge = 120 //Emergency lights use 0.2 W per tick, meaning ~10 minutes of emergency power from a cell matter = list(MAT_GLASS = 20) icon_state = "em_light" @@ -240,3 +249,35 @@ cut_overlays() target.adjust_nutrition(amount) user.custom_emote(message = "connects \the [src] to [user == target ? "their" : "[target]'s"] charging port, expending it.") + +//The machine cell +/obj/item/cell/void + name = "void cell (machinery)" + desc = "An alien technology that produces energy seemingly out of nowhere. Its small, cylinderal shape means it might be able to be used with human technology, perhaps?" + origin_tech = list(TECH_POWER = 8, TECH_ENGINEERING = 6) + icon = 'icons/obj/abductor.dmi' + icon_state = "cell" + charge = 4800 + maxcharge = 4800 //10x the device version + charge_amount = 1200 //10x the device version + self_recharge = TRUE + charge_delay = 50 + matter = null + standard_overlays = FALSE + var/swaps_to = /obj/item/cell/device/weapon/recharge/alien + robot_durability = 100 + +/obj/item/cell/void/attack_self(var/mob/user) + user.remove_from_mob(src) + to_chat(user, span_notice("You swap [src] to 'device cell' mode.")) + var/obj/item/cell/newcell = new swaps_to(null) + user.put_in_active_hand(newcell) + var/percentage = charge/maxcharge + newcell.charge = newcell.maxcharge * percentage + newcell.persist_storable = persist_storable + qdel(src) + +/obj/item/cell/void/hybrid + icon = 'icons/obj/power_vr.dmi' + icon_state = "cellb" + swaps_to = /obj/item/cell/device/weapon/recharge/alien/hybrid diff --git a/code/modules/power/supermatter/setup_supermatter.dm b/code/modules/power/supermatter/setup_supermatter.dm index 2267909e850..ab3729890d4 100644 --- a/code/modules/power/supermatter/setup_supermatter.dm +++ b/code/modules/power/supermatter/setup_supermatter.dm @@ -10,7 +10,7 @@ /datum/admins/proc/setup_supermatter() - set category = "Debug" + set category = "Debug.Game" set name = "Setup Supermatter" set desc = "Allows you to start the Supermatter engine." diff --git a/code/modules/projectiles/targeting/targeting_mob.dm b/code/modules/projectiles/targeting/targeting_mob.dm index f80255c2b55..17aa15eed7a 100644 --- a/code/modules/projectiles/targeting/targeting_mob.dm +++ b/code/modules/projectiles/targeting/targeting_mob.dm @@ -4,7 +4,7 @@ /mob/verb/toggle_gun_mode() set name = "Toggle Gun Mode" set desc = "Begin or stop aiming." - set category = "IC" + set category = "IC.Game" if(isliving(src)) var/mob/living/M = src diff --git a/code/modules/random_map/drop/droppod.dm b/code/modules/random_map/drop/droppod.dm index 6ceb139537e..09ef0e6d2ed 100644 --- a/code/modules/random_map/drop/droppod.dm +++ b/code/modules/random_map/drop/droppod.dm @@ -149,7 +149,7 @@ drop.forceMove(T) /datum/admins/proc/call_drop_pod() - set category = "Fun" + set category = "Fun.Drop Pod" set desc = "Call an immediate drop pod on your location." set name = "Call Drop Pod" diff --git a/code/modules/random_map/drop/supply.dm b/code/modules/random_map/drop/supply.dm index e4c2047d1f6..2e04d38d922 100644 --- a/code/modules/random_map/drop/supply.dm +++ b/code/modules/random_map/drop/supply.dm @@ -33,7 +33,7 @@ /datum/admins/proc/call_supply_drop() - set category = "Fun" + set category = "Fun.Drop Pod" set desc = "Call an immediate supply drop on your location." set name = "Call Supply Drop" diff --git a/code/modules/random_map/random_map_verbs.dm b/code/modules/random_map/random_map_verbs.dm index c08e5ea119e..8bef0f3231e 100644 --- a/code/modules/random_map/random_map_verbs.dm +++ b/code/modules/random_map/random_map_verbs.dm @@ -1,5 +1,5 @@ /client/proc/print_random_map() - set category = "Debug" + set category = "Debug.Events" set name = "Display Random Map" set desc = "Show the contents of a random map." @@ -13,7 +13,7 @@ M.display_map(usr) /client/proc/delete_random_map() - set category = "Debug" + set category = "Debug.Events" set name = "Delete Random Map" set desc = "Delete a random map." @@ -30,7 +30,7 @@ qdel(M) /client/proc/create_random_map() - set category = "Debug" + set category = "Debug.Events" set name = "Create Random Map" set desc = "Create a random map." @@ -54,7 +54,7 @@ log_admin("[key_name(usr)] has created [M.name].") /client/proc/apply_random_map() - set category = "Debug" + set category = "Debug.Events" set name = "Apply Random Map" set desc = "Apply a map to the game world." @@ -79,7 +79,7 @@ M.apply_to_map() /client/proc/overlay_random_map() - set category = "Debug" + set category = "Debug.Events" set name = "Overlay Random Map" set desc = "Apply a map to another map." diff --git a/code/modules/reagents/Chemistry-Logging.dm b/code/modules/reagents/Chemistry-Logging.dm index 4c7b2343ad8..57ea0270ad7 100644 --- a/code/modules/reagents/Chemistry-Logging.dm +++ b/code/modules/reagents/Chemistry-Logging.dm @@ -16,7 +16,7 @@ /client/proc/view_chemical_reaction_logs() set name = "Show Chemical Reactions" - set category = "Admin" + set category = "Admin.Investigate" if(!check_rights(R_ADMIN|R_MOD)) return diff --git a/code/modules/reagents/machinery/dispenser/cartridge_spawn.dm b/code/modules/reagents/machinery/dispenser/cartridge_spawn.dm index 00287e83734..a33c401f03d 100644 --- a/code/modules/reagents/machinery/dispenser/cartridge_spawn.dm +++ b/code/modules/reagents/machinery/dispenser/cartridge_spawn.dm @@ -1,6 +1,6 @@ /client/proc/spawn_chemdisp_cartridge(size in list("small", "medium", "large"), reagent in SSchemistry.chemical_reagents) set name = "Spawn Chemical Dispenser Cartridge" - set category = "Admin" + set category = "Admin.Events" var/obj/item/reagent_containers/chem_disp_cartridge/C switch(size) diff --git a/code/modules/reagents/machinery/dispenser/reagent_tank.dm b/code/modules/reagents/machinery/dispenser/reagent_tank.dm index e821a54366b..058cbe26ea8 100644 --- a/code/modules/reagents/machinery/dispenser/reagent_tank.dm +++ b/code/modules/reagents/machinery/dispenser/reagent_tank.dm @@ -340,7 +340,7 @@ /obj/structure/reagent_dispensers/water_cooler/Initialize() . = ..() if(bottle) - reagents.add_reagent("water",120) + reagents.add_reagent("water",2000) update_icon() /obj/structure/reagent_dispensers/water_cooler/examine(mob/user) diff --git a/code/modules/reagents/machinery/pump.dm b/code/modules/reagents/machinery/pump.dm index 53bf48365ee..ed371c96732 100644 --- a/code/modules/reagents/machinery/pump.dm +++ b/code/modules/reagents/machinery/pump.dm @@ -18,7 +18,7 @@ var/obj/item/cell/cell = null var/obj/item/hose_connector/output/Output = null - var/reagents_per_cycle = 40 + var/reagents_per_cycle = 5 // severe nerf to unupgraded speed var/on = 0 var/unlocked = 0 var/open = 0 @@ -58,6 +58,8 @@ qdel(src.reagents) src.reagents = R + cell = locate(/obj/item/cell) in src + /obj/machinery/pump/update_icon() ..() cut_overlays() @@ -158,7 +160,13 @@ return FALSE default_unfasten_wrench(user, W, 2 SECONDS) - else if(istype(W, /obj/item/cell) && open) + else if(istype(W, /obj/item/cell)) + if(!open) + if(unlocked) + to_chat(user, span_notice("The battery panel is screwed shut.")) + else + to_chat(user, span_notice("The battery panel is watertight and cannot be opened without a crowbar.")) + return FALSE if(istype(cell)) to_chat(user, span_notice("There is a power cell already installed.")) return FALSE @@ -168,7 +176,7 @@ else . = ..() - RefreshParts() + RefreshParts() // Handles cell assignment update_icon() @@ -184,13 +192,13 @@ . = ..() R.add_reagent("water", round(volume, 0.1)) - if(temperature <= T0C) + var/datum/gas_mixture/air = return_air() // v + if(air.temperature <= T0C) // Uses the current air temp, instead of the turf starting temp R.add_reagent("ice", round(volume / 2, 0.1)) - for(var/turf/simulated/mineral/M in orange(5)) - if(istype(M.mineral, /obj/effect/mineral)) - var/obj/effect/mineral/ore = M.mineral - reagents.add_reagent(ore.ore_reagent, round(volume / 2, 0.1)) + for(var/turf/simulated/mineral/M in orange(5,src)) // Uses the turf as center instead of an unset usr + if(M.mineral && prob(40)) // v + R.add_reagent(M.mineral.reagent, round(volume / 5, 0.1)) // Was the turf's reagents variable not the R argument, and changed ore_reagent to M.mineral.reagent because of above change. Also nerfed amount to 1/5 instead of 1/2 /turf/simulated/floor/water/pool/pump_reagents(var/datum/reagents/R, var/volume) . = ..() diff --git a/code/modules/reagents/reactions/instant/virology.dm b/code/modules/reagents/reactions/instant/virology.dm new file mode 100644 index 00000000000..f8d50383267 --- /dev/null +++ b/code/modules/reagents/reactions/instant/virology.dm @@ -0,0 +1,133 @@ +/decl/chemical_reaction/instant/virus_food_mutagen + name = "mutagenic agar" + id = "mutagenvirusfood" + result = "mutagenvirusfood" + required_reagents = list("mutagen" = 1, "virusfood" = 1) + result_amount = 1 + +/decl/chemical_reaction/instant/virus_food_adranol + name = "virus rations" + id = "adranolvirusfood" + result = "adranolvirusfood" + required_reagents = list("adranol" = 1, "virusfood" = 1) + result_amount = 1 + +/decl/chemical_reaction/instant/virus_food_phoron + name = "phoronic virus food" + id = "phoronvirusfood" + result = "phoronvirusfood" + required_reagents = list("phoron" = 1, "virusfood" = 1) + result_amount = 1 + +/decl/chemical_reaction/instant/virus_food_phoron_adranol + name = "weakened phoronic virus food" + id = "weakphoronvirusfood" + result = "weakphoronvirusfood" + required_reagents = list("adranol" = 1, "phoronvirusfood" = 1) + result_amount = 2 + +/decl/chemical_reaction/instant/virus_food_mutagen_sugar + name = "sucrose agar" + id = "sugarvirusfood" + result = "sugarvirusfood" + required_reagents = list("sugar" = 1, "mutagenvirusfood" = 1) + result_amount = 2 + +/decl/chemical_reaction/instant/virus_food_mutagen_inaprovaline + name = "sucrose agar" + id = "inaprovalinevirusfood" + result = "sugarvirusfood" + required_reagents = list("inaprovaline" = 1, "mutagenvirusfood" = 1) + result_amount = 2 + +/decl/chemical_reaction/instant/mix_virus + name = "Mix Virus" + id = "mixvirus" + required_reagents = list("virusfood" = 1) + catalysts = list("blood" = 1) + var/level_min = 0 + var/level_max = 2 + +/decl/chemical_reaction/instant/mix_virus/on_reaction(datum/reagents/holder) + var/datum/reagent/blood/B = locate(/datum/reagent/blood) in holder.reagent_list + if(B && B.data) + var/datum/disease/advance/D = locate(/datum/disease/advance) in B.data["viruses"] + if(D) + D.Evolve(level_min, level_max) + +/decl/chemical_reaction/instant/mix_virus/mix_virus_2 + name = "Mix Virus 2" + id = "mixvirus2" + required_reagents = list("mutagen" = 1) + level_min = 2 + level_max = 4 + +/decl/chemical_reaction/instant/mix_virus/mix_virus_3 + name = "Mix Virus 3" + id = "mixvirus3" + required_reagents = list("phoron" = 1) + level_min = 4 + level_max = 6 + +/decl/chemical_reaction/instant/mix_virus/mix_virus_4 + name = "Mix Virus 4" + id = "mixvirus4" + required_reagents = list("uranium" = 1) + level_min = 5 + level_max = 6 + +/decl/chemical_reaction/instant/mix_virus/mix_virus_5 + name = "Mix Virus 5" + id = "mixvirus5" + required_reagents = list("mutagenvirusfood" = 1) + level_min = 3 + level_max = 3 + +/decl/chemical_reaction/instant/mix_virus/mix_virus_6 + name = "Mix Virus 6" + id = "mixvirus6" + required_reagents = list("sugarvirusfood" = 1) + level_min = 4 + level_max = 4 + +/decl/chemical_reaction/instant/mix_virus/mix_virus_7 + name = "Mix Virus 7" + id = "mixvirus7" + required_reagents = list("weakphoronvirusfood" = 1) + level_min = 5 + level_max = 5 + +/decl/chemical_reaction/instant/mix_virus/mix_virus_8 + name = "Mix Virus 8" + id = "mixvirus8" + required_reagents = list("phoronvirusfood" = 1) + level_min = 6 + level_max = 6 + +/decl/chemical_reaction/instant/mix_virus/mix_virus_9 + name = "Mix Virus 9" + id = "mixvirus9" + required_reagents = list("adranolvirusfood" = 1) + level_min = 1 + level_max = 1 + +/decl/chemical_reaction/instant/mix_virus/rem_virus + name = "Devolve Virus" + id = "remvirus" + required_reagents = list("adranol" = 1) + catalysts = list("blood" = 1) + +/decl/chemical_reaction/instant/mix_virus/rem_virus/on_reaction(var/datum/reagents/holder) + var/datum/reagent/blood/B = locate(/datum/reagent/blood) in holder.reagent_list + if(B && B.data) + var/datum/disease/advance/D = locate(/datum/disease/advance) in B.data["viruses"] + if(D) + D.Devolve() + +/decl/chemical_reaction/instant/antibodies + name = "Antibodies" + id = "antibodiesmix" + result = "antibodies" + required_reagents = list("vaccine") + catalysts = list("inaprovaline" = 0.1) + result_amount = 0.5 diff --git a/code/modules/reagents/reagent_containers/glass.dm b/code/modules/reagents/reagent_containers/glass.dm index e7f7611c796..0298998d7f4 100644 --- a/code/modules/reagents/reagent_containers/glass.dm +++ b/code/modules/reagents/reagent_containers/glass.dm @@ -39,17 +39,16 @@ /obj/item/storage/secure/safe, /obj/machinery/iv_drip, /obj/structure/medical_stand, //VOREStation Add, - /obj/machinery/disease2/incubator, /obj/machinery/disposal, /mob/living/simple_mob/animal/passive/cow, /mob/living/simple_mob/animal/goat, - /obj/machinery/computer/centrifuge, /obj/machinery/sleeper, /obj/machinery/smartfridge/, /obj/machinery/biogenerator, /obj/structure/frame, /obj/machinery/radiocarbon_spectrometer, - /obj/machinery/portable_atmospherics/powered/reagent_distillery + /obj/machinery/portable_atmospherics/powered/reagent_distillery, + /obj/machinery/computer/pandemic ) /obj/item/reagent_containers/glass/Initialize() @@ -399,11 +398,18 @@ name = "water-cooler bottle" icon = 'icons/obj/vending.dmi' icon_state = "water_cooler_bottle" - matter = list(MAT_GLASS = 2000) - w_class = ITEMSIZE_NORMAL + matter = list(MAT_PLASTIC = 2000) + w_class = ITEMSIZE_NO_CONTAINER amount_per_transfer_from_this = 20 possible_transfer_amounts = list(10,20,30,60,120) - volume = 120 + volume = 2000 + slowdown = 2 + + can_be_placed_into = list( + /obj/structure/table, + /obj/structure/closet, + /obj/structure/sink + ) /obj/item/reagent_containers/glass/pint_mug desc = "A rustic pint mug designed for drinking ale." diff --git a/code/modules/reagents/reagent_containers/hypospray.dm b/code/modules/reagents/reagent_containers/hypospray.dm index fb98d48483e..0ba23194183 100644 --- a/code/modules/reagents/reagent_containers/hypospray.dm +++ b/code/modules/reagents/reagent_containers/hypospray.dm @@ -381,5 +381,4 @@ /obj/item/reagent_containers/hypospray/autoinjector/biginjector/contaminated/do_injection(mob/living/carbon/human/H, mob/living/user) . = ..() if(.) // Will occur if successfully injected. - infect_mob_random_lesser(H) add_attack_logs(user, H, "Infected \the [H] with \the [src], by \the [user].") diff --git a/code/modules/reagents/reagent_containers/syringes.dm b/code/modules/reagents/reagent_containers/syringes.dm index bc472d3424c..7c5c3cc9c68 100644 --- a/code/modules/reagents/reagent_containers/syringes.dm +++ b/code/modules/reagents/reagent_containers/syringes.dm @@ -32,7 +32,7 @@ var/used = FALSE var/dirtiness = 0 var/list/targets - var/list/datum/disease2/disease/viruses + var/list/datum/disease/viruses drop_sound = 'sound/items/drop/glass.ogg' pickup_sound = 'sound/items/pickup/glass.ogg' @@ -402,10 +402,10 @@ targets |= hash //Grab any viruses they have - if(iscarbon(target) && LAZYLEN(target.virus2.len)) + if(iscarbon(target) && LAZYLEN(target.viruses.len)) LAZYINITLIST(viruses) - var/datum/disease2/disease/virus = pick(target.virus2.len) - viruses[hash] = virus.getcopy() + var/datum/disease/virus = pick(target.viruses.len) + viruses[hash] = virus.Copy() //Dirtiness should be very low if you're the first injectee. If you're spam-injecting 4 people in a row around you though, //This gives the last one a 30% chance of infection. @@ -421,8 +421,8 @@ if(LAZYLEN(viruses) && prob(75)) var/old_hash = pick(viruses) if(hash != old_hash) //Same virus you already had? - var/datum/disease2/disease/virus = viruses[old_hash] - infect_virus2(target,virus.getcopy()) + var/datum/disease/virus = viruses[old_hash] + target.ContractDisease(virus) if(!used) START_PROCESSING(SSobj, src) diff --git a/code/modules/reagents/reagent_containers/virology.dm b/code/modules/reagents/reagent_containers/virology.dm new file mode 100644 index 00000000000..a1d4403900f --- /dev/null +++ b/code/modules/reagents/reagent_containers/virology.dm @@ -0,0 +1,26 @@ +/obj/item/reagent_containers/glass/bottle/culture + name = "virus culture" + desc = "A bottle with a virus culture" + icon_state = "bottle-1" + var/list/data = list("donor" = null, "viruses" = null, "blood_DNA" = null, "blood_type" = null, "resistances" = null, "trace_chems" = null) + var/list/diseases = list() + +/obj/item/reagent_containers/glass/bottle/culture/cold + name = "cold virus culture" + desc = "A bottle with the common cold culture" + +/obj/item/reagent_containers/glass/bottle/culture/cold/Initialize() + . = ..() + diseases += new /datum/disease/advance/cold + data["viruses"] = diseases + reagents.add_reagent("blood", 10, data) + +/obj/item/reagent_containers/glass/bottle/culture/flu + name = "flu virus culture" + desc = "A bottle with the flu culture" + +/obj/item/reagent_containers/glass/bottle/culture/flu/Initialize() + . = ..() + diseases += new /datum/disease/advance/flu + data["viruses"] = diseases + reagents.add_reagent("blood", 10, data) diff --git a/code/modules/reagents/reagents/core.dm b/code/modules/reagents/reagents/core.dm index 10a50a3b982..8157632742d 100644 --- a/code/modules/reagents/reagents/core.dm +++ b/code/modules/reagents/reagents/core.dm @@ -23,9 +23,9 @@ /datum/reagent/blood/get_data() // Just in case you have a reagent that handles data differently. var/t = data.Copy() - if(t["virus2"]) - var/list/v = t["virus2"] - t["virus2"] = v.Copy() + if(t["viruses"]) + var/list/v = t["viruses"] + t["viruses"] = v.Copy() return t /datum/reagent/blood/touch_turf(var/turf/simulated/T) @@ -70,13 +70,16 @@ if(effective_dose > 15) if(!is_vampire) //VOREStation Edit. M.adjustToxLoss(removed) //VOREStation Edit. - if(data && data["virus2"]) - var/list/vlist = data["virus2"] + if(data && data["viruses"]) + var/list/vlist = data["viruses"] if(vlist.len) for(var/ID in vlist) - var/datum/disease2/disease/V = vlist[ID] - if(V.spreadtype == "Contact") - infect_virus2(M, V.getcopy()) + if(!ID) + continue + var/datum/disease/D = ID + if((D.spread_flags & SPECIAL) || (D.spread_flags & NON_CONTAGIOUS)) + continue + M.ContractDisease(D) /datum/reagent/blood/affect_touch(var/mob/living/carbon/M, var/alien, var/removed) if(ishuman(M)) @@ -86,15 +89,59 @@ if(alien == IS_SLIME) affect_ingest(M, alien, removed) return - if(data && data["virus2"]) - var/list/vlist = data["virus2"] + if(data && data["viruses"]) + var/list/vlist = data["viruses"] if(vlist.len) for(var/ID in vlist) - var/datum/disease2/disease/V = vlist[ID] - if(V.spreadtype == "Contact") - infect_virus2(M, V.getcopy()) - if(data && data["antibodies"]) - M.antibodies |= data["antibodies"] + var/datum/disease/D = ID + if((D.spread_flags & SPECIAL) || (D.spread_flags & NON_CONTAGIOUS)) + continue + M.ContractDisease(D) + if(data && data["resistances"]) + M.resistances |= data["resistances"] + +/datum/reagent/blood/mix_data(newdata, newamount) + if(!data || !newdata) + return + + if(data["viruses"] || newdata["viruses"]) + var/list/mix1 = data["viruses"] + var/list/mix2 = newdata["viruses"] + + var/list/to_mix = list() + var/list/preserve = list() + + for(var/datum/disease/advance/AD in mix1) + to_mix += AD + for(var/datum/disease/advance/AD in mix2) + to_mix += AD + + var/datum/disease/advance/mixed_AD = Advance_Mix(to_mix) + + if(mixed_AD) + preserve += mixed_AD + + for(var/datum/disease/D1 in mix1) + if(!istype(D1, /datum/disease/advance)) + var/keep = TRUE + for(var/datum/disease/D2 in preserve) + if(D1.IsSame(D2)) + keep = FALSE + break + if(keep) + preserve += D1 + + for(var/datum/disease/D1 in mix2) + if(!istype(D1, /datum/disease/advance)) + var/keep = TRUE + for(var/datum/disease/D2 in preserve) + if(D1.IsSame(D2)) + keep = FALSE + break + if(keep) + preserve += D1 + + data["viruses"] = preserve /datum/reagent/blood/affect_blood(var/mob/living/carbon/M, var/alien, var/removed) if(alien == IS_SLIME) //They don't have blood, so it seems weird that they would instantly 'process' the chemical like another species does. diff --git a/code/modules/reagents/reagents/dispenser.dm b/code/modules/reagents/reagents/dispenser.dm index add0a751561..dcdc0f7c50b 100644 --- a/code/modules/reagents/reagents/dispenser.dm +++ b/code/modules/reagents/reagents/dispenser.dm @@ -319,20 +319,7 @@ /datum/reagent/radium/affect_blood(var/mob/living/carbon/M, var/alien, var/removed) if(issmall(M)) removed *= 2 - M.apply_effect(10 * removed, IRRADIATE, 0) // Radium may increase your chances to cure a disease - if(M.virus2.len) - for(var/ID in M.virus2) - var/datum/disease2/disease/V = M.virus2[ID] - if(prob(5)) - M.antibodies |= V.antigen - if(prob(50)) - M.apply_effect(50, IRRADIATE, check_protection = 0) // curing it that way may kill you instead - var/absorbed = 0 - var/obj/item/organ/internal/diona/nutrients/rad_organ = locate() in M.internal_organs - if(rad_organ && !rad_organ.is_broken()) - absorbed = 1 - if(!absorbed) - M.adjustToxLoss(100) + M.apply_effect(10 * removed, IRRADIATE, 0) /datum/reagent/radium/touch_turf(var/turf/T) ..() diff --git a/code/modules/reagents/reagents/toxins.dm b/code/modules/reagents/reagents/toxins.dm index 26b70123304..c0545b8b068 100644 --- a/code/modules/reagents/reagents/toxins.dm +++ b/code/modules/reagents/reagents/toxins.dm @@ -973,3 +973,15 @@ /datum/reagent/neurophage_nanites/affect_blood(var/mob/living/carbon/M, var/alien, var/removed) M.adjustBrainLoss(2 * removed) // Their job is to give you a bad time. M.adjustBruteLoss(2 * removed) + +/datum/reagent/salmonella + name = "Salmonella" + id = "salmonella" + description = "A nasty bacteria found in spoiled food." + reagent_state = LIQUID + color = "#1E4600" + taste_mult = 0 + +/datum/reagent/salmonella/on_mob_life(mob/living/carbon/M) + M.ForceContractDisease(new /datum/disease/food_poisoning(0)) + return ..() diff --git a/code/modules/reagents/reagents/virology.dm b/code/modules/reagents/reagents/virology.dm new file mode 100644 index 00000000000..4556b1ed09c --- /dev/null +++ b/code/modules/reagents/reagents/virology.dm @@ -0,0 +1,47 @@ +/datum/reagent/vaccine + name = "Vaccine" + id = "vaccine" + color = "#C81040" + taste_description = "antibodies" + +/datum/reagent/vaccine/affect_blood(mob/living/carbon/M, alien, removed) + if(islist(data)) + for(var/thing in M.GetViruses()) + var/datum/disease/D = thing + if(D.GetDiseaseID() in data) + D.cure() + M.resistances |= data + +/datum/reagent/vaccines/mix_data(newdata, newamount) + if(islist(newdata)) + var/list/newdatalist = newdata + data |= newdatalist.Copy() + +/datum/reagent/mutagen/mutagenvirusfood + name = "Mutagenic agar" + id = "mutagenvirusfood" + description = "mutates blood" + color = "#A3C00F" + +/datum/reagent/mutagen/mutagenvirusfood/sugar + name = "Sucrose agar" + id = "sugarvirusfood" + color = "#41B0C0" + taste_mult = 1.5 + +/datum/reagent/medicine/adranol/adranolvirusfood + name = "Virus rations" + id = "adranolvirusfood" + description = "mutates blood" + color = "#D18AA5" + +/datum/reagent/phoron_dust/phoronvirusfood + name = "Phoronic virus food" + id = "phoronvirusfood" + description = "mutates blood" + color = "#A69DA9" + +/datum/reagent/phoron_dust/phoronvirusfood/weak + name = "Weakened phoronic virus food" + id = "weakphoronvirusfood" + color = "#CEC3C6" diff --git a/code/modules/research/circuitprinter.dm b/code/modules/research/circuitprinter.dm index 75f4fb1cacb..745dcf8dfc5 100644 --- a/code/modules/research/circuitprinter.dm +++ b/code/modules/research/circuitprinter.dm @@ -168,8 +168,9 @@ using metal and glass, it uses glass and reagents (usually sulphuric acid). return /obj/machinery/r_n_d/circuit_imprinter/proc/removeFromQueue(var/index) - queue.Cut(index, index + 1) - return + if(queue.len >= index) + queue.Cut(index, index + 1) + return /obj/machinery/r_n_d/circuit_imprinter/proc/canBuild(var/datum/design/D) for(var/M in D.materials) diff --git a/code/modules/research/prosfab_designs.dm b/code/modules/research/prosfab_designs.dm index 803ac462db0..8bf0beb7429 100644 --- a/code/modules/research/prosfab_designs.dm +++ b/code/modules/research/prosfab_designs.dm @@ -378,6 +378,50 @@ id = "mmi_ai_shell" build_path = /obj/item/mmi/inert/ai_remote +//////////////////// Advanced Components //////////////////// +/datum/design/item/prosfab/cyborg/component/radio_upgraded + name = "Improved Radio" + id = "improved_radio" + build_path = /obj/item/robot_parts/robot_component/radio/upgraded + req_tech = list(TECH_MAGNET = 7, TECH_MATERIAL = 5, TECH_PRECURSOR = 1) + materials = list(MAT_STEEL = 10000, MAT_DIAMOND = 2000, MAT_PLASTEEL = 3000, MAT_GLASS = 6500, MAT_SILVER = 3000, MAT_MORPHIUM = 560, MAT_DURASTEEL = 800) + +/datum/design/item/prosfab/cyborg/component/actuator_upgraded + name = "Improved Actuator" + id = "improved_actuator" + build_path = /obj/item/robot_parts/robot_component/actuator/upgraded + req_tech = list(TECH_MAGNET = 7, TECH_MATERIAL = 5, TECH_PRECURSOR = 1) + materials = list(MAT_STEEL = 10000, MAT_PLASTEEL = 2500, MAT_MORPHIUM = 500, MAT_DURASTEEL = 500) + +/datum/design/item/prosfab/cyborg/component/diagnosis_unit_upgraded + name = "Improved Diagnosis Unit" + id = "improved_diagnosis_unit" + build_path = /obj/item/robot_parts/robot_component/diagnosis_unit/upgraded + req_tech = list(TECH_MAGNET = 7, TECH_MATERIAL = 5, TECH_PRECURSOR = 1) + materials = list(MAT_STEEL = 10000, MAT_DIAMOND = 2000, MAT_URANIUM = 4000, MAT_PLASTEEL = 1000, MAT_GLASS = 400, MAT_SILVER = 1000, MAT_MORPHIUM = 420, MAT_DURASTEEL = 600) + +/datum/design/item/prosfab/cyborg/component/camera_upgraded + name = "Improved Camera" + id = "improved_camera" + build_path = /obj/item/robot_parts/robot_component/camera/upgraded + req_tech = list(TECH_MAGNET = 7, TECH_MATERIAL = 5, TECH_PRECURSOR = 1) + materials = list(MAT_STEEL = 10000, MAT_DIAMOND = 2000, MAT_PLASTEEL = 3000, MAT_GLASS = 6500, MAT_SILVER = 3000, MAT_MORPHIUM = 560, MAT_DURASTEEL = 800) + +/datum/design/item/prosfab/cyborg/component/binary_communication_device/upgraded + name = "Improved Binary Communication Device" + id = "improved_binary_communication_device" + build_path = /obj/item/robot_parts/robot_component/binary_communication_device/upgraded + req_tech = list(TECH_MAGNET = 7, TECH_MATERIAL = 5, TECH_PRECURSOR = 1) + materials = list(MAT_STEEL = 10000, MAT_DIAMOND = 2000, MAT_PLASTEEL = 3000, MAT_GLASS = 6500, MAT_GOLD = 3000, MAT_DURASTEEL = 800) + +/datum/design/item/prosfab/cyborg/component/armour_very_heavy + name = "Armour Plating (Prototype)" + id = "titan_armour" + build_path = /obj/item/robot_parts/robot_component/armour/armour_titan + req_tech = list(TECH_MATERIAL = 9, TECH_PRECURSOR = 3) + materials = list(MAT_STEEL = 12000, MAT_MORPHIUM = 3000, MAT_DURASTEEL = 5000) + + //////////////////// Cyborg Modules //////////////////// /datum/design/item/prosfab/robot_upgrade category = list("Cyborg Modules") diff --git a/code/modules/research/protolathe.dm b/code/modules/research/protolathe.dm index e6f87f61180..0fc4de44c62 100644 --- a/code/modules/research/protolathe.dm +++ b/code/modules/research/protolathe.dm @@ -184,8 +184,9 @@ return /obj/machinery/r_n_d/protolathe/proc/removeFromQueue(var/index) - queue.Cut(index, index + 1) - return + if(queue.len >= index) + queue.Cut(index, index + 1) + return /obj/machinery/r_n_d/protolathe/proc/canBuild(var/datum/design/D) for(var/M in D.materials) diff --git a/code/modules/shieldgen/directional_shield.dm b/code/modules/shieldgen/directional_shield.dm index 4dcc10b43d4..f1e2d3fd535 100644 --- a/code/modules/shieldgen/directional_shield.dm +++ b/code/modules/shieldgen/directional_shield.dm @@ -102,12 +102,10 @@ START_PROCESSING(SSobj, src) AddComponent(/datum/component/recursive_move) RegisterSignal(src, COMSIG_OBSERVER_MOVED, PROC_REF(moved_event)) - //ChompEDIT START - shields on init if(always_on) spawn(0) if(!QDELETED(src)) create_shields() - //ChompEDIT END return ..() /obj/item/shield_projector/Destroy() diff --git a/code/modules/tgchat/chat_verbs.dm b/code/modules/tgchat/chat_verbs.dm index 29edc5b2279..53cb07a84c0 100644 --- a/code/modules/tgchat/chat_verbs.dm +++ b/code/modules/tgchat/chat_verbs.dm @@ -1,5 +1,5 @@ /client/verb/export_chat() - set category = "OOC" + set category = "OOC.Chat" set name = "Export Chatlog" set desc = "Allows to trigger the chat export" diff --git a/code/modules/tgui/external.dm b/code/modules/tgui/external.dm index 85b48569ba7..93c5fe81295 100644 --- a/code/modules/tgui/external.dm +++ b/code/modules/tgui/external.dm @@ -183,7 +183,7 @@ /client/verb/tgui_fix_white() set desc = "Only use this if you have a broken TGUI window occupying your screen!" set name = "Fix TGUI" - set category = "OOC" + set category = "OOC.Debug" if(alert(src, "Only use this verb if you have a white TGUI window stuck on your screen.", "Fix TGUI", "Continue", "Nevermind") != "Continue") // Not tgui_alert since we're fixing tgui return diff --git a/code/modules/tgui/modules/overmap.dm b/code/modules/tgui/modules/overmap.dm index ed2f166c6a2..0661d4b146a 100644 --- a/code/modules/tgui/modules/overmap.dm +++ b/code/modules/tgui/modules/overmap.dm @@ -2,6 +2,7 @@ var/obj/effect/overmap/visitable/ship/linked var/list/viewers var/extra_view = 0 + var/map_view_used = FALSE /datum/tgui_module/ship/New() . = ..() @@ -77,13 +78,17 @@ user.reset_view(linked) user.set_viewsize(world.view + extra_view) user.AddComponent(/datum/component/recursive_move) - RegisterSignal(user, COMSIG_OBSERVER_MOVED, /datum/tgui_module/ship/proc/unlook) + if(!map_view_used) + RegisterSignal(user, COMSIG_OBSERVER_MOVED, /datum/tgui_module/ship/proc/unlook) + map_view_used = TRUE LAZYDISTINCTADD(viewers, WEAKREF(user)) /datum/tgui_module/ship/proc/unlook(var/mob/user) user.reset_view() user.set_viewsize() // reset to default - UnregisterSignal(user, COMSIG_OBSERVER_MOVED) + if(map_view_used) + UnregisterSignal(user, COMSIG_OBSERVER_MOVED) + map_view_used = FALSE LAZYREMOVE(viewers, WEAKREF(user)) /datum/tgui_module/ship/proc/viewing_overmap(mob/user) diff --git a/code/modules/tgui_panel/external.dm b/code/modules/tgui_panel/external.dm index 3e7dbc3178f..a4c8855fca5 100644 --- a/code/modules/tgui_panel/external.dm +++ b/code/modules/tgui_panel/external.dm @@ -10,7 +10,7 @@ */ /client/verb/fix_tgui_panel() set name = "Fix chat" - set category = "OOC" + set category = "OOC.Debug" var/action log_tgui(src, "Started fixing.", context = "verb/fix_tgui_panel") @@ -35,10 +35,16 @@ // Force show the panel to see if there are any errors winset(src, "output", "is-disabled=1&is-visible=0") winset(src, "browseroutput", "is-disabled=0;is-visible=1") + // TODO: Remove version check with 516 + if(byond_version >= 516) + if(prefs?.read_preference(/datum/preference/toggle/browser_dev_tools)) + winset(src, null, "browser-options=[DEFAULT_CLIENT_BROWSER_OPTIONS],devtools") + else + winset(src, null, "browser-options=[DEFAULT_CLIENT_BROWSER_OPTIONS]") /client/verb/refresh_tgui() set name = "Refresh TGUI" - set category = "OOC" + set category = "OOC.Debug" for(var/window_id in tgui_windows) var/datum/tgui_window/window = tgui_windows[window_id] diff --git a/code/modules/vchat/vchat_client.dm b/code/modules/vchat/vchat_client.dm index 5c4b0e16178..c22a790ef54 100644 --- a/code/modules/vchat/vchat_client.dm +++ b/code/modules/vchat/vchat_client.dm @@ -387,7 +387,7 @@ var/to_chat_src /client/proc/vchat_export_log() set name = "Export chatlog" - set category = "OOC" + set category = "OOC.Chat" if(chatOutput.broken) to_chat(src, span_warning("Error: VChat isn't processing your messages!")) diff --git a/code/modules/ventcrawl/ventcrawl_multiz.dm b/code/modules/ventcrawl/ventcrawl_multiz.dm index 87ef8f9ba70..1f669b34072 100644 --- a/code/modules/ventcrawl/ventcrawl_multiz.dm +++ b/code/modules/ventcrawl/ventcrawl_multiz.dm @@ -1,7 +1,7 @@ /obj/machinery/atmospherics/pipe/zpipe/up/verb/ventcrawl_move_up() set name = "Ventcrawl Upwards" set desc = "Climb up through a pipe." - set category = "Abilities" + set category = "Abilities.General" set src = usr.loc var/obj/machinery/atmospherics/target = check_ventcrawl(GetAbove(loc)) if(target) ventcrawl_to(usr, target, UP) @@ -9,7 +9,7 @@ /obj/machinery/atmospherics/pipe/zpipe/down/verb/ventcrawl_move_down() set name = "Ventcrawl Downwards" set desc = "Climb down through a pipe." - set category = "Abilities" + set category = "Abilities.General" set src = usr.loc var/obj/machinery/atmospherics/target = check_ventcrawl(GetBelow(loc)) if(target) ventcrawl_to(usr, target, DOWN) @@ -21,4 +21,4 @@ return node1 if(node2 in target) return node2 - return \ No newline at end of file + return diff --git a/code/modules/ventcrawl/ventcrawl_verb.dm b/code/modules/ventcrawl/ventcrawl_verb.dm index b49f22836dc..82352777be0 100644 --- a/code/modules/ventcrawl/ventcrawl_verb.dm +++ b/code/modules/ventcrawl/ventcrawl_verb.dm @@ -1,7 +1,7 @@ /mob/living/proc/ventcrawl() set name = "Crawl through Vent" set desc = "Enter an air vent and crawl through the pipe system." - set category = "Abilities" + set category = "Abilities.General" var/pipe = start_ventcrawl() if(pipe) handle_ventcrawl() diff --git a/code/modules/virus2/admin.dm b/code/modules/virus2/admin.dm deleted file mode 100644 index e8d1687f648..00000000000 --- a/code/modules/virus2/admin.dm +++ /dev/null @@ -1,222 +0,0 @@ -/datum/disease2/disease/Topic(href, href_list) - . = ..() - if(.) return - - if(href_list["info"]) - // spawn or admin privileges to see info about viruses - if(!check_rights(R_ADMIN|R_SPAWN|R_EVENT)) return - - to_chat(usr, "Infection chance: [infectionchance]; Speed: [speed]; Spread type: [spreadtype]") - to_chat(usr, "Affected species: [english_list(affected_species)]") - to_chat(usr, "Effects:") - for(var/datum/disease2/effectholder/E in effects) - to_chat(usr, "[E.stage]: [E.effect.name]; chance=[E.chance]; multiplier=[E.multiplier]") - to_chat(usr, "Antigens: [antigens2string(antigen)]; Resistance: [resistance]") - - return 1 - -/datum/disease2/disease/vv_get_header() - . = list() - for(var/datum/disease2/effectholder/E in effects) - . += "[E.stage]: [E.effect.name]" - . = list({" - [name()]
- [jointext(., "
")]
- "}) - -/datum/disease2/disease/get_view_variables_options() - return ..() + {" - - "} - -/datum/admins/var/datum/virus2_editor/virus2_editor_datum = new -/client/proc/virus2_editor() - set name = "Virus Editor" - set category = "Admin" - if(!holder || !check_rights(R_SPAWN)) return // spawn privileges to create viruses - - holder.virus2_editor_datum.show_ui(src) - -/datum/virus2_editor - var/list/s = list(/datum/disease2/effect/invisible,/datum/disease2/effect/invisible,/datum/disease2/effect/invisible,/datum/disease2/effect/invisible) - var/list/s_chance = list(1,1,1,1) - var/list/s_multiplier = list(1,1,1,1) - var/species = list() - var/infectionchance = 70 - var/spreadtype = "Contact" - var/list/antigens = list() - var/speed = 1 - var/resistance = 10 - var/mob/living/carbon/infectee = null - - // this holds spawned viruses so that the "Info" links work after the proc exits - var/list/spawned_viruses = list() - -/datum/virus2_editor/proc/select(mob/user, stage) - if(stage < 1 || stage > 4) return - - var/list/L = list() - - for(var/datum/disease2/effect/f as anything in subtypesof(/datum/disease2/effect)) - if(initial(f.stage) <= stage) - L[initial(f.name)] = f - - var/datum/disease2/effect/Eff = s[stage] - - var/C = tgui_input_list(usr, "Select effect for stage [stage]:", "Stage [stage]", L, Eff) - if(!C) return - return L[C] - -/datum/virus2_editor/proc/show_ui(mob/user) - var/H = {" -

Virus2 Virus Editor


- Effects:
- "} - for(var/i = 1 to 4) - var/datum/disease2/effect/Eff = s[i] - H += {" - [initial(Eff.name)] - Chance: [s_chance[i]] - Multiplier: [s_multiplier[i]] -
- "} - H += {" -
- Infectable Species:
- "} - var/f = 1 - for(var/k in GLOB.all_species) - var/datum/species/S = GLOB.all_species[k] - if(S.get_virus_immune()) - continue - if(!f) H += " | " - else f = 0 - H += "[k]" - H += {" - Reset -
- Infection Chance: [infectionchance]
- Spread Type: [spreadtype]
- Speed: [speed]
- Resistance: [resistance]
-
- "} - f = 1 - for(var/k in ALL_ANTIGENS) - if(!f) H += " | " - else f = 0 - H += "[k]" - H += {" - Reset -
-
- Initial infectee: [infectee ? infectee : "(choose)"] - RELEASE - "} - - user << browse(H, "window=virus2edit") - -/datum/virus2_editor/Topic(href, href_list) - switch(href_list["what"]) - if("effect") - var/stage = text2num(href_list["stage"]) - if(href_list["effect"]) - var/datum/disease2/effect/E = select(usr,stage) - if(!E) return - s[stage] = E - // set a default chance and multiplier of half the maximum (roughly average) - s_chance[stage] = max(1, round(initial(E.chance_maxm)/2)) - s_multiplier[stage] = max(1, round(initial(E.maxm)/2)) - else if(href_list["chance"]) - var/datum/disease2/effect/Eff = s[stage] - var/I = tgui_input_number(usr, "Chance, per tick, of this effect happening (min 0, max [initial(Eff.chance_maxm)])", "Effect Chance", s_chance[stage], initial(Eff.chance_maxm), 0) - if(I == null || I < 0 || I > initial(Eff.chance_maxm)) return - s_chance[stage] = I - else if(href_list["multiplier"]) - var/datum/disease2/effect/Eff = s[stage] - var/I = tgui_input_number(usr, "Multiplier for this effect (min 1, max [initial(Eff.maxm)])", "Effect Multiplier", s_multiplier[stage], initial(Eff.maxm), 1) - if(I == null || I < 1 || I > initial(Eff.maxm)) return - s_multiplier[stage] = I - if("species") - if(href_list["toggle"]) - var/T = href_list["toggle"] - if(T in species) - species -= T - else - species |= T - else if(href_list["reset"]) - species = list() - if(infectee) - if(!infectee.species || !(infectee.species.get_bodytype() in species)) - infectee = null - if("ichance") - var/I = tgui_input_number(usr, "Input infection chance", "Infection Chance", infectionchance, 100) - if(!I) return - infectionchance = I - if("stype") - var/S = tgui_alert(usr, "Which spread type?", "Spread Type", list("Contact", "Airborne", "Blood")) - if(!S) return - spreadtype = S - if("speed") - var/S = tgui_input_number(usr, "Input speed", "Speed", speed) - if(!S) return - speed = S - if("antigen") - if(href_list["toggle"]) - var/T = href_list["toggle"] - if(length(T) != 1) return - if(T in antigens) - antigens -= T - else - antigens |= T - else if(href_list["reset"]) - antigens = list() - if("resistance") - var/S = tgui_input_number(usr, "Input % resistance to antibiotics", "Resistance", resistance, 100) - if(!S) return - resistance = S - if("infectee") - var/list/candidates = list() - for(var/mob/living/carbon/G in living_mob_list) - if(G.stat != DEAD && G.species && !isbelly(G.loc)) - if(G.species.get_bodytype() in species) - candidates["[G.name][G.client ? "" : " (no client)"]"] = G - else - candidates["[G.name] ([G.species.get_bodytype()])[G.client ? "" : " (no client)"]"] = G - if(!candidates.len) - to_chat(usr, "No possible candidates found!") - - var/I = tgui_input_list(usr, "Choose initial infectee", "Infectee", candidates) - if(!I || !candidates[I]) return - infectee = candidates[I] - species |= infectee.species.get_bodytype() - if("go") - if(!antigens.len) - var/a = tgui_alert(usr, "This disease has no antigens; it will be impossible to permanently immunise anyone without them.\ - It is strongly recommended to set at least one antigen. Do you want to go back and edit your virus?", "Antigens", list("Yes", "No")) - if(!a || a == "Yes") return - var/datum/disease2/disease/D = new - D.infectionchance = infectionchance - D.spreadtype = spreadtype - D.antigen = antigens - D.affected_species = species - D.speed = speed - D.resistance = resistance - for(var/i in 1 to 4) - var/datum/disease2/effectholder/E = new - var/Etype = s[i] - E.effect = new Etype() - E.effect.generate() - E.chance = s_chance[i] - E.multiplier = s_multiplier[i] - E.stage = i - - D.effects += E - - spawned_viruses += D - - message_admins(span_danger("[key_name_admin(usr)] infected [key_name_admin(infectee)] with a virus (Info)")) - log_admin("[key_name_admin(usr)] infected [key_name_admin(infectee)] with a virus!") - infect_virus2(infectee, D, forced=1) - - show_ui(usr) diff --git a/code/modules/virus2/analyser.dm b/code/modules/virus2/analyser.dm deleted file mode 100644 index f9522caea8a..00000000000 --- a/code/modules/virus2/analyser.dm +++ /dev/null @@ -1,73 +0,0 @@ -/obj/machinery/disease2/diseaseanalyser - name = "disease analyser" - desc = "Analyzes diseases to find out information about them!" - icon = 'icons/obj/virology_vr.dmi' //VOREStation Edit - icon_state = "analyser" - anchored = TRUE - density = TRUE - - var/scanning = 0 - var/pause = 0 - - var/obj/item/virusdish/dish = null - -/obj/machinery/disease2/diseaseanalyser/attackby(var/obj/O as obj, var/mob/user as mob) - if(default_unfasten_wrench(user, O, 20)) - return - - else if(!istype(O,/obj/item/virusdish)) return - - if(dish) - to_chat(user, "\The [src] is already loaded.") - return - - dish = O - user.drop_item() - O.loc = src - - user.visible_message("[user] adds \a [O] to \the [src]!", "You add \a [O] to \the [src]!") - -/obj/machinery/disease2/diseaseanalyser/process() - if(stat & (NOPOWER|BROKEN)) - return - - if(scanning) - scanning -= 1 - if(scanning == 0) - if (dish.virus2.addToDB()) - ping("\The [src] pings, \"New pathogen added to data bank.\"") - - var/obj/item/paper/P = new /obj/item/paper(src.loc) - P.name = "paper - [dish.virus2.name()]" - - var/r = dish.virus2.get_info() - P.info = {" - [virology_letterhead("Post-Analysis Memo")] - [r] -
- Additional Notes:  -"} - dish.basic_info = dish.virus2.get_basic_info() - dish.info = r - dish.name = "[initial(dish.name)] ([dish.virus2.name()])" - dish.analysed = 1 - dish.loc = src.loc - dish = null - - icon_state = "analyser" - src.state("\The [src] prints a sheet of paper.") - - else if(dish && !scanning && !pause) - if(dish.virus2 && dish.growth > 50) - dish.growth -= 10 - scanning = 5 - icon_state = "analyser_processing" - else - pause = 1 - spawn(25) - dish.loc = src.loc - dish = null - - src.state("\The [src] buzzes, \"Insufficient growth density to complete analysis.\"") - pause = 0 - return diff --git a/code/modules/virus2/antibodies.dm b/code/modules/virus2/antibodies.dm deleted file mode 100644 index cecb0709406..00000000000 --- a/code/modules/virus2/antibodies.dm +++ /dev/null @@ -1,26 +0,0 @@ -//This file was auto-corrected by findeclaration.exe on 25.5.2012 20:42:33 - -var/global/list/ALL_ANTIGENS = list( - "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z" - ) - -/hook/startup/proc/randomise_antigens_order() - ALL_ANTIGENS = shuffle(ALL_ANTIGENS) - return 1 - -// iterate over the list of antigens and see what matches -/proc/antigens2string(list/antigens, none="None") - if(!istype(antigens)) - CRASH("Illegal type!") - if(!antigens.len) - return none - - var/code = "" - for(var/V in ALL_ANTIGENS) - if(V in antigens) - code += V - - if(!code) - return none - - return code diff --git a/code/modules/virus2/biohazard destroyer.dm b/code/modules/virus2/biohazard destroyer.dm deleted file mode 100644 index 37eaf06561c..00000000000 --- a/code/modules/virus2/biohazard destroyer.dm +++ /dev/null @@ -1,20 +0,0 @@ -/obj/machinery/disease2/biodestroyer - name = "Biohazard destroyer" - icon = 'icons/obj/pipes/disposal.dmi' - icon_state = "disposalbio" - var/list/accepts = list(/obj/item/clothing,/obj/item/virusdish/,/obj/item/cureimplanter,/obj/item/diseasedisk,/obj/item/reagent_containers) - density = TRUE - anchored = TRUE - -/obj/machinery/disease2/biodestroyer/attackby(var/obj/I as obj, var/mob/user as mob) - for(var/path in accepts) - if(I.type in typesof(path)) - user.drop_item() - qdel(I) - add_overlay("dispover-handle") - return - user.drop_item() - I.loc = src.loc - - for(var/mob/O in hearers(src, null)) - O.show_message(span_blue("[icon2html(src, O.client)] The [src.name] beeps."), 2) diff --git a/code/modules/virus2/centrifuge.dm b/code/modules/virus2/centrifuge.dm deleted file mode 100644 index 7c17ea24e9a..00000000000 --- a/code/modules/virus2/centrifuge.dm +++ /dev/null @@ -1,208 +0,0 @@ -/obj/machinery/computer/centrifuge - name = "isolation centrifuge" - desc = "Used to separate things with different weight. Spin 'em round, round, right round." - icon = 'icons/obj/virology_vr.dmi' //VOREStation Edit - icon_state = "centrifuge" - var/curing - var/isolating - - var/obj/item/reagent_containers/glass/beaker/vial/sample = null - var/datum/disease2/disease/virus2 = null - -/obj/machinery/computer/centrifuge/attackby(var/obj/item/O as obj, var/mob/user as mob) - if(O.has_tool_quality(TOOL_SCREWDRIVER)) - return ..(O,user) - - if(default_unfasten_wrench(user, O, 20)) - return - - if(istype(O,/obj/item/reagent_containers/glass/beaker/vial)) - if(sample) - to_chat(user, "\The [src] is already loaded.") - return - - sample = O - user.drop_item() - O.loc = src - - user.visible_message("[user] adds \a [O] to \the [src]!", "You add \a [O] to \the [src]!") - SStgui.update_uis(src) - - src.attack_hand(user) - -/obj/machinery/computer/centrifuge/update_icon() - ..() - if(! (stat & (BROKEN|NOPOWER)) && (isolating || curing)) - icon_state = "centrifuge_moving" - -/obj/machinery/computer/centrifuge/attack_hand(var/mob/user as mob) - if(..()) - return - tgui_interact(user) - -/obj/machinery/computer/centrifuge/tgui_interact(mob/user, datum/tgui/ui) - ui = SStgui.try_update_ui(user, src, ui) - if(!ui) - ui = new(user, src, "IsolationCentrifuge", name) - ui.open() - -/obj/machinery/computer/centrifuge/tgui_data(mob/user) - var/list/data = list() - data["antibodies"] = null - data["pathogens"] = list() - data["is_antibody_sample"] = null - data["busy"] = null - data["sample_inserted"] = !!sample - - if(curing) - data["busy"] = "Isolating antibodies..." - else if(isolating) - data["busy"] = "Isolating pathogens..." - else - if(sample) - var/datum/reagent/blood/B = locate(/datum/reagent/blood) in sample.reagents.reagent_list - if(B) - data["antibodies"] = antigens2string(B.data["antibodies"], none=null) - - var/list/pathogens[0] - var/list/virus = B.data["virus2"] - for (var/ID in virus) - var/datum/disease2/disease/V = virus[ID] - pathogens.Add(list(list("name" = V.name(), "spread_type" = V.spreadtype, "reference" = "\ref[V]"))) - - data["pathogens"] = pathogens - - else - var/datum/reagent/antibodies/A = locate(/datum/reagent/antibodies) in sample.reagents.reagent_list - if(A) - data["antibodies"] = antigens2string(A.data["antibodies"], none=null) - data["is_antibody_sample"] = 1 - - return data - -/obj/machinery/computer/centrifuge/process() - ..() - if(stat & (NOPOWER|BROKEN)) return - - if(curing) - curing -= 1 - if(curing == 0) - cure() - - if(isolating) - isolating -= 1 - if(isolating == 0) - isolate() - -/obj/machinery/computer/centrifuge/tgui_act(action, params) - if(..()) - return TRUE - - var/mob/user = usr - add_fingerprint(user) - - - switch(action) - if("print") - print(user) - . = TRUE - if("isolate") - var/datum/reagent/blood/B = locate(/datum/reagent/blood) in sample.reagents.reagent_list - if(B) - var/datum/disease2/disease/virus = locate(params["isolate"]) - virus2 = virus.getcopy() - isolating = 40 - update_icon() - . = TRUE - if("antibody") - var/delay = 20 - var/datum/reagent/blood/B = locate(/datum/reagent/blood) in sample.reagents.reagent_list - if(!B) - state("\The [src] buzzes, \"No antibody carrier detected.\"", "blue") - return TRUE - - var/has_toxins = locate(/datum/reagent/toxin) in sample.reagents.reagent_list - var/has_radium = sample.reagents.has_reagent("radium") - if(has_toxins || has_radium) - state("\The [src] beeps, \"Pathogen purging speed above nominal.\"", "blue") - if(has_toxins) - delay = delay/2 - if(has_radium) - delay = delay/2 - - curing = round(delay) - playsound(src, 'sound/machines/juicer.ogg', 50, 1) - update_icon() - . = TRUE - if("sample") - if(sample) - sample.loc = src.loc - sample = null - . = TRUE - - -/obj/machinery/computer/centrifuge/proc/cure() - if(!sample) return - var/datum/reagent/blood/B = locate(/datum/reagent/blood) in sample.reagents.reagent_list - if(!B) return - - var/list/data = list("antibodies" = B.data["antibodies"]) - var/amt= sample.reagents.get_reagent_amount("blood") - sample.reagents.remove_reagent("blood", amt) - sample.reagents.add_reagent("antibodies", amt, data) - - SStgui.update_uis(src) - update_icon() - ping("\The [src] pings, \"Antibody isolated.\"") - -/obj/machinery/computer/centrifuge/proc/isolate() - if(!sample) return - var/obj/item/virusdish/dish = new/obj/item/virusdish(loc) - dish.virus2 = virus2 - virus2 = null - - SStgui.update_uis(src) - update_icon() - ping("\The [src] pings, \"Pathogen isolated.\"") - -/obj/machinery/computer/centrifuge/proc/print(var/mob/user) - var/obj/item/paper/P = new /obj/item/paper(loc) - P.name = "paper - Pathology Report" - P.info = {" - [virology_letterhead("Pathology Report")] - Sample: [sample.name]
-"} - - if(user) - P.info += "Generated By: [user.name]
" - - P.info += "
" - - var/datum/reagent/blood/B = locate(/datum/reagent/blood) in sample.reagents.reagent_list - if(B) - P.info += "Antibodies: " - P.info += antigens2string(B.data["antibodies"]) - P.info += "
" - - var/list/virus = B.data["virus2"] - P.info += "Pathogens:
" - if(virus.len > 0) - for (var/ID in virus) - var/datum/disease2/disease/V = virus[ID] - P.info += "[V.name()]
" - else - P.info += "None
" - - else - var/datum/reagent/antibodies/A = locate(/datum/reagent/antibodies) in sample.reagents.reagent_list - if(A) - P.info += "The following antibodies have been isolated from the blood sample: " - P.info += antigens2string(A.data["antibodies"]) - P.info += "
" - - P.info += {" -
- Additional Notes: -"} - - state("The nearby computer prints out a pathology report.") diff --git a/code/modules/virus2/curer.dm b/code/modules/virus2/curer.dm deleted file mode 100644 index fda185f15f2..00000000000 --- a/code/modules/virus2/curer.dm +++ /dev/null @@ -1,105 +0,0 @@ -/obj/machinery/computer/curer - name = "cure research machine" - icon_keyboard = "med_key" - icon_screen = "dna" - circuit = /obj/item/circuitboard/curefab - var/curing - var/virusing - - var/obj/item/reagent_containers/container = null - -/obj/machinery/computer/curer/attackby(var/obj/I as obj, var/mob/user as mob) - if(istype(I,/obj/item/reagent_containers)) - var/mob/living/carbon/C = user - if(!container) - container = I - C.drop_item() - I.loc = src - return - if(istype(I,/obj/item/virusdish)) - if(virusing) - to_chat(user, span_infoplain(span_bold("The pathogen materializer is still recharging..."))) - return - var/obj/item/reagent_containers/glass/beaker/product = new(src.loc) - - var/list/data = list("donor"=null,"viruses"=null,"blood_DNA"=null,"blood_type"=null,"resistances"=null,"trace_chem"=null,"virus2"=list(),"antibodies"=list()) - data["virus2"] |= I:virus2 - product.reagents.add_reagent("blood",30,data) - - virusing = 1 - spawn(1200) virusing = 0 - - state("The [src.name] Buzzes", "blue") - return - ..() - return - -/obj/machinery/computer/curer/attack_ai(var/mob/user as mob) - return src.attack_hand(user) - -/obj/machinery/computer/curer/attack_hand(var/mob/user as mob) - if(..()) - return - user.machine = src - var/dat - if(curing) - dat = "Antibody production in progress" - else if(virusing) - dat = "Virus production in progress" - else if(container) - // see if there's any blood in the container - var/datum/reagent/blood/B = locate(/datum/reagent/blood) in container.reagents.reagent_list - - if(B) - dat = "Blood sample inserted." - dat += "
Antibodies: [antigens2string(B.data["antibodies"])]" - dat += "
Begin antibody production" - else - dat += "
Please check container contents." - dat += "
Eject container" - else - dat = "Please insert a container." - - user << browse(dat, "window=computer;size=400x500") - onclose(user, "computer") - return - -/obj/machinery/computer/curer/process() - ..() - - if(stat & (NOPOWER|BROKEN)) - return - use_power(500) - - if(curing) - curing -= 1 - if(curing == 0) - if(container) - createcure(container) - return - -/obj/machinery/computer/curer/Topic(href, href_list) - if(..()) - return 1 - usr.machine = src - - if (href_list["antibody"]) - curing = 10 - else if(href_list["eject"]) - container.loc = src.loc - container = null - - src.add_fingerprint(usr) - src.updateUsrDialog() - - -/obj/machinery/computer/curer/proc/createcure(var/obj/item/reagent_containers/container) - var/obj/item/reagent_containers/glass/beaker/product = new(src.loc) - - var/datum/reagent/blood/B = locate() in container.reagents.reagent_list - - var/list/data = list() - data["antibodies"] = B.data["antibodies"] - product.reagents.add_reagent("antibodies",30,data) - - state("\The [src.name] buzzes", "blue") diff --git a/code/modules/virus2/disease2.dm b/code/modules/virus2/disease2.dm deleted file mode 100644 index e8a275e8382..00000000000 --- a/code/modules/virus2/disease2.dm +++ /dev/null @@ -1,320 +0,0 @@ -/datum/disease2/disease - var/infectionchance = 70 - var/speed = 1 - var/spreadtype = "Blood" // Can also be "Contact" or "Airborne" - var/stage = 1 - var/stageprob = 10 - var/dead = 0 - var/clicks = 0 - var/uniqueID = 0 - var/list/datum/disease2/effectholder/effects = list() - var/antigen = list() // 16 bits describing the antigens, when one bit is set, a cure with that bit can dock here - var/max_stage = 4 - var/list/affected_species = list(SPECIES_HUMAN,SPECIES_UNATHI,SPECIES_SKRELL,SPECIES_TAJ) - var/resistance = 10 // % chance a disease will resist cure, up to 100 - -/datum/disease2/disease/New() - uniqueID = rand(0,10000) - ..() - -/datum/disease2/disease/proc/makerandom(var/severity=1) - var/list/excludetypes = list() - for(var/i=1 ; i <= max_stage ; i++ ) - var/datum/disease2/effectholder/holder = new /datum/disease2/effectholder - holder.stage = i - holder.getrandomeffect(severity, excludetypes) - excludetypes += holder.effect.type - effects += holder - uniqueID = rand(0,10000) - switch(severity) - if(1) - infectionchance = 1 - if(2) - infectionchance = rand(10,20) - else - infectionchance = rand(60,90) - - antigen = list(pick(ALL_ANTIGENS)) - antigen |= pick(ALL_ANTIGENS) - spreadtype = prob(70) ? "Airborne" : "Contact" - resistance = rand(15,70) - - if(severity >= 2 && prob(33)) - resistance += 10 - - if(GLOB.all_species.len) - affected_species = get_infectable_species() - -/proc/get_infectable_species() - var/list/meat = list() - var/list/res = list() - for (var/specie in GLOB.all_species) - var/datum/species/S = GLOB.all_species[specie] - if(!S.get_virus_immune()) - meat += S - if(meat.len) - var/num = rand(1,meat.len) - for(var/i=0,i 50) - if(prob(1)) - majormutate() - - //Space antibiotics have a good chance to stop disease completely - if(mob.chem_effects[CE_ANTIBIOTIC]) - if(stage == 1 && prob(70-resistance)) - src.cure(mob) - else - resistance += rand(1,9) - - //VOREStation Add Start - Corophazine can treat higher stages - var/antibiotics = mob.chem_effects[CE_ANTIBIOTIC] - if(antibiotics == ANTIBIO_SUPER) - if(prob(70)) - src.cure(mob) - //VOREStation Add End - - //Resistance is capped at 90 without being manually set to 100 - if(resistance > 90 && resistance < 100) - resistance = 90 - - - //Virus food speeds up disease progress - if(mob.reagents.has_reagent("virusfood")) - mob.reagents.remove_reagent("virusfood",0.1) - clicks += 10 - - if(prob(1) && prob(stage)) // Increasing chance of curing as the virus progresses - src.cure(mob) - mob.antibodies |= src.antigen - - //Moving to the next stage - if(clicks > max(stage*100, 200) && prob(10)) - if((stage <= max_stage) && prob(5)) // ~20% of viruses will be cured by the end of S4 with this - src.cure(mob) - mob.antibodies |= src.antigen - stage++ - clicks = 0 - - //Do nasty effects - for(var/datum/disease2/effectholder/e in effects) - if(prob(33)) - e.runeffect(mob,stage) - - //Short airborne spread - if(src.spreadtype == "Airborne") - for(var/mob/living/carbon/M in oview(1,mob)) - if(airborne_can_reach(get_turf(mob), get_turf(M))) - infect_virus2(M,src) - - //fever - mob.bodytemperature = max(mob.bodytemperature, min(310+5*min(stage,max_stage) ,mob.bodytemperature+5*min(stage,max_stage))) - clicks+=speed - -/datum/disease2/disease/proc/cure(var/mob/living/carbon/mob) - for(var/datum/disease2/effectholder/e in effects) - e.effect.deactivate(mob) - mob.virus2.Remove("[uniqueID]") - BITSET(mob.hud_updateflag, STATUS_HUD) - -/datum/disease2/disease/proc/minormutate() - //uniqueID = rand(0,10000) - var/datum/disease2/effectholder/holder = pick(effects) - holder.minormutate() - //infectionchance = min(50,infectionchance + rand(0,10)) - -/datum/disease2/disease/proc/majormutate() - uniqueID = rand(0,10000) - var/datum/disease2/effectholder/holder = pick(effects) - var/list/exclude = list() - for(var/datum/disease2/effectholder/D in effects) - if(D != holder) - exclude += D.effect.type - holder.majormutate(exclude) - if (prob(5) && prob(100-resistance)) // The more resistant the disease,the lower the chance of randomly developing the antibodies - antigen = list(pick(ALL_ANTIGENS)) - antigen |= pick(ALL_ANTIGENS) - if (prob(5) && GLOB.all_species.len) - affected_species = get_infectable_species() - if (prob(10)) - resistance += rand(1,9) - if(resistance > 90 && resistance < 100) - resistance = 90 - -/datum/disease2/disease/proc/getcopy() - var/datum/disease2/disease/disease = new /datum/disease2/disease - disease.infectionchance = infectionchance - disease.spreadtype = spreadtype - disease.stageprob = stageprob - disease.antigen = antigen - disease.uniqueID = uniqueID - disease.resistance = resistance - disease.affected_species = affected_species.Copy() - for(var/datum/disease2/effectholder/holder in effects) - var/datum/disease2/effectholder/newholder = new /datum/disease2/effectholder - newholder.effect = new holder.effect.type - newholder.effect.generate(holder.effect.data) - newholder.chance = holder.chance - newholder.cure = holder.cure - newholder.multiplier = holder.multiplier - newholder.happensonce = holder.happensonce - newholder.stage = holder.stage - disease.effects += newholder - return disease - -/datum/disease2/disease/proc/issame(var/datum/disease2/disease/disease) - var/list/types = list() - var/list/types2 = list() - for(var/datum/disease2/effectholder/d in effects) - types += d.effect.type - var/equal = 1 - - for(var/datum/disease2/effectholder/d in disease.effects) - types2 += d.effect.type - - for(var/type in types) - if(!(type in types2)) - equal = 0 - - if (antigen != disease.antigen) - equal = 0 - return equal - -/proc/virus_copylist(var/list/datum/disease2/disease/viruses) - var/list/res = list() - for (var/ID in viruses) - var/datum/disease2/disease/V = viruses[ID] - res["[V.uniqueID]"] = V.getcopy() - return res - - -var/global/list/virusDB = list() - -/datum/disease2/disease/proc/name() - .= "stamm #[add_zero("[uniqueID]", 4)]" - if ("[uniqueID]" in virusDB) - var/datum/data/record/V = virusDB["[uniqueID]"] - .= V.fields["name"] - -/datum/disease2/disease/proc/get_basic_info() - var/t = "" - for(var/datum/disease2/effectholder/E in effects) - t += ", [E.effect.name]" - return "[name()] ([copytext(t,3)])" - -/datum/disease2/disease/proc/get_info() - var/r = {" - Analysis determined the existence of a GNAv2-based viral lifeform.
- Designation: [name()]
- Antigen: [antigens2string(antigen)]
- Transmitted By: [spreadtype]
- Rate of Progression: [stageprob * 10]
- Antibiotic Resistance [resistance]%
- Species Affected: [jointext(affected_species, ", ")]
-"} - - r += "Symptoms:
" - for(var/datum/disease2/effectholder/E in effects) - r += "([E.stage]) [E.effect.name] " - r += "Strength: [E.multiplier >= 3 ? "Severe" : E.multiplier > 1 ? "Above Average" : "Average"] " - r += "Aggressiveness: [E.chance * 15]
" - - return r - -/datum/disease2/disease/proc/get_tgui_info() - . = list( - "name" = name(), - "spreadtype" = spreadtype, - "antigen" = antigens2string(antigen), - "rate" = stageprob * 10, - "resistance" = resistance, - "species" = jointext(affected_species, ", "), - "ref" = "\ref[src]", - ) - - var/list/symptoms = list() - for(var/datum/disease2/effectholder/E in effects) - symptoms.Add(list(list( - "stage" = E.stage, - "name" = E.effect.name, - "strength" = "[E.multiplier >= 3 ? "Severe" : E.multiplier > 1 ? "Above Average" : "Average"]", - "aggressiveness" = E.chance * 15, - ))) - .["symptoms"] = symptoms - -/datum/disease2/disease/proc/addToDB() - if ("[uniqueID]" in virusDB) - return 0 - var/datum/data/record/v = new() - v.fields["id"] = uniqueID - v.fields["name"] = name() - v.fields["description"] = get_info() - v.fields["tgui_description"] = get_tgui_info() - v.fields["tgui_description"]["record"] = "\ref[v]" - v.fields["antigen"] = antigens2string(antigen) - v.fields["spread type"] = spreadtype - virusDB["[uniqueID]"] = v - return 1 - -/proc/virus2_lesser_infection() - var/list/candidates = list() //list of candidate keys - - for(var/mob/living/carbon/human/G in player_list) - if(G.client && G.stat != DEAD && !isbelly(G.loc)) - candidates += G - - if(!candidates.len) return - - candidates = shuffle(candidates) - - infect_mob_random_lesser(candidates[1]) - -/proc/virus2_greater_infection() - var/list/candidates = list() //list of candidate keys - - for(var/mob/living/carbon/human/G in player_list) - if(G.client && G.stat != DEAD && !isbelly(G.loc)) - candidates += G - if(!candidates.len) return - - candidates = shuffle(candidates) - - infect_mob_random_greater(candidates[1]) - -/proc/virology_letterhead(var/report_name) - return {" -

[report_name]

-
[station_name()] Virology Lab
-
-"} - -/datum/disease2/disease/proc/can_add_symptom(type) - for(var/datum/disease2/effectholder/H in effects) - if(H.effect.type == type) - return 0 - - return 1 diff --git a/code/modules/virus2/diseasesplicer.dm b/code/modules/virus2/diseasesplicer.dm deleted file mode 100644 index 74f9ad43d48..00000000000 --- a/code/modules/virus2/diseasesplicer.dm +++ /dev/null @@ -1,193 +0,0 @@ -/obj/machinery/computer/diseasesplicer - name = "disease splicer" - icon_keyboard = "med_key" - icon_screen = "crew" - - var/datum/disease2/effectholder/memorybank = null - var/list/species_buffer = null - var/analysed = 0 - var/obj/item/virusdish/dish = null - var/burning = 0 - var/splicing = 0 - var/scanning = 0 - -/obj/machinery/computer/diseasesplicer/attackby(var/obj/item/I as obj, var/mob/user as mob) - if(I.has_tool_quality(TOOL_SCREWDRIVER)) - return ..(I,user) - - if(default_unfasten_wrench(user, I, 20)) - return - - if(istype(I,/obj/item/virusdish)) - var/mob/living/carbon/c = user - if(dish) - to_chat(user, "\The [src] is already loaded.") - return - - dish = I - c.drop_item() - I.loc = src - - if(istype(I,/obj/item/diseasedisk)) - to_chat(user, "You upload the contents of the disk onto the buffer.") - memorybank = I:effect - species_buffer = I:species - analysed = I:analysed - - src.attack_hand(user) - -/obj/machinery/computer/diseasesplicer/attack_ai(var/mob/user as mob) - return src.attack_hand(user) - -/obj/machinery/computer/diseasesplicer/attack_hand(var/mob/user as mob) - if(..()) - return TRUE - tgui_interact(user) - -/obj/machinery/computer/diseasesplicer/tgui_interact(mob/user, datum/tgui/ui) - ui = SStgui.try_update_ui(user, src, ui) - if(!ui) - ui = new(user, src, "DiseaseSplicer", name) - ui.open() - -/obj/machinery/computer/diseasesplicer/tgui_data(mob/user) - var/list/data = list() - data["dish_inserted"] = !!dish - - data["buffer"] = null - if(memorybank) - data["buffer"] = list("name" = (analysed ? memorybank.effect.name : "Unknown Symptom"), "stage" = memorybank.effect.stage) - data["species_buffer"] = null - if(species_buffer) - data["species_buffer"] = analysed ? jointext(species_buffer, ", ") : "Unknown Species" - - data["effects"] = null - data["info"] = null - data["growth"] = 0 - data["affected_species"] = null - data["busy"] = null - if(splicing) - data["busy"] = "Splicing..." - else if(scanning) - data["busy"] = "Scanning..." - else if(burning) - data["busy"] = "Copying data to disk..." - else if(dish) - data["growth"] = min(dish.growth, 100) - - if(dish.virus2) - if(dish.virus2.affected_species) - data["affected_species"] = dish.analysed ? dish.virus2.affected_species : list() - - if(dish.growth >= 50) - var/list/effects[0] - for (var/datum/disease2/effectholder/e in dish.virus2.effects) - effects.Add(list(list("name" = (dish.analysed ? e.effect.name : "Unknown"), "stage" = (e.stage), "reference" = "\ref[e]", "badness" = e.effect.badness))) - data["effects"] = effects - else - data["info"] = "Insufficient cell growth for gene splicing." - else - data["info"] = "No virus detected." - else - data["info"] = "No dish loaded." - - return data - -/obj/machinery/computer/diseasesplicer/process() - if(stat & (NOPOWER|BROKEN)) - return - - if(scanning) - scanning -= 1 - if(!scanning) - ping("\The [src] pings, \"Analysis complete.\"") - SStgui.update_uis(src) - if(splicing) - splicing -= 1 - if(!splicing) - ping("\The [src] pings, \"Splicing operation complete.\"") - SStgui.update_uis(src) - if(burning) - burning -= 1 - if(!burning) - var/obj/item/diseasedisk/d = new /obj/item/diseasedisk(src.loc) - d.analysed = analysed - if(analysed) - if(memorybank) - d.name = "[memorybank.effect.name] GNA disk (Stage: [memorybank.effect.stage])" - d.effect = memorybank - else if(species_buffer) - d.name = "[jointext(species_buffer, ", ")] GNA disk" - d.species = species_buffer - else - if(memorybank) - d.name = "Unknown GNA disk (Stage: [memorybank.effect.stage])" - d.effect = memorybank - else if(species_buffer) - d.name = "Unknown Species GNA disk" - d.species = species_buffer - - ping("\The [src] pings, \"Backup disk saved.\"") - SStgui.update_uis(src) - -/obj/machinery/computer/diseasesplicer/tgui_act(action, list/params, datum/tgui/ui, datum/tgui_state/state) - if(..()) - return TRUE - - var/mob/user = usr - add_fingerprint(user) - - switch(action) - if("grab") - if(dish) - memorybank = locate(params["grab"]) - species_buffer = null - analysed = dish.analysed - dish = null - scanning = 10 - . = TRUE - - if("affected_species") - if(dish) - memorybank = null - species_buffer = dish.virus2.affected_species - analysed = dish.analysed - dish = null - scanning = 10 - . = TRUE - - if("eject") - if(dish) - dish.loc = src.loc - dish = null - . = TRUE - - if("splice") - if(dish) - var/target = text2num(params["splice"]) // target = 1 to 4 for effects, 5 for species - if(memorybank && 0 < target && target <= 4) - if(target < memorybank.effect.stage) return // too powerful, catching this for href exploit prevention - - var/datum/disease2/effectholder/target_holder - var/list/illegal_types = list() - for(var/datum/disease2/effectholder/e in dish.virus2.effects) - if(e.stage == target) - target_holder = e - else - illegal_types += e.effect.type - if(memorybank.effect.type in illegal_types) return - target_holder.effect = memorybank.effect - - else if(species_buffer && target == 5) - dish.virus2.affected_species = species_buffer - - else - return - - splicing = 10 - dish.virus2.uniqueID = rand(0,10000) - . = TRUE - - if("disk") - burning = 10 - . = TRUE diff --git a/code/modules/virus2/dishincubator.dm b/code/modules/virus2/dishincubator.dm deleted file mode 100644 index d6a84991d1d..00000000000 --- a/code/modules/virus2/dishincubator.dm +++ /dev/null @@ -1,201 +0,0 @@ -/obj/machinery/disease2/incubator/ - name = "pathogenic incubator" - desc = "Encourages the growth of diseases. This model comes with a dispenser system and a small radiation generator." - density = TRUE - anchored = TRUE - icon = 'icons/obj/virology_vr.dmi' //VOREStation Edit - icon_state = "incubator" - var/obj/item/virusdish/dish - var/obj/item/reagent_containers/glass/beaker = null - var/radiation = 0 - - var/on = 0 - var/power = 0 - - var/foodsupply = 0 - var/toxins = 0 - -/obj/machinery/disease2/incubator/attackby(var/obj/O as obj, var/mob/user as mob) - if(default_unfasten_wrench(user, O, 20)) - return - - if(istype(O, /obj/item/reagent_containers/glass) || istype(O,/obj/item/reagent_containers/syringe)) - - if(beaker) - to_chat(user, "\The [src] is already loaded.") - return - - beaker = O - user.drop_item() - O.loc = src - - user.visible_message("[user] adds \a [O] to \the [src]!", "You add \a [O] to \the [src]!") - SStgui.update_uis(src) - - src.attack_hand(user) - return - - if(istype(O, /obj/item/virusdish)) - - if(dish) - to_chat(user, "The dish tray is aleady full!") - return - - dish = O - user.drop_item() - O.loc = src - - user.visible_message("[user] adds \a [O] to \the [src]!", "You add \a [O] to \the [src]!") - SStgui.update_uis(src) - - src.attack_hand(user) - -/obj/machinery/disease2/incubator/attack_hand(mob/user as mob) - if(stat & (NOPOWER|BROKEN)) - return - tgui_interact(user) - -/obj/machinery/disease2/incubator/tgui_interact(mob/user, datum/tgui/ui) - ui = SStgui.try_update_ui(user, src, ui) - if(!ui) - ui = new(user, src, "DishIncubator", name) - ui.set_autoupdate(FALSE) - ui.open() - -/obj/machinery/disease2/incubator/tgui_data(mob/user) - var/data[0] - data["chemicals_inserted"] = !!beaker - data["dish_inserted"] = !!dish - data["food_supply"] = foodsupply - data["radiation"] = radiation - data["toxins"] = min(toxins, 100) - data["on"] = on - data["system_in_use"] = foodsupply > 0 || radiation > 0 || toxins > 0 - data["chemical_volume"] = beaker ? beaker.reagents.total_volume : 0 - data["max_chemical_volume"] = beaker ? beaker.volume : 1 - data["virus"] = dish ? dish.virus2 : null - data["growth"] = dish ? min(dish.growth, 100) : 0 - data["infection_rate"] = dish && dish.virus2 ? dish.virus2.infectionchance * 10 : 0 - data["analysed"] = dish && dish.analysed ? 1 : 0 - data["can_breed_virus"] = null - data["blood_already_infected"] = null - - if(beaker) - var/datum/reagent/blood/B = locate(/datum/reagent/blood) in beaker.reagents.reagent_list - data["can_breed_virus"] = dish && dish.virus2 && B - - if(B) - if(!B.data["virus2"]) - B.data["virus2"] = list() - - var/list/virus = B.data["virus2"] - for (var/ID in virus) - data["blood_already_infected"] = virus[ID] - - return data - -/obj/machinery/disease2/incubator/process() - if(dish && on && dish.virus2) - use_power(50,EQUIP) - if(!powered(EQUIP)) - on = 0 - icon_state = "incubator" - - if(foodsupply) - if(dish.growth + 3 >= 100 && dish.growth < 100) - ping("\The [src] pings, \"Sufficient viral growth density achieved.\"") - - foodsupply -= 1 - dish.growth += 3 - SStgui.update_uis(src) - - if(radiation) - if(radiation > 50 & prob(5)) - dish.virus2.majormutate() - if(dish.info) - dish.info = "OUTDATED : [dish.info]" - dish.basic_info = "OUTDATED: [dish.basic_info]" - dish.analysed = 0 - ping("\The [src] pings, \"Mutant viral strain detected.\"") - else if(prob(5)) - dish.virus2.minormutate() - radiation -= 1 - SStgui.update_uis(src) - if(toxins && prob(5)) - dish.virus2.infectionchance -= 1 - SStgui.update_uis(src) - if(toxins > 50) - dish.growth = 0 - dish.virus2 = null - SStgui.update_uis(src) - else if(!dish) - on = 0 - icon_state = "incubator" - SStgui.update_uis(src) - - if(beaker) - if(foodsupply < 100 && beaker.reagents.remove_reagent("virusfood",5)) - if(foodsupply + 10 <= 100) - foodsupply += 10 - SStgui.update_uis(src) - - if(locate(/datum/reagent/toxin) in beaker.reagents.reagent_list && toxins < 100) - for(var/datum/reagent/toxin/T in beaker.reagents.reagent_list) - toxins += max(T.strength,1) - beaker.reagents.remove_reagent(T.id,1) - if(toxins > 100) - toxins = 100 - break - SStgui.update_uis(src) - -/obj/machinery/disease2/incubator/tgui_act(action, params) - if(..()) - return TRUE - - var/mob/user = usr - add_fingerprint(user) - switch(action) - if("ejectchem") - if(beaker) - beaker.loc = src.loc - beaker = null - . = TRUE - - if("power") - if(dish) - on = !on - icon_state = on ? "incubator_on" : "incubator" - . = TRUE - - if("ejectdish") - if(dish) - dish.loc = src.loc - dish = null - . = TRUE - - if("rad") - radiation = min(100, radiation + 10) - . = TRUE - - if("flush") - radiation = 0 - toxins = 0 - foodsupply = 0 - . = TRUE - - if("virus") - if(!dish) - return TRUE - - var/datum/reagent/blood/B = locate(/datum/reagent/blood) in beaker.reagents.reagent_list - if(!B) - return TRUE - - if(!B.data["virus2"]) - B.data["virus2"] = list() - - var/list/virus = list("[dish.virus2.uniqueID]" = dish.virus2.getcopy()) - B.data["virus2"] += virus - - ping("\The [src] pings, \"Injection complete.\"") - . = TRUE diff --git a/code/modules/virus2/effect.dm b/code/modules/virus2/effect.dm deleted file mode 100644 index 8f088ee0e69..00000000000 --- a/code/modules/virus2/effect.dm +++ /dev/null @@ -1,520 +0,0 @@ -/datum/disease2/effectholder - var/name = "Holder" - var/datum/disease2/effect/effect - var/chance = 0 //Chance in percentage each tick - var/cure = "" //Type of cure it requires - var/happensonce = 0 - var/multiplier = 1 //The chance the effects are WORSE - var/stage = 0 - -/datum/disease2/effectholder/proc/runeffect(var/mob/living/carbon/human/mob,var/stage) - if(happensonce > -1 && effect.stage <= stage && prob(chance)) - effect.activate(mob, multiplier) - if(happensonce == 1) - happensonce = -1 - -/datum/disease2/effectholder/proc/getrandomeffect(var/badness = 1, exclude_types=list()) - var/list/datum/disease2/effect/list = list() - for(var/datum/disease2/effect/f as anything in subtypesof(/datum/disease2/effect)) - if(f in exclude_types) - continue - if(initial(f.badness) > badness) //we don't want such strong effects - continue - if(initial(f.stage) <= src.stage) - list += f - var/type = pick(list) - effect = new type() - effect.generate() - chance = rand(0,effect.chance_maxm) - multiplier = rand(1,effect.maxm) - -/datum/disease2/effectholder/proc/minormutate() - switch(pick(1,2,3,4,5)) - if(1) - chance = rand(0,effect.chance_maxm) - if(2) - multiplier = rand(1,effect.maxm) - -/datum/disease2/effectholder/proc/majormutate(exclude_types=list()) - getrandomeffect(3, exclude_types) - -//////////////////////////////////////////////////////////////// -////////////////////////EFFECTS///////////////////////////////// -//////////////////////////////////////////////////////////////// - -/datum/disease2/effect - var/chance_maxm = 50 //note that disease effects only proc once every 3 ticks for humans - var/name = "Blanking effect" - var/stage = 4 - var/maxm = 1 - var/badness = 1 - var/data = null // For semi-procedural effects; this should be generated in generate() if used - -/datum/disease2/effect/proc/activate(var/mob/living/carbon/mob,var/multiplier) -/datum/disease2/effect/proc/deactivate(var/mob/living/carbon/mob) -/datum/disease2/effect/proc/generate(copy_data) // copy_data will be non-null if this is a copy; it should be used to initialise the data for this effect if present - -/datum/disease2/effect/invisible - name = "Waiting Syndrome" - stage = 1 - badness = 3 - -/datum/disease2/effect/invisible/activate(var/mob/living/carbon/mob,var/multiplier) - return - -////////////////////////STAGE 4///////////////////////////////// - -/datum/disease2/effect/nothing - name = "Nil Syndrome" - stage = 4 - badness = 1 - chance_maxm = 0 - -/datum/disease2/effect/gibbingtons - name = "Gibbington's Syndrome" - stage = 4 - badness = 3 - -/datum/disease2/effect/gibbingtons/activate(var/mob/living/carbon/mob,var/multiplier) - // Probabilities have been tweaked to kill in ~2-3 minutes, giving 5-10 messages. - // Probably needs more balancing, but it's better than LOL U GIBBED NOW, especially now that viruses can potentially have no signs up until Gibbingtons. - mob.adjustBruteLoss(10*multiplier) - if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - var/obj/item/organ/external/O = pick(H.organs) - if(prob(25)) - to_chat(mob, span_warning("Your [O.name] feels as if it might burst!")) - if(prob(10)) - spawn(50) - if(O) - O.droplimb(0,DROPLIMB_BLUNT) - else - if(prob(75)) - to_chat(mob, span_warning("Your whole body feels like it might fall apart!")) - if(prob(10)) - mob.adjustBruteLoss(25*multiplier) - -/datum/disease2/effect/radian - name = "Radian's Syndrome" - stage = 4 - maxm = 3 - badness = 2 - -/datum/disease2/effect/radian/activate(var/mob/living/carbon/mob,var/multiplier) - mob.apply_effect(2*multiplier, IRRADIATE, check_protection = 0) - -/datum/disease2/effect/deaf - name = "Deafness" - stage = 4 - badness = 2 - -/datum/disease2/effect/deaf/activate(var/mob/living/carbon/mob,var/multiplier) - mob.ear_deaf += 20 - -/datum/disease2/effect/monkey - name = "Genome Regression" - stage = 4 - badness = 3 - -/datum/disease2/effect/monkey/activate(var/mob/living/carbon/mob,var/multiplier) - if(istype(mob,/mob/living/carbon/human)) - var/mob/living/carbon/human/h = mob - h.monkeyize() - -/datum/disease2/effect/killertoxins - name = "Autoimmune Response" - stage = 4 - badness = 2 - -/datum/disease2/effect/killertoxins/activate(var/mob/living/carbon/mob,var/multiplier) - mob.adjustToxLoss(15*multiplier) - -/datum/disease2/effect/dna - name = "Catastrophic DNA Degeneration" - stage = 4 - badness = 2 - -/datum/disease2/effect/dna/activate(var/mob/living/carbon/mob,var/multiplier) - mob.bodytemperature = max(mob.bodytemperature, 350) - scramble(0,mob,10) - mob.apply_damage(10, CLONE) - -/datum/disease2/effect/organs - name = "Limb Paralysis" - stage = 4 - badness = 2 - -/datum/disease2/effect/organs/activate(var/mob/living/carbon/mob,var/multiplier) - if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - var/organ = pick(list("r_arm","l_arm","r_leg","l_leg")) - var/obj/item/organ/external/E = H.organs_by_name[organ] - if (!(E.status & ORGAN_DEAD)) - E.status |= ORGAN_DEAD - to_chat(H, span_notice("You can't feel your [E.name] anymore...")) - for (var/obj/item/organ/external/C in E.children) - C.status |= ORGAN_DEAD - H.update_icons_body() - mob.adjustToxLoss(15*multiplier) - -/datum/disease2/effect/organs/deactivate(var/mob/living/carbon/mob,var/multiplier) - if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - for (var/obj/item/organ/external/E in H.organs) - E.status &= ~ORGAN_DEAD - for (var/obj/item/organ/external/C in E.children) - C.status &= ~ORGAN_DEAD - H.update_icons_body() - -/datum/disease2/effect/internalorgan - name = "Organ Shutdown" - stage = 4 - badness = 2 - -/datum/disease2/effect/internalorgan/activate(var/mob/living/carbon/mob,var/multiplier) - if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - var/organ = pick(list("heart","kidney","liver", "lungs")) - var/obj/item/organ/internal/O = H.organs_by_name[organ] - if (O.robotic != ORGAN_ROBOT) - O.damage += (5*multiplier) - to_chat(H, span_notice("You feel a cramp in your guts.")) - -/datum/disease2/effect/immortal - name = "Hyperaccelerated Aging" - stage = 4 - badness = 2 - -/datum/disease2/effect/immortal/activate(var/mob/living/carbon/mob,var/multiplier) - if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - for (var/obj/item/organ/external/E in H.organs) - if (E.status & ORGAN_BROKEN && prob(30)) - E.status ^= ORGAN_BROKEN - var/heal_amt = -5*multiplier - mob.apply_damages(heal_amt,heal_amt,heal_amt,heal_amt) - -/datum/disease2/effect/immortal/deactivate(var/mob/living/carbon/mob,var/multiplier) - if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - to_chat(H, span_notice("You suddenly feel hurt and old...")) - H.age += 8 - var/backlash_amt = 5*multiplier - mob.apply_damages(backlash_amt,backlash_amt,backlash_amt,backlash_amt) - -/datum/disease2/effect/bones - name = "Brittle Bones" - stage = 4 - badness = 2 -/datum/disease2/effect/bones/activate(var/mob/living/carbon/mob,var/multiplier) - if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - for (var/obj/item/organ/external/E in H.organs) - E.min_broken_damage = max(5, E.min_broken_damage - 30) - -/datum/disease2/effect/bones/deactivate(var/mob/living/carbon/mob,var/multiplier) - if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - for (var/obj/item/organ/external/E in H.organs) - E.min_broken_damage = initial(E.min_broken_damage) - -/datum/disease2/effect/combustion - name = "Organic Ignition" - stage = 4 - badness = 3 - -/datum/disease2/effect/combustion/activate(var/mob/living/carbon/mob,var/multiplier) - if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - var/obj/item/organ/external/O = pick(H.organs) - if(prob(25)) - to_chat(mob, span_warning("It feels like your [O.name] is on fire and your blood is boiling!")) - H.adjust_fire_stacks(1) - if(prob(10)) - to_chat(mob, span_warning("Flames erupt from your skin, your entire body is burning!")) - H.adjust_fire_stacks(2) - H.IgniteMob() - - -////////////////////////STAGE 3///////////////////////////////// - -/datum/disease2/effect/toxins - name = "Hyperacidity" - stage = 3 - maxm = 3 - -/datum/disease2/effect/toxins/activate(var/mob/living/carbon/mob,var/multiplier) - mob.adjustToxLoss((2*multiplier)) - -/datum/disease2/effect/shakey - name = "Nervous Motor Instability" - stage = 3 - maxm = 3 - -/datum/disease2/effect/shakey/activate(var/mob/living/carbon/mob,var/multiplier) - shake_camera(mob,5*multiplier) - -/datum/disease2/effect/telepathic - name = "Pineal Gland Decalcification" - stage = 3 - -/datum/disease2/effect/telepathic/activate(var/mob/living/carbon/mob,var/multiplier) - mob.dna.SetSEState(REMOTETALKBLOCK,1) - domutcheck(mob, null, MUTCHK_FORCED) - -/datum/disease2/effect/mind - name = "Neurodegeneration" - stage = 3 - -/datum/disease2/effect/mind/activate(var/mob/living/carbon/mob,var/multiplier) - if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - var/obj/item/organ/internal/brain/B = H.internal_organs_by_name["brain"] - if (B && B.damage < B.min_broken_damage) - B.take_damage(5) - else - mob.setBrainLoss(10) - -/datum/disease2/effect/hallucinations - name = "Hallucination" - stage = 3 - -/datum/disease2/effect/hallucinations/activate(var/mob/living/carbon/mob,var/multiplier) - mob.hallucination += 25 - -/datum/disease2/effect/minordeaf - name = "Hearing Loss" - stage = 3 - -/datum/disease2/effect/minordeaf/activate(var/mob/living/carbon/mob,var/multiplier) - mob.ear_deaf = 5 - -/datum/disease2/effect/giggle - name = "Uncontrolled Laughter" - stage = 3 - chance_maxm = 20 - -/datum/disease2/effect/giggle/activate(var/mob/living/carbon/mob,var/multiplier) - if(prob(66)) - mob.say("*giggle") - else - to_chat(mob, span_notice("What's so funny?")) - -/datum/disease2/effect/confusion - name = "Topographical Cretinism" - stage = 3 - -/datum/disease2/effect/confusion/activate(var/mob/living/carbon/mob,var/multiplier) - to_chat(mob, span_notice("You have trouble telling right and left apart all of a sudden.")) - mob.Confuse(10) - -/datum/disease2/effect/mutation - name = "DNA Degradation" - stage = 3 - -/datum/disease2/effect/mutation/activate(var/mob/living/carbon/mob,var/multiplier) - mob.apply_damage(2, CLONE) - -/datum/disease2/effect/groan - name = "Phantom Aches" - stage = 3 - chance_maxm = 20 - -/datum/disease2/effect/groan/activate(var/mob/living/carbon/mob,var/multiplier) - if(prob(66)) - mob.say("*groan") - else if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - var/obj/item/organ/external/E = pick(H.organs) - to_chat(mob, span_warning("Your [E] aches.")) - -/datum/disease2/effect/chem_synthesis - name = "Chemical Synthesis" - stage = 3 - chance_maxm = 25 - -/datum/disease2/effect/chem_synthesis/generate(c_data) - if(c_data) - data = c_data - else - data = pick("bicaridine", "kelotane", "anti_toxin", "inaprovaline", "bliss", "sugar", - "tramadol", "dexalin", "cryptobiolin", "impedrezene", "hyperzine", "ethylredoxrazine", - "mindbreaker", "glucose") - var/datum/reagent/R = SSchemistry.chemical_reagents[data] - name = "[initial(name)] ([initial(R.name)])" - -/datum/disease2/effect/chem_synthesis/activate(var/mob/living/carbon/mob,var/multiplier) - if (mob.reagents.get_reagent_amount(data) < 5) - mob.reagents.add_reagent(data, 2) - -/datum/disease2/effect/nonrejection - name = "Genetic Chameleonism" - stage = 3 - -/datum/disease2/effect/nonrejection/activate(var/mob/living/carbon/mob,var/multiplier) - if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - var/obj/item/organ/internal/O = H.organs_by_name - for (var/organ in H.organs_by_name) - if (O.robotic != ORGAN_ROBOT) - O.rejecting = 0 - - -////////////////////////STAGE 2///////////////////////////////// - -/datum/disease2/effect/scream - name = "Involuntary Vocalization" - stage = 2 - chance_maxm = 10 - -/datum/disease2/effect/scream/activate(var/mob/living/carbon/mob,var/multiplier) - mob.say("*scream") - -/datum/disease2/effect/drowsness - name = "Excessive Sleepiness" - stage = 2 - -/datum/disease2/effect/drowsness/activate(var/mob/living/carbon/mob,var/multiplier) - mob.drowsyness += 10 - -/datum/disease2/effect/sleepy - name = "Narcolepsy" - stage = 2 - chance_maxm = 15 - -/datum/disease2/effect/sleepy/activate(var/mob/living/carbon/mob,var/multiplier) - mob.say("*collapse") - -/datum/disease2/effect/blind - name = "Vision Loss" - stage = 2 - -/datum/disease2/effect/blind/activate(var/mob/living/carbon/mob,var/multiplier) - mob.SetBlinded(4) - -/datum/disease2/effect/cough - name = "Severe Cough" - stage = 2 - chance_maxm = 20 - -/datum/disease2/effect/cough/activate(var/mob/living/carbon/mob,var/multiplier) - if(prob(60)) - mob.say("*cough") - for(var/mob/living/carbon/M in oview(2,mob)) - mob.spread_disease_to(M) - else - to_chat(mob, span_warning("Something gets caught in your throat.")) - -/datum/disease2/effect/hungry - name = "Digestive Inefficiency" - stage = 2 - -/datum/disease2/effect/hungry/activate(var/mob/living/carbon/mob,var/multiplier) - mob.adjust_nutrition(-200) - -/datum/disease2/effect/fridge - name = "Reduced Circulation" - stage = 2 - chance_maxm = 25 - -/datum/disease2/effect/fridge/activate(var/mob/living/carbon/mob,var/multiplier) - mob.say("*shiver") - -/datum/disease2/effect/hair - name = "Hair Loss" - stage = 2 - -/datum/disease2/effect/hair/activate(var/mob/living/carbon/mob,var/multiplier) - if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - if(H.species.name == SPECIES_HUMAN && !(H.h_style == "Bald") && !(H.h_style == "Balding Hair")) - to_chat(H, span_danger("Your hair starts to fall out in clumps...")) - spawn(50) - H.h_style = "Balding Hair" - H.update_hair() - -/datum/disease2/effect/stimulant - name = "Overactive Adrenal Gland" - stage = 2 - -/datum/disease2/effect/stimulant/activate(var/mob/living/carbon/mob,var/multiplier) - to_chat(mob, span_notice("You feel a rush of energy inside you!")) - if (mob.reagents.get_reagent_amount("hyperzine") < 10) - mob.reagents.add_reagent("hyperzine", 4) - if (prob(30)) - mob.jitteriness += 10 - -/datum/disease2/effect/ringing - name = "Tinnitus" - stage = 2 - chance_maxm = 25 - -/datum/disease2/effect/ringing/activate(var/mob/living/carbon/mob,var/multiplier) - if(istype(mob, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = mob - to_chat(H, span_notice("You hear an awful ringing in your ears.")) - H << 'sound/weapons/flash.ogg' - -/datum/disease2/effect/vomiting - name = "Vomiting" - stage = 2 - chance_maxm = 15 - -/datum/disease2/effect/vomiting/activate(var/mob/living/carbon/mob,var/multiplier) - to_chat(mob, span_notice("Your stomach churns!")) - if (prob(50)) - mob.say("*vomit") - -////////////////////////STAGE 1///////////////////////////////// - -/datum/disease2/effect/sneeze - name = "Sneezing" - stage = 1 - chance_maxm = 20 - -/datum/disease2/effect/sneeze/activate(var/mob/living/carbon/mob,var/multiplier) - if(prob(20)) - to_chat(mob, span_warning("You go to sneeze, but it gets caught in your sinuses!")) - else if(prob(80)) - if(prob(30)) - to_chat(mob, span_warning("You feel like you are about to sneeze!")) - spawn(5) //Sleep may have been hanging Mob controller. - mob.say("*sneeze") - for(var/mob/living/carbon/M in get_step(mob,mob.dir)) - mob.spread_disease_to(M) - if (prob(50)) - var/obj/effect/decal/cleanable/mucus/M = new(get_turf(mob)) - M.virus2 = virus_copylist(mob.virus2) - -/datum/disease2/effect/gunck - name = "Mucus Buildup" - stage = 1 - -/datum/disease2/effect/gunck/activate(var/mob/living/carbon/mob,var/multiplier) - to_chat(mob, span_warning("Mucous runs down the back of your throat.")) - -/datum/disease2/effect/drool - name = "Salivary Gland Stimulation" - stage = 1 - chance_maxm = 15 - -/datum/disease2/effect/drool/activate(var/mob/living/carbon/mob,var/multiplier) - mob.say("*drool") - if (prob(30)) - var/obj/effect/decal/cleanable/mucus/M = new(get_turf(mob)) - M.virus2 = virus_copylist(mob.virus2) - -/datum/disease2/effect/twitch - name = "Involuntary Twitching" - stage = 1 - chance_maxm = 15 - -/datum/disease2/effect/twitch/activate(var/mob/living/carbon/mob,var/multiplier) - mob.say("*twitch") - -/datum/disease2/effect/headache - name = "Headache" - stage = 1 - -/datum/disease2/effect/headache/activate(var/mob/living/carbon/mob,var/multiplier) - to_chat(mob, span_warning("Your head hurts a bit.")) diff --git a/code/modules/virus2/effect_vr.dm b/code/modules/virus2/effect_vr.dm deleted file mode 100644 index 307111f44e8..00000000000 --- a/code/modules/virus2/effect_vr.dm +++ /dev/null @@ -1,63 +0,0 @@ -/////////////////////////////////////////////// -/////////////////// Stage 1 /////////////////// - -/datum/disease2/effect/mlem - name = "Mlemington's Syndrome" - stage = 1 - chance_maxm = 25 - -/datum/disease2/effect/mlem/activate(var/mob/living/carbon/mob,var/multiplier) - mob.say("[pick("Mlem.","MLEM!","Mlem?")]") - -/datum/disease2/effect/spin - name = "Spyndrome" - stage = 1 - chance_maxm = 7 - var/list/directions = list(2,4,1,8,2,4,1,8,2,4,1,8,2,4,1,8,2,4,1,8) - -/datum/disease2/effect/spin/activate(var/mob/living/carbon/mob,var/multiplier) - if(mob.buckled()) - to_chat(viewers(mob),span_warning("[mob.name] struggles violently against their restraints!")) - else - to_chat(viewers(mob),span_warning("[mob.name] spins around violently!")) - for(var/D in directions) - mob.dir = D - sleep(1) - mob.dir = pick(2,4,1,8) //For that added annoyance - -/////////////////////////////////////////////// -/////////////////// Stage 2 /////////////////// - -/datum/disease2/effect/lang - name = "Lingual Dissocation" - stage = 2 - chance_maxm = 2 - -/datum/disease2/effect/lang/activate(var/mob/living/carbon/mob,var/multiplier) - mob.set_default_language(pick(mob.languages)) - -/////////////////////////////////////////////// -/////////////////// Stage 3 /////////////////// - -/datum/disease2/effect/size - name = "Mass Revectoring" - stage = 3 - chance_maxm = 1 - -/datum/disease2/effect/size/activate(var/mob/living/carbon/mob,var/multiplier) - var/newsize = rand (25, 200) - mob.resize(newsize/100) - to_chat(viewers(mob),span_warning("[mob.name] suddenly changes size!")) - -/datum/disease2/effect/flip - name = "Flipponov's Disease" - stage = 3 - chance_maxm = 5 - -/datum/disease2/effect/flip/activate(var/mob/living/carbon/mob,var/multiplier) //Remind me why mob is carbon...? - if(ishuman(mob)) - var/mob/living/carbon/human/H = mob - H.emote("flip") - else - to_chat(viewers(mob),span_warning("[mob.name] does a backflip!")) - mob.SpinAnimation(7,1) diff --git a/code/modules/virus2/helpers.dm b/code/modules/virus2/helpers.dm deleted file mode 100644 index 053498042ef..00000000000 --- a/code/modules/virus2/helpers.dm +++ /dev/null @@ -1,181 +0,0 @@ -//Returns 1 if mob can be infected, 0 otherwise. -/proc/infection_check(var/mob/living/carbon/M, var/vector = "Airborne") - if (!istype(M)) - return 0 - - var/mob/living/carbon/human/H = M - if(istype(H) && H.species.get_virus_immune(H)) - return 0 - - var/protection = M.getarmor(null, "bio") //gets the full body bio armour value, weighted by body part coverage. - var/score = round(0.06*protection) //scales 100% protection to 6. - - switch(vector) - if("Airborne") - if(M.internal) //not breathing infected air helps greatly - return 0 - var/obj/item/I = M.wear_mask - //masks provide a small bonus and can replace overall bio protection - if(I) - score = max(score, round(0.06*I.armor["bio"])) - if (istype(I, /obj/item/clothing/mask)) - score += 1 //this should be added after - - if("Contact") - if(istype(H)) - //gloves provide a larger bonus - if (istype(H.gloves, /obj/item/clothing/gloves)) - score += 2 - - if(score >= 6) - return 0 - else if(score >= 5 && prob(99)) - return 0 - else if(score >= 4 && prob(95)) - return 0 - else if(score >= 3 && prob(75)) - return 0 - else if(score >= 2 && prob(55)) - return 0 - else if(score >= 1 && prob(35)) - return 0 - return 1 - -//Similar to infection check, but used for when M is spreading the virus. -/proc/infection_spreading_check(var/mob/living/carbon/M, var/vector = "Airborne") - if (!istype(M)) - return 0 - - var/protection = M.getarmor(null, "bio") //gets the full body bio armour value, weighted by body part coverage. - - if (vector == "Airborne") - var/obj/item/I = M.wear_mask - if (istype(I)) - protection = max(protection, I.armor["bio"]) - - return prob(protection) - -//Checks if table-passing table can reach target (5 tile radius) -/proc/airborne_can_reach(turf/source, turf/target) - var/obj/dummy = new(source) - dummy.pass_flags = PASSTABLE - - for(var/i=0, i<5, i++) if(!step_towards(dummy, target)) break - - var/rval = dummy.Adjacent(target) - dummy.loc = null - dummy = null - return rval - -//Attemptes to infect mob M with virus. Set forced to 1 to ignore protective clothnig -/proc/infect_virus2(var/mob/living/carbon/M,var/datum/disease2/disease/disease,var/forced = 0) - if(!istype(disease)) -// log_debug("Bad virus") - return - if(!istype(M)) -// log_debug("Bad mob") - return - if ("[disease.uniqueID]" in M.virus2) - return - // if one of the antibodies in the mob's body matches one of the disease's antigens, don't infect - var/list/antibodies_in_common = M.antibodies & disease.antigen - if(antibodies_in_common.len) - return - if(M.chem_effects[CE_ANTIBIOTIC]) - if(prob(disease.resistance)) - var/datum/disease2/disease/D = disease.getcopy() - D.minormutate() - D.resistance += rand(1,9) -// log_debug("Adding virus") - M.virus2["[D.uniqueID]"] = D - BITSET(M.hud_updateflag, STATUS_HUD) - else - return //Virus prevented by antibiotics - - if(!disease.affected_species.len) - return - - if (!(M.species.get_bodytype() in disease.affected_species)) - if (forced) - disease.affected_species[1] = M.species.get_bodytype() - else - return //not compatible with this species - -// log_debug("Infecting [M]") - - if(forced || (infection_check(M, disease.spreadtype) && prob(disease.infectionchance))) - var/datum/disease2/disease/D = disease.getcopy() - D.minormutate() -// log_debug("Adding virus") - M.virus2["[D.uniqueID]"] = D - BITSET(M.hud_updateflag, STATUS_HUD) - - -//Infects mob M with disease D -/proc/infect_mob(var/mob/living/carbon/M, var/datum/disease2/disease/D) - infect_virus2(M,D,1) - M.hud_updateflag |= 1 << STATUS_HUD - -//Infects mob M with random lesser disease, if he doesn't have one -/proc/infect_mob_random_lesser(var/mob/living/carbon/M) - var/datum/disease2/disease/D = new /datum/disease2/disease - - D.makerandom(1) - infect_mob(M, D) - -//Infects mob M with random greated disease, if he doesn't have one -/proc/infect_mob_random_greater(var/mob/living/carbon/M) - var/datum/disease2/disease/D = new /datum/disease2/disease - - D.makerandom(2) - infect_mob(M, D) - -//Fancy prob() function. -/proc/dprob(var/p) - return(prob(sqrt(p)) && prob(sqrt(p))) - -/mob/living/carbon/proc/spread_disease_to(var/mob/living/carbon/victim, var/vector = "Airborne") - if (src == victim) - return "Neurodegeneration" - -// log_debug("Spreading [vector] diseases from [src] to [victim]") - if (virus2.len > 0) - for (var/ID in virus2) -// log_debug("Attempting virus [ID]") - var/datum/disease2/disease/V = virus2[ID] - if(V.spreadtype != vector) continue - - //It's hard to get other people sick if you're in an airtight suit. - if(!infection_spreading_check(src, V.spreadtype)) continue - - if (vector == "Airborne") - if(airborne_can_reach(get_turf(src), get_turf(victim))) -// log_debug("In range, infecting") - infect_virus2(victim,V) -// else -// log_debug("Could not reach target") - - if (vector == "Contact") - if (Adjacent(victim)) -// log_debug("In range, infecting") - infect_virus2(victim,V) - - //contact goes both ways - if (victim.virus2.len > 0 && vector == "Contact" && Adjacent(victim)) -// log_debug("Spreading [vector] diseases from [victim] to [src]") - var/nudity = 1 - - if (ishuman(victim)) - var/mob/living/carbon/human/H = victim - var/obj/item/organ/external/select_area = H.get_organ(src.zone_sel.selecting) - var/list/clothes = list(H.head, H.wear_mask, H.wear_suit, H.w_uniform, H.gloves, H.shoes) - for(var/obj/item/clothing/C in clothes) - if(C && istype(C)) - if(C.body_parts_covered & select_area.body_part) - nudity = 0 - if (nudity) - for (var/ID in victim.virus2) - var/datum/disease2/disease/V = victim.virus2[ID] - if(V && V.spreadtype != vector) continue - if(!infection_spreading_check(victim, V.spreadtype)) continue - infect_virus2(src,V) diff --git a/code/modules/virus2/isolator.dm b/code/modules/virus2/isolator.dm deleted file mode 100644 index 7e4dc129728..00000000000 --- a/code/modules/virus2/isolator.dm +++ /dev/null @@ -1,211 +0,0 @@ -/obj/machinery/disease2/isolator/ - name = "pathogenic isolator" - desc = "Used to isolate and identify diseases, allowing for comparison with a remote database." - density = TRUE - anchored = TRUE - icon = 'icons/obj/virology_vr.dmi' //VOREStation Edit - icon_state = "isolator" - var/isolating = 0 - var/datum/disease2/disease/virus2 = null - var/obj/item/reagent_containers/syringe/sample = null - -/obj/machinery/disease2/isolator/update_icon() - if (stat & (BROKEN|NOPOWER)) - icon_state = "isolator" - return - - if (isolating) - icon_state = "isolator_processing" - else if (sample) - icon_state = "isolator_in" - else - icon_state = "isolator" - -/obj/machinery/disease2/isolator/attackby(var/obj/O as obj, var/mob/user) - if(default_unfasten_wrench(user, O, 20)) - return - - else if(!istype(O,/obj/item/reagent_containers/syringe)) return - var/obj/item/reagent_containers/syringe/S = O - - if(sample) - to_chat(user, "\The [src] is already loaded.") - return - - sample = S - user.drop_item() - S.loc = src - - user.visible_message("[user] adds \a [O] to \the [src]!", "You add \a [O] to \the [src]!") - SStgui.update_uis(src) - update_icon() - - src.attack_hand(user) - -/obj/machinery/disease2/isolator/attack_hand(mob/user as mob) - if(stat & (NOPOWER|BROKEN)) - return - tgui_interact(user) - -/obj/machinery/disease2/isolator/tgui_interact(mob/user, datum/tgui/ui) - ui = SStgui.try_update_ui(user, src, ui) - if(!ui) - ui = new(user, src, "PathogenicIsolator", name) - ui.open() - - -/obj/machinery/disease2/isolator/tgui_data(mob/user) - var/list/data = list() - data["syringe_inserted"] = !!sample - data["isolating"] = isolating - data["pathogen_pool"] = null - data["can_print"] = !isolating - - var/list/pathogen_pool = list() - if(sample) - for(var/datum/reagent/blood/B in sample.reagents.reagent_list) - var/list/virus = B.data["virus2"] - for (var/ID in virus) - var/datum/disease2/disease/V = virus[ID] - var/datum/data/record/R = null - if (ID in virusDB) - R = virusDB[ID] - - var/mob/living/carbon/human/D = B.data["donor"] - pathogen_pool.Add(list(list(\ - "name" = "[istype(D) ? "[D.get_species()] " : ""][B.name]", \ - "dna" = B.data["blood_DNA"], \ - "unique_id" = V.uniqueID, \ - "reference" = "\ref[V]", \ - "is_in_database" = !!R, \ - "record" = "\ref[R]"))) - data["pathogen_pool"] = pathogen_pool - - var/list/db = list() - for(var/ID in virusDB) - var/datum/data/record/r = virusDB[ID] - db.Add(list(list("name" = r.fields["name"], "record" = "\ref[r]"))) - data["database"] = db - data["modal"] = tgui_modal_data(src) - return data - -/obj/machinery/disease2/isolator/process() - if (isolating > 0) - isolating -= 1 - if (isolating == 0) - if (virus2) - var/obj/item/virusdish/d = new /obj/item/virusdish(src.loc) - d.virus2 = virus2.getcopy() - virus2 = null - ping("\The [src] pings, \"Viral strain isolated.\"") - - SStgui.update_uis(src) - update_icon() - -/obj/machinery/disease2/isolator/tgui_act(action, list/params) - if(..()) - return TRUE - - var/mob/user = usr - add_fingerprint(user) - - . = TRUE - switch(tgui_modal_act(src, action, params)) - if(TGUI_MODAL_ANSWER) - return - - switch(action) - if("view_entry") - var/datum/data/record/v = locate(params["vir"]) - if(!istype(v)) - return FALSE - tgui_modal_message(src, "virus", "", null, v.fields["tgui_description"]) - return TRUE - - if("print") - print(user, params) - return TRUE - - if("isolate") - var/datum/disease2/disease/V = locate(params["isolate"]) - if (V) - virus2 = V - isolating = 20 - update_icon() - return TRUE - - if("eject") - if(!sample) - return FALSE - sample.forceMove(loc) - sample = null - update_icon() - return TRUE - -/obj/machinery/disease2/isolator/proc/print(mob/user, list/params) - var/obj/item/paper/P = new /obj/item/paper(loc) - - switch(params["type"]) - if("patient_diagnosis") - if (!sample) return - P.name = "paper - Patient Diagnostic Report" - P.info = {" - [virology_letterhead("Patient Diagnostic Report")] -
CONFIDENTIAL MEDICAL REPORT

- Sample: [sample.name]
-"} - - if (user) - P.info += "Generated By: [user.name]
" - - P.info += "
" - - for(var/datum/reagent/blood/B in sample.reagents.reagent_list) - var/mob/living/carbon/human/D = B.data["donor"] - P.info += "[D.get_species()] [B.name]:
[B.data["blood_DNA"]]
" - - var/list/virus = B.data["virus2"] - P.info += "Pathogens:
" - if (virus.len > 0) - for (var/ID in virus) - var/datum/disease2/disease/V = virus[ID] - P.info += "[V.name()]
" - else - P.info += "None
" - - P.info += {" -
- Additional Notes:  -"} - - if("virus_list") - P.name = "paper - Virus List" - P.info = {" - [virology_letterhead("Virus List")] -"} - - var/i = 0 - for (var/ID in virusDB) - i++ - var/datum/data/record/r = virusDB[ID] - P.info += "[i]. " + r.fields["name"] - P.info += "
" - - P.info += {" -
- Additional Notes:  -"} - - if("virus_record") - var/datum/data/record/v = locate(params["vir"]) - if(!istype(v)) - return FALSE - P.name = "paper - Viral Profile" - P.info = {" - [virology_letterhead("Viral Profile")] - [v.fields["description"]] -
- Additional Notes:  -"} - - state("The nearby computer prints out a report.") diff --git a/code/modules/virus2/items_devices.dm b/code/modules/virus2/items_devices.dm deleted file mode 100644 index ee9d4b63771..00000000000 --- a/code/modules/virus2/items_devices.dm +++ /dev/null @@ -1,114 +0,0 @@ -///////////////ANTIBODY SCANNER/////////////// - -/obj/item/antibody_scanner - name = "antibody scanner" - desc = "Scans living beings for antibodies in their blood." - icon = 'icons/obj/device_vr.dmi' - icon_state = "antibody" - w_class = ITEMSIZE_SMALL - item_state = "electronic" - -/obj/item/antibody_scanner/attack(mob/M as mob, mob/user as mob) - if(!istype(M,/mob/living/carbon/)) - report("Scan aborted: Incompatible target.", user) - return - - var/mob/living/carbon/C = M - if (istype(C,/mob/living/carbon/human/)) - var/mob/living/carbon/human/H = C - if(!H.should_have_organ(O_HEART)) - report("Scan aborted: The target does not have blood.", user) - return - - if(!C.antibodies.len) - report("Scan Complete: No antibodies detected.", user) - return - - if (CLUMSY in user.mutations && prob(50)) - // I was tempted to be really evil and rot13 the output. - report("Antibodies detected: [reverse_text(antigens2string(C.antibodies))]", user) - else - report("Antibodies detected: [antigens2string(C.antibodies)]", user) - -/obj/item/antibody_scanner/proc/report(var/text, mob/user as mob) - to_chat(user, "[span_blue("[icon2html(src, user.client)] \The [src] beeps,")] \"[span_blue("[text]")]\"") - -///////////////VIRUS DISH/////////////// - -/obj/item/virusdish - name = "virus dish" - icon = 'icons/obj/items.dmi' - icon_state = "virussample" - var/datum/disease2/disease/virus2 = null - var/growth = 0 - var/basic_info = null - var/info = 0 - var/analysed = 0 - -/obj/item/virusdish/random - name = "virus sample" - -/obj/item/virusdish/random/New() - ..() - src.virus2 = new /datum/disease2/disease - src.virus2.makerandom() - growth = rand(5, 50) - -/obj/item/virusdish/attackby(var/obj/item/W as obj,var/mob/living/carbon/user as mob) - if(istype(W,/obj/item/hand_labeler) || istype(W,/obj/item/reagent_containers/syringe)) - //VOREstation edit - Actually functional virus dishes - // Originally this returns, THEN calls ..() instead of returning the value of ..() - return ..() - //VOREstation edit end - if(prob(50)) - to_chat(user, span_danger("\The [src] shatters!")) - if(virus2.infectionchance > 0) - for(var/mob/living/carbon/target in view(1, get_turf(src))) - if(airborne_can_reach(get_turf(src), get_turf(target))) - infect_virus2(target, src.virus2) - qdel(src) - -/obj/item/virusdish/examine(mob/user) - . = ..() - if(basic_info) - . += "[basic_info] : More Information" - -/obj/item/virusdish/Topic(href, href_list) - . = ..() - if(.) return 1 - - if(href_list["info"]) - usr << browse(info, "window=info_\ref[src]") - return 1 - -/obj/item/ruinedvirusdish - name = "ruined virus sample" - icon = 'icons/obj/items.dmi' - icon_state = "virussample-ruined" - desc = "The bacteria in the dish are completely dead." - -/obj/item/ruinedvirusdish/attackby(var/obj/item/W as obj,var/mob/living/carbon/user as mob) - if(istype(W,/obj/item/hand_labeler) || istype(W,/obj/item/reagent_containers/syringe)) - return ..() - - if(prob(50)) - to_chat(user, "\The [src] shatters!") - qdel(src) - -///////////////GNA DISK/////////////// - -/obj/item/diseasedisk - name = "blank GNA disk" - icon = 'icons/obj/cloning.dmi' - icon_state = "datadisk0" - w_class = ITEMSIZE_TINY - var/datum/disease2/effectholder/effect = null - var/list/species = null - var/stage = 1 - var/analysed = 1 - -/obj/item/diseasedisk/premade/New() - name = "blank GNA disk (stage: [stage])" - effect = new /datum/disease2/effectholder - effect.effect = new /datum/disease2/effect/invisible - effect.stage = stage diff --git a/code/modules/vore/chat_healthbars.dm b/code/modules/vore/chat_healthbars.dm index 84616f4fca4..15d45a22999 100644 --- a/code/modules/vore/chat_healthbars.dm +++ b/code/modules/vore/chat_healthbars.dm @@ -114,7 +114,7 @@ /mob/living/verb/print_healthbars() set name = "Print Prey Healthbars" - set category = "Abilities" + set category = "Abilities.Vore" var/nuffin = TRUE diff --git a/code/modules/vore/eating/belly_import.dm b/code/modules/vore/eating/belly_import.dm index 18e750863f6..d13389b579b 100644 --- a/code/modules/vore/eating/belly_import.dm +++ b/code/modules/vore/eating/belly_import.dm @@ -525,7 +525,7 @@ new_belly.egg_type = new_egg_type /* Not implemented on virgo - if(istext(belly_data["egg_name"])) //CHOMPAdd Start + if(istext(belly_data["egg_name"])) var/new_egg_name = html_encode(belly_data["egg_name"]) if(new_egg_name) new_egg_name = readd_quotes(new_egg_name) @@ -643,7 +643,7 @@ var/new_sound_volume = belly_data["sound_volume"] new_belly.sound_volume = sanitize_integer(new_sound_volume, 0, 100, initial(new_belly.sound_volume)) - if(isnum(belly_data["noise_freq"])) //CHOMPAdd Start + if(isnum(belly_data["noise_freq"])) var/new_noise_freq = belly_data["noise_freq"] new_belly.noise_freq = sanitize_integer(new_noise_freq, MIN_VOICE_FREQ, MAX_VOICE_FREQ, initial(new_belly.noise_freq)) */ diff --git a/code/modules/vore/eating/inbelly_spawn.dm b/code/modules/vore/eating/inbelly_spawn.dm index e684d39b5c6..e2ef03a4727 100644 --- a/code/modules/vore/eating/inbelly_spawn.dm +++ b/code/modules/vore/eating/inbelly_spawn.dm @@ -1,5 +1,5 @@ /mob/observer/dead/verb/spawn_in_belly() - set category = "Ghost" + set category = "Ghost.Join" set name = "Spawn In Belly" set desc = "Spawn in someone's belly." diff --git a/code/modules/vore/eating/living_vr.dm b/code/modules/vore/eating/living_vr.dm index bc37ecc6059..ae486f1e3f8 100644 --- a/code/modules/vore/eating/living_vr.dm +++ b/code/modules/vore/eating/living_vr.dm @@ -459,7 +459,7 @@ // /mob/living/proc/lick(mob/living/tasted in living_mobs(1)) set name = "Lick" - set category = "IC" + set category = "IC.Game" set desc = "Lick someone nearby!" set popup_menu = FALSE // Stop licking by accident! @@ -500,7 +500,7 @@ //This is just the above proc but switched about. /mob/living/proc/smell(mob/living/smelled in living_mobs(1)) set name = "Smell" - set category = "IC" + set category = "IC.Game" set desc = "Smell someone nearby!" set popup_menu = FALSE @@ -536,7 +536,7 @@ // /mob/living/proc/escapeOOC() set name = "OOC Escape" - set category = "OOC" + set category = "OOC.Vore" //You're in a belly! if(isbelly(loc)) @@ -825,7 +825,7 @@ /mob/living/proc/glow_toggle() set name = "Glow (Toggle)" - set category = "Abilities" + set category = "Abilities.General" set desc = "Toggle your glowing on/off!" //I don't really see a point to any sort of checking here. @@ -836,7 +836,7 @@ /mob/living/proc/glow_color() set name = "Glow (Set Color)" - set category = "Abilities" + set category = "Abilities.Settings" set desc = "Pick a color for your body's glow." //Again, no real need for a check on this. I'm unsure how it could be somehow abused. @@ -856,7 +856,7 @@ /mob/living/proc/eat_trash() set name = "Eat Trash" - set category = "Abilities" + set category = "Abilities.Vore" set desc = "Consume held garbage." if(!vore_selected) @@ -1000,14 +1000,14 @@ /mob/living/proc/toggle_trash_catching() //Ported from chompstation set name = "Toggle Trash Catching" - set category = "Abilities" + set category = "Abilities.Vore" set desc = "Toggle Trash Eater throw vore abilities." trash_catching = !trash_catching to_chat(src, span_warning("Trash catching [trash_catching ? "enabled" : "disabled"].")) /mob/living/proc/eat_minerals() //Actual eating abstracted so the user isn't given a prompt due to an argument in this verb. set name = "Eat Minerals" - set category = "Abilities" + set category = "Abilities.Vore" set desc = "Consume held raw ore, gems and refined minerals. Snack time!" handle_eat_minerals() @@ -1136,7 +1136,7 @@ /mob/living/proc/toggle_stuffing_mode() set name = "Toggle feeding mode" - set category = "Abilities" + set category = "Abilities.Vore" set desc = "Switch whether you will try to feed other people food whole or normally, bite by bite." stuffing_feeder = !stuffing_feeder @@ -1144,7 +1144,7 @@ /mob/living/proc/switch_scaling() set name = "Switch scaling mode" - set category = "Preferences" + set category = "Preferences.Game" set desc = "Switch sharp/fuzzy scaling for current mob." appearance_flags ^= PIXEL_SCALE fuzzy = !fuzzy @@ -1152,7 +1152,7 @@ /mob/living/proc/center_offset() set name = "Switch center offset mode" - set category = "Preferences" + set category = "Preferences.Game" set desc = "Switch sprite center offset to fix even/odd symmetry." offset_override = !offset_override update_transform() @@ -1236,7 +1236,7 @@ /mob/living/proc/vorebelly_printout() //Spew the vorepanel belly messages into chat window for copypasting. set name = "X-Print Vorebelly Settings" - set category = "Preferences" + set category = "Preferences.Vore" set desc = "Print out your vorebelly messages into chat for copypasting." var/result = tgui_alert(src, "Would you rather open the export panel?", "Selected Belly Export", list("Open Panel", "Print to Chat")) diff --git a/code/modules/vore/eating/silicon_vr.dm b/code/modules/vore/eating/silicon_vr.dm index dd6d2260cb9..0ef778f829d 100644 --- a/code/modules/vore/eating/silicon_vr.dm +++ b/code/modules/vore/eating/silicon_vr.dm @@ -41,7 +41,7 @@ /mob/living/silicon/ai/verb/holo_nom() set name = "Hardlight Nom" - set category = "AI Commands" + set category = "AI.Vore" set desc = "Wrap up a person in hardlight holograms." // Wrong state @@ -80,7 +80,7 @@ //I basically have to do this, you know? /mob/living/silicon/ai/examinate(atom/A as mob|obj|turf in view(eyeobj)) set name = "Examine" - set category = "IC" + set category = "IC.Game" A.examine(src) */ diff --git a/code/modules/vore/eating/simple_animal_vr.dm b/code/modules/vore/eating/simple_animal_vr.dm index 21380ccf596..b6eb8840b33 100644 --- a/code/modules/vore/eating/simple_animal_vr.dm +++ b/code/modules/vore/eating/simple_animal_vr.dm @@ -8,7 +8,7 @@ // /mob/living/simple_mob/proc/animal_nom(mob/living/T in living_mobs(1)) set name = "Animal Nom" - set category = "Abilities" // Moving this to abilities from IC as it's more fitting there + set category = "Abilities.Vore" // Moving this to abilities from IC as it's more fitting there set desc = "Since you can't grab, you get a verb!" if(stat != CONSCIOUS) @@ -30,7 +30,7 @@ /mob/living/simple_mob/proc/toggle_digestion() set name = "Toggle Animal's Digestion" set desc = "Enables digestion on this mob for 20 minutes." - set category = "OOC" + set category = "OOC.Mob Settings" set src in oview(1) var/mob/living/carbon/human/user = usr @@ -56,7 +56,7 @@ /mob/living/simple_mob/proc/toggle_fancygurgle() set name = "Toggle Animal's Gurgle sounds" set desc = "Switches between Fancy and Classic sounds on this mob." - set category = "OOC" + set category = "OOC.Mob Settings" set src in oview(1) var/mob/living/user = usr //I mean, At least ghosts won't use it. diff --git a/code/modules/vore/eating/vertical_nom_vr.dm b/code/modules/vore/eating/vertical_nom_vr.dm index f819fa5138e..e47c1f00d95 100644 --- a/code/modules/vore/eating/vertical_nom_vr.dm +++ b/code/modules/vore/eating/vertical_nom_vr.dm @@ -1,7 +1,7 @@ /mob/living/proc/vertical_nom() set name = "Nom from Above" set desc = "Allows you to eat people who are below your tile or adjacent one. Requires passability." - set category = "Abilities" + set category = "Abilities.Vore" if(stat == DEAD || paralysis || weakened || stunned) to_chat(src, span_notice("You cannot do that while in your current state.")) diff --git a/code/modules/vore/eating/vorepanel_vr.dm b/code/modules/vore/eating/vorepanel_vr.dm index 88266f1b849..f682673a14b 100644 --- a/code/modules/vore/eating/vorepanel_vr.dm +++ b/code/modules/vore/eating/vorepanel_vr.dm @@ -22,7 +22,7 @@ var/global/list/belly_colorable_only_fullscreens = list("a_synth_flesh_mono", /mob/proc/insidePanel() set name = "Vore Panel" - set category = "IC" + set category = "IC.Vore" if(SSticker.current_state == GAME_STATE_INIT) return diff --git a/code/modules/vore/resizing/resize_vr.dm b/code/modules/vore/resizing/resize_vr.dm index 33a152492b2..9a0a59047d4 100644 --- a/code/modules/vore/resizing/resize_vr.dm +++ b/code/modules/vore/resizing/resize_vr.dm @@ -152,7 +152,7 @@ /mob/living/proc/set_size() set name = "Adjust Mass" - set category = "Abilities" //Seeing as prometheans have an IC reason to be changing mass. + set category = "Abilities.General" //Seeing as prometheans have an IC reason to be changing mass. var/nagmessage = "Adjust your mass to be a size between 25 to 200% (or 1% to 600% in dormitories). (DO NOT ABUSE)" var/default = size_multiplier * 100 @@ -403,7 +403,7 @@ /mob/living/verb/toggle_pickups() set name = "Toggle Micro Pick-up" set desc = "Toggles whether your help-intent action attempts to pick up the micro or pet/hug/help them. Does not disable participation in pick-up mechanics entirely, refer to Vore Panel preferences for that." - set category = "IC" + set category = "IC.Settings" pickup_active = !pickup_active to_chat(src, span_filter_notice("You will [pickup_active ? "now" : "no longer"] attempt to pick up mobs when clicking them with help intent.")) diff --git a/code/modules/vore/trycatch_vr.dm b/code/modules/vore/trycatch_vr.dm index 396352aadc6..fa1b556280c 100644 --- a/code/modules/vore/trycatch_vr.dm +++ b/code/modules/vore/trycatch_vr.dm @@ -49,10 +49,10 @@ The hooks you're calling should return nonzero values on success. error("hook_vr: Invalid hook '/hook/[hook]' called.") return 0 - var/caller = new hook_path + var/hook_instance = new hook_path var/status = 1 for(var/P in typesof("[hook_path]/proc")) - if(!call(caller, P)(arglist(args))) + if(!call(hook_instance, P)(arglist(args))) error("hook_vr: Hook '[P]' failed or runtimed.") status = 0 diff --git a/code/modules/whitelist/whitelist.dm b/code/modules/whitelist/whitelist.dm index 2bc269acf7e..917ecc56ec8 100644 --- a/code/modules/whitelist/whitelist.dm +++ b/code/modules/whitelist/whitelist.dm @@ -5,7 +5,7 @@ /client/verb/print_whitelist() set name = "Show Whitelist Entries" set desc = "Print the set of things you're whitelisted for." - set category = "OOC" + set category = "OOC.Client settings" to_chat(src, "You are whitelisted for:") to_chat(src, jointext(get_whitelists_list(), "\n")) diff --git a/config/example/game_options.txt b/config/example/game_options.txt index 67322ac49a5..f5b43ecb366 100644 --- a/config/example/game_options.txt +++ b/config/example/game_options.txt @@ -18,12 +18,12 @@ BONES_CAN_BREAK 1 LIMBS_CAN_BREAK 1 ## multiplier which enables organs to take more damage before bones breaking or limbs being destroyed -## 100 means normal, 50 means half -ORGAN_HEALTH_MULTIPLIER 100 +## 1.0 means normal, 0.5 means half +ORGAN_HEALTH_MULTIPLIER 1.0 ## multiplier which influences how fast organs regenerate naturally -## 100 means normal, 50 means half -ORGAN_REGENERATION_MULTIPLIER 50 +## 1.0 means normal, 0.5 means half +ORGAN_REGENERATION_MULTIPLIER 0.5 ### REVIVAL ### diff --git a/icons/inventory/feet/mob_digi.dmi b/icons/inventory/feet/mob_digi.dmi index 71cecdb2cd6..04d2fa870d1 100644 Binary files a/icons/inventory/feet/mob_digi.dmi and b/icons/inventory/feet/mob_digi.dmi differ diff --git a/icons/mob/macrophage.dmi b/icons/mob/macrophage.dmi new file mode 100644 index 00000000000..4b7518bfc64 Binary files /dev/null and b/icons/mob/macrophage.dmi differ diff --git a/icons/obj/device.dmi b/icons/obj/device.dmi index a538ec2b609..2a817ae4e0e 100644 Binary files a/icons/obj/device.dmi and b/icons/obj/device.dmi differ diff --git a/icons/obj/door_release.dmi b/icons/obj/door_release.dmi new file mode 100644 index 00000000000..669aa390b0b Binary files /dev/null and b/icons/obj/door_release.dmi differ diff --git a/icons/obj/pandemic.dmi b/icons/obj/pandemic.dmi new file mode 100644 index 00000000000..870341bb870 Binary files /dev/null and b/icons/obj/pandemic.dmi differ diff --git a/interface/interface.dm b/interface/interface.dm index 7276d0fc60c..7042a2dda04 100644 --- a/interface/interface.dm +++ b/interface/interface.dm @@ -2,7 +2,7 @@ /client/verb/wiki(query as text) set name = "wiki" set desc = "Type what you want to know about. This will open the wiki on your web browser." - set category = "OOC" + set category = "OOC.Resources" if(CONFIG_GET(string/wikiurl)) if(query) if(CONFIG_GET(string/wikisearchurl)) @@ -95,7 +95,7 @@ /client/verb/hotkeys_help() set name = "hotkeys-help" - set category = "OOC" + set category = "OOC.Resources" var/admin = {" Admin: diff --git a/maps/expedition_vr/beach/submaps/quarantineshuttle.dmm b/maps/expedition_vr/beach/submaps/quarantineshuttle.dmm index 83694ffdc0e..8b7ac40dd50 100644 --- a/maps/expedition_vr/beach/submaps/quarantineshuttle.dmm +++ b/maps/expedition_vr/beach/submaps/quarantineshuttle.dmm @@ -141,6 +141,7 @@ /area/submap/cave/qShuttle) "au" = ( /obj/structure/closet/crate/secure/loot, +/obj/item/reagent_containers/glass/bottle/culture/cold, /turf/simulated/shuttle/floor{ icon_state = "floor_yellow" }, @@ -332,7 +333,8 @@ }, /area/submap/cave/qShuttle) "aV" = ( -/obj/item/virusdish/random, +/obj/structure/closet/crate/secure/loot, +/obj/item/reagent_containers/glass/bottle/culture/flu, /turf/simulated/shuttle/floor{ icon_state = "floor_yellow" }, @@ -472,9 +474,6 @@ name = "Virus Samples - FRAGILE"; opened = 1 }, -/obj/item/virusdish/random, -/obj/item/virusdish/random, -/obj/item/virusdish/random, /turf/simulated/shuttle/floor{ icon_state = "floor_yellow" }, @@ -1311,7 +1310,7 @@ ab ad au aF -aV +aA bj bv bE @@ -1363,7 +1362,7 @@ aa aa ab ad -au +aV aH aW bk @@ -1394,7 +1393,7 @@ ad ad aX aA -aV +aA ad ad ad diff --git a/maps/groundbase/gb-z2.dmm b/maps/groundbase/gb-z2.dmm index e3d7326b77d..ac234c68285 100644 --- a/maps/groundbase/gb-z2.dmm +++ b/maps/groundbase/gb-z2.dmm @@ -312,11 +312,6 @@ /area/groundbase/level2/nw) "aH" = ( /obj/structure/table/glass, -/obj/item/antibody_scanner, -/obj/item/antibody_scanner{ - pixel_x = 2; - pixel_y = 2 - }, /turf/simulated/floor/tiled/white, /area/medical/virology) "aI" = ( @@ -2120,6 +2115,12 @@ icon_state = "2-8" }, /obj/machinery/atmospherics/pipe/simple/hidden/scrubbers, +/obj/machinery/button/remote/airlock/release{ + dir = 8; + pixel_y = -7; + pixel_x = 27; + id = "dorm5" + }, /turf/simulated/floor/wood, /area/groundbase/dorms/room5) "fn" = ( @@ -2641,6 +2642,12 @@ icon_state = "2-4" }, /obj/machinery/atmospherics/pipe/simple/hidden/scrubbers, +/obj/machinery/button/remote/airlock/release{ + dir = 4; + pixel_y = -7; + pixel_x = -27; + id = "dorm4" + }, /turf/simulated/floor/wood, /area/groundbase/dorms/room4) "gQ" = ( @@ -3827,12 +3834,7 @@ }, /turf/simulated/floor/outdoors/sidewalk/slab, /area/groundbase/level2/nw) -"kb" = ( -/obj/machinery/disease2/diseaseanalyser, -/turf/simulated/floor/tiled/white, -/area/medical/virology) "kc" = ( -/obj/machinery/disease2/incubator, /obj/structure/reagent_dispensers/virusfood{ pixel_y = 27 }, @@ -4968,9 +4970,7 @@ /turf/simulated/floor/tiled, /area/groundbase/science/hall) "nx" = ( -/obj/machinery/computer/diseasesplicer{ - dir = 1 - }, +/obj/machinery/computer/pandemic, /turf/simulated/floor/tiled/white, /area/medical/virology) "ny" = ( @@ -6090,6 +6090,12 @@ icon_state = "2-4" }, /obj/machinery/atmospherics/pipe/simple/hidden/scrubbers, +/obj/machinery/button/remote/airlock/release{ + dir = 4; + pixel_y = -7; + pixel_x = -27; + id = "dorm6" + }, /turf/simulated/floor/wood, /area/groundbase/dorms/room6) "qG" = ( @@ -6999,10 +7005,15 @@ /turf/simulated/floor/tiled/eris/cafe, /area/groundbase/civilian/kitchen) "tk" = ( -/obj/machinery/disease2/isolator, /obj/machinery/light{ dir = 1 }, +/obj/structure/closet/crate/medical, +/obj/item/reagent_containers/glass/bottle/culture/cold{ + pixel_x = -5; + pixel_y = 5 + }, +/obj/item/reagent_containers/glass/bottle/culture/flu, /turf/simulated/floor/tiled/white, /area/medical/virology) "tm" = ( @@ -7288,6 +7299,12 @@ icon_state = "2-8" }, /obj/machinery/atmospherics/pipe/simple/hidden/scrubbers, +/obj/machinery/button/remote/airlock/release{ + dir = 8; + pixel_y = -7; + pixel_x = 27; + id = "dorm3" + }, /turf/simulated/floor/wood, /area/groundbase/dorms/room3) "uf" = ( @@ -9316,7 +9333,6 @@ "Ag" = ( /obj/structure/table/glass, /obj/item/book/manual/virology, -/obj/item/antibody_scanner, /obj/item/reagent_containers/glass/beaker, /obj/item/paper_bin, /obj/item/folder/white, @@ -13390,6 +13406,11 @@ /obj/structure/bed/chair/sofa/corp/left{ dir = 4 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = 27; + pixel_x = 7; + id = "dorm8" + }, /turf/simulated/floor/wood, /area/groundbase/dorms/room8) "Lu" = ( @@ -15037,6 +15058,12 @@ /obj/structure/bed/chair/sofa/corp/left{ dir = 8 }, +/obj/machinery/button/remote/airlock/release{ + dir = 8; + pixel_y = -7; + pixel_x = 27; + id = "dorm1" + }, /turf/simulated/floor/wood, /area/groundbase/dorms/room1) "PU" = ( @@ -15368,6 +15395,11 @@ /obj/structure/bed/chair/sofa/corp/right{ dir = 8 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = 27; + pixel_x = -7; + id = "dorm7" + }, /turf/simulated/floor/wood, /area/groundbase/dorms/room7) "QP" = ( @@ -16945,6 +16977,12 @@ /obj/structure/bed/chair/sofa/corp/right{ dir = 4 }, +/obj/machinery/button/remote/airlock/release{ + dir = 4; + pixel_y = -7; + pixel_x = -27; + id = "dorm2" + }, /turf/simulated/floor/wood, /area/groundbase/dorms/room2) "Vz" = ( @@ -18140,10 +18178,6 @@ /obj/structure/closet/secure_closet/personal/patient, /turf/simulated/floor/tiled/white, /area/medical/virology) -"Zd" = ( -/obj/machinery/computer/centrifuge, -/turf/simulated/floor/tiled/white, -/area/medical/virology) "Ze" = ( /obj/structure/cable/yellow{ icon_state = "1-2" @@ -36289,8 +36323,8 @@ QA pe lj RW -Zd -kb +cG +cG aZ mb pe @@ -36431,7 +36465,7 @@ pe pe tk OH -cG +nx Qr cG xf @@ -36576,7 +36610,7 @@ OH aH bC cG -nx +cG pe fk UH diff --git a/maps/stellar_delight/stellar_delight1.dmm b/maps/stellar_delight/stellar_delight1.dmm index b6a140ba19d..4a75431ddac 100644 --- a/maps/stellar_delight/stellar_delight1.dmm +++ b/maps/stellar_delight/stellar_delight1.dmm @@ -7207,6 +7207,12 @@ /obj/structure/closet/crate/bin{ anchored = 1 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = -22; + pixel_x = 6; + dir = 1; + id = "dorm4" + }, /turf/simulated/floor/carpet, /area/stellardelight/deck1/dorms/dorm4) "oB" = ( @@ -7545,6 +7551,12 @@ /obj/structure/closet/crate/bin{ anchored = 1 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = -22; + pixel_x = -8; + dir = 1; + id = "dorm6" + }, /turf/simulated/floor/carpet/purcarpet, /area/stellardelight/deck1/dorms/dorm6) "pn" = ( @@ -8799,6 +8811,11 @@ /obj/structure/closet/crate/bin{ anchored = 1 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = 24; + pixel_x = -7; + id = "dorm8" + }, /turf/simulated/floor/carpet, /area/stellardelight/deck1/dorms/dorm8) "rX" = ( @@ -8897,7 +8914,6 @@ /turf/simulated/floor/tiled/techmaint, /area/stellardelight/deck1/starboard) "sf" = ( -/obj/machinery/disease2/isolator, /obj/machinery/light/floortube{ dir = 8; pixel_x = -6 @@ -8907,6 +8923,12 @@ dir = 8; pixel_x = -24 }, +/obj/structure/closet/crate/medical, +/obj/item/reagent_containers/glass/bottle/culture/cold{ + pixel_x = -5; + pixel_y = 5 + }, +/obj/item/reagent_containers/glass/bottle/culture/flu, /turf/simulated/floor/tiled/eris/white/bluecorner, /area/medical/virology) "sg" = ( @@ -10985,9 +11007,6 @@ /turf/simulated/floor, /area/maintenance/stellardelight/deck1/portaft) "wR" = ( -/obj/machinery/computer/diseasesplicer{ - dir = 1 - }, /turf/simulated/floor/tiled/eris/white/bluecorner, /area/medical/virology) "wS" = ( @@ -13386,7 +13405,6 @@ /turf/simulated/wall/bay/black, /area/chapel/main) "BV" = ( -/obj/machinery/disease2/incubator, /obj/structure/reagent_dispensers/virusfood{ pixel_y = 27 }, @@ -13717,7 +13735,6 @@ "CJ" = ( /obj/structure/table/glass, /obj/item/book/manual/virology, -/obj/item/antibody_scanner, /obj/item/reagent_containers/glass/beaker, /obj/item/paper_bin, /obj/item/folder/white, @@ -15308,11 +15325,11 @@ /turf/simulated/floor/tiled/steel_ridged, /area/prison/cell_block) "Gn" = ( -/obj/machinery/disease2/diseaseanalyser, /obj/machinery/light/floortube{ dir = 8; pixel_x = -6 }, +/obj/machinery/computer/pandemic, /turf/simulated/floor/tiled/eris/white/bluecorner, /area/medical/virology) "Go" = ( @@ -16042,6 +16059,11 @@ /obj/structure/closet/crate/bin{ anchored = 1 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = 24; + pixel_x = 7; + id = "dorm1" + }, /turf/simulated/floor/carpet, /area/stellardelight/deck1/dorms/dorm1) "HY" = ( @@ -21133,6 +21155,12 @@ /obj/structure/closet/crate/bin{ anchored = 1 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = -22; + pixel_x = 6; + dir = 1; + id = "dorm3" + }, /turf/simulated/floor/carpet/purcarpet, /area/stellardelight/deck1/dorms/dorm3) "SQ" = ( @@ -22405,7 +22433,6 @@ /turf/simulated/floor/wood, /area/library) "Vq" = ( -/obj/machinery/computer/centrifuge, /obj/machinery/embedded_controller/radio/airlock/access_controller{ dir = 4; id_tag = "virology_airlock_control"; @@ -22475,6 +22502,11 @@ /obj/structure/closet/crate/bin{ anchored = 1 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = 24; + pixel_x = -7; + id = "dorm7" + }, /turf/simulated/floor/carpet/purcarpet, /area/stellardelight/deck1/dorms/dorm7) "Vw" = ( @@ -22760,6 +22792,11 @@ /obj/structure/closet/crate/bin{ anchored = 1 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = 24; + pixel_x = 7; + id = "dorm2" + }, /turf/simulated/floor/carpet/purcarpet, /area/stellardelight/deck1/dorms/dorm2) "Wb" = ( @@ -23885,6 +23922,12 @@ /obj/structure/closet/crate/bin{ anchored = 1 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = -22; + pixel_x = -8; + dir = 1; + id = "dorm5" + }, /turf/simulated/floor/carpet, /area/stellardelight/deck1/dorms/dorm5) "Yt" = ( diff --git a/maps/tether/tether-01-surface1.dmm b/maps/tether/tether-01-surface1.dmm index 2e93b90624e..2768b3e8c66 100644 --- a/maps/tether/tether-01-surface1.dmm +++ b/maps/tether/tether-01-surface1.dmm @@ -12580,10 +12580,6 @@ /obj/structure/catwalk, /turf/simulated/floor/plating, /area/maintenance/lower/solars) -"avQ" = ( -/obj/machinery/disease2/isolator, -/turf/simulated/floor/tiled/white, -/area/medical/virology) "avR" = ( /obj/machinery/atmospherics/pipe/simple/hidden/yellow, /obj/structure/disposalpipe/segment, @@ -14214,11 +14210,6 @@ /obj/machinery/atmospherics/pipe/simple/hidden/yellow, /obj/machinery/atmospherics/pipe/simple/hidden/supply, /obj/structure/table/glass, -/obj/item/antibody_scanner, -/obj/item/antibody_scanner{ - pixel_x = 2; - pixel_y = 2 - }, /turf/simulated/floor/tiled/white, /area/medical/virology) "ayk" = ( @@ -22258,6 +22249,11 @@ /obj/structure/cable/orange{ icon_state = "1-2" }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = -4; + pixel_x = 33; + id = "dorm7" + }, /turf/simulated/floor/wood, /area/crew_quarters/sleep/Dorm_7) "aMA" = ( @@ -22326,6 +22322,11 @@ pixel_y = -4; specialfunctions = 4 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = -4; + pixel_x = -33; + id = "dorm8" + }, /turf/simulated/floor/wood, /area/crew_quarters/sleep/Dorm_8) "aMD" = ( @@ -23381,6 +23382,11 @@ /obj/structure/cable/orange{ icon_state = "1-2" }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = -4; + pixel_x = 33; + id = "dorm5" + }, /turf/simulated/floor/wood, /area/crew_quarters/sleep/Dorm_5) "aOI" = ( @@ -23445,6 +23451,11 @@ pixel_y = -4; specialfunctions = 4 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = -4; + pixel_x = -33; + id = "dorm6" + }, /turf/simulated/floor/wood, /area/crew_quarters/sleep/Dorm_6) "aOL" = ( @@ -24537,6 +24548,11 @@ /obj/structure/cable/orange{ icon_state = "1-2" }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = -4; + pixel_x = 33; + id = "dorm3" + }, /turf/simulated/floor/wood, /area/crew_quarters/sleep/Dorm_3) "aQI" = ( @@ -24605,6 +24621,11 @@ pixel_y = -4; specialfunctions = 4 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = -4; + pixel_x = -33; + id = "dorm4" + }, /turf/simulated/floor/wood, /area/crew_quarters/sleep/Dorm_4) "aQL" = ( @@ -25617,6 +25638,11 @@ /obj/structure/cable/orange{ icon_state = "1-2" }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = -4; + pixel_x = 33; + id = "dorm1" + }, /turf/simulated/floor/wood, /area/crew_quarters/sleep/Dorm_1) "aSV" = ( @@ -25627,6 +25653,11 @@ pixel_y = -4; specialfunctions = 4 }, +/obj/machinery/button/remote/airlock/release{ + pixel_y = -4; + pixel_x = -33; + id = "dorm2" + }, /turf/simulated/floor/wood, /area/crew_quarters/sleep/Dorm_2) "aSW" = ( @@ -30617,7 +30648,6 @@ /turf/simulated/floor/tiled, /area/tether/surfacebase/security/brig) "cdl" = ( -/obj/machinery/disease2/diseaseanalyser, /obj/item/radio/intercom{ dir = 1; name = "Station Intercom (General)"; @@ -30629,6 +30659,7 @@ /obj/effect/floor_decal/corner/lime/border{ dir = 9 }, +/obj/structure/table/standard, /turf/simulated/floor/tiled/white, /area/medical/virology) "cdO" = ( @@ -34852,10 +34883,11 @@ dir = 1 }, /obj/structure/closet/crate/freezer, -/obj/item/virusdish/random, -/obj/item/virusdish/random, -/obj/item/virusdish/random, -/obj/item/virusdish/random, +/obj/item/reagent_containers/glass/bottle/culture/cold{ + pixel_x = -5; + pixel_y = 5 + }, +/obj/item/reagent_containers/glass/bottle/culture/flu, /turf/simulated/floor/tiled/white, /area/medical/virology) "nMH" = ( @@ -36504,7 +36536,6 @@ /turf/simulated/floor/plating, /area/maintenance/lower/vacant_site) "sLf" = ( -/obj/machinery/computer/diseasesplicer, /obj/machinery/light{ dir = 1 }, @@ -36514,6 +36545,7 @@ /obj/effect/floor_decal/corner/lime/border{ dir = 1 }, +/obj/machinery/computer/pandemic, /turf/simulated/floor/tiled/white, /area/medical/virology) "sLi" = ( @@ -37386,7 +37418,7 @@ /obj/effect/floor_decal/corner/lime/border{ dir = 1 }, -/obj/machinery/computer/centrifuge, +/obj/structure/table/standard, /turf/simulated/floor/tiled/white, /area/medical/virology) "vBy" = ( @@ -37505,10 +37537,6 @@ /obj/machinery/computer/arcade/orion_trail, /turf/simulated/floor/tiled, /area/tether/surfacebase/security/brig) -"vXS" = ( -/obj/machinery/disease2/incubator, -/turf/simulated/floor/tiled/white, -/area/medical/virology) "waR" = ( /turf/simulated/floor/tiled/dark, /area/tether/surfacebase/security/weaponsrange) @@ -54088,7 +54116,7 @@ aeE vwM avl afB -avQ +avl axj ayk ayK @@ -54230,7 +54258,7 @@ aeE nLm avl afD -vXS +avl axF ayl avl diff --git a/maps/~map_system/_map_selection.dm b/maps/~map_system/_map_selection.dm index 879f058f545..47ff0d984d0 100644 --- a/maps/~map_system/_map_selection.dm +++ b/maps/~map_system/_map_selection.dm @@ -5,8 +5,8 @@ /* FOR LIVE SERVER */ /*********************/ -#define USE_MAP_TETHER -//#define USE_MAP_STELLARDELIGHT +//#define USE_MAP_TETHER +#define USE_MAP_STELLARDELIGHT //#define USE_MAP_GROUNDBASE // Debug diff --git a/tgui/packages/common/storage.js b/tgui/packages/common/storage.js index afe00644f6c..a08d604fcae 100644 --- a/tgui/packages/common/storage.js +++ b/tgui/packages/common/storage.js @@ -7,7 +7,7 @@ */ export const IMPL_MEMORY = 0; -export const IMPL_LOCAL_STORAGE = 1; +export const IMPL_HUB_STORAGE = 1; export const IMPL_INDEXED_DB = 2; const INDEXED_DB_VERSION = 1; @@ -25,14 +25,11 @@ const testGeneric = (testFn) => () => { } }; -// Localstorage can sometimes throw an error, even if DOM storage is not -// disabled in IE11 settings. -// See: https://superuser.com/questions/1080011 -// prettier-ignore -const testLocalStorage = testGeneric(() => ( - window.localStorage && window.localStorage.getItem -)); +const testHubStorage = testGeneric( + () => window.hubStorage && window.hubStorage.getItem, +); +// TODO: Remove with 516 // prettier-ignore const testIndexedDb = testGeneric(() => ( (window.indexedDB || window.msIndexedDB) @@ -45,49 +42,50 @@ class MemoryBackend { this.store = {}; } - get(key) { + async get(key) { return this.store[key]; } - set(key, value) { + async set(key, value) { this.store[key] = value; } - remove(key) { + async remove(key) { this.store[key] = undefined; } - clear() { + async clear() { this.store = {}; } } -class LocalStorageBackend { +class HubStorageBackend { constructor() { - this.impl = IMPL_LOCAL_STORAGE; + this.impl = IMPL_HUB_STORAGE; } - get(key) { - const value = localStorage.getItem(key); + async get(key) { + const value = await window.hubStorage.getItem('virgo-' + key); if (typeof value === 'string') { return JSON.parse(value); } } set(key, value) { - localStorage.setItem(key, JSON.stringify(value)); + window.hubStorage.setItem('virgo-' + key, JSON.stringify(value)); } remove(key) { - localStorage.removeItem(key); + window.hubStorage.removeItem('virgo-' + key); } clear() { - localStorage.clear(); + window.hubStorage.clear(); } } class IndexedDbBackend { + // TODO: Remove with 516 constructor() { this.impl = IMPL_INDEXED_DB; /** @type {Promise} */ @@ -108,7 +106,7 @@ class IndexedDbBackend { }); } - getStore(mode) { + async getStore(mode) { // prettier-ignore return this.dbPromise.then((db) => db .transaction(INDEXED_DB_STORE_NAME, mode) @@ -125,13 +123,6 @@ class IndexedDbBackend { } async set(key, value) { - // The reason we don't _save_ null is because IE 10 does - // not support saving the `null` type in IndexedDB. How - // ironic, given the bug below! - // See: https://github.com/mozilla/localForage/issues/161 - if (value === null) { - value = undefined; - } // NOTE: We deliberately make this operation transactionless const store = await this.getStore(READ_WRITE); store.put(value, key); @@ -157,6 +148,10 @@ class IndexedDbBackend { class StorageProxy { constructor() { this.backendPromise = (async () => { + if (!Byond.TRIDENT && testHubStorage()) { + return new HubStorageBackend(); + } + // TODO: Remove with 516 if (testIndexedDb()) { try { const backend = new IndexedDbBackend(); @@ -164,9 +159,9 @@ class StorageProxy { return backend; } catch {} } - if (testLocalStorage()) { - return new LocalStorageBackend(); - } + console.warn( + 'No supported storage backend found. Using in-memory storage.', + ); return new MemoryBackend(); })(); } diff --git a/tgui/packages/tgui-panel/chat/middleware.js b/tgui/packages/tgui-panel/chat/middleware.js index f1745b353bf..d2b55898b7f 100644 --- a/tgui/packages/tgui-panel/chat/middleware.js +++ b/tgui/packages/tgui-panel/chat/middleware.js @@ -35,7 +35,7 @@ import { chatRenderer } from './renderer'; import { selectChat, selectCurrentChatPage } from './selectors'; // List of blacklisted tags -const FORBID_TAGS = ['a', 'iframe', 'link', 'video']; +const blacklisted_tags = ['a', 'iframe', 'link', 'video']; let storedRounds = []; let storedLines = []; @@ -72,7 +72,7 @@ const loadChatFromStorage = async (store) => { for (let message of messages) { if (message.html) { message.html = DOMPurify.sanitize(message.html, { - FORBID_TAGS, + FORBID_TAGS: blacklisted_tags, }); } } @@ -90,7 +90,7 @@ const loadChatFromStorage = async (store) => { for (let archivedMessage of archivedMessages) { if (archivedMessage.html) { archivedMessage.html = DOMPurify.sanitize(archivedMessage.html, { - FORBID_TAGS, + FORBID_TAGS: blacklisted_tags, }); } } diff --git a/tgui/packages/tgui-panel/styles/tgchat/chat-dark.scss b/tgui/packages/tgui-panel/styles/tgchat/chat-dark.scss index cb27c044ad8..a23afafa9c2 100644 --- a/tgui/packages/tgui-panel/styles/tgchat/chat-dark.scss +++ b/tgui/packages/tgui-panel/styles/tgchat/chat-dark.scss @@ -15,7 +15,7 @@ img { margin: 0; padding: 0; line-height: 1; - -ms-interpolation-mode: nearest-neighbor; + -ms-interpolation-mode: nearest-neighbor; // TODO: Remove with 516 image-rendering: pixelated; } @@ -176,12 +176,6 @@ a.popt { padding: 2px 0; } -.filterMessages input { -} - -.filterMessages label { -} - .icon-stack { height: 1em; line-height: 1em; @@ -375,19 +369,6 @@ img.icon.bigicon { font-weight: bold; } -.say, -.emote, -.emotesubtle, -.multizsay, -.npcemote, -.npcsay, -.infoplain, -.oocplain, -.warningplain, -.chatexport, -.body { -} - .warningplain { font-style: italic; } @@ -396,9 +377,6 @@ img.icon.bigicon { font-style: italic; } -.nif { -} - .psay { color: #e300e4; font-style: italic; diff --git a/tgui/packages/tgui-panel/styles/tgchat/chat-light.scss b/tgui/packages/tgui-panel/styles/tgchat/chat-light.scss index e7b4e47ba78..3d6385f904c 100644 --- a/tgui/packages/tgui-panel/styles/tgchat/chat-light.scss +++ b/tgui/packages/tgui-panel/styles/tgchat/chat-light.scss @@ -33,7 +33,7 @@ img { margin: 0; padding: 0; line-height: 1; - -ms-interpolation-mode: nearest-neighbor; + -ms-interpolation-mode: nearest-neighbor; // TODO: Remove with 516 image-rendering: pixelated; } @@ -194,12 +194,6 @@ a.popt { padding: 2px 0; } -.filterMessages input { -} - -.filterMessages label { -} - .icon-stack { height: 1em; line-height: 1em; @@ -393,19 +387,6 @@ img.icon.bigicon { font-weight: bold; } -.say, -.emote, -.emotesubtle, -.multizsay, -.npcemote, -.npcsay, -.infoplain, -.oocplain, -.warningplain, -.chatexport, -.body { -} - .warningplain { font-style: italic; } @@ -414,9 +395,6 @@ img.icon.bigicon { font-style: italic; } -.nif { -} - .psay { color: #800080; font-style: italic; diff --git a/tgui/packages/tgui-panel/styles/tgchat/chat-vchatdark.scss b/tgui/packages/tgui-panel/styles/tgchat/chat-vchatdark.scss index 32ab6331d5f..5797bc32433 100644 --- a/tgui/packages/tgui-panel/styles/tgchat/chat-vchatdark.scss +++ b/tgui/packages/tgui-panel/styles/tgchat/chat-vchatdark.scss @@ -15,7 +15,7 @@ img { margin: 0; padding: 0; line-height: 1; - -ms-interpolation-mode: nearest-neighbor; + -ms-interpolation-mode: nearest-neighbor; // TODO: Remove with 516 image-rendering: pixelated; } @@ -176,12 +176,6 @@ a.popt { padding: 2px 0; } -.filterMessages input { -} - -.filterMessages label { -} - .icon-stack { height: 1em; line-height: 1em; @@ -375,18 +369,6 @@ img.icon.bigicon { font-weight: bold; } -.say, -.emote, -.emotesubtle, -.multizsay, -.npcemote, -.npcsay, -.infoplain, -.oocplain, -.chatexport, -.body { -} - .warningplain { font-style: italic; } @@ -396,9 +378,6 @@ img.icon.bigicon { color: #ffffff; } -.nif { -} - .psay { color: #e300e4; font-style: italic; diff --git a/tgui/packages/tgui-panel/styles/tgchat/chat-vchatlight.scss b/tgui/packages/tgui-panel/styles/tgchat/chat-vchatlight.scss index fd4c060a7fb..eef022ff5ba 100644 --- a/tgui/packages/tgui-panel/styles/tgchat/chat-vchatlight.scss +++ b/tgui/packages/tgui-panel/styles/tgchat/chat-vchatlight.scss @@ -33,7 +33,7 @@ img { margin: 0; padding: 0; line-height: 1; - -ms-interpolation-mode: nearest-neighbor; + -ms-interpolation-mode: nearest-neighbor; // TODO: Remove with 516 image-rendering: pixelated; } @@ -194,12 +194,6 @@ a.popt { padding: 2px 0; } -.filterMessages input { -} - -.filterMessages label { -} - .icon-stack { height: 1em; line-height: 1em; @@ -393,19 +387,6 @@ img.icon.bigicon { font-weight: bold; } -.say, -.emote, -.emotesubtle, -.multizsay, -.npcemote, -.npcsay, -.infoplain, -.oocplain, -.warningplain, -.chatexport, -.body { -} - .warningplain { font-style: italic; } @@ -414,9 +395,6 @@ img.icon.bigicon { font-style: italic; } -.nif { -} - .psay { color: #800080; font-style: italic; diff --git a/tgui/packages/tgui-say/TguiSay.tsx b/tgui/packages/tgui-say/TguiSay.tsx index cb11f78e89b..9c558c34112 100644 --- a/tgui/packages/tgui-say/TguiSay.tsx +++ b/tgui/packages/tgui-say/TguiSay.tsx @@ -1,4 +1,4 @@ -import { KEY } from 'common/keys'; +import { isEscape, KEY } from 'common/keys'; import { clamp } from 'common/math'; import { BooleanLike } from 'common/react'; import { Component, createRef, RefObject } from 'react'; @@ -31,6 +31,14 @@ type State = { const CHANNEL_REGEX = /^:\w\s|^,b\s/; +const ROWS: Record = { + small: 1, + medium: 2, + large: 3, + max: 6, + width: 1, // not used +} as const; + export class TguiSay extends Component<{}, State> { private channelIterator: ChannelIterator; private chatHistory: ChatHistory; @@ -281,9 +289,10 @@ export class TguiSay extends Component<{}, State> { } break; - case KEY.Escape: - this.handleClose(); - break; + default: + if (isEscape(event.key)) { + this.handleClose(); + } } } @@ -369,11 +378,14 @@ export class TguiSay extends Component<{}, State> { {this.state.buttonContent}