Merge remote-tracking branch 'upstream/dev' into faxmachine

Conflicts:
	code/WorkInProgress/kilakk/fax.dm
	code/modules/paperwork/faxmachine.dm
	code/modules/paperwork/paper.dm
	code/modules/paperwork/paper_bundle.dm
	code/modules/paperwork/photocopier.dm
	maps/tgstation2.dmm
This commit is contained in:
mwerezak
2014-11-20 14:57:35 -05:00
595 changed files with 7780 additions and 7624 deletions
+9 -5
View File
@@ -164,7 +164,11 @@
#include "code\datums\spells\trigger.dm"
#include "code\datums\spells\turf_teleport.dm"
#include "code\datums\spells\wizard.dm"
#include "code\datums\wires\airlock.dm"
#include "code\datums\wires\alarm.dm"
#include "code\datums\wires\apc.dm"
#include "code\datums\wires\camera.dm"
#include "code\datums\wires\robot.dm"
#include "code\datums\wires\smartfridge.dm"
#include "code\datums\wires\suit_storage_unit.dm"
#include "code\datums\wires\vending.dm"
@@ -312,6 +316,7 @@
#include "code\game\machinery\holosign.dm"
#include "code\game\machinery\igniter.dm"
#include "code\game\machinery\iv_drip.dm"
#include "code\game\machinery\jukebox.dm"
#include "code\game\machinery\lightswitch.dm"
#include "code\game\machinery\machinery.dm"
#include "code\game\machinery\magnet.dm"
@@ -320,6 +325,7 @@
#include "code\game\machinery\newscaster.dm"
#include "code\game\machinery\OpTable.dm"
#include "code\game\machinery\overview.dm"
#include "code\game\machinery\portable_tag_turret.dm"
#include "code\game\machinery\portable_turret.dm"
#include "code\game\machinery\recharger.dm"
#include "code\game\machinery\rechargestation.dm"
@@ -357,7 +363,6 @@
#include "code\game\machinery\camera\motion.dm"
#include "code\game\machinery\camera\presets.dm"
#include "code\game\machinery\camera\tracking.dm"
#include "code\game\machinery\camera\wires.dm"
#include "code\game\machinery\computer\ai_core.dm"
#include "code\game\machinery\computer\aifixer.dm"
#include "code\game\machinery\computer\arcade.dm"
@@ -393,6 +398,7 @@
#include "code\game\machinery\doors\checkForMultipleDoors.dm"
#include "code\game\machinery\doors\door.dm"
#include "code\game\machinery\doors\firedoor.dm"
#include "code\game\machinery\doors\firedoor_assembly.dm"
#include "code\game\machinery\doors\multi_tile.dm"
#include "code\game\machinery\doors\poddoor.dm"
#include "code\game\machinery\doors\shutters.dm"
@@ -684,7 +690,6 @@
#include "code\game\turfs\unsimulated\beach.dm"
#include "code\game\turfs\unsimulated\floor.dm"
#include "code\game\turfs\unsimulated\walls.dm"
#include "code\game\verbs\atom_verbs.dm"
#include "code\game\verbs\ooc.dm"
#include "code\game\verbs\suicide.dm"
#include "code\game\verbs\who.dm"
@@ -844,6 +849,7 @@
#include "code\modules\events\disease_outbreak.dm"
#include "code\modules\events\electrical_storm.dm"
#include "code\modules\events\event.dm"
#include "code\modules\events\event_container.dm"
#include "code\modules\events\event_dynamic.dm"
#include "code\modules\events\event_manager.dm"
#include "code\modules\events\grid_check.dm"
@@ -976,7 +982,6 @@
#include "code\modules\mob\living\carbon\human\examine.dm"
#include "code\modules\mob\living\carbon\human\human.dm"
#include "code\modules\mob\living\carbon\human\human_attackhand.dm"
#include "code\modules\mob\living\carbon\human\human_attackpaw.dm"
#include "code\modules\mob\living\carbon\human\human_damage.dm"
#include "code\modules\mob\living\carbon\human\human_defense.dm"
#include "code\modules\mob\living\carbon\human\human_defines.dm"
@@ -1060,7 +1065,6 @@
#include "code\modules\mob\living\silicon\robot\robot_items.dm"
#include "code\modules\mob\living\silicon\robot\robot_modules.dm"
#include "code\modules\mob\living\silicon\robot\robot_movement.dm"
#include "code\modules\mob\living\silicon\robot\wires.dm"
#include "code\modules\mob\living\silicon\robot\drone\drone.dm"
#include "code\modules\mob\living\silicon\robot\drone\drone_abilities.dm"
#include "code\modules\mob\living\silicon\robot\drone\drone_console.dm"
@@ -1128,7 +1132,7 @@
#include "code\modules\organs\wound.dm"
#include "code\modules\paperwork\carbonpaper.dm"
#include "code\modules\paperwork\clipboard.dm"
#include "code\modules\paperwork\faxmachine2.dm"
#include "code\modules\paperwork\faxmachine.dm"
#include "code\modules\paperwork\filingcabinet.dm"
#include "code\modules\paperwork\folders.dm"
#include "code\modules\paperwork\handlabeler.dm"
+1 -1
View File
@@ -3,4 +3,4 @@
MAP_ICON_TYPE: 0
AUTO_FILE_DIR: OFF
*/
// END_INTERNALS
// END_INTERNALS
+7 -2
View File
@@ -67,8 +67,8 @@ var/global/list/pipe_colors = list("grey" = PIPE_COLOR_GREY, "red" = PIPE_COLOR_
return omni_icons[state]
if("underlay")
return underlays[state + dir + color]
//if("underlay_intact")
// return underlays_intact[state + dir + color]
// if("underlay_intact")
// return underlays_intact[state + dir + color]
// if("underlay_exposed")
// return underlays_exposed[state + dir + color]
// if("underlay_down")
@@ -194,6 +194,11 @@ var/global/list/pipe_colors = list("grey" = PIPE_COLOR_GREY, "red" = PIPE_COLOR_
I.color = pipe_colors[pipe_color]
underlays[state + "[D]" + "[pipe_colors[pipe_color]]"] = I
/*
Leaving the old icon manager code commented out for now, as we may want to rewrite the new code to cleanly
separate the newpipe icon caching (speshul supply and scrubber lines) from the rest of the pipe code.
*/
/*
/datum/pipe_icon_manager/proc/gen_underlay_icons()
if(!underlays_intact)
@@ -27,6 +27,8 @@
active_power_usage = 7500 //This also doubles as a measure of how powerful the pump is, in Watts. 7500 W ~ 10 HP
var/last_power_draw = 0
connect_types = list(1,2,3) //connects to regular, supply and scrubbers pipes
var/on = 0
var/pump_direction = 1 //0 = siphoning, 1 = releasing
@@ -62,7 +64,7 @@
return
overlays.Cut()
var/vent_icon = "vent"
var/turf/T = get_turf(src)
@@ -71,7 +73,7 @@
if(T.intact && node1 && node2 && node1.level == 1 && node2.level == 1 && istype(node1, /obj/machinery/atmospherics/pipe) && istype(node2, /obj/machinery/atmospherics/pipe))
vent_icon += "h"
if(!powered())
vent_icon += "off"
else
@@ -88,8 +90,14 @@
if(T.intact && node1 && node2 && node1.level == 1 && node2.level == 1 && istype(node1, /obj/machinery/atmospherics/pipe) && istype(node2, /obj/machinery/atmospherics/pipe))
return
else
add_underlay(T, node1, turn(dir, -180))
add_underlay(T, node2, dir)
if (node1)
add_underlay(T, node1, turn(dir, -180), node1.icon_connect_type)
else
add_underlay(T, node1, turn(dir, -180))
if (node2)
add_underlay(T, node2, dir, node2.icon_connect_type)
else
add_underlay(T, node2, dir)
/obj/machinery/atmospherics/binary/dp_vent_pump/hide(var/i)
update_icon()
@@ -97,7 +105,7 @@
/obj/machinery/atmospherics/binary/dp_vent_pump/process()
..()
if(stat & (NOPOWER|BROKEN) || !on)
update_use_power(0) //usually we get here because a player turned a pump off - definitely want to update.
last_power_draw = 0
@@ -107,19 +115,19 @@
var/datum/gas_mixture/environment = loc.return_air()
var/power_draw = -1
//Figure out the target pressure difference
var/pressure_delta = get_pressure_delta(environment)
if(pressure_delta > 0.5)
if(pump_direction) //internal -> external
if(pump_direction) //internal -> external
if (node1 && (environment.temperature || air1.temperature))
var/output_volume = environment.volume * environment.group_multiplier
var/air_temperature = environment.temperature? environment.temperature : air1.temperature
var/transfer_moles = pressure_delta*output_volume/(air_temperature * R_IDEAL_GAS_EQUATION)
power_draw = pump_gas(src, air1, environment, transfer_moles, active_power_usage)
if(power_draw >= 0 && network1)
network1.update = 1
else //external -> internal
@@ -127,15 +135,15 @@
var/output_volume = air2.volume + (network2? network2.volume : 0)
var/air_temperature = air2.temperature? air2.temperature : environment.temperature
var/transfer_moles = pressure_delta*output_volume/(air_temperature * R_IDEAL_GAS_EQUATION)
//limit flow rate from turfs
transfer_moles = min(transfer_moles, environment.total_moles*air2.volume/environment.volume) //group_multiplier gets divided out here
power_draw = pump_gas(src, environment, air2, transfer_moles, active_power_usage)
if(power_draw >= 0 && network2)
network2.update = 1
if (power_draw < 0)
last_power_draw = 0
last_flow_rate = 0
@@ -149,7 +157,7 @@
/obj/machinery/atmospherics/binary/dp_vent_pump/proc/get_pressure_delta(datum/gas_mixture/environment)
var/pressure_delta = DEFAULT_PRESSURE_DELTA
var/environment_pressure = environment.return_pressure()
if(pump_direction) //internal -> external
if(pressure_checks & PRESSURE_CHECK_EXTERNAL)
pressure_delta = min(pressure_delta, external_pressure_bound - environment_pressure) //increasing the pressure here
@@ -160,9 +168,9 @@
pressure_delta = min(pressure_delta, environment_pressure - external_pressure_bound) //decreasing the pressure here
if(pressure_checks & PRESSURE_CHECK_OUTPUT)
pressure_delta = min(pressure_delta, output_pressure_max - air2.return_pressure()) //increasing the pressure here
return pressure_delta
//Radio remote control
@@ -200,12 +208,10 @@
if(frequency)
set_frequency(frequency)
/obj/machinery/atmospherics/binary/dp_vent_pump/examine()
set src in oview(1)
..()
if (get_dist(usr, src) <= 1)
usr << "A small gauge in the corner reads [round(last_flow_rate, 0.1)] L/s; [round(last_power_draw)] W"
/obj/machinery/atmospherics/binary/dp_vent_pump/examine(mob/user)
if(..(user, 1))
user << "A small gauge in the corner reads [round(last_flow_rate, 0.1)] L/s; [round(last_power_draw)] W"
/obj/machinery/atmospherics/unary/vent_pump/power_change()
var/old_stat = stat
@@ -190,9 +190,11 @@
if(!istype(T))
return
if(T.intact && istype(P.node, /obj/machinery/atmospherics/pipe) && P.node.level == 1 )
pipe_state = icon_manager.get_atmos_icon("underlay_down", P.dir, color_cache_name(P.node))
//pipe_state = icon_manager.get_atmos_icon("underlay_down", P.dir, color_cache_name(P.node))
pipe_state = icon_manager.get_atmos_icon("underlay", P.dir, color_cache_name(P.node), "down")
else
pipe_state = icon_manager.get_atmos_icon("underlay_intact", P.dir, color_cache_name(P.node))
//pipe_state = icon_manager.get_atmos_icon("underlay_intact", P.dir, color_cache_name(P.node))
pipe_state = icon_manager.get_atmos_icon("underlay", P.dir, color_cache_name(P.node), "intact")
return list("on_icon" = ic_on, "off_icon" = ic_off, "pipe_icon" = pipe_state)
-3
View File
@@ -172,9 +172,6 @@
/obj/machinery/atmospherics/tvalve/attack_ai(mob/user as mob)
return
/obj/machinery/atmospherics/tvalve/attack_paw(mob/user as mob)
return attack_hand(user)
/obj/machinery/atmospherics/tvalve/attack_hand(mob/user as mob)
src.add_fingerprint(usr)
update_icon(1)
@@ -65,9 +65,6 @@
/obj/machinery/atmospherics/unary/freezer/attack_ai(mob/user as mob)
src.ui_interact(user)
/obj/machinery/atmospherics/unary/freezer/attack_paw(mob/user as mob)
src.ui_interact(user)
/obj/machinery/atmospherics/unary/freezer/attack_hand(mob/user as mob)
src.ui_interact(user)
@@ -201,7 +198,7 @@
..()
/obj/machinery/atmospherics/unary/freezer/examine()
..()
/obj/machinery/atmospherics/unary/freezer/examine(mob/user)
..(user)
if (opened)
usr << "The maintenance hatch is open."
user << "The maintenance hatch is open."
@@ -18,7 +18,7 @@
use_power = 0
idle_power_usage = 5 //5 Watts for thermostat related circuitry
active_power_usage //50 kW. The power rating of the heater
var/max_power_usage = 20000 //power rating when the usage is turned up to 100
var/power_setting = 100
@@ -35,7 +35,7 @@
component_parts += new /obj/item/weapon/stock_parts/matter_bin(src)
component_parts += new /obj/item/weapon/stock_parts/capacitor(src)
component_parts += new /obj/item/weapon/stock_parts/capacitor(src)
active_power_usage = max_power_usage * (power_setting/100)
/obj/machinery/atmospherics/unary/heater/initialize()
@@ -86,9 +86,6 @@
/obj/machinery/atmospherics/unary/heater/attack_ai(mob/user as mob)
src.ui_interact(user)
/obj/machinery/atmospherics/unary/heater/attack_paw(mob/user as mob)
src.ui_interact(user)
/obj/machinery/atmospherics/unary/heater/attack_hand(mob/user as mob)
src.ui_interact(user)
@@ -164,10 +161,10 @@
/obj/machinery/atmospherics/unary/heater/proc/set_power_level(var/new_power_setting)
power_setting = new_power_setting
var/old_power_usage = active_power_usage
active_power_usage = max_power_usage * (power_setting/100)
if (use_power >= 2 && old_power_usage != active_power_usage)
force_power_update()
@@ -184,7 +181,7 @@
..()
/obj/machinery/atmospherics/unary/heater/examine()
..()
/obj/machinery/atmospherics/unary/heater/examine(mob/user)
..(user)
if (opened)
usr << "The maintenance hatch is open."
user << "The maintenance hatch is open."
@@ -375,15 +375,13 @@
else
..()
/obj/machinery/atmospherics/unary/vent_pump/examine()
set src in oview(1)
..()
if (get_dist(usr, src) <= 1)
usr << "A small gauge in the corner reads [round(last_flow_rate, 0.1)] L/s; [round(last_power_draw)] W"
/obj/machinery/atmospherics/unary/vent_pump/examine(mob/user)
if(..(user, 1))
user << "A small gauge in the corner reads [round(last_flow_rate, 0.1)] L/s; [round(last_power_draw)] W"
else
usr << "You are too far away to read the gauge."
user << "You are too far away to read the gauge."
if(welded)
usr << "It seems welded shut."
user << "It seems welded shut."
/obj/machinery/atmospherics/unary/vent_pump/power_change()
var/old_stat = stat
@@ -1,6 +1,6 @@
/obj/machinery/atmospherics/unary/vent_scrubber
icon = 'icons/atmos/vent_scrubber.dmi'
icon_state = "map_scrubber"
icon_state = "map_scrubber_off"
name = "Air Scrubber"
desc = "Has a valve and pump attached to it"
@@ -30,6 +30,7 @@
/obj/machinery/atmospherics/unary/vent_scrubber/on
on = 1
icon_state = "map_scrubber_on"
/obj/machinery/atmospherics/unary/vent_scrubber/New()
..()
@@ -260,13 +261,11 @@
new /obj/item/pipe(loc, make_from=src)
del(src)
/obj/machinery/atmospherics/unary/vent_scrubber/examine()
set src in oview(1)
..()
if (get_dist(usr, src) <= 1)
usr << "A small gauge in the corner reads [round(last_flow_rate, 0.1)] L/s; [round(last_power_draw)] W"
/obj/machinery/atmospherics/unary/vent_scrubber/examine(mob/user)
if(..(user, 1))
user << "A small gauge in the corner reads [round(last_flow_rate, 0.1)] L/s; [round(last_power_draw)] W"
else
usr << "You are too far away to read the gauge."
user << "You are too far away to read the gauge."
/obj/machinery/atmospherics/unary/vent_scrubber/Del()
if(initial_loc)
-3
View File
@@ -130,9 +130,6 @@
/obj/machinery/atmospherics/valve/attack_ai(mob/user as mob)
return
/obj/machinery/atmospherics/valve/attack_paw(mob/user as mob)
return attack_hand(user)
/obj/machinery/atmospherics/valve/attack_hand(mob/user as mob)
src.add_fingerprint(usr)
update_icon(1)
+22 -20
View File
@@ -6,7 +6,7 @@
var/volume = 0
force = 20
//layer = 2.4 //under wires with their 2.44
layer = 2.4 //under wires with their 2.44
use_power = 0
var/alert_pressure = 80*ONE_ATMOSPHERE
@@ -256,9 +256,9 @@
del(meter)
del(src)
else if(node1 && node2)
overlays += icon_manager.get_atmos_icon("pipe", , pipe_color, "intact" + icon_connect_type)
overlays += icon_manager.get_atmos_icon("pipe", , pipe_color, "[pipe_icon]intact[icon_connect_type]")
else
overlays += icon_manager.get_atmos_icon("pipe", , pipe_color, "exposed[node1?1:0][node2?1:0]" + icon_connect_type)
overlays += icon_manager.get_atmos_icon("pipe", , pipe_color, "[pipe_icon]exposed[node1?1:0][node2?1:0][icon_connect_type]")
/obj/machinery/atmospherics/pipe/simple/update_underlays()
return
@@ -911,29 +911,21 @@
/obj/machinery/atmospherics/pipe/cap
name = "pipe endcap"
desc = "An endcap for pipes"
icon = 'icons/obj/pipes.dmi'
icon_state = "cap"
icon = 'icons/atmos/pipes.dmi'
icon_state = ""
level = 2
layer = 2.4 //under wires with their 2.44
volume = 35
dir = SOUTH
initialize_directions = NORTH
initialize_directions = SOUTH
var/obj/machinery/atmospherics/node
/obj/machinery/atmospherics/pipe/cap/New()
..()
switch(dir)
if(SOUTH)
initialize_directions = NORTH
if(NORTH)
initialize_directions = SOUTH
if(WEST)
initialize_directions = EAST
if(EAST)
initialize_directions = WEST
initialize_directions = dir
/obj/machinery/atmospherics/pipe/cap/hide(var/i)
if(level == 1 && istype(loc, /turf/simulated))
@@ -964,11 +956,20 @@
..()
/obj/machinery/atmospherics/pipe/cap/update_icon()
overlays = new()
/obj/machinery/atmospherics/pipe/cap/change_color(var/new_color)
..()
//for updating connected atmos device pipes (i.e. vents, manifolds, etc)
if(node)
node.update_underlays()
icon_state = "cap[invisibility ? "-f" : ""]"
return
/obj/machinery/atmospherics/pipe/cap/update_icon(var/safety = 0)
if(!check_icon_cache())
return
alpha = 255
overlays.Cut()
overlays += icon_manager.get_atmos_icon("pipe", , pipe_color, "cap")
/obj/machinery/atmospherics/pipe/cap/initialize()
for(var/obj/machinery/atmospherics/target in get_step(src, dir))
@@ -1008,7 +1009,8 @@
/obj/machinery/atmospherics/pipe/cap/hidden
level = 1
icon_state = "cap-f"
icon_state = "cap"
alpha = 128
/obj/machinery/atmospherics/pipe/cap/hidden/scrubbers
name = "scrubbers pipe endcap"
-3
View File
@@ -55,9 +55,6 @@
del target
return ..()
attack_paw(var/mob/M)
return attack_hand(M)
attackby(obj/item/C as obj, mob/user as mob)
(..)
@@ -68,7 +68,7 @@
harm_intent_damage = 8
melee_damage_lower = 15
melee_damage_upper = 15
attacktext = "slashes"
attacktext = "slashed"
attack_sound = 'sound/weapons/bite.ogg'
layer = 3.1 //so they can stay hidde under the /obj/structure/bush
@@ -126,7 +126,7 @@
harm_intent_damage = 2
melee_damage_lower = 3
melee_damage_upper = 10
attacktext = "bites"
attacktext = "bitten"
attack_sound = 'sound/weapons/bite.ogg'
layer = 3.1 //so they can stay hidde under the /obj/structure/bush
+4 -7
View File
@@ -16,12 +16,12 @@
else
return temp_access
/obj/item/weapon/card/id/guest/examine()
..()
/obj/item/weapon/card/id/guest/examine(mob/user)
..(user)
if (world.time < expiration_time)
usr << "<span class='notice'>This pass expires at [worldtime2text(expiration_time)].</span>"
user << "<span class='notice'>This pass expires at [worldtime2text(expiration_time)].</span>"
else
usr << "<span class='warning'>It expired at [worldtime2text(expiration_time)].</span>"
user << "<span class='warning'>It expired at [worldtime2text(expiration_time)].</span>"
/obj/item/weapon/card/id/guest/read()
if (world.time > expiration_time)
@@ -71,9 +71,6 @@
/obj/machinery/computer/guestpass/attack_ai(var/mob/user as mob)
return attack_hand(user)
/obj/machinery/computer/guestpass/attack_paw(var/mob/user as mob)
return attack_hand(user)
/obj/machinery/computer/guestpass/attack_hand(var/mob/user as mob)
if(..())
return
+5 -1
View File
@@ -292,8 +292,12 @@ mob/living/parasite/meme/verb/Agony()
spawn
// backup the host incase we switch hosts after using the verb
var/mob/host = src.host
var/mob/living/carbon/host = src.host
if (host.species && (host.species.flags & NO_PAIN))
usr << "Nothing seems to happen."
return
host.paralysis = max(host.paralysis, 2)
host.flash_weak_pain()
@@ -34,9 +34,6 @@
/obj/machinery/computer/atmoscontrol/attack_ai(var/mob/user as mob)
return interact(user)
/obj/machinery/computer/atmoscontrol/attack_paw(var/mob/user as mob)
return interact(user)
/obj/machinery/computer/atmoscontrol/attack_hand(mob/user)
if(..())
return
+1 -2
View File
@@ -135,8 +135,7 @@
else
breaktape(null, user)
/obj/item/tape/attack_paw(mob/user as mob)
breaktape(/obj/item/weapon/wirecutters,user)
/obj/item/tape/proc/breaktape(obj/item/weapon/W as obj, mob/user as mob)
if(user.a_intent == "help" && ((!can_puncture(W) && src.allowed(user))))
@@ -9,7 +9,6 @@
icon_off = "capsecureoff"
New()
sleep(2)
if(prob(50))
new /obj/item/weapon/storage/backpack/captain(src)
else
@@ -40,7 +39,6 @@
icon_off = "hopsecureoff"
New()
sleep(2)
new /obj/item/clothing/under/rank/head_of_personnel(src)
new /obj/item/clothing/suit/armor/vest(src)
new /obj/item/clothing/head/helmet(src)
@@ -66,7 +64,6 @@
icon_off = "hossecureoff"
New()
sleep(2)
new /obj/item/weapon/storage/backpack/satchel_sec(src)
new /obj/item/weapon/cartridge/hos(src)
new /obj/item/device/radio/headset/heads/hos(src)
@@ -93,7 +90,6 @@
New()
sleep(2)
new /obj/item/weapon/storage/backpack/satchel_sec(src)
new /obj/item/clothing/under/rank/advisor(src)
new /obj/item/device/radio/headset/headset_sec(src)
@@ -118,7 +114,6 @@
icon_off = "secoff"
New()
sleep(2)
new /obj/item/weapon/storage/backpack/satchel_sec(src)
new /obj/item/device/radio/headset/headset_sec(src)
new /obj/item/weapon/storage/belt/security(src)
@@ -141,7 +136,6 @@
icon_off = "cabinetdetective_broken"
New()
sleep(2)
new /obj/item/clothing/under/det(src)
new /obj/item/clothing/suit/armor/det_suit(src)
new /obj/item/clothing/suit/det_suit(src)
@@ -173,7 +167,6 @@
New()
sleep(2)
new /obj/item/weapon/reagent_containers/ld50_syringe/choral(src)
new /obj/item/weapon/reagent_containers/ld50_syringe/choral(src)
return
@@ -197,7 +190,6 @@
req_access = list(access_court)
New()
sleep(2)
new /obj/item/clothing/shoes/brown(src)
new /obj/item/weapon/paper/Court (src)
new /obj/item/weapon/paper/Court (src)
+7 -10
View File
@@ -63,16 +63,13 @@
user.visible_message("\blue [user] gathers up[could_fill ? " " : " most of "]the pile of items and puts it into [src].")
update_icon()
examine()
set src in view()
..()
if(src in usr)
usr << "It claims to contain [contents.len ? descriptor : descriptor + "... but it looks empty"]."
if(seal_torn && !contents.len)
usr << "The seal on the bag is broken."
else
usr << "The seal on the bag is[seal_torn ? ", however, not intact" : " intact"]."
return
examine(mob/user)
..(user)
user << "It claims to contain [contents.len ? descriptor : descriptor + "... but it looks empty"]."
if(seal_torn && !contents.len)
user << "The seal on the bag is broken."
else
user << "The seal on the bag is[seal_torn ? ", however, not intact" : " intact"]."
update_icon()
if(contents.len)
@@ -46,8 +46,7 @@
user << "\blue The pack is already full!"
return
/obj/item/weapon/weldpack/examine()
set src in usr
usr << text("\icon[] [] units of fuel left!", src, src.reagents.total_volume)
..()
/obj/item/weapon/weldpack/examine(mob/user)
..(user)
user << text("\icon[] [] units of fuel left!", src, src.reagents.total_volume)
return
@@ -131,8 +131,6 @@
for(var/typekey in spawn_files)
hdd.addfile(new typekey,1)
if(program)
program.execute(os)
update_icon()
@@ -163,8 +163,10 @@
R.ResetSecurityCodes()
else
message_admins("\blue [key_name_admin(usr)] detonated [R.name]!")
log_game("\blue [key_name_admin(usr)] detonated [R.name]!")
message_admins("<span class='notice'>[key_name_admin(usr)] detonated [key_name(R.name)]!</span>")
log_game("<span class='notice'>[key_name_admin(usr)] detonated [key_name(R.name)]!</span>")
if(R.connected_ai)
R.connected_ai << "<br><br><span class='alert'>ALERT - Cyborg kill-switch activated: [R.name]</span><br>"
R.self_destruct()
else
usr << "\red Access Denied."
@@ -176,16 +178,14 @@
var/choice = input("Are you certain you wish to [R.canmove ? "lock down" : "release"] [R.name]?") in list("Confirm", "Abort")
if(choice == "Confirm")
if(R && istype(R))
message_admins("\blue [key_name_admin(usr)] [R.canmove ? "locked down" : "released"] [R.name]!")
log_game("[key_name(usr)] [R.canmove ? "locked down" : "released"] [R.name]!")
message_admins("<span class='notice'>[key_name_admin(usr)] [R.canmove ? "locked down" : "released"] [R.name]!</span>")
log_game("[key_name(usr)] [R.canmove ? "locked down" : "released"] [key_name(R.name)]!")
R.canmove = !R.canmove
if (R.lockcharge)
// R.cell.charge = R.lockcharge
R.lockcharge = !R.lockcharge
R << "Your lockdown has been lifted!"
else
R.lockcharge = !R.lockcharge
// R.cell.charge = 0
R << "You have been locked down!"
else
+7 -2
View File
@@ -138,6 +138,9 @@
usr << "You can't reach it."
return
close_laptop(usr)
proc/close_laptop(mob/user = null)
if(istype(loc,/obj/item/device/laptop))
testing("Close closed computer")
return
@@ -146,7 +149,8 @@
return
if(stat&BROKEN)
usr << "\The [src] is broken! You can't quite get it closed."
if(user)
user << "\The [src] is broken! You can't quite get it closed."
return
if(!portable)
@@ -157,7 +161,8 @@
portable.loc = loc
loc = portable
stat |= MAINT
usr << "You close \the [src]."
if(user)
user << "You close \the [src]."
auto_use_power()
if(stat&MAINT)
+1 -1
View File
@@ -263,7 +263,7 @@
choose_progs(C)
vend()
popup.close()
newlap.close_computer()
newlap.close_laptop()
newlap = null
cardreader = 0
floppy = 0
+2 -7
View File
@@ -143,10 +143,5 @@ proc/announce_newscaster_news(datum/news_announcement/news)
sendto.is_admin_channel = 1
news_network.network_channels += sendto
var/datum/feed_message/newMsg = new /datum/feed_message
newMsg.author = news.author ? news.author : sendto.author
newMsg.is_admin_message = !news.can_be_redacted
newMsg.body = news.message
newMsg.message_type = news.message_type
news_network.insert_message_in_channel(sendto, newMsg)
var/author = news.author ? news.author : sendto.author
news_network.SubmitArticle(news.message, author, news.channel_name, null, !news.can_be_redacted, news.message_type)
+15
View File
@@ -45,8 +45,20 @@
return heard
/proc/isStationLevel(var/level)
return level in config.station_levels
/proc/isNotStationLevel(var/level)
return !isStationLevel()
/proc/isPlayerLevel(var/level)
return level in config.player_levels
/proc/isAdminLevel(var/level)
return level in config.admin_levels
/proc/isNotAdminLevel(var/level)
return !isAdminLevel(level)
//Magic constants obtained by using linear regression on right-angled triangles of sides 0<x<1, 0<y<1
//They should approximate pythagoras theorem well enough for our needs.
@@ -477,3 +489,6 @@ datum/projectile_data
rstats[i] = environment.vars[stats[i]]
temps[direction] = rstats
return temps
/proc/MinutesToTicks(var/minutes as num)
return minutes * 60 * 10
+5 -1
View File
@@ -116,4 +116,8 @@ var/list/sqrtTable = list(1, 1, 1, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4,
/proc/Wrap(val, min, max)
var/d = max - min
var/t = Floor((val - min) / d)
return val - (t * d)
return val - (t * d)
proc/RaiseToPower(num, power)
if(!power) return 1
return (power-- > 1 ? num * RaiseToPower(num, power) : num)
+18
View File
@@ -97,3 +97,21 @@ proc/RoundHealth(health)
else
return "health-100"
return "0"
/*
Proc for attack log creation, because really why not
1 argument is the actor
2 argument is the target of action
3 is the description of action(like punched, throwed, or any other verb)
4 should it make adminlog note or not
5 is the tool with which the action was made(usually item) 5 and 6 are very similar(5 have "by " before it, that it) and are separated just to keep things in a bit more in order
6 is additional information, anything that needs to be added
*/
/proc/add_logs(mob/user, mob/target, what_done, var/admin=1, var/object=null, var/addition=null)
if(user && ismob(user))
user.attack_log += text("\[[time_stamp()]\] <font color='red'>Has [what_done] [target ? "[target.name][(ismob(target) && target.ckey) ? "([target.ckey])" : ""]" : "NON-EXISTANT SUBJECT"][object ? " with [object]" : " "][addition]</font>")
if(target && ismob(target))
target.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has been [what_done] by [user ? "[user.name][(ismob(user) && user.ckey) ? "([user.ckey])" : ""]" : "NON-EXISTANT SUBJECT"][object ? " with [object]" : " "][addition]</font>")
if(admin)
log_attack("<font color='red'>[user ? "[user.name][(ismob(user) && user.ckey) ? "([user.ckey])" : ""]" : "NON-EXISTANT SUBJECT"] [what_done] [target ? "[target.name][(ismob(target) && target.ckey)? "([target.ckey])" : ""]" : "NON-EXISTANT SUBJECT"][object ? " with [object]" : " "][addition]</font>")
+5 -2
View File
@@ -228,9 +228,12 @@ Turf and target are seperate in case you want to teleport some distance from a t
if (findtext(key, "Guest-", 1, 7) != 1) //was findtextEx
return 0
var/i, ch, len = length(key)
var/i = 7, ch, len = length(key)
for (i = 7, i <= len, ++i)
if(copytext(key, 7, 8) == "W") //webclient
i++
for (, i <= len, ++i)
ch = text2ascii(key, i)
if (ch < 48 || ch > 57)
return 0
+11 -15
View File
@@ -106,9 +106,9 @@
/obj/machinery/door/airlock/AIShiftClick() // Opens and closes doors!
if(density)
Topic("aiEnable=7", list("aiEnable"="7"), 1) // 1 meaning no window (consistency!)
Topic(src, list("src"= "\ref[src]", "aiEnable"="7"), 1) // 1 meaning no window (consistency!)
else
Topic("aiDisable=7", list("aiDisable"="7"), 1)
Topic(src, list("src"= "\ref[src]", "aiDisable"="7"), 1)
return
/atom/proc/AICtrlClick()
@@ -116,17 +116,15 @@
/obj/machinery/door/airlock/AICtrlClick() // Bolts doors
if(locked)
Topic("aiEnable=4", list("aiEnable"="4"), 1)// 1 meaning no window (consistency!)
Topic(src, list("src"= "\ref[src]", "aiEnable"="4"), 1)// 1 meaning no window (consistency!)
else
Topic("aiDisable=4", list("aiDisable"="4"), 1)
Topic(src, list("src"= "\ref[src]", "aiDisable"="4"), 1)
/obj/machinery/power/apc/AICtrlClick() // turns off/on APCs.
Topic("breaker=1", list("breaker"="1"), 1) // 0 meaning window (consistency! wait...)
Topic(src, list("src"= "\ref[src]", "breaker"="1"), 1) // 1 meaning no window (consistency!)
/obj/machinery/turretid/AICtrlClick() //turns off/on Turrets
if(!ailock)
src.enabled = !src.enabled
src.updateTurrets()
Topic(src, list("src"= "\ref[src]", "toggleOn"="1", 1)) // 1 meaning no window (consistency!)
/atom/proc/AIAltClick(var/atom/A)
AltClick(A)
@@ -134,25 +132,23 @@
/obj/machinery/door/airlock/AIAltClick() // Electrifies doors.
if(!secondsElectrified)
// permanent shock
Topic("aiEnable=6", list("aiEnable"="6"), 1) // 1 meaning no window (consistency!)
Topic(src, list("src"= "\ref[src]", "aiEnable"="6"), 1) // 1 meaning no window (consistency!)
else
// disable/6 is not in Topic; disable/5 disables both temporary and permanent shock
Topic("aiDisable=5", list("aiDisable"="5"), 1)
Topic(src, list("src"= "\ref[src]", "aiDisable"="5"), 1)
return
/obj/machinery/turretid/AIAltClick() //toggles lethal on turrets
if(!ailock)
src.lethal = !src.lethal
src.updateTurrets()
Topic(src, list("src"= "\ref[src]", "toggleLethal"="1", 1)) // 1 meaning no window (consistency!)
/atom/proc/AIMiddleClick()
return
/obj/machinery/door/airlock/AIMiddleClick() // Toggles door bolt lights.
if(!src.lights)
Topic("aiEnable=10", list("aiEnable"="10"), 1) // 1 meaning no window (consistency!)
Topic(src, list("src"= "\ref[src]", "aiEnable"="10"), 1) // 1 meaning no window (consistency!)
else
Topic("aiDisable=10", list("aiDisable"="10"), 1)
Topic(src, list("src"= "\ref[src]", "aiDisable"="10"), 1)
return
//
+18 -7
View File
@@ -154,7 +154,6 @@
/mob/proc/DblClickOn(var/atom/A, var/params)
ClickOn(A,params)
/*
Translates into attack_hand, etc.
@@ -168,6 +167,21 @@
/mob/proc/UnarmedAttack(var/atom/A, var/proximity_flag)
return
/mob/living/UnarmedAttack(var/atom/A, var/proximity_flag)
if(!ticker)
src << "You cannot attack people before the game has started."
return 0
if (istype(get_area(src), /area/start))
src << "No attacking people at spawn, you jackass."
return 0
if(stat)
return 0
return 1
/*
Ranged unarmed attack:
@@ -227,8 +241,7 @@
return
/atom/proc/ShiftClick(var/mob/user)
if(user.client && user.client.eye == user)
examine()
user.face_atom(src)
user.examinate(src)
return
/*
@@ -304,7 +317,6 @@
// Simple helper to face what you clicked on, in case it should be needed in more than one place
/mob/proc/face_atom(var/atom/A)
// Snowflake for space vines.
var/is_buckled = 0
if(buckled)
@@ -313,8 +325,7 @@
is_buckled = 1
else
is_buckled = 0
if( stat || is_buckled || !A || !x || !y || !A.x || !A.y ) return
if( is_buckled || !A || !x || !y || !A.x || !A.y || (stat && !isobserver(src))) return
var/dx = A.x - x
var/dy = A.y - y
if(!dx && !dy) return
@@ -326,7 +337,7 @@
else
if(dx > 0) direction = EAST
else direction = WEST
usr.dir = direction
dir = direction
if(buckled && buckled.movable)
buckled.dir = direction
buckled.handle_rotation()
+1 -1
View File
@@ -41,7 +41,7 @@
// Oh by the way this didn't work with old click code which is why clicking shit didn't spam you
/atom/proc/attack_ghost(mob/dead/observer/user as mob)
if(user.client && user.client.inquisitive_ghost)
examine()
user.examinate(src)
return
// ---------------------------------------
+88 -18
View File
@@ -1,3 +1,7 @@
// Generic damage proc (slimes and monkeys).
/atom/proc/attack_generic(mob/user as mob)
return 0
/*
Humans:
Adds an exception for gloves, to allow special glove types like the ninja ones.
@@ -5,15 +9,19 @@
Otherwise pretty standard.
*/
/mob/living/carbon/human/UnarmedAttack(var/atom/A, var/proximity)
var/obj/item/clothing/gloves/G = gloves // not typecast specifically enough in defines
if(!..())
return
// Special glove functions:
// If the gloves do anything, have them return 1 to stop
// normal attack_hand() here.
if(proximity && istype(G) && G.Touch(A,1))
var/obj/item/clothing/gloves/G = gloves // not typecast specifically enough in defines
if(istype(G) && G.Touch(A,1))
return
A.attack_hand(src)
/atom/proc/attack_hand(mob/user as mob)
return
@@ -41,23 +49,20 @@
return
A.attack_tk(src)
/*
Animals & All Unspecified
*/
/mob/living/UnarmedAttack(var/atom/A)
A.attack_animal(src)
/atom/proc/attack_animal(mob/user as mob)
return
/mob/living/RestrainedClickOn(var/atom/A)
return
/*
Monkeys
*/
/mob/living/carbon/monkey/UnarmedAttack(var/atom/A)
A.attack_paw(src)
/atom/proc/attack_paw(mob/user as mob)
return
/mob/living/carbon/monkey/UnarmedAttack(var/atom/A, var/proximity)
if(!..())
return
A.attack_hand(src)
/*
Monkey RestrainedClickOn() was apparently the
@@ -88,26 +93,91 @@
/*
Aliens
Defaults to same as monkey in most places
*/
/mob/living/carbon/alien/RestrainedClickOn(var/atom/A)
return
/mob/living/carbon/alien/UnarmedAttack(var/atom/A, var/proximity)
if(!..())
return 0
A.attack_generic(src,rand(5,6),"bitten")
/*
Slimes
Nothing happening here
*/
/mob/living/carbon/slime/UnarmedAttack(var/atom/A)
A.attack_slime(src)
/atom/proc/attack_slime(mob/user as mob)
return
/mob/living/carbon/slime/RestrainedClickOn(var/atom/A)
return
/mob/living/carbon/slime/UnarmedAttack(var/atom/A, var/proximity)
if(!..())
return
// Eating
if(Victim)
return
// Basic attack.
A.attack_generic(src, (is_adult ? rand(20,40) : rand(5,25)), "glomped")
// Handle mob shocks.
var/mob/living/M = A
if(istype(M) && powerlevel > 0 && !istype(A,/mob/living/carbon/slime))
if(ishuman(M))
var/mob/living/carbon/human/H = M
if(H.species.flags & IS_SYNTHETIC || H.species.insulated)
return
var/power = max(0,min(10,(powerlevel+rand(0,3))))
var/stunprob = 10
switch(power*10)
if(1 to 2) stunprob = 20
if(3 to 4) stunprob = 30
if(5 to 6) stunprob = 40
if(7 to 8) stunprob = 60
if(9) stunprob = 70
if(10) stunprob = 95
if(prob(stunprob))
powerlevel = max(0,powerlevel-3)
src.visible_message("\red <B>The [name] has shocked [M]!</B>")
M.Weaken(power)
M.Stun(power)
if (M.stuttering < power) M.stuttering = power
var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
s.set_up(5, 1, M)
s.start()
if(prob(stunprob) && powerlevel >= 8)
M.adjustFireLoss(powerlevel * rand(6,10))
M.updatehealth()
/*
New Players:
Have no reason to click on anything at all.
*/
/mob/new_player/ClickOn()
return
/*
Animals
*/
/mob/living/simple_animal/UnarmedAttack(var/atom/A, var/proximity)
if(!..())
return
if(melee_damage_upper == 0 && istype(A,/mob/living))
custom_emote(1,"[friendly] [src]!")
return
var/damage = rand(melee_damage_lower, melee_damage_upper)
if(A.attack_generic(src,damage,attacktext,wall_smash) && loc && attack_sound)
playsound(loc, attack_sound, 50, 1, 1)
+36 -1
View File
@@ -75,6 +75,7 @@ Radio:
1341 - death squad
1443 - Confession Intercom
1347 - Cargo techs
1349 - Service people
Devices:
1451 - tracking implant
@@ -109,6 +110,7 @@ var/const/ENG_FREQ = 1357
var/const/SCI_FREQ = 1351
var/const/MED_FREQ = 1355
var/const/SUP_FREQ = 1347
var/const/SRV_FREQ = 1349
var/list/radiochannels = list(
"Common" = PUB_FREQ,
@@ -121,6 +123,7 @@ var/list/radiochannels = list(
"Special Ops" = DTH_FREQ,
"Mercenary" = SYND_FREQ,
"Supply" = SUP_FREQ,
"Service" = SRV_FREQ,
"AI Private" = AI_FREQ
)
@@ -131,11 +134,43 @@ var/list/CENT_FREQS = list(ERT_FREQ, DTH_FREQ)
var/list/ANTAG_FREQS = list(SYND_FREQ)
//depenging helpers
var/list/DEPT_FREQS = list(SCI_FREQ, MED_FREQ, ENG_FREQ, SEC_FREQ, SUP_FREQ, ERT_FREQ, SYND_FREQ, DTH_FREQ)
var/list/DEPT_FREQS = list(SCI_FREQ, MED_FREQ, ENG_FREQ, SEC_FREQ, SUP_FREQ, SRV_FREQ, ERT_FREQ, SYND_FREQ, DTH_FREQ)
#define TRANSMISSION_WIRE 0
#define TRANSMISSION_RADIO 1
/proc/frequency_span_class(var/frequency)
// Antags!
if (frequency in ANTAG_FREQS)
return "syndradio"
// centcomm channels (deathsquid and ert)
else if(frequency in CENT_FREQS)
return "centradio"
// command channel
else if(frequency == COMM_FREQ)
return "comradio"
// AI private channel
else if(frequency == AI_FREQ)
return "airadio"
// department radio formatting (poorly optimized, ugh)
else if(frequency == SEC_FREQ)
return "secradio"
else if (frequency == ENG_FREQ)
return "engradio"
else if(frequency == SCI_FREQ)
return "sciradio"
else if(frequency == MED_FREQ)
return "medradio"
else if(frequency == SUP_FREQ) // cargo
return "supradio"
else if(frequency == SRV_FREQ) // service
return "srvradio"
// If all else fails and it's a dept_freq, color me purple!
else if(frequency in DEPT_FREQS)
return "deptradio"
return "radio"
/* filters */
//When devices register with the radio controller, they might register under a certain filter.
//Other devices can then choose to send signals to only those devices that belong to a particular filter.
+44
View File
@@ -152,9 +152,23 @@
var/use_overmap = 0
var/list/station_levels = list(1) // Defines which Z-levels the station exists on.
var/list/admin_levels= list(2) // Defines which Z-levels which are for admin functionality, for example including such areas as Central Command and the Syndicate Shuttle
var/list/contact_levels = list(1, 5) // Defines which Z-levels which, for example, a Code Red announcement may affect
var/list/player_levels = list(1, 3, 4, 5, 6) // Defines all Z-levels a character can typically reach
// Event settings
var/expected_round_length = 3 * 60 * 60 * 10 // 3 hours
// If the first delay has a custom start time
// No custom time, no custom time, between 80 to 100 minutes respectively.
var/list/event_first_run = list(EVENT_LEVEL_MUNDANE = null, EVENT_LEVEL_MODERATE = null, EVENT_LEVEL_MAJOR = list("lower" = 48000, "upper" = 60000))
// The lowest delay until next event
// 10, 30, 50 minutes respectively
var/list/event_delay_lower = list(EVENT_LEVEL_MUNDANE = 6000, EVENT_LEVEL_MODERATE = 18000, EVENT_LEVEL_MAJOR = 30000)
// The upper delay until next event
// 15, 45, 70 minutes respectively
var/list/event_delay_upper = list(EVENT_LEVEL_MUNDANE = 9000, EVENT_LEVEL_MODERATE = 27000, EVENT_LEVEL_MAJOR = 42000)
/datum/configuration/New()
var/list/L = typesof(/datum/game_mode) - /datum/game_mode
for (var/T in L)
@@ -518,12 +532,42 @@
if("station_levels")
config.station_levels = text2numlist(value, ";")
if("admin_levels")
config.admin_levels = text2numlist(value, ";")
if("contact_levels")
config.contact_levels = text2numlist(value, ";")
if("player_levels")
config.player_levels = text2numlist(value, ";")
if("expected_round_length")
config.expected_round_length = MinutesToTicks(text2num(value))
if("event_custom_start_mundane")
var/values = text2numlist(value, ";")
config.event_first_run[EVENT_LEVEL_MUNDANE] = list("lower" = MinutesToTicks(values[1]), "upper" = MinutesToTicks(values[2]))
if("event_custom_start_moderate")
var/values = text2numlist(value, ";")
config.event_first_run[EVENT_LEVEL_MODERATE] = list("lower" = MinutesToTicks(values[1]), "upper" = MinutesToTicks(values[2]))
if("event_custom_start_major")
var/values = text2numlist(value, ";")
config.event_first_run[EVENT_LEVEL_MAJOR] = list("lower" = MinutesToTicks(values[1]), "upper" = MinutesToTicks(values[2]))
if("event_delay_lower")
var/values = text2numlist(value, ";")
config.event_delay_lower[EVENT_LEVEL_MUNDANE] = MinutesToTicks(values[1])
config.event_delay_lower[EVENT_LEVEL_MODERATE] = MinutesToTicks(values[2])
config.event_delay_lower[EVENT_LEVEL_MAJOR] = MinutesToTicks(values[3])
if("event_delay_upper")
var/values = text2numlist(value, ";")
config.event_delay_upper[EVENT_LEVEL_MUNDANE] = MinutesToTicks(values[1])
config.event_delay_upper[EVENT_LEVEL_MODERATE] = MinutesToTicks(values[2])
config.event_delay_upper[EVENT_LEVEL_MAJOR] = MinutesToTicks(values[3])
else
log_misc("Unknown setting in configuration: '[name]'")
+2 -9
View File
@@ -360,6 +360,7 @@ datum/controller/game_controller/proc/process_pipenets()
Powernet.reset()
datum/controller/game_controller/proc/process_nano()
last_thing_processed = /datum/nanoui
var/i = 1
while(i<=nanomanager.processing_uis.len)
var/datum/nanoui/ui = nanomanager.processing_uis[i]
@@ -371,15 +372,7 @@ datum/controller/game_controller/proc/process_nano()
datum/controller/game_controller/proc/process_events()
last_thing_processed = /datum/event
var/i = 1
while(i<=events.len)
var/datum/event/Event = events[i]
if(Event)
Event.process()
i++
continue
events.Cut(i,i+1)
checkEvent()
event_manager.process()
datum/controller/game_controller/proc/Recover() //Mostly a placeholder for now.
var/msg = "## DEBUG: [time2text(world.timeofday)] MC restarted. Reports:\n"
+5 -2
View File
@@ -48,7 +48,7 @@
message_admins("Admin [key_name_admin(usr)] has restarted the [controller] controller.")
return
/client/proc/debug_controller(controller in list("Master","Failsafe","Ticker","Lighting","Air","Jobs","Sun","Radio","Supply","Shuttles","Emergency Shuttle","Configuration","pAI", "Cameras", "Transfer Controller", "Gas Data"))
/client/proc/debug_controller(controller in list("Master","Failsafe","Ticker","Lighting","Air","Jobs","Sun","Radio","Supply","Shuttles","Emergency Shuttle","Configuration","pAI", "Cameras", "Transfer Controller", "Gas Data","Event"))
set category = "Debug"
set name = "Debug Controller"
set desc = "Debug the various periodic loop controllers for the game (be careful!)"
@@ -102,6 +102,9 @@
feedback_add_details("admin_verb","DAutovoter")
if("Gas Data")
debug_variables(gas_data)
feedback_add_details("admin_verv","DGasdata")
feedback_add_details("admin_verb","DGasdata")
if("Event")
debug_variables(event_manager)
feedback_add_details("admin_verb", "DEvent")
message_admins("Admin [key_name_admin(usr)] is debugging the [controller] controller.")
return
+2 -2
View File
@@ -290,9 +290,9 @@ datum/controller/vote
var/admin = 0
var/trialmin = 0
if(C.holder)
admin = 1
if(C.holder.rights & R_ADMIN)
trialmin = 1
admin = 1
trialmin = 1 // don't know why we use both of these it's really weird, but I'm 2 lasy to refactor this all to use just admin.
voting |= C
. = "<html><head><title>Voting Panel</title></head><body>"
+3 -3
View File
@@ -450,7 +450,7 @@ var/list/all_supply_groups = list("Operations","Security","Hospitality","Enginee
containertype = /obj/structure/closet/crate
containername = "Wooden planks crate"
group = "Engineering"
/datum/supply_packs/plastic50
name = "50 plastic sheets"
contains = list(/obj/item/stack/sheet/mineral/plastic)
@@ -980,7 +980,7 @@ var/list/all_supply_groups = list("Operations","Security","Hospitality","Enginee
/obj/item/clothing/under/rank/mailman,
/obj/item/clothing/under/dress/dress_saloon,
/obj/item/clothing/suit/suspenders,
/obj/item/clothing/suit/storage/labcoat/mad,
/obj/item/clothing/suit/storage/toggle/labcoat/mad,
/obj/item/clothing/suit/bio_suit/plaguedoctorsuit,
/obj/item/clothing/under/schoolgirl,
/obj/item/clothing/under/owl,
@@ -1003,7 +1003,7 @@ var/list/all_supply_groups = list("Operations","Security","Hospitality","Enginee
/datum/supply_packs/formal_wear
contains = list(/obj/item/clothing/head/bowler,
/obj/item/clothing/head/that,
/obj/item/clothing/suit/storage/lawyer/bluejacket,
/obj/item/clothing/suit/storage/toggle/lawyer/bluejacket,
/obj/item/clothing/suit/storage/lawyer/purpjacket,
/obj/item/clothing/under/suit_jacket,
/obj/item/clothing/under/suit_jacket/female,
+195
View File
@@ -0,0 +1,195 @@
// Wires for airlocks
/datum/wires/airlock/secure
random = 1
wire_count = 14
/datum/wires/airlock
holder_type = /obj/machinery/door/airlock
wire_count = 12
window_y = 570
var/const/AIRLOCK_WIRE_IDSCAN = 1
var/const/AIRLOCK_WIRE_MAIN_POWER1 = 2
var/const/AIRLOCK_WIRE_MAIN_POWER2 = 4
var/const/AIRLOCK_WIRE_DOOR_BOLTS = 8
var/const/AIRLOCK_WIRE_BACKUP_POWER1 = 16
var/const/AIRLOCK_WIRE_BACKUP_POWER2 = 32
var/const/AIRLOCK_WIRE_OPEN_DOOR = 64
var/const/AIRLOCK_WIRE_AI_CONTROL = 128
var/const/AIRLOCK_WIRE_ELECTRIFY = 256
var/const/AIRLOCK_WIRE_SAFETY = 512
var/const/AIRLOCK_WIRE_SPEED = 1024
var/const/AIRLOCK_WIRE_LIGHT = 2048
/datum/wires/airlock/CanUse(var/mob/living/L)
var/obj/machinery/door/airlock/A = holder
if(!istype(L, /mob/living/silicon))
if(A.isElectrified())
if(A.shock(L, 100))
return 0
if(A.p_open)
return 1
return 0
/datum/wires/airlock/GetInteractWindow()
var/obj/machinery/door/airlock/A = holder
. += ..()
. += text("<br>\n[]<br>\n[]<br>\n[]<br>\n[]<br>\n[]<br>\n[]<br>\n[]", (A.locked ? "The door bolts have fallen!" : "The door bolts look up."),
(A.lights ? "The door bolt lights are on." : "The door bolt lights are off!"),
((A.hasPower()) ? "The test light is on." : "The test light is off!"),
((A.aiControlDisabled==0 && !A.emagged) ? "The 'AI control allowed' light is on." : "The 'AI control allowed' light is off."),
(A.safe==0 ? "The 'Check Wiring' light is on." : "The 'Check Wiring' light is off."),
(A.normalspeed==0 ? "The 'Check Timing Mechanism' light is on." : "The 'Check Timing Mechanism' light is off."),
(A.aiDisabledIdScanner==0 ? "The IDScan light is on." : "The IDScan light is off."))
/datum/wires/airlock/UpdateCut(var/index, var/mended)
var/obj/machinery/door/airlock/A = holder
switch(index)
if(AIRLOCK_WIRE_IDSCAN)
A.aiDisabledIdScanner = !mended
if(AIRLOCK_WIRE_MAIN_POWER1, AIRLOCK_WIRE_MAIN_POWER2)
if(!mended)
//Cutting either one disables the main door power, but unless backup power is also cut, the backup power re-powers the door in 10 seconds. While unpowered, the door may be crowbarred open, but bolts-raising will not work. Cutting these wires may electocute the user.
A.loseMainPower()
A.shock(usr, 50)
else
if((!IsIndexCut(AIRLOCK_WIRE_MAIN_POWER1)) && (!IsIndexCut(AIRLOCK_WIRE_MAIN_POWER2)))
A.regainMainPower()
A.shock(usr, 50)
if(AIRLOCK_WIRE_BACKUP_POWER1, AIRLOCK_WIRE_BACKUP_POWER2)
if(!mended)
//Cutting either one disables the backup door power (allowing it to be crowbarred open, but disabling bolts-raising), but may electocute the user.
A.loseBackupPower()
A.shock(usr, 50)
else
if((!IsIndexCut(AIRLOCK_WIRE_BACKUP_POWER1)) && (!IsIndexCut(AIRLOCK_WIRE_BACKUP_POWER2)))
A.regainBackupPower()
A.shock(usr, 50)
if(AIRLOCK_WIRE_DOOR_BOLTS)
if(!mended)
//Cutting this wire also drops the door bolts, and mending it does not raise them. (This is what happens now, except there are a lot more wires going to door bolts at present)
if(A.locked!=1)
A.locked = 1
A.update_icon()
if(AIRLOCK_WIRE_AI_CONTROL)
if(!mended)
//one wire for AI control. Cutting this prevents the AI from controlling the door unless it has hacked the door through the power connection (which takes about a minute). If both main and backup power are cut, as well as this wire, then the AI cannot operate or hack the door at all.
//aiControlDisabled: If 1, AI control is disabled until the AI hacks back in and disables the lock. If 2, the AI has bypassed the lock. If -1, the control is enabled but the AI had bypassed it earlier, so if it is disabled again the AI would have no trouble getting back in.
if(A.aiControlDisabled == 0)
A.aiControlDisabled = 1
else if(A.aiControlDisabled == -1)
A.aiControlDisabled = 2
else
if(A.aiControlDisabled == 1)
A.aiControlDisabled = 0
else if(A.aiControlDisabled == 2)
A.aiControlDisabled = -1
if(AIRLOCK_WIRE_ELECTRIFY)
if(!mended)
//Cutting this wire electrifies the door, so that the next person to touch the door without insulated gloves gets electrocuted.
if(A.secondsElectrified != -1)
A.shockedby += text("\[[time_stamp()]\][usr](ckey:[usr.ckey])")
add_logs(usr, A, "electrified", admin=0, addition="at [A.x],[A.y],[A.z]")
A.secondsElectrified = -1
else
if(A.secondsElectrified == -1)
A.secondsElectrified = 0
return // Don't update the dialog.
if (AIRLOCK_WIRE_SAFETY)
A.safe = mended
if(AIRLOCK_WIRE_SPEED)
A.autoclose = mended
if(mended)
if(!A.density)
A.close()
if(AIRLOCK_WIRE_LIGHT)
A.lights = mended
A.update_icon()
/datum/wires/airlock/UpdatePulsed(var/index)
var/obj/machinery/door/airlock/A = holder
switch(index)
if(AIRLOCK_WIRE_IDSCAN)
//Sending a pulse through flashes the red light on the door (if the door has power).
if(A.hasPower() && A.density)
A.do_animate("deny")
if(AIRLOCK_WIRE_MAIN_POWER1 || AIRLOCK_WIRE_MAIN_POWER2)
//Sending a pulse through either one causes a breaker to trip, disabling the door for 10 seconds if backup power is connected, or 1 minute if not (or until backup power comes back on, whichever is shorter).
A.loseMainPower()
if(AIRLOCK_WIRE_DOOR_BOLTS)
//one wire for door bolts. Sending a pulse through this drops door bolts if they're not down (whether power's on or not),
//raises them if they are down (only if power's on)
if(!A.locked)
A.locked = 1
A.audible_message("You hear a click from the bottom of the door.", null, 1)
else
if(A.hasPower()) //only can raise bolts if power's on
A.locked = 0
A.audible_message("You hear a click from the bottom of the door.", null, 1)
A.update_icon()
if(AIRLOCK_WIRE_BACKUP_POWER1 || AIRLOCK_WIRE_BACKUP_POWER2)
//two wires for backup power. Sending a pulse through either one causes a breaker to trip, but this does not disable it unless main power is down too (in which case it is disabled for 1 minute or however long it takes main power to come back, whichever is shorter).
A.loseBackupPower()
if(AIRLOCK_WIRE_AI_CONTROL)
if(A.aiControlDisabled == 0)
A.aiControlDisabled = 1
else if(A.aiControlDisabled == -1)
A.aiControlDisabled = 2
spawn(10)
if(A)
if(A.aiControlDisabled == 1)
A.aiControlDisabled = 0
else if(A.aiControlDisabled == 2)
A.aiControlDisabled = -1
if(AIRLOCK_WIRE_ELECTRIFY)
//one wire for electrifying the door. Sending a pulse through this electrifies the door for 30 seconds.
if(A.secondsElectrified==0)
A.shockedby += text("\[[time_stamp()]\][usr](ckey:[usr.ckey])")
add_logs(usr, A, "electrified", admin=0, addition="at [A.x],[A.y],[A.z]")
A.secondsElectrified = 30
spawn(10)
if(A)
//TODO: Move this into process() and make pulsing reset secondsElectrified to 30
while (A.secondsElectrified>0)
A.secondsElectrified-=1
if(A.secondsElectrified<0)
A.secondsElectrified = 0
sleep(10)
return
if(AIRLOCK_WIRE_OPEN_DOOR)
//tries to open the door without ID
//will succeed only if the ID wire is cut or the door requires no access and it's not emagged
if(A.emagged) return
if(!A.requiresID() || A.check_access(null))
if(A.density) A.open()
else A.close()
if(AIRLOCK_WIRE_SAFETY)
A.safe = !A.safe
if(!A.density)
A.close()
if(AIRLOCK_WIRE_SPEED)
A.normalspeed = !A.normalspeed
if(AIRLOCK_WIRE_LIGHT)
A.lights = !A.lights
A.update_icon()
+93
View File
@@ -0,0 +1,93 @@
/datum/wires/alarm
holder_type = /obj/machinery/alarm
wire_count = 5
var/const/AALARM_WIRE_IDSCAN = 1
var/const/AALARM_WIRE_POWER = 2
var/const/AALARM_WIRE_SYPHON = 4
var/const/AALARM_WIRE_AI_CONTROL = 8
var/const/AALARM_WIRE_AALARM = 16
/datum/wires/alarm/CanUse(var/mob/living/L)
var/obj/machinery/alarm/A = holder
if(A.wiresexposed)
return 1
return 0
/datum/wires/alarm/GetInteractWindow()
var/obj/machinery/alarm/A = holder
. += ..()
. += text("<br>\n[(A.locked ? "The Air Alarm is locked." : "The Air Alarm is unlocked.")]<br>\n[((A.shorted || (A.stat & (NOPOWER|BROKEN))) ? "The Air Alarm is offline." : "The Air Alarm is working properly!")]<br>\n[(A.aidisabled ? "The 'AI control allowed' light is off." : "The 'AI control allowed' light is on.")]")
/datum/wires/alarm/UpdateCut(var/index, var/mended)
var/obj/machinery/alarm/A = holder
switch(index)
if(AALARM_WIRE_IDSCAN)
if(!mended)
A.locked = 1
//world << "Idscan wire cut"
if(AALARM_WIRE_POWER)
A.shock(usr, 50)
A.shorted = !mended
A.update_icon()
//world << "Power wire cut"
if (AALARM_WIRE_AI_CONTROL)
if (A.aidisabled == !mended)
A.aidisabled = mended
//world << "AI Control Wire Cut"
if(AALARM_WIRE_SYPHON)
if(!mended)
A.mode = 3 // AALARM_MODE_PANIC
A.apply_mode()
//world << "Syphon Wire Cut"
if(AALARM_WIRE_AALARM)
if (A.alarm_area.atmosalert(2))
A.post_alert(2)
A.update_icon()
/datum/wires/alarm/UpdatePulsed(var/index)
var/obj/machinery/alarm/A = holder
switch(index)
if(AALARM_WIRE_IDSCAN)
A.locked = !A.locked
// world << "Idscan wire pulsed"
if (AALARM_WIRE_POWER)
// world << "Power wire pulsed"
if(A.shorted == 0)
A.shorted = 1
A.update_icon()
spawn(12000)
if(A.shorted == 1)
A.shorted = 0
A.update_icon()
if (AALARM_WIRE_AI_CONTROL)
// world << "AI Control wire pulsed"
if (A.aidisabled == 0)
A.aidisabled = 1
A.updateDialog()
spawn(100)
if (A.aidisabled == 1)
A.aidisabled = 0
if(AALARM_WIRE_SYPHON)
// world << "Syphon wire pulsed"
if(A.mode == 1) // AALARM_MODE_SCRUB
A.mode = 3 // AALARM_MODE_PANIC
else
A.mode = 1 // AALARM_MODE_SCRUB
A.apply_mode()
if(AALARM_WIRE_AALARM)
// world << "Aalarm wire pulsed"
if (A.alarm_area.atmosalert(0))
A.post_alert(0)
A.update_icon()
+4 -10
View File
@@ -2,10 +2,10 @@
holder_type = /obj/machinery/power/apc
wire_count = 4
var/const/APC_WIRE_IDSCAN = 1
var/const/APC_WIRE_MAIN_POWER1 = 2
var/const/APC_WIRE_MAIN_POWER2 = 4
var/const/APC_WIRE_AI_CONTROL = 8
#define APC_WIRE_IDSCAN 1
#define APC_WIRE_MAIN_POWER1 2
#define APC_WIRE_MAIN_POWER2 4
#define APC_WIRE_AI_CONTROL 8
/datum/wires/apc/GetInteractWindow()
var/obj/machinery/power/apc/A = holder
@@ -31,7 +31,6 @@ var/const/APC_WIRE_AI_CONTROL = 8
spawn(300)
if(A)
A.locked = 1
A.updateDialog()
if (APC_WIRE_MAIN_POWER1, APC_WIRE_MAIN_POWER2)
if(A.shorted == 0)
@@ -40,7 +39,6 @@ var/const/APC_WIRE_AI_CONTROL = 8
spawn(1200)
if(A && !IsIndexCut(APC_WIRE_MAIN_POWER1) && !IsIndexCut(APC_WIRE_MAIN_POWER2))
A.shorted = 0
A.updateDialog()
if (APC_WIRE_AI_CONTROL)
if (A.aidisabled == 0)
@@ -49,9 +47,6 @@ var/const/APC_WIRE_AI_CONTROL = 8
spawn(10)
if(A && !IsIndexCut(APC_WIRE_AI_CONTROL))
A.aidisabled = 0
A.updateDialog()
A.updateDialog()
/datum/wires/apc/UpdateCut(var/index, var/mended)
var/obj/machinery/power/apc/A = holder
@@ -75,4 +70,3 @@ var/const/APC_WIRE_AI_CONTROL = 8
else
if (A.aidisabled == 1)
A.aidisabled = 0
A.updateDialog()
+74
View File
@@ -0,0 +1,74 @@
// Wires for cameras.
/datum/wires/camera
random = 1
holder_type = /obj/machinery/camera
wire_count = 6
/datum/wires/camera/GetInteractWindow()
. = ..()
var/obj/machinery/camera/C = holder
. += "<br>\n[(C.view_range == initial(C.view_range) ? "The focus light is on." : "The focus light is off.")]"
. += "<br>\n[(C.can_use() ? "The power link light is on." : "The power link light is off.")]"
. += "<br>\n[(C.light_disabled ? "The camera light is off." : "The camera light is on.")]"
. += "<br>\n[(C.alarm_on ? "The alarm light is on." : "The alarm light is off.")]"
return .
/datum/wires/camera/CanUse(var/mob/living/L)
var/obj/machinery/camera/C = holder
return C.panel_open
var/const/CAMERA_WIRE_FOCUS = 1
var/const/CAMERA_WIRE_POWER = 2
var/const/CAMERA_WIRE_LIGHT = 4
var/const/CAMERA_WIRE_ALARM = 8
var/const/CAMERA_WIRE_NOTHING1 = 16
var/const/CAMERA_WIRE_NOTHING2 = 32
/datum/wires/camera/UpdateCut(var/index, var/mended)
var/obj/machinery/camera/C = holder
switch(index)
if(CAMERA_WIRE_FOCUS)
var/range = (mended ? initial(C.view_range) : C.short_range)
C.setViewRange(range)
if(CAMERA_WIRE_POWER)
if(C.status && !mended || !C.status && mended)
C.deactivate(usr, 1)
if(CAMERA_WIRE_LIGHT)
C.light_disabled = !mended
if(CAMERA_WIRE_ALARM)
if(!mended)
C.triggerCameraAlarm()
else
C.cancelCameraAlarm()
return
/datum/wires/camera/UpdatePulsed(var/index)
var/obj/machinery/camera/C = holder
if(IsIndexCut(index))
return
switch(index)
if(CAMERA_WIRE_FOCUS)
var/new_range = (C.view_range == initial(C.view_range) ? C.short_range : initial(C.view_range))
C.setViewRange(new_range)
if(CAMERA_WIRE_POWER)
C.deactivate(null) // Deactivate the camera
if(CAMERA_WIRE_LIGHT)
C.light_disabled = !C.light_disabled
if(CAMERA_WIRE_ALARM)
C.visible_message("\icon[C] *beep*", "\icon[C] *beep*")
return
/datum/wires/camera/proc/CanDeconstruct()
if(IsIndexCut(CAMERA_WIRE_POWER) && IsIndexCut(CAMERA_WIRE_FOCUS) && IsIndexCut(CAMERA_WIRE_LIGHT) && IsIndexCut(CAMERA_WIRE_NOTHING1) && IsIndexCut(CAMERA_WIRE_NOTHING2))
return 1
else
return 0
+103
View File
@@ -0,0 +1,103 @@
/datum/wires/robot
random = 1
holder_type = /mob/living/silicon/robot
wire_count = 5
var/const/BORG_WIRE_LAWCHECK = 1
var/const/BORG_WIRE_MAIN_POWER = 2 // The power wires do nothing whyyyyyyyyyyyyy
var/const/BORG_WIRE_LOCKED_DOWN = 4
var/const/BORG_WIRE_AI_CONTROL = 8
var/const/BORG_WIRE_CAMERA = 16
/datum/wires/robot/GetInteractWindow()
. = ..()
var/mob/living/silicon/robot/R = holder
. += text("<br>\n[(R.lawupdate ? "The LawSync light is on." : "The LawSync light is off.")]")
. += text("<br>\n[(R.connected_ai ? "The AI link light is on." : "The AI link light is off.")]")
. += text("<br>\n[((!isnull(R.camera) && R.camera.status == 1) ? "The Camera light is on." : "The Camera light is off.")]")
. += text("<br>\n[(R.lockcharge ? "The lockdown light is on." : "The lockdown light is off.")]")
return .
/datum/wires/robot/UpdateCut(var/index, var/mended)
var/mob/living/silicon/robot/R = holder
switch(index)
if(BORG_WIRE_LAWCHECK) //Cut the law wire, and the borg will no longer receive law updates from its AI
if(!mended)
if (R.lawupdate == 1)
R << "LawSync protocol engaged."
R.show_laws()
else
if (R.lawupdate == 0 && !R.emagged)
R.lawupdate = 1
if (BORG_WIRE_AI_CONTROL) //Cut the AI wire to reset AI control
if(!mended)
if (R.connected_ai)
R.connected_ai = null
if (BORG_WIRE_CAMERA)
if(!isnull(R.camera) && !R.scrambledcodes)
R.camera.status = mended
R.camera.deactivate(usr, 0) // Will kick anyone who is watching the Cyborg's camera.
if(BORG_WIRE_LAWCHECK) //Forces a law update if the borg is set to receive them. Since an update would happen when the borg checks its laws anyway, not much use, but eh
if (R.lawupdate)
R.lawsync()
if(BORG_WIRE_LOCKED_DOWN)
R.SetLockdown(!mended)
/datum/wires/robot/UpdatePulsed(var/index)
var/mob/living/silicon/robot/R = holder
switch(index)
if (BORG_WIRE_AI_CONTROL) //pulse the AI wire to make the borg reselect an AI
if(!R.emagged)
var/new_ai = select_active_ai(R)
if(new_ai && (new_ai != R.connected_ai))
R.connected_ai = new_ai
R.notify_ai(1)
var/numberer = 1 // Send images the Cyborg has taken to the AI's album upon sync.
for(var/datum/picture/z in R.aiCamera.aipictures)
if(R.connected_ai.aiCamera.aipictures.len == 0)
var/datum/picture/p = new/datum/picture()
p = z
p.fields["name"] = "Uploaded Image [numberer] (synced from [R.name])"
R.connected_ai.aiCamera.aipictures += p
numberer++
continue
for(var/datum/picture/t in R.connected_ai.aiCamera.aipictures) //Hopefully to prevent someone spamming images to silicons, by spamming this wire
if((z.fields["pixel_y"] != t.fields["pixel_y"]) && (z.fields["pixel_x"] != t.fields["pixel_x"])) //~2.26 out of 1000 chance this will stop something it shouldn't
var/datum/picture/p = new/datum/picture()
p = z
p.fields["name"] = "Uploaded Image [numberer] (synced from [R.name])"
R.connected_ai.aiCamera.aipictures += p
else
continue
numberer++
if(R.aiCamera.aipictures.len > 0)
R << "<span class='notice'>Locally saved images synced with AI. Images were retained in local database in case of loss of connection with the AI.</span>"
if (BORG_WIRE_CAMERA)
if(!isnull(R.camera) && R.camera.can_use() && !R.scrambledcodes)
R.camera.deactivate(usr, 0) // Kick anyone watching the Cyborg's camera, doesn't display you disconnecting the camera.
R.visible_message("[R]'s camera lense focuses loudly.")
R << "Your camera lense focuses loudly."
if(BORG_WIRE_LOCKED_DOWN)
R.SetLockdown(!R.lockcharge) // Toggle
/datum/wires/robot/CanUse(var/mob/living/L)
var/mob/living/silicon/robot/R = holder
if(R.wiresexposed)
return 1
return 0
/datum/wires/robot/proc/IsCameraCut()
return wires_status & BORG_WIRE_CAMERA
/datum/wires/robot/proc/LockedCut()
return wires_status & BORG_WIRE_LOCKED_DOWN
+4 -5
View File
@@ -2,6 +2,10 @@
holder_type = /obj/machinery/smartfridge
wire_count = 3
/datum/wires/smartfridge/secure
random = 1
wire_count = 4
var/const/SMARTFRIDGE_WIRE_ELECTRIFY = 1
var/const/SMARTFRIDGE_WIRE_THROW = 2
var/const/SMARTFRIDGE_WIRE_IDSCAN = 4
@@ -16,11 +20,6 @@ var/const/SMARTFRIDGE_WIRE_IDSCAN = 4
return 1
return 0
/datum/wires/smartfridge/Interact(var/mob/living/user)
if(CanUse(user))
var/obj/machinery/smartfridge/S = holder
S.attack_hand(user)
/datum/wires/smartfridge/GetInteractWindow()
var/obj/machinery/smartfridge/S = holder
. += ..()
-5
View File
@@ -16,11 +16,6 @@ var/const/SUIT_STORAGE_WIRE_LOCKED = 4
return 1
return 0
/datum/wires/suit_storage_unit/Interact(var/mob/living/user)
if(CanUse(user))
var/obj/machinery/suit_cycler/S = holder
S.attack_hand(user)
/datum/wires/suit_storage_unit/GetInteractWindow()
var/obj/machinery/suit_cycler/S = holder
. += ..()
+2 -2
View File
@@ -6,8 +6,8 @@
#define MAX_FLAG 65535
var/list/same_wires = list()
// 12 colours, if you're adding more than 12 wires then add more colours here
var/list/wireColours = list("red", "blue", "green", "black", "orange", "brown", "gold", "gray", "cyan", "navy", "purple", "pink")
// 14 colours, if you're adding more than 14 wires then add more colours here
var/list/wireColours = list("red", "blue", "green", "white", "orange", "brown", "gold", "gray", "cyan", "navy", "purple", "pink", "black", "yellow")
/datum/wires
+4
View File
@@ -1,3 +1,7 @@
proc/log_and_message_admins(var/message as text)
log_admin("[usr]([usr.ckey]) " + message)
message_admins("[usr]([usr.ckey]) " + message)
proc/admin_log_and_message_admins(var/message as text)
log_admin("[key_name(usr)] " + message)
message_admins("[key_name_admin(usr)] " + message, 1)
+1 -1
View File
@@ -7,7 +7,7 @@
var/log = 0
var/sound
var/newscast = 0
var/channel_name = "Public Station Announcements"
var/channel_name = "Station Announcements"
var/announcement_type = "Announcement"
/datum/announcement/New(var/do_log = 0, var/new_sound = null, var/do_newscast = 0)
+4 -5
View File
@@ -51,27 +51,26 @@
return TELECOMMS_RECEPTION_RECEIVER
return TELECOMMS_RECEPTION_NONE
/proc/get_reception(var/atom/sender, var/receiver, var/message = "")
/proc/get_reception(var/atom/sender, var/receiver, var/message = "", var/do_sleep = 1)
var/datum/reception/reception = new
// check if telecomms I/O route 1459 is stable
//var/telecomms_intact = telecomms_process(P.owner, owner, t)
reception.message_server = get_message_server()
var/datum/signal/signal = sender.telecomms_process() // Be aware that this proc calls sleep, to simulate transmition delays
var/datum/signal/signal = sender.telecomms_process(do_sleep) // Be aware that this proc calls sleep, to simulate transmition delays
reception.telecomms_reception |= get_sender_reception(sender, signal)
reception.telecomms_reception |= get_receiver_reception(receiver, signal)
reception.message = signal && signal.data["compression"] > 0 ? Gibberish(message, signal.data["compression"] + 50) : message
return reception
/proc/get_receptions(var/atom/sender, var/list/atom/receivers)
/proc/get_receptions(var/atom/sender, var/list/atom/receivers, var/do_sleep = 1)
var/datum/receptions/receptions = new
receptions.message_server = get_message_server()
var/datum/signal/signal
if(sender)
signal = sender.telecomms_process()
signal = sender.telecomms_process(do_sleep)
receptions.sender_reception = get_sender_reception(sender, signal)
for(var/atom/receiver in receivers)
+3
View File
@@ -39,6 +39,9 @@
data_core.security += R
return R
/proc/find_security_record(field, value)
return find_record(field, value, data_core.security)
/proc/find_record(field, value, list/L)
for(var/datum/data/record/R in L)
if(R.fields[field] == value)
+33 -11
View File
@@ -56,6 +56,7 @@ NOTE: there are two lists of areas in the end of this file: centcom and station
var/list/all_doors = list() //Added by Strumpetplaya - Alarm Change - Contains a list of doors adjacent to this area
var/air_doors_activated = 0
var/list/ambience = list('sound/ambience/ambigen1.ogg','sound/ambience/ambigen3.ogg','sound/ambience/ambigen4.ogg','sound/ambience/ambigen5.ogg','sound/ambience/ambigen6.ogg','sound/ambience/ambigen7.ogg','sound/ambience/ambigen8.ogg','sound/ambience/ambigen9.ogg','sound/ambience/ambigen10.ogg','sound/ambience/ambigen11.ogg','sound/ambience/ambigen12.ogg','sound/ambience/ambigen14.ogg')
var/sound/forced_ambience = null
/*Adding a wizard area teleport list because motherfucking lag -- Urist*/
/*I am far too lazy to make it a proper list of areas so I'll just make it run the usual telepot routine at the start of the game*/
@@ -717,6 +718,10 @@ var/list/ghostteleportlocs = list()
name = "\improper Incinerator"
icon_state = "disposal"
/area/maintenance/library
name = "Library Maintenance"
icon_state = "maint_library"
/area/maintenance/locker
name = "Locker Room Maintenance"
icon_state = "maint_locker"
@@ -726,11 +731,11 @@ var/list/ghostteleportlocs = list()
icon_state = "maint_medbay"
/area/maintenance/research_port
name = "Port Research Maintenance"
name = "Research Maintenance - Port"
icon_state = "maint_research_port"
/area/maintenance/research_starboard
name = "Starboard Research Maintenance"
name = "Research Maintenance - Starboard"
icon_state = "maint_research_starboard"
/area/maintenance/research_shuttle
@@ -738,11 +743,11 @@ var/list/ghostteleportlocs = list()
icon_state = "maint_research_shuttle"
/area/maintenance/security_port
name = "Port Security Maintenance"
name = "Security Maintenance - Port"
icon_state = "maint_security_port"
/area/maintenance/security_starboard
name = "Starboard Security Maintenance"
name = "Security Maintenance - Starboard"
icon_state = "maint_security_starboard"
/area/maintenance/storage
@@ -814,9 +819,21 @@ var/list/ghostteleportlocs = list()
name = "\improper Construction Area"
icon_state = "construction"
/area/hallway/secondary/entry
name = "\improper Arrival Shuttle Hallway"
icon_state = "entry"
/area/hallway/secondary/entry/fore
name = "\improper Arrival Shuttle Hallway - Fore"
icon_state = "entry_1"
/area/hallway/secondary/entry/port
name = "\improper Arrival Shuttle Hallway - Port"
icon_state = "entry_2"
/area/hallway/secondary/entry/starboard
name = "\improper Arrival Shuttle Hallway - Starboard"
icon_state = "entry_3"
/area/hallway/secondary/entry/aft
name = "\improper Arrival Shuttle Hallway - Aft"
icon_state = "entry_4"
//Command
@@ -1175,7 +1192,7 @@ var/list/ghostteleportlocs = list()
/area/assembly/robotics
name = "\improper Robotics Lab"
icon_state = "ass_line"
icon_state = "robotics"
/area/assembly/assembly_line //Derelict Assembly Line
name = "\improper Assembly Line"
@@ -1205,21 +1222,26 @@ var/list/ghostteleportlocs = list()
//MedBay
/area/medical/medbay
name = "\improper Medbay"
name = "\improper Medbay Hallway - Port"
icon_state = "medbay"
music = 'sound/ambience/signal.ogg'
//Medbay is a large area, these additional areas help level out APC load.
/area/medical/medbay2
name = "\improper Medbay"
name = "\improper Medbay Hallway - Starboard"
icon_state = "medbay2"
music = 'sound/ambience/signal.ogg'
/area/medical/medbay3
name = "\improper Medbay"
name = "\improper Medbay Hallway - Fore"
icon_state = "medbay3"
music = 'sound/ambience/signal.ogg'
/area/medical/medbay4
name = "\improper Medbay Hallway - Aft"
icon_state = "medbay4"
music = 'sound/ambience/signal.ogg'
/area/medical/biostorage
name = "\improper Secondary Storage"
icon_state = "medbay2"
+17 -8
View File
@@ -65,7 +65,7 @@
//Check all the alarms before lowering atmosalm. Raising is perfectly fine.
for (var/area/RA in related)
for (var/obj/machinery/alarm/AA in RA)
if ( !(AA.stat & (NOPOWER|BROKEN)) && !AA.shorted)
if (!(AA.stat & (NOPOWER|BROKEN)) && !AA.shorted && AA.report_danger_level)
danger_level = max(danger_level, AA.danger_level)
if(danger_level != atmosalm)
@@ -282,10 +282,9 @@
master.used_environ += amount
/area/Entered(A)
var/musVolume = 25
var/sound = 'sound/ambience/ambigen1.ogg'
var/list/mob/living/forced_ambiance_list = new
/area/Entered(A)
if(!istype(A,/mob/living)) return
var/mob/living/L = A
@@ -300,18 +299,28 @@
L.make_floating(0)
L.lastarea = newarea
play_ambience(L)
/area/proc/play_ambience(var/mob/living/L)
// Ambience goes down here -- make sure to list each area seperately for ease of adding things in later, thanks! Note: areas adjacent to each other should have the same sounds to prevent cutoff when possible.- LastyScratch
if(!(L && L.client && (L.client.prefs.toggles & SOUND_AMBIENCE))) return
// If we previously were in an area with force-played ambiance, stop it.
if(L in forced_ambiance_list)
L << sound(null, channel = 1)
forced_ambiance_list -= L
if(!L.client.ambience_playing)
L.client.ambience_playing = 1
L << sound('sound/ambience/shipambience.ogg', repeat = 1, wait = 0, volume = 35, channel = 2)
if(src.ambience.len && prob(35))
sound = pick(ambience)
if(world.time > L.client.played + 600)
if(forced_ambience)
forced_ambiance_list += L
L << forced_ambience
else if(src.ambience.len && prob(35))
if((world.time >= L.client.played + 600))
var/musVolume = 25
var/sound = pick(ambience)
L << sound(sound, repeat = 0, wait = 0, volume = musVolume, channel = 1)
L.client.played = world.time
+22 -17
View File
@@ -187,18 +187,22 @@ its easier to just keep the beam vertical.
//All atoms
/atom/verb/examine()
set name = "Examine"
set category = "IC"
set src in view(usr.client) //If it can be seen, it can be examined.
/atom/proc/examine(mob/user, var/distance = -1, var/sufix = "")
//This reformat names to get a/an properly working on item descriptions when they are bloody
var/f_name = "\a [src]."
if(src.blood_DNA && !istype(src, /obj/effect/decal))
if(gender == PLURAL)
f_name = "some "
else
f_name = "a "
f_name += "<span class='danger'>blood-stained</span> [name]!"
if (!( usr ))
return
usr << "That's \a [src]." //changed to "That's" from "This is" because "This is some metal sheets" sounds dumb compared to "That's some metal sheets" ~Carn
usr << desc
// *****RM
//usr << "[name]: Dn:[density] dir:[dir] cont:[contents] icon:[icon] is:[icon_state] loc:[loc]"
return
user << "\icon[src] That's [f_name] [sufix]"
if(desc)
user << desc
return distance == -1 || (get_dist(src, user) <= distance)
// called by mobs when e.g. having the atom as their machine, pulledby, loc (AKA mob being inside the atom) or buckled var set.
// see code/modules/mob/mob_movement.dm for more.
@@ -244,7 +248,7 @@ its easier to just keep the beam vertical.
src.fingerprintslast = M.key
return
/atom/proc/add_fingerprint(mob/living/M as mob)
/atom/proc/add_fingerprint(mob/living/M as mob, ignoregloves = 0)
if(isnull(M)) return
if(isAI(M)) return
if(isnull(M.key)) return
@@ -280,11 +284,12 @@ its easier to just keep the beam vertical.
H.gloves.add_fingerprint(M)
//Deal with gloves the pass finger/palm prints.
if(H.gloves != src)
if(prob(75) && istype(H.gloves, /obj/item/clothing/gloves/latex))
return 0
else if(H.gloves && !istype(H.gloves, /obj/item/clothing/gloves/latex))
return 0
if(!ignoregloves)
if(H.gloves != src)
if(prob(75) && istype(H.gloves, /obj/item/clothing/gloves/latex))
return 0
else if(H.gloves && !istype(H.gloves, /obj/item/clothing/gloves/latex))
return 0
//More adminstuffz
if(fingerprintslast != H.key)
-5
View File
@@ -193,11 +193,6 @@
return src.master.attackby(a, b)
return
/atom/movable/overlay/attack_paw(a, b, c)
if (src.master)
return src.master.attack_paw(a, b, c)
return
/atom/movable/overlay/attack_hand(a, b, c)
if (src.master)
return src.master.attack_hand(a, b, c)
+3 -5
View File
@@ -324,8 +324,6 @@
return
return
*/
/obj/machinery/computer/scan_consolenew/attack_paw(user as mob)
ui_interact(user)
/obj/machinery/computer/scan_consolenew/attack_ai(user as mob)
src.add_hiddenprint(user)
@@ -424,15 +422,15 @@
if (connected.beaker.reagents && connected.beaker.reagents.reagent_list.len)
for(var/datum/reagent/R in connected.beaker.reagents.reagent_list)
data["beakerVolume"] += R.volume
// update the ui if it exists, returns null if no ui is passed/found
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
if (!ui)
// the ui does not exist, so we'll create a new() one
// for a list of parameters and their descriptions see the code docs in \code\modules\nano\nanoui.dm
ui = new(user, src, ui_key, "dna_modifier.tmpl", "DNA Modifier Console", 660, 700)
// when the ui is first opened this is the data it will use
ui.set_initial_data(data)
ui.set_initial_data(data)
// open the new ui window
ui.open()
// auto update every Master Controller tick
+1 -1
View File
@@ -82,7 +82,7 @@ var/list/blob_nodes = list()
sleep(-1)
if(!blobs.len) break
var/obj/effect/blob/B = pick(blobs)
if(B.z != 1)
if(isNotStationLevel(B.z))
continue
B.Life()
+3 -3
View File
@@ -7,12 +7,12 @@
return 1
for(var/obj/effect/blob/B in blob_cores)
if(B && B.z != 1) continue
if(B && isNotStationLevel(B.z)) continue
return 0
var/nodes = 0
for(var/obj/effect/blob/B in blob_nodes)
if(B && B.z != 1) continue
if(B && isNotStationLevel(B.z)) continue
nodes++
if(nodes > 4)//Perhapse make a new core with a low prob
return 0
@@ -62,7 +62,7 @@
if (istype(T, /turf/space))
numSpace += 1
else if(istype(T, /turf))
if (M.z!=1)
if (isNotStationLevel(M.z))
numOffStation += 1
else
numAlive += 1
+2 -2
View File
@@ -62,7 +62,7 @@
proc/count()
for(var/turf/T in world)
if(T.z != 1)
if(isNotStationLevel(T.z)
continue
if(istype(T,/turf/simulated/floor))
@@ -84,7 +84,7 @@
src.r_wall += 1
for(var/obj/O in world)
if(O.z != 1)
if(isNotStationLevel(O.z))
continue
if(istype(O, /obj/structure/window))
+1 -1
View File
@@ -34,7 +34,7 @@
maxHealth = 20
melee_damage_lower = 4
melee_damage_upper = 8
attacktext = "hits"
attacktext = "hit"
attack_sound = 'sound/weapons/genhit1.ogg'
var/obj/effect/blob/factory/factory = null
faction = "blob"
+11
View File
@@ -82,6 +82,17 @@
return 1
/datum/game_mode/calamity/post_setup()
event_manager.report_at_round_end = 1
// Reduce the interval between moderate/major events
var/datum/event_container/EModerate = event_manager.event_containers[EVENT_LEVEL_MODERATE]
var/datum/event_container/EMajor = event_manager.event_containers[EVENT_LEVEL_MAJOR]
EModerate.delay_modifier = 0.5
EMajor.delay_modifier = 0.75
// Add the cortical borer event
var/list/moderate_event_list = EModerate.available_events
var/event = new /datum/event_meta(EVENT_LEVEL_MODERATE, "Borer Infestation", /datum/event/borer_infestation, 400, one_shot = 1)
moderate_event_list.Add(event)
if(chosen_atypes)
for(var/atype in chosen_atypes)
+11 -27
View File
@@ -20,7 +20,7 @@ var/engwords = list("travel", "blood", "join", "hell", "destroy", "technology",
runewords-=cultwords[word]
/obj/effect/rune
desc = ""
desc = "A strange collection of symbols drawn in blood."
anchored = 1
icon = 'icons/obj/rune.dmi'
icon_state = "1"
@@ -68,26 +68,10 @@ var/engwords = list("travel", "blood", "join", "hell", "destroy", "technology",
for(var/mob/living/silicon/ai/AI in player_list)
AI.client.images += blood
examine()
set src in view(2)
if(!iscultist(usr))
usr << "A strange collection of symbols drawn in blood."
return
/* Explosions... really?
if(desc && !usr.stat)
usr << "It reads: <i>[desc]</i>."
sleep(30)
explosion(src.loc, 0, 2, 5, 5)
if(src)
del(src)
*/
if(!desc)
usr << "A spell circle drawn in blood. It reads: <i>[word1] [word2] [word3]</i>."
else
usr << "Explosive Runes inscription in blood. It reads: <i>[desc]</i>."
return
examine(mob/user)
..()
if(iscultist(user))
user << "This spell circle reads: <i>[word1] [word2] [word3]</i>."
attackby(I as obj, user as mob)
@@ -346,7 +330,8 @@ var/engwords = list("travel", "blood", "join", "hell", "destroy", "technology",
msg_admin_attack("[user.name] ([user.ckey]) used [name] on [M.name] ([M.ckey]) (<A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[user.x];Y=[user.y];Z=[user.z]'>JMP</a>)")
if(istype(M,/mob/dead))
M.invisibility = 0
var/mob/dead/D = M
D.manifest()
user.visible_message( \
"\red [user] drags the ghost to our plan of reality!", \
"\red You drag the ghost to our plan of reality!" \
@@ -510,12 +495,11 @@ var/engwords = list("travel", "blood", "join", "hell", "destroy", "technology",
user << "You copy the translation notes from your tome."
examine()
set src in usr
if(!iscultist(usr))
usr << "An old, dusty tome with frayed edges and a sinister looking cover."
examine(mob/user)
if(!iscultist(user))
user << "An old, dusty tome with frayed edges and a sinister looking cover."
else
usr << "The scriptures of Nar-Sie, The One Who Sees, The Geometer of Blood. Contains the details of every ritual his followers could think of. Most of these are useless, though."
user << "The scriptures of Nar-Sie, The One Who Sees, The Geometer of Blood. Contains the details of every ritual his followers could think of. Most of these are useless, though."
/obj/item/weapon/book/tome/imbued //admin tome, spawns working runes without waiting
w_class = 2.0
+8 -4
View File
@@ -12,7 +12,7 @@ var/list/sacrificed = list()
for(var/obj/effect/rune/R in world)
if(R == src)
continue
if(R.word1 == cultwords["travel"] && R.word2 == cultwords["self"] && R.word3 == key && R.z != 2)
if(R.word1 == cultwords["travel"] && R.word2 == cultwords["self"] && R.word3 == key && isPlayerLevel(R.z))
index++
allrunesloc.len = index
allrunesloc[index] = R.loc
@@ -104,9 +104,13 @@ var/list/sacrificed = list()
if(M.stat==2)
continue
usr.say("Mah[pick("'","`")]weyh pleggh at e'ntrath!")
M.visible_message("\red [M] writhes in pain as the markings below \him glow a bloody red.", \
"\red AAAAAAHHHH!", \
"\red You hear an anguished scream.")
if (M.species && (M.species.flags & NO_PAIN))
M.visible_message("\red The markings below [M] glow a bloody red.")
else
M.visible_message("\red [M] writhes in pain as the markings below \him glow a bloody red.", \
"\red AAAAAAHHHH!", \
"\red You hear an anguished scream.")
if(is_convertable_to_cult(M.mind) && !jobban_isbanned(M, "cultist"))//putting jobban check here because is_convertable uses mind as argument
// Mostly for the benefit of those who resist, but it makes sense for even those who join to have some.. effect.
-7
View File
@@ -3,13 +3,6 @@
var/imbue = null
var/uses = 0
examine()
set src in view(2)
..()
return
attack_self(mob/living/user as mob)
if(iscultist(user))
var/delete = 1
+4 -4
View File
@@ -151,7 +151,7 @@
var/turf/T = get_turf(H)
if(!T)
continue
if(T.z != 1)
if(isNotStationLevel(T.z))
continue
for(var/datum/disease/D in H.viruses)
foundAlready = 1
@@ -211,7 +211,7 @@
/* // Haha, this is way too laggy. I'll keep the prison break though.
for(var/obj/machinery/light/L in world)
if(L.z != 1) continue
if(isNotStationLevel(L.z)) continue
L.flicker(50)
sleep(100)
@@ -220,7 +220,7 @@
var/turf/T = get_turf(H)
if(!T)
continue
if(T.z != 1)
if(isNotStationLevel(T.z))
continue
if(istype(H,/mob/living/carbon/human))
H.apply_effect((rand(15,75)),IRRADIATE,0)
@@ -237,7 +237,7 @@
var/turf/T = get_turf(M)
if(!T)
continue
if(T.z != 1)
if(isNotStationLevel(T.z))
continue
M.apply_effect((rand(15,75)),IRRADIATE,0)
sleep(100)
+1
View File
@@ -29,6 +29,7 @@
if(/obj/item/weapon/twohanded/fireaxe) del src
if(/obj/item/weapon/hatchet) del src
if(/obj/item/weapon/melee/energy) del src
if(/obj/item/weapon/pickaxe/plasmacutter) del src
//less effective weapons
if(/obj/item/weapon/wirecutters)
+2 -2
View File
@@ -78,8 +78,8 @@ In my current plan for it, 'solid' will be defined as anything with density == 1
walk_towards(immrod, end,1)
sleep(1)
while (immrod)
if (immrod.z != 1)
immrod.z = 1
if (isNotStationLevel(immrod.z))
immrod.z = pick(config.station_levels)
if(immrod.loc == end)
del(immrod)
sleep(10)
+1 -1
View File
@@ -83,7 +83,7 @@ The "dust" will damage the hull of the station causin minor hull breaches.
var/goal = locate(endx, endy, 1)
src.x = startx
src.y = starty
src.z = 1
src.z = pick(config.station_levels)
spawn(0)
walk_towards(src, goal, 1)
return
@@ -1,6 +1,6 @@
/proc/Christmas_Game_Start()
for(var/obj/structure/flora/tree/pine/xmas in world)
if(xmas.z != 1) continue
if(isNotStationLevel(xmas.z)) continue
for(var/turf/simulated/floor/T in orange(1,xmas))
for(var/i=1,i<=rand(1,5),i++)
new /obj/item/weapon/a_gift(T)
@@ -171,7 +171,7 @@ var/global/Holiday = null
*/
/* var/list/obj/containers = list()
for(var/obj/item/weapon/storage/S in world)
if(S.z != 1) continue
if(isNotStationLevel(S.z)) continue
containers += S
message_admins("\blue DEBUG: Event: Egg spawned at [Egg.loc] ([Egg.x],[Egg.y],[Egg.z])")*/
+1 -1
View File
@@ -21,7 +21,7 @@
sleep(-1)
if(!blob_cores.len) break
var/obj/effect/blob/B = pick(blob_cores)
if(B.z != 1)
if(isNotStationLevel(B.z))
continue
B.Life()
spawn(30)
+8 -14
View File
@@ -911,9 +911,8 @@ ________________________________________________________________________________
U.drop_item()
return 0
/obj/item/clothing/suit/space/space_ninja/examine()
set src in view()
..()
/obj/item/clothing/suit/space/space_ninja/examine(mob/user)
..(user)
if(s_initialized)
var/mob/living/carbon/human/U = affecting
if(s_control)
@@ -1168,9 +1167,8 @@ ________________________________________________________________________________
U << "You <b>[candrain?"disable":"enable"]</b> special interaction."
candrain=!candrain
/obj/item/clothing/gloves/space_ninja/examine()
set src in view()
..()
/obj/item/clothing/gloves/space_ninja/examine(mob/user)
..(user)
if(!canremove)
var/mob/living/carbon/human/U = loc
U << "The energy drain mechanism is: <B>[candrain?"active":"inactive"]</B>."
@@ -1306,12 +1304,11 @@ ________________________________________________________________________________
var/mob/U = loc
U << "Switching mode to <B>[ninja_vision.mode]</B>."
/obj/item/clothing/mask/gas/voice/space_ninja/examine()
set src in view()
..()
/obj/item/clothing/mask/gas/voice/space_ninja/examine(mob/user)
..(user)
usr << "<B>[ninja_vision.mode]</B> is active."//Leaving usr here since it may be on the floor or on a person.
usr << "Voice mimicking algorithm is set <B>[!vchange?"inactive":"active"]</B>."
user << "<B>[ninja_vision.mode]</B> is active."
user << "Voice mimicking algorithm is set <B>[!vchange?"inactive":"active"]</B>."
/*
===================================================================================
@@ -1476,9 +1473,6 @@ It is possible to destroy the net by the occupant or someone else.
healthcheck()
return
attack_paw()
return attack_hand()
attackby(obj/item/weapon/W as obj, mob/user as mob)
var/aforce = W.force
health = max(0, health - aforce)
+3 -3
View File
@@ -33,7 +33,7 @@
C.cell.charge = C.cell.maxcharge
for(var/obj/machinery/power/smes/S in world)
var/area/current_area = get_area(S)
if(current_area.type in skipped_areas || S.z != 1)
if(current_area.type in skipped_areas || isNotStationLevel(S.z))
continue
S.charge = S.last_charge
S.output = S.last_output
@@ -46,10 +46,10 @@
if(announce)
command_announcement.Announce("All SMESs on [station_name()] have been recharged. We apologize for the inconvenience.", "Power Systems Nominal", new_sound = 'sound/AI/poweron.ogg')
for(var/obj/machinery/power/smes/S in world)
if(S.z != 1)
if(isNotStationLevel(S.z))
continue
S.charge = S.capacity
S.output = 200000
S.output = S.output_level_max // Most new SMESs on map are of buildable type, and may actually have higher output limit than 200kW. Use max output of that SMES instead.
S.online = 1
S.updateicon()
S.power_change()
+1 -1
View File
@@ -213,7 +213,7 @@
/datum/game_mode/proc/send_intercept()
var/intercepttext = "<FONT size = 3><B>Cent. Com. Update</B> Requested status information:</FONT><HR>"
intercepttext += "<B> In case you have misplaced your copy, attached is a list of personnel whom reliable sources&trade; suspect may be affiliated with criminal organisations or hostile foreign entities:</B><br>"
intercepttext += "<B> In case you have misplaced your copy, attached is a list of personnel whom reliable sources&trade; suspect may be affiliated with subversive elements:</B><br>"
var/list/suspects = list()
+6 -3
View File
@@ -274,7 +274,7 @@ var/global/datum/controller/gameticker/ticker
proc/create_characters()
for(var/mob/new_player/player in player_list)
if(player.ready && player.mind)
if(player && player.ready && player.mind)
if(player.mind.assigned_role=="AI")
player.close_spawn_windows()
player.AIize()
@@ -382,11 +382,11 @@ var/global/datum/controller/gameticker/ticker
if(Player.stat != DEAD)
var/turf/playerTurf = get_turf(Player)
if(emergency_shuttle.departed && emergency_shuttle.evac)
if(playerTurf.z != 2)
if(isNotAdminLevel(playerTurf.z))
Player << "<font color='blue'><b>You managed to survive, but were marooned on [station_name()] as [Player.real_name]...</b></font>"
else
Player << "<font color='green'><b>You managed to survive the events on [station_name()] as [Player.real_name].</b></font>"
else if(playerTurf.z == 2)
else if(isAdminLevel(playerTurf.z))
Player << "<font color='green'><b>You successfully underwent crew transfer after events on [station_name()] as [Player.real_name].</b></font>"
else if(issilicon(Player))
Player << "<font color='green'><b>You remain operational after the events on [station_name()] as [Player.real_name].</b></font>"
@@ -441,6 +441,9 @@ var/global/datum/controller/gameticker/ticker
if (findtext("[handler]","auto_declare_completion_"))
call(mode, handler)()
//Ask the event manager to print round end information
event_manager.RoundEnd()
//Print a list of antagonists to the server log
var/list/total_antagonists = list()
//Look into all mobs in world, dead or alive
@@ -99,7 +99,7 @@
return
..()
/obj/machinery/emergency_authentication_device/examine()
usr << {"
/obj/machinery/emergency_authentication_device/examine(mob/user)
user << {"
This is a specialized communications device that is able to instantly send a message to <b>NanoTrasen High Command</b> via quantum entanglement with a sister device at CentCom.
The EAD's status is [get_status()]."}
+4 -4
View File
@@ -25,14 +25,14 @@
icon_state = "pinoff"
usr << "\blue You switch \the [src] off."
/obj/item/weapon/pinpointer/advpinpointer/auth_key/examine()
/obj/item/weapon/pinpointer/advpinpointer/auth_key/examine(mob/user)
switch(mode)
if (1)
usr << "Is is calibrated for the Captain's Authentication Key."
user << "Is is calibrated for the Captain's Authentication Key."
if (2)
usr << "It is calibrated for the Emergency Secondary Authentication Key."
user << "It is calibrated for the Emergency Secondary Authentication Key."
else
usr << "It is switched off."
user << "It is switched off."
/datum/supply_packs/key_pinpointer
name = "Authentication Key Pinpointer crate"
+1 -1
View File
@@ -1404,7 +1404,7 @@ datum
var/turf/T = get_turf(target.current)
if(target.current.stat == 2)
return 1
else if((T) && (T.z != 1))//If they leave the station they count as dead for this
else if((T) && (isNotStationLevel(T.z)))//If they leave the station they count as dead for this
return 2
else
return 0
@@ -165,9 +165,6 @@ var/bomb_set
return
..()
/obj/machinery/nuclearbomb/attack_paw(mob/user as mob)
return src.attack_hand(user)
/obj/machinery/nuclearbomb/attack_hand(mob/user as mob)
if (src.extended)
if (!ishuman(user))
+3 -3
View File
@@ -42,11 +42,11 @@
icon_state = "pinonfar"
spawn(5) .()
examine()
..()
examine(mob/user)
..(user)
for(var/obj/machinery/nuclearbomb/bomb in world)
if(bomb.timing)
usr << "Extreme danger. Arming signal detected. Time remaining: [bomb.timeleft]"
user << "Extreme danger. Arming signal detected. Time remaining: [bomb.timeleft]"
/obj/item/weapon/pinpointer/advpinpointer
+2 -2
View File
@@ -88,7 +88,7 @@ datum/objective/mutiny
if(target.current.stat == DEAD || !ishuman(target.current) || !target.current.ckey)
return 1
var/turf/T = get_turf(target.current)
if(T && (T.z != 1)) //If they leave the station they count as dead for this
if(T && isNotStationLevel(T.z)) //If they leave the station they count as dead for this
return 2
return 0
return 1
@@ -123,7 +123,7 @@ datum/objective/mutiny/rp
if(target in ticker.mode:head_revolutionaries)
return 1
var/turf/T = get_turf(target.current)
if(T && (T.z != 1)) //If they leave the station they count as dead for this
if(T && isNotStationLevel(T.z)) //If they leave the station they count as dead for this
rval = 2
return 0
return rval
+3 -3
View File
@@ -367,7 +367,7 @@
if(headrev.current)
if(headrev.current.stat == DEAD)
text += "died"
else if(headrev.current.z != 1)
else if(isNotStationLevel(headrev.current.z))
text += "fled the station"
else
text += "survived the revolution"
@@ -390,7 +390,7 @@
if(rev.current)
if(rev.current.stat == DEAD)
text += "died"
else if(rev.current.z != 1)
else if(isNotStationLevel(rev.current.z))
text += "fled the station"
else
text += "survived the revolution"
@@ -415,7 +415,7 @@
if(head.current)
if(head.current.stat == DEAD)
text += "died"
else if(head.current.z != 1)
else if(isNotStationLevel(head.current.z))
text += "fled the station"
else
text += "survived the revolution"
+11 -67
View File
@@ -417,76 +417,20 @@
/proc/get_all_centcom_jobs()
return list("VIP Guest","Custodian","Thunderdome Overseer","Intel Officer","Medical Officer","Death Commando","Research Officer","BlackOps Commander","Supreme Commander")
//gets the actual job rank (ignoring alt titles)
//this is used solely for sechuds
/obj/proc/GetJobRealName()
if (!istype(src, /obj/item/device/pda) && !istype(src,/obj/item/weapon/card/id))
return
var/rank
var/assignment
if(istype(src, /obj/item/device/pda))
if(src:id)
rank = src:id:rank
assignment = src:id:assignment
else if(istype(src, /obj/item/weapon/card/id))
rank = src:rank
assignment = src:assignment
if( rank in joblist )
return rank
if( assignment in joblist )
return assignment
return "Unknown"
//gets the alt title, failing that the actual job rank
//this is unused
/obj/proc/sdsdsd() //GetJobDisplayName
if (!istype(src, /obj/item/device/pda) && !istype(src,/obj/item/weapon/card/id))
return
var/assignment
if(istype(src, /obj/item/device/pda))
if(src:id)
assignment = src:id:assignment
else if(istype(src, /obj/item/weapon/card/id))
assignment = src:assignment
if(assignment)
return assignment
return "Unknown"
proc/GetIdCard(var/mob/living/carbon/human/H)
if(H.wear_id)
var/id = H.wear_id.GetID()
if(id)
return id
if(H.get_active_hand())
var/obj/item/I = H.get_active_hand()
return I.GetID()
proc/FindNameFromID(var/mob/living/carbon/human/H)
ASSERT(istype(H))
var/obj/item/weapon/card/id/C = H.get_active_hand()
if( istype(C) || istype(C, /obj/item/device/pda) )
var/obj/item/weapon/card/id/ID = C
if( istype(C, /obj/item/device/pda) )
var/obj/item/device/pda/pda = C
ID = pda.id
if(!istype(ID))
ID = null
if(ID)
return ID.registered_name
C = H.wear_id
if( istype(C) || istype(C, /obj/item/device/pda) )
var/obj/item/weapon/card/id/ID = C
if( istype(C, /obj/item/device/pda) )
var/obj/item/device/pda/pda = C
ID = pda.id
if(!istype(ID))
ID = null
if(ID)
return ID.registered_name
var/obj/item/weapon/card/id/C = GetIdCard(H)
if(C)
return C.registered_name
proc/get_all_job_icons() //For all existing HUD icons
return joblist + list("Prisoner")
+3 -1
View File
@@ -34,7 +34,9 @@ var/datum/announcement/minor/captain_announcement = new(do_newscast = 1)
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/ids(H), slot_r_hand)
else
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/ids(H.back), slot_in_backpack)
captain_announcement.Announce("All hands, captain [H.real_name] on deck!")
var/sound/announce_sound = (ticker.current_state <= GAME_STATE_SETTING_UP)? null : sound('sound/misc/boatswain.ogg', volume=20)
captain_announcement.Announce("All hands, Captain [H.real_name] on deck!", new_sound=announce_sound)
H.implant_loyalty(src)
+5 -1
View File
@@ -18,6 +18,7 @@
if(2) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack(H), slot_back)
if(3) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel_norm(H), slot_back)
if(4) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel(H), slot_back)
H.equip_to_slot_or_del(new /obj/item/device/radio/headset/headset_service(H), slot_l_ear)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/bartender(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/device/pda/bar(H), slot_belt)
@@ -56,6 +57,7 @@
equip(var/mob/living/carbon/human/H)
if(!H) return 0
H.equip_to_slot_or_del(new /obj/item/device/radio/headset/headset_service(H), slot_l_ear)
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/chef(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/chef(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(H), slot_shoes)
@@ -85,6 +87,7 @@
equip(var/mob/living/carbon/human/H)
if(!H) return 0
H.equip_to_slot_or_del(new /obj/item/device/radio/headset/headset_service(H), slot_l_ear)
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/hydroponics(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/clothing/gloves/botanic_leather(H), slot_gloves)
@@ -286,6 +289,7 @@
equip(var/mob/living/carbon/human/H)
if(!H) return 0
H.equip_to_slot_or_del(new /obj/item/device/radio/headset/headset_service(H), slot_l_ear)
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/janitor(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/device/pda/janitor(H), slot_belt)
@@ -348,7 +352,7 @@
if(3) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel_norm(H), slot_back)
if(4) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel(H), slot_back)
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/internalaffairs(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/internalaffairs(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/internalaffairs(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/brown(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/clothing/glasses/sunglasses/big(H), slot_glasses)
H.equip_to_slot_or_del(new /obj/item/device/pda/lawyer(H), slot_belt)
+40 -1
View File
@@ -70,4 +70,43 @@
if(!isnum(minimal_player_age))
return 0
return max(0, minimal_player_age - C.player_age)
return max(0, minimal_player_age - C.player_age)
/datum/job/proc/apply_fingerprints(var/mob/living/carbon/human/H)
if(!istype(H))
return
if(H.back)
H.back.add_fingerprint(H,1) //The 1 sets a flag to ignore gloves
for(var/obj/item/I in H.back.contents)
I.add_fingerprint(H,1)
if(H.wear_id)
H.wear_id.add_fingerprint(H,1)
if(H.w_uniform)
H.w_uniform.add_fingerprint(H,1)
if(H.wear_suit)
H.wear_suit.add_fingerprint(H,1)
if(H.wear_mask)
H.wear_mask.add_fingerprint(H,1)
if(H.head)
H.head.add_fingerprint(H,1)
if(H.shoes)
H.shoes.add_fingerprint(H,1)
if(H.gloves)
H.gloves.add_fingerprint(H,1)
if(H.l_ear)
H.l_ear.add_fingerprint(H,1)
if(H.r_ear)
H.r_ear.add_fingerprint(H,1)
if(H.glasses)
H.glasses.add_fingerprint(H,1)
if(H.belt)
H.belt.add_fingerprint(H,1)
for(var/obj/item/I in H.belt.contents)
I.add_fingerprint(H,1)
if(H.s_store)
H.s_store.add_fingerprint(H,1)
if(H.l_store)
H.l_store.add_fingerprint(H,1)
if(H.r_store)
H.r_store.add_fingerprint(H,1)
return 1
+11 -13
View File
@@ -27,7 +27,7 @@
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/chief_medical_officer(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/brown(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/device/pda/heads/cmo(H), slot_belt)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/labcoat/cmo(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/labcoat/cmo(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/weapon/storage/firstaid/adv(H), slot_l_hand)
H.equip_to_slot_or_del(new /obj/item/device/flashlight/pen(H), slot_s_store)
if(H.backbag == 1)
@@ -62,24 +62,22 @@
switch(H.mind.role_alt_title)
if("Emergency Physician")
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/medical(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/fr_jacket(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/fr_jacket(H), slot_wear_suit)
if("Surgeon")
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/medical/blue(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/labcoat(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/labcoat(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/head/surgery/blue(H), slot_head)
if("Virologist")
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/labcoat/virologist(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/labcoat/virologist(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/virologist(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/mask/surgical(H), slot_wear_mask)
switch(H.backbag)
if(1) H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H), slot_r_hand)
if(2) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/virology(H), slot_back)
if(3) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel_vir(H), slot_back)
if(4) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel(H), slot_back)
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack)
if("Medical Doctor")
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/medical(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/labcoat(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/labcoat(H), slot_wear_suit)
if("Nurse")
if(H.gender == FEMALE)
if(prob(50))
@@ -91,7 +89,7 @@
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/medical/purple(H), slot_w_uniform)
else
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/medical(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/labcoat(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/labcoat(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/white(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/device/pda/medical(H), slot_belt)
H.equip_to_slot_or_del(new /obj/item/weapon/storage/firstaid/adv(H), slot_l_hand)
@@ -125,7 +123,7 @@
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/chemist(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/white(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/device/pda/chemist(H), slot_belt)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/labcoat/chemist(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/labcoat/chemist(H), slot_wear_suit)
switch(H.backbag)
if(1) H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H), slot_r_hand)
if(2) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/chemistry(H), slot_back)
@@ -155,7 +153,7 @@
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/geneticist(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/white(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/device/pda/geneticist(H), slot_belt)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/labcoat/genetics(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/labcoat/genetics(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/device/flashlight/pen(H), slot_s_store)
switch(H.backbag)
if(1) H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H), slot_r_hand)
@@ -190,7 +188,7 @@
H.equip_to_slot_or_del(new /obj/item/device/pda/viro(H), slot_belt)
H.equip_to_slot_or_del(new /obj/item/clothing/mask/surgical(H), slot_wear_mask)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/white(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/labcoat/virologist(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/labcoat/virologist(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/device/flashlight/pen(H), slot_s_store)
if(H.backbag == 1)
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H), slot_r_hand)
@@ -226,10 +224,10 @@
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/psych/turtleneck(H), slot_w_uniform)
else
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/medical(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/labcoat(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/labcoat(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/laceup(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/device/pda/medical(H), slot_belt)
if(H.backbag == 1)
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H), slot_r_hand)
else
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack)
H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H.back), slot_in_backpack)
+4 -4
View File
@@ -25,7 +25,7 @@
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/brown(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/research_director(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/device/pda/heads/rd(H), slot_belt)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/labcoat(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/labcoat(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/weapon/clipboard(H), slot_l_hand)
switch(H.backbag)
if(1) H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H), slot_r_hand)
@@ -58,7 +58,7 @@
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/scientist(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/white(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/device/pda/science(H), slot_belt)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/labcoat/science(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/labcoat/science(H), slot_wear_suit)
switch(H.backbag)
if(1) H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H), slot_r_hand)
if(2) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/toxins(H), slot_back)
@@ -89,7 +89,7 @@
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/scientist(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/white(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/device/pda/science(H), slot_belt)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/labcoat/science(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/labcoat/science(H), slot_wear_suit)
switch(H.backbag)
if(1) H.equip_to_slot_or_del(new /obj/item/weapon/storage/box/survival(H), slot_r_hand)
if(2) H.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/toxins(H), slot_back)
@@ -122,7 +122,7 @@
H.equip_to_slot_or_del(new /obj/item/clothing/under/rank/roboticist(H), slot_w_uniform)
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(H), slot_shoes)
H.equip_to_slot_or_del(new /obj/item/device/pda/roboticist(H), slot_belt)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/labcoat(H), slot_wear_suit)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/toggle/labcoat(H), slot_wear_suit)
// H.equip_to_slot_or_del(new /obj/item/clothing/gloves/black(H), slot_gloves)
H.equip_to_slot_or_del(new /obj/item/weapon/storage/toolbox/mechanical(H), slot_l_hand)
if(H.backbag == 1)
+1 -1
View File
@@ -21,7 +21,7 @@
flag = CYBORG
department_flag = ENGSEC
faction = "Station"
total_positions = 0
total_positions = 2
spawn_positions = 2
supervisors = "your laws and the AI" //Nodrak
selection_color = "#ddffdd"
+4 -4
View File
@@ -348,7 +348,7 @@ var/global/datum/controller/occupations/job_master
proc/EquipRank(var/mob/living/carbon/human/H, var/rank, var/joined_late = 0)
if(!H) return 0
if(!H) return null
var/datum/job/job = GetJob(rank)
var/list/spawn_in_storage = list()
@@ -386,6 +386,7 @@ var/global/datum/controller/occupations/job_master
//Equip job items.
job.equip(H)
job.apply_fingerprints(H)
else
H << "Your job is [rank] and the game just can't handle it! Please report this bug to an administrator."
@@ -444,8 +445,7 @@ var/global/datum/controller/occupations/job_master
switch(rank)
if("Cyborg")
H.Robotize()
return 1
return H.Robotize()
if("AI","Clown") //don't need bag preference stuff!
else
switch(H.backbag) //BS12 EDIT
@@ -524,7 +524,7 @@ var/global/datum/controller/occupations/job_master
H.hud_updateflag |= (1 << ID_HUD)
H.hud_updateflag |= (1 << IMPLOYAL_HUD)
H.hud_updateflag |= (1 << SPECIALROLE_HUD)
return 1
return H
proc/spawnId(var/mob/living/carbon/human/H, rank, title)
-13
View File
@@ -45,19 +45,6 @@
if(prob(75))
del(src)
/obj/machinery/optable/attack_paw(mob/user as mob)
if ((HULK in usr.mutations))
usr << text("\blue You destroy the operating table.")
visible_message("\red [usr] destroys the operating table!")
src.density = 0
del(src)
if (!( locate(/obj/machinery/optable, user.loc) ))
step(user, get_dir(user, src))
if (user.loc == src.loc)
user.layer = TURF_LAYER
visible_message("The monkey hides under the table!")
return
/obj/machinery/optable/attack_hand(mob/user as mob)
if (HULK in usr.mutations)
usr << text("\blue You destroy the table.")
+4 -7
View File
@@ -10,7 +10,7 @@
anchored = 1 //About time someone fixed this.
density = 1
var/orient = "LEFT" // "RIGHT" changes the dir suffix to "-r"
use_power = 1
idle_power_usage = 40
@@ -50,9 +50,6 @@
/obj/machinery/sleep_console/attack_ai(mob/user as mob)
return src.attack_hand(user)
/obj/machinery/sleep_console/attack_paw(mob/user as mob)
return src.attack_hand(user)
/obj/machinery/sleep_console/attack_hand(mob/user as mob)
if(..())
return
@@ -166,7 +163,7 @@
var/amounts = list(5, 10)
var/obj/item/weapon/reagent_containers/glass/beaker = null
var/filtering = 0
use_power = 1
idle_power_usage = 15
active_power_usage = 200 //builtin health analyzer, dialysis machine, injectors.
@@ -188,7 +185,7 @@
process()
if (stat & (NOPOWER|BROKEN))
return
if(filtering > 0)
if(beaker)
if(beaker.reagents.total_volume < beaker.reagents.maximum_volume)
@@ -338,7 +335,7 @@
proc/inject_chemical(mob/living/user as mob, chemical, amount)
if (stat & (BROKEN|NOPOWER))
return
if(src.occupant && src.occupant.reagents)
if(src.occupant.reagents.get_reagent_amount(chemical) + amount <= 20)
use_power(amount * CHEM_SYNTH_ENERGY)
-4
View File
@@ -211,10 +211,6 @@
*/
/obj/machinery/body_scanconsole/attack_paw(user as mob)
return src.attack_hand(user)
/obj/machinery/body_scanconsole/attack_ai(user as mob)
return src.attack_hand(user)
+17 -220
View File
@@ -2,32 +2,6 @@
//CONTAINS: Air Alarms and Fire Alarms//
////////////////////////////////////////
/proc/RandomAAlarmWires()
//to make this not randomize the wires, just set index to 1 and increment it in the flag for loop (after doing everything else).
var/list/AAlarmwires = list(0, 0, 0, 0, 0)
AAlarmIndexToFlag = list(0, 0, 0, 0, 0)
AAlarmIndexToWireColor = list(0, 0, 0, 0, 0)
AAlarmWireColorToIndex = list(0, 0, 0, 0, 0)
var/flagIndex = 1
for (var/flag=1, flag<32, flag+=flag)
var/valid = 0
while (!valid)
var/colorIndex = rand(1, 5)
if (AAlarmwires[colorIndex]==0)
valid = 1
AAlarmwires[colorIndex] = flag
AAlarmIndexToFlag[flagIndex] = flag
AAlarmIndexToWireColor[flagIndex] = colorIndex
AAlarmWireColorToIndex[colorIndex] = flagIndex
flagIndex+=1
return AAlarmwires
#define AALARM_WIRE_IDSCAN 1 //Added wires
#define AALARM_WIRE_POWER 2
#define AALARM_WIRE_SYPHON 3
#define AALARM_WIRE_AI_CONTROL 4
#define AALARM_WIRE_AALARM 5
#define AALARM_MODE_SCRUBBING 1
#define AALARM_MODE_REPLACEMENT 2 //like scrubbing, but faster.
#define AALARM_MODE_PANIC 3 //constantly sucks all air
@@ -79,9 +53,10 @@
var/locked = 1
var/wiresexposed = 0 // If it's been screwdrivered open.
var/aidisabled = 0
var/AAlarmwires = 31
var/shorted = 0
var/datum/wires/alarm/wires
var/mode = AALARM_MODE_SCRUBBING
var/screen = AALARM_SCREEN_MAIN
var/area_uid
@@ -103,13 +78,11 @@
var/temperature_dangerlevel = 0
var/other_dangerlevel = 0
var/apply_danger_level = 1
var/post_alert = 1
var/report_danger_level = 1
/obj/machinery/alarm/monitor
apply_danger_level = 0
report_danger_level = 0
breach_detection = 0
post_alert = 0
/obj/machinery/alarm/server/New()
..()
@@ -153,6 +126,9 @@
if (name == "alarm")
name = "[alarm_area.name] Air Alarm"
if(!wires)
wires = new(src)
// breathable air according to human/Life()
TLV["oxygen"] = list(16, 19, 135, 140) // Partial pressure, kpa
TLV["carbon dioxide"] = list(-1.0, -1.0, 5, 10) // Partial pressure, kpa
@@ -454,15 +430,12 @@
send_signal(device_id, list("power"= 0) )
/obj/machinery/alarm/proc/apply_danger_level(var/new_danger_level)
if (apply_danger_level && alarm_area.atmosalert(new_danger_level))
if (report_danger_level && alarm_area.atmosalert(new_danger_level))
post_alert(new_danger_level)
update_icon()
/obj/machinery/alarm/proc/post_alert(alert_level)
if(!post_alert)
return
var/datum/radio_frequency/frequency = radio_controller.return_frequency(alarm_frequency)
if(!frequency)
return
@@ -482,125 +455,6 @@
frequency.post_signal(src, alert_signal)
///////////
//HACKING//
///////////
/obj/machinery/alarm/proc/isWireColorCut(var/wireColor)
var/wireFlag = AAlarmWireColorToFlag[wireColor]
return ((AAlarmwires & wireFlag) == 0)
/obj/machinery/alarm/proc/isWireCut(var/wireIndex)
var/wireFlag = AAlarmIndexToFlag[wireIndex]
return ((AAlarmwires & wireFlag) == 0)
/obj/machinery/alarm/proc/allWiresCut()
var/i = 1
while(i<=5)
if(AAlarmwires & AAlarmIndexToFlag[i])
return 0
i++
return 1
/obj/machinery/alarm/proc/cut(var/wireColor)
var/wireFlag = AAlarmWireColorToFlag[wireColor]
var/wireIndex = AAlarmWireColorToIndex[wireColor]
AAlarmwires &= ~wireFlag
switch(wireIndex)
if(AALARM_WIRE_IDSCAN)
locked = 1
if(AALARM_WIRE_POWER)
shock(usr, 50)
shorted = 1
update_icon()
if (AALARM_WIRE_AI_CONTROL)
if (aidisabled == 0)
aidisabled = 1
if(AALARM_WIRE_SYPHON)
mode = AALARM_MODE_PANIC
apply_mode()
if(AALARM_WIRE_AALARM)
if (alarm_area.atmosalert(2))
apply_danger_level(2)
spawn(1)
updateUsrDialog()
update_icon()
updateDialog()
return
/obj/machinery/alarm/proc/mend(var/wireColor)
var/wireFlag = AAlarmWireColorToFlag[wireColor]
var/wireIndex = AAlarmWireColorToIndex[wireColor] //not used in this function
AAlarmwires |= wireFlag
switch(wireIndex)
if(AALARM_WIRE_IDSCAN)
if(AALARM_WIRE_POWER)
shorted = 0
shock(usr, 50)
update_icon()
if(AALARM_WIRE_AI_CONTROL)
if (aidisabled == 1)
aidisabled = 0
updateDialog()
return
/obj/machinery/alarm/proc/pulse(var/wireColor)
//var/wireFlag = AAlarmWireColorToFlag[wireColor] //not used in this function
var/wireIndex = AAlarmWireColorToIndex[wireColor]
switch(wireIndex)
if(AALARM_WIRE_IDSCAN) //unlocks for 30 seconds, if you have a better way to hack I'm all ears
locked = 0
spawn(300)
locked = 1
if (AALARM_WIRE_POWER)
if(shorted == 0)
shorted = 1
update_icon()
spawn(1200)
if(shorted == 1)
shorted = 0
update_icon()
if (AALARM_WIRE_AI_CONTROL)
if (aidisabled == 0)
aidisabled = 1
updateDialog()
spawn(10)
if (aidisabled == 1)
aidisabled = 0
updateDialog()
if(AALARM_WIRE_SYPHON)
mode = AALARM_MODE_REPLACEMENT
apply_mode()
if(AALARM_WIRE_AALARM)
if (alarm_area.atmosalert(0))
apply_danger_level(0)
spawn(1)
updateUsrDialog()
update_icon()
updateDialog()
return
///////////////
//END HACKING//
///////////////
/obj/machinery/alarm/attack_ai(mob/user)
return interact(user)
@@ -616,7 +470,7 @@
if(buildstage!=2)
return
if ( (get_dist(src, user) > 1 ))
if((get_dist(src, user) > 1 ))
if (!istype(user, /mob/living/silicon))
user.machine = null
user << browse(null, "window=air_alarm")
@@ -629,30 +483,8 @@
user << browse(null, "window=air_alarm")
return
if(wiresexposed && (!istype(user, /mob/living/silicon)))
var/t1 = text("<html><head><title>[alarm_area.name] Air Alarm Wires</title></head><body><B>Access Panel</B><br>\n")
var/list/wirecolors = list(
"Orange" = 1,
"Dark red" = 2,
"White" = 3,
"Yellow" = 4,
"Black" = 5,
)
for(var/wiredesc in wirecolors)
var/is_uncut = AAlarmwires & AAlarmWireColorToFlag[wirecolors[wiredesc]]
t1 += "[wiredesc] wire: "
if(!is_uncut)
t1 += "<a href='?src=\ref[src];AAlarmwires=[wirecolors[wiredesc]]'>Mend</a>"
else
t1 += "<a href='?src=\ref[src];AAlarmwires=[wirecolors[wiredesc]]'>Cut</a> "
t1 += "<a href='?src=\ref[src];pulse=[wirecolors[wiredesc]]'>Pulse</a> "
t1 += "<br>"
t1 += text("<br>\n[(locked ? "The Air Alarm is locked." : "The Air Alarm is unlocked.")]<br>\n[((shorted || (stat & (NOPOWER|BROKEN))) ? "The Air Alarm is offline." : "The Air Alarm is working properly!")]<br>\n[(aidisabled ? "The 'AI control allowed' light is off." : "The 'AI control allowed' light is on.")]")
t1 += text("<p><a href='?src=\ref[src];close2=1'>Close</a></p></body></html>")
user << browse(t1, "window=AAlarmwires")
onclose(user, "AAlarmwires")
if(wiresexposed && (!istype(user, /mob/living/silicon/ai)))
wires.Interact(user)
if(!shorted)
user << browse(return_text(user),"window=air_alarm")
@@ -1055,35 +887,6 @@ table tr:first-child th:first-child { border: none;}
mode = text2num(href_list["mode"])
apply_mode()
// hrefs that need the AA wires exposed, note that borgs should be in range here too -walter0o
if(wiresexposed && Adjacent(usr))
if (href_list["AAlarmwires"])
var/t1 = text2num(href_list["AAlarmwires"])
if (!( istype(usr.equipped(), /obj/item/weapon/wirecutters) ))
usr << "You need wirecutters!"
return
if (isWireColorCut(t1))
mend(t1)
else
cut(t1)
if (AAlarmwires == 0)
usr << "<span class='notice'>You cut last of wires inside [src]</span>"
update_icon()
buildstage = 1
return
else if (href_list["pulse"])
var/t1 = text2num(href_list["pulse"])
if (!istype(usr.equipped(), /obj/item/device/multitool))
usr << "You need a multitool!"
return
if (isWireColorCut(t1))
usr << "You can't pulse a cut wire."
return
else
pulse(t1)
updateUsrDialog()
@@ -1115,7 +918,7 @@ table tr:first-child th:first-child { border: none;}
user << "It does nothing"
return
else
if(allowed(usr) && !isWireCut(AALARM_WIRE_IDSCAN))
if(allowed(usr) && !wires.IsIndexCut(AALARM_WIRE_IDSCAN))
locked = !locked
user << "\blue You [ locked ? "lock" : "unlock"] the Air Alarm interface."
updateUsrDialog()
@@ -1168,12 +971,12 @@ table tr:first-child th:first-child { border: none;}
spawn(rand(0,15))
update_icon()
/obj/machinery/alarm/examine()
..()
/obj/machinery/alarm/examine(mob/user)
..(user)
if (buildstage < 2)
usr << "It is not wired."
user << "It is not wired."
if (buildstage < 1)
usr << "The circuit is missing."
user << "The circuit is missing."
/*
AIR ALARM CIRCUIT
Just a object used in constructing air alarms
@@ -1286,9 +1089,6 @@ FIRE ALARM
/obj/machinery/firealarm/bullet_act(BLAH)
return src.alarm()
/obj/machinery/firealarm/attack_paw(mob/user as mob)
return src.attack_hand(user)
/obj/machinery/firealarm/emp_act(severity)
if(prob(50/severity)) alarm()
..()
@@ -1488,7 +1288,7 @@ FIRE ALARM
wiresexposed = 1
pixel_x = (dir & 3)? 0 : (dir == 4 ? -24 : 24)
pixel_y = (dir & 3)? (dir ==1 ? -24 : 24) : 0
/obj/machinery/firealarm/initialize()
if(z in config.contact_levels)
if(security_level)
@@ -1571,9 +1371,6 @@ Code shamelessly copied from apc_frame
idle_power_usage = 2
active_power_usage = 6
/obj/machinery/partyalarm/attack_paw(mob/user as mob)
return attack_hand(user)
/obj/machinery/partyalarm/attack_hand(mob/user as mob)
if(user.stat || stat & (NOPOWER|BROKEN))
return
@@ -21,9 +21,6 @@
attack_ai(var/mob/user as mob)
return src.attack_hand(user)
attack_paw(var/mob/user as mob)
return
attack_hand(var/mob/user as mob)
if(..(user))
return
+22 -20
View File
@@ -11,8 +11,8 @@
var/canister_color = "yellow"
var/can_label = 1
var/filled = 0.5
pressure_resistance = 7*ONE_ATMOSPHERE
start_pressure = 45 * ONE_ATMOSPHERE
pressure_resistance = 7 * ONE_ATMOSPHERE
var/temperature_resistance = 1000 + T0C
volume = 1000
use_power = 0
@@ -24,33 +24,44 @@
icon_state = "redws"
canister_color = "redws"
can_label = 0
/obj/machinery/portable_atmospherics/canister/nitrogen
name = "Canister: \[N2\]"
icon_state = "red"
canister_color = "red"
can_label = 0
/obj/machinery/portable_atmospherics/canister/oxygen
name = "Canister: \[O2\]"
icon_state = "blue"
canister_color = "blue"
can_label = 0
/obj/machinery/portable_atmospherics/canister/phoron
name = "Canister \[Phoron\]"
icon_state = "orange"
canister_color = "orange"
can_label = 0
/obj/machinery/portable_atmospherics/canister/carbon_dioxide
name = "Canister \[CO2\]"
icon_state = "black"
canister_color = "black"
can_label = 0
/obj/machinery/portable_atmospherics/canister/air
name = "Canister \[Air\]"
icon_state = "grey"
canister_color = "grey"
can_label = 0
/obj/machinery/portable_atmospherics/canister/air/airlock
filled = 0.05
start_pressure = 3 * ONE_ATMOSPHERE
/obj/machinery/portable_atmospherics/canister/empty/
start_pressure = 0
can_label = 1
/obj/machinery/portable_atmospherics/canister/empty/oxygen
name = "Canister: \[O2\]"
icon_state = "blue"
@@ -243,9 +254,6 @@ update_flag
/obj/machinery/portable_atmospherics/canister/attack_ai(var/mob/user as mob)
return src.attack_hand(user)
/obj/machinery/portable_atmospherics/canister/attack_paw(var/mob/user as mob)
return src.attack_hand(user)
/obj/machinery/portable_atmospherics/canister/attack_hand(var/mob/user as mob)
return src.ui_interact(user)
@@ -345,28 +353,23 @@ update_flag
return 1
/obj/machinery/portable_atmospherics/canister/phoron/New()
..()
src.air_contents.adjust_gas("phoron", (src.maximum_pressure*filled)*air_contents.volume/(R_IDEAL_GAS_EQUATION*air_contents.temperature))
src.air_contents.adjust_gas("phoron", MolesForPressure())
src.update_icon()
return 1
/obj/machinery/portable_atmospherics/canister/oxygen/New()
..()
src.air_contents.adjust_gas("oxygen", (src.maximum_pressure*filled)*air_contents.volume/(R_IDEAL_GAS_EQUATION*air_contents.temperature))
src.air_contents.adjust_gas("oxygen", MolesForPressure())
src.update_icon()
return 1
/obj/machinery/portable_atmospherics/canister/sleeping_agent/New()
..()
air_contents.adjust_gas("sleeping_agent", (src.maximum_pressure*filled)*air_contents.volume/(R_IDEAL_GAS_EQUATION*air_contents.temperature))
air_contents.adjust_gas("sleeping_agent", MolesForPressure())
src.update_icon()
return 1
@@ -387,22 +390,21 @@ update_flag
..()
src.air_contents.adjust_gas("nitrogen", (src.maximum_pressure*filled)*air_contents.volume/(R_IDEAL_GAS_EQUATION*air_contents.temperature))
src.air_contents.adjust_gas("nitrogen", MolesForPressure())
src.update_icon()
return 1
/obj/machinery/portable_atmospherics/canister/carbon_dioxide/New()
..()
src.air_contents.adjust_gas("carbon_dioxide", (src.maximum_pressure*filled)*air_contents.volume/(R_IDEAL_GAS_EQUATION*air_contents.temperature))
src.air_contents.adjust_gas("carbon_dioxide", MolesForPressure())
src.update_icon()
return 1
/obj/machinery/portable_atmospherics/canister/air/New()
..()
src.air_contents.adjust_multi("oxygen", (O2STANDARD*src.maximum_pressure*filled)*air_contents.volume/(R_IDEAL_GAS_EQUATION*air_contents.temperature), "nitrogen", (N2STANDARD*src.maximum_pressure*filled)*air_contents.volume/(R_IDEAL_GAS_EQUATION*air_contents.temperature))
var/list/air_mix = StandardAirMix()
src.air_contents.adjust_multi("oxygen", air_mix["oxygen"], "nitrogen", air_mix["nitrogen"])
src.update_icon()
return 1
+4 -4
View File
@@ -65,10 +65,10 @@
)
radio_connection.post_signal(src, signal)
/obj/machinery/meter/examine()
/obj/machinery/meter/examine(mob/user)
var/t = "A gas flow meter. "
if(get_dist(usr, src) > 3 && !(istype(usr, /mob/living/silicon/ai) || istype(usr, /mob/dead)))
if(get_dist(user, src) > 3 && !(istype(user, /mob/living/silicon/ai) || istype(user, /mob/dead)))
t += "\blue <B>You are too far away to read it.</B>"
else if(stat & (NOPOWER|BROKEN))
@@ -83,12 +83,12 @@
else
t += "The connect error light is blinking."
usr << t
user << t
/obj/machinery/meter/Click()
if(istype(usr, /mob/living/silicon/ai)) // ghosts can call ..() for examine
examine()
usr.examinate(src)
return 1
return ..()
@@ -9,7 +9,8 @@
var/volume = 0
var/destroyed = 0
var/maximum_pressure = 90*ONE_ATMOSPHERE
var/start_pressure = ONE_ATMOSPHERE
var/maximum_pressure = 90 * ONE_ATMOSPHERE
/obj/machinery/portable_atmospherics/New()
..()
@@ -39,6 +40,14 @@
..()
/obj/machinery/portable_atmospherics/proc/StandardAirMix()
return list(
"oxygen" = O2STANDARD * MolesForPressure(),
"nitrogen" = N2STANDARD * MolesForPressure())
/obj/machinery/portable_atmospherics/proc/MolesForPressure(var/target_pressure = start_pressure)
return (target_pressure * air_contents.volume) / (R_IDEAL_GAS_EQUATION * air_contents.temperature)
/obj/machinery/portable_atmospherics/update_icon()
return null
+16 -13
View File
@@ -10,14 +10,20 @@
var/target_pressure = 100
volume = 1000
power_rating = 7500 //7500 W ~ 10 HP
power_losses = 150
/obj/machinery/portable_atmospherics/powered/pump/filled
start_pressure = 90 * ONE_ATMOSPHERE
/obj/machinery/portable_atmospherics/powered/pump/New()
..()
cell = new/obj/item/weapon/cell(src)
var/list/air_mix = StandardAirMix()
src.air_contents.adjust_multi("oxygen", air_mix["oxygen"], "nitrogen", air_mix["nitrogen"])
/obj/machinery/portable_atmospherics/powered/pump/update_icon()
src.overlays = 0
@@ -53,16 +59,16 @@
/obj/machinery/portable_atmospherics/powered/pump/process()
..()
var/power_draw = -1
if(on && cell && cell.charge)
var/datum/gas_mixture/environment
if(holding)
environment = holding.air_contents
else
environment = loc.return_air()
var/pressure_delta
var/output_volume
var/output_volume
var/air_temperature
if(direction_out)
pressure_delta = target_pressure - environment.return_pressure()
@@ -72,15 +78,15 @@
pressure_delta = target_pressure - air_contents.return_pressure()
output_volume = air_contents.volume * air_contents.group_multiplier
air_temperature = air_contents.temperature? air_contents.temperature : environment.temperature
var/transfer_moles = pressure_delta*output_volume/(air_temperature * R_IDEAL_GAS_EQUATION)
if (pressure_delta > 0.01)
if (direction_out)
power_draw = pump_gas(src, air_contents, environment, transfer_moles, power_rating)
else
power_draw = pump_gas(src, environment, air_contents, transfer_moles, power_rating)
if (power_draw < 0)
last_flow_rate = 0
last_power_draw = 0
@@ -88,13 +94,13 @@
power_draw = max(power_draw, power_losses)
cell.use(power_draw * CELLRATE)
last_power_draw = power_draw
update_connected_network()
//ran out of charge
if (!cell.charge)
update_icon()
src.updateDialog()
/obj/machinery/portable_atmospherics/powered/pump/return_air()
@@ -103,9 +109,6 @@
/obj/machinery/portable_atmospherics/powered/pump/attack_ai(var/mob/user as mob)
return src.attack_hand(user)
/obj/machinery/portable_atmospherics/powered/pump/attack_paw(var/mob/user as mob)
return src.attack_hand(user)
/obj/machinery/portable_atmospherics/powered/pump/attack_hand(var/mob/user as mob)
user.set_machine(src)

Some files were not shown because too many files have changed in this diff Show More