Merge resolution.
@@ -1146,6 +1146,7 @@
|
||||
#include "code\modules\organs\wound.dm"
|
||||
#include "code\modules\paperwork\carbonpaper.dm"
|
||||
#include "code\modules\paperwork\clipboard.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"
|
||||
@@ -1171,9 +1172,7 @@
|
||||
#include "code\modules\power\lighting.dm"
|
||||
#include "code\modules\power\port_gen.dm"
|
||||
#include "code\modules\power\power.dm"
|
||||
#include "code\modules\power\power_monitor.dm"
|
||||
#include "code\modules\power\powernet.dm"
|
||||
#include "code\modules\power\profiling.dm"
|
||||
#include "code\modules\power\smes.dm"
|
||||
#include "code\modules\power\smes_construction.dm"
|
||||
#include "code\modules\power\solar.dm"
|
||||
@@ -1183,6 +1182,8 @@
|
||||
#include "code\modules\power\antimatter\containment_jar.dm"
|
||||
#include "code\modules\power\antimatter\control.dm"
|
||||
#include "code\modules\power\antimatter\shielding.dm"
|
||||
#include "code\modules\power\sensors\powernet_sensor.dm"
|
||||
#include "code\modules\power\sensors\sensor_monitoring.dm"
|
||||
#include "code\modules\power\singularity\collector.dm"
|
||||
#include "code\modules\power\singularity\containment_field.dm"
|
||||
#include "code\modules\power\singularity\emitter.dm"
|
||||
@@ -1312,6 +1313,7 @@
|
||||
#include "code\modules\research\xenoarchaeology\artifact\effects\unknown_effect_teleport.dm"
|
||||
#include "code\modules\research\xenoarchaeology\finds\finds.dm"
|
||||
#include "code\modules\research\xenoarchaeology\finds\finds_defines.dm"
|
||||
#include "code\modules\research\xenoarchaeology\finds\finds_eguns.dm"
|
||||
#include "code\modules\research\xenoarchaeology\finds\finds_fossils.dm"
|
||||
#include "code\modules\research\xenoarchaeology\finds\finds_misc.dm"
|
||||
#include "code\modules\research\xenoarchaeology\finds\finds_special.dm"
|
||||
@@ -1484,7 +1486,6 @@
|
||||
#include "code\WorkInProgress\computer3\computers\robot.dm"
|
||||
#include "code\WorkInProgress\computer3\computers\security.dm"
|
||||
#include "code\WorkInProgress\computer3\computers\welcome.dm"
|
||||
#include "code\WorkInProgress\kilakk\fax.dm"
|
||||
#include "code\WorkInProgress\Mini\atmos_control.dm"
|
||||
#include "code\WorkInProgress\Ported\policetape.dm"
|
||||
#include "code\WorkInProgress\SkyMarshal\officer_stuff.dm"
|
||||
|
||||
@@ -178,13 +178,8 @@
|
||||
|
||||
/obj/machinery/atmospherics/unary/freezer/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()
|
||||
|
||||
//dismantling code. copied from autolathe
|
||||
/obj/machinery/atmospherics/unary/freezer/attackby(var/obj/item/O as obj, var/mob/user as mob)
|
||||
if(istype(O, /obj/item/weapon/screwdriver))
|
||||
|
||||
@@ -161,13 +161,8 @@
|
||||
|
||||
/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()
|
||||
|
||||
//dismantling code. copied from autolathe
|
||||
/obj/machinery/atmospherics/unary/heater/attackby(var/obj/item/O as obj, var/mob/user as mob)
|
||||
if(istype(O, /obj/item/weapon/screwdriver))
|
||||
|
||||
@@ -1,213 +0,0 @@
|
||||
var/list/obj/machinery/faxmachine/allfaxes = list()
|
||||
var/list/alldepartments = list("Central Command")
|
||||
|
||||
/obj/machinery/faxmachine
|
||||
name = "fax machine"
|
||||
icon = 'icons/obj/library.dmi'
|
||||
icon_state = "fax"
|
||||
req_one_access = list(access_lawyer, access_heads, access_armory) //Warden needs to be able to Fax solgov too.
|
||||
anchored = 1
|
||||
density = 1
|
||||
use_power = 1
|
||||
idle_power_usage = 30
|
||||
active_power_usage = 200
|
||||
power_channel = EQUIP
|
||||
|
||||
var/obj/item/weapon/card/id/scan = null // identification
|
||||
var/authenticated = 0
|
||||
|
||||
var/obj/item/weapon/paper/tofax = null // what we're sending
|
||||
var/sendcooldown = 0 // to avoid spamming fax messages
|
||||
|
||||
var/department = "Unknown" // our department
|
||||
|
||||
var/dpt = "Central Command" // the department we're sending to
|
||||
|
||||
|
||||
/obj/machinery/faxmachine/New()
|
||||
..()
|
||||
allfaxes += src
|
||||
|
||||
if( !("[department]" in alldepartments) )
|
||||
alldepartments += department
|
||||
alldepartments += "Sol Government"
|
||||
|
||||
/obj/machinery/faxmachine/process()
|
||||
return 0
|
||||
|
||||
/obj/machinery/faxmachine/attack_ai(mob/user as mob)
|
||||
return attack_hand(user)
|
||||
|
||||
/obj/machinery/faxmachine/attack_hand(mob/user as mob)
|
||||
user.set_machine(src)
|
||||
|
||||
var/dat = "Fax Machine<BR>"
|
||||
|
||||
var/scan_name
|
||||
if(scan)
|
||||
scan_name = scan.name
|
||||
else
|
||||
scan_name = "--------"
|
||||
|
||||
dat += "Confirm Identity: <a href='byond://?src=\ref[src];scan=1'>[scan_name]</a><br>"
|
||||
|
||||
if(authenticated)
|
||||
dat += "<a href='byond://?src=\ref[src];logout=1'>{Log Out}</a>"
|
||||
else
|
||||
dat += "<a href='byond://?src=\ref[src];auth=1'>{Log In}</a>"
|
||||
|
||||
dat += "<hr>"
|
||||
|
||||
if(authenticated)
|
||||
dat += "<b>Logged in to:</b> Central Command Quantum Entanglement Network<br><br>"
|
||||
|
||||
if(tofax)
|
||||
dat += "<a href='byond://?src=\ref[src];remove=1'>Remove Paper</a><br><br>"
|
||||
|
||||
if(sendcooldown)
|
||||
dat += "<b>Transmitter arrays realigning. Please stand by.</b><br>"
|
||||
|
||||
else
|
||||
dat += "<a href='byond://?src=\ref[src];send=1'>Send</a><br>"
|
||||
dat += "<b>Currently sending:</b> [tofax.name]<br>"
|
||||
dat += "<b>Sending to:</b> <a href='byond://?src=\ref[src];dept=1'>[dpt]</a><br>"
|
||||
|
||||
else
|
||||
if(sendcooldown)
|
||||
dat += "Please insert paper to send via secure connection.<br><br>"
|
||||
dat += "<b>Transmitter arrays realigning. Please stand by.</b><br>"
|
||||
else
|
||||
dat += "Please insert paper to send via secure connection.<br><br>"
|
||||
|
||||
else
|
||||
dat += "Proper authentication is required to use this device.<br><br>"
|
||||
|
||||
if(tofax)
|
||||
dat += "<a href ='byond://?src=\ref[src];remove=1'>Remove Paper</a><br>"
|
||||
|
||||
user << browse(dat, "window=copier")
|
||||
onclose(user, "copier")
|
||||
return
|
||||
|
||||
/obj/machinery/faxmachine/Topic(href, href_list)
|
||||
if(href_list["send"])
|
||||
if(tofax)
|
||||
|
||||
if(dpt == "Central Command")
|
||||
Centcomm_fax(src, tofax.info, tofax.name, usr)
|
||||
sendcooldown = 1800
|
||||
|
||||
else if(dpt == "Sol Government")
|
||||
Solgov_fax(src, tofax.info, tofax.name, usr)
|
||||
sendcooldown = 1800
|
||||
else
|
||||
SendFax(tofax.info, tofax.name, usr, dpt)
|
||||
sendcooldown = 600
|
||||
|
||||
usr << "Message transmitted successfully."
|
||||
|
||||
spawn(sendcooldown) // cooldown time
|
||||
sendcooldown = 0
|
||||
|
||||
if(href_list["remove"])
|
||||
if(tofax)
|
||||
if(!ishuman(usr))
|
||||
usr << "<span class='warning'>You can't do it.</span>"
|
||||
else
|
||||
tofax.loc = usr.loc
|
||||
usr.put_in_hands(tofax)
|
||||
usr << "<span class='notice'>You take the paper out of \the [src].</span>"
|
||||
tofax = null
|
||||
|
||||
if(href_list["scan"])
|
||||
if (scan)
|
||||
if(ishuman(usr))
|
||||
scan.loc = usr.loc
|
||||
if(!usr.get_active_hand())
|
||||
usr.put_in_hands(scan)
|
||||
scan = null
|
||||
else
|
||||
scan.loc = src.loc
|
||||
scan = null
|
||||
else
|
||||
var/obj/item/I = usr.get_active_hand()
|
||||
if (istype(I, /obj/item/weapon/card/id))
|
||||
usr.drop_item()
|
||||
I.loc = src
|
||||
scan = I
|
||||
authenticated = 0
|
||||
|
||||
if(href_list["dept"])
|
||||
var/lastdpt = dpt
|
||||
dpt = input(usr, "Which department?", "Choose a department", "") as null|anything in alldepartments
|
||||
if(!dpt) dpt = lastdpt
|
||||
|
||||
if(href_list["auth"])
|
||||
if ( (!( authenticated ) && (scan)) )
|
||||
if (check_access(scan))
|
||||
authenticated = 1
|
||||
|
||||
if(href_list["logout"])
|
||||
authenticated = 0
|
||||
|
||||
updateUsrDialog()
|
||||
|
||||
/obj/machinery/faxmachine/attackby(obj/item/O as obj, mob/user as mob)
|
||||
|
||||
if(istype(O, /obj/item/weapon/paper))
|
||||
if(!tofax)
|
||||
user.drop_item()
|
||||
tofax = O
|
||||
O.loc = src
|
||||
user << "<span class='notice'>You insert the paper into \the [src].</span>"
|
||||
flick("faxsend", src)
|
||||
updateUsrDialog()
|
||||
else
|
||||
user << "<span class='notice'>There is already something in \the [src].</span>"
|
||||
|
||||
else if(istype(O, /obj/item/weapon/card/id))
|
||||
|
||||
var/obj/item/weapon/card/id/idcard = O
|
||||
if(!scan)
|
||||
usr.drop_item()
|
||||
idcard.loc = src
|
||||
scan = idcard
|
||||
|
||||
else if(istype(O, /obj/item/weapon/wrench))
|
||||
playsound(loc, 'sound/items/Ratchet.ogg', 50, 1)
|
||||
anchored = !anchored
|
||||
user << "<span class='notice'>You [anchored ? "wrench" : "unwrench"] \the [src].</span>"
|
||||
return
|
||||
|
||||
/proc/Centcomm_fax(var/originfax, var/sent, var/sentname, var/mob/Sender)
|
||||
|
||||
var/msg = "\blue <b><font color='#006100'>CENTCOMM FAX: </font>[key_name(Sender, 1)] (<A HREF='?_src_=holder;adminplayeropts=\ref[Sender]'>PP</A>) (<A HREF='?_src_=vars;Vars=\ref[Sender]'>VV</A>) (<A HREF='?_src_=holder;subtlemessage=\ref[Sender]'>SM</A>) (<A HREF='?_src_=holder;adminplayerobservejump=\ref[Sender]'>JMP</A>) (<A HREF='?_src_=holder;secretsadmin=check_antagonist'>CA</A>) (<a href='?_src_=holder;CentcommFaxReply=\ref[Sender];originfax=\ref[originfax]'>RPLY</a>)</b>: Receiving '[sentname]' via secure connection ... <a href='?_src_=holder;CentcommFaxView=\ref[sent]'>view message</a>"
|
||||
|
||||
for(var/client/C in admins)
|
||||
if(R_ADMIN & C.holder.rights)
|
||||
C << msg
|
||||
|
||||
/proc/Solgov_fax(var/originfax, var/sent, var/sentname, var/mob/Sender)
|
||||
var/msg = "\blue <b><font color='#1F66A0'>SOL GOVERNMENT FAX: </font>[key_name(Sender, 1)] (<A HREF='?_src_=holder;adminplayeropts=\ref[Sender]'>PP</A>) (<A HREF='?_src_=vars;Vars=\ref[Sender]'>VV</A>) (<A HREF='?_src_=holder;subtlemessage=\ref[Sender]'>SM</A>) (<A HREF='?_src_=holder;adminplayerobservejump=\ref[Sender]'>JMP</A>) (<A HREF='?_src_=holder;secretsadmin=check_antagonist'>CA</A>) (<a href='?_src_=holder;SolGovFaxReply=\ref[Sender];originfax=\ref[originfax]'>RPLY</a>)</b>: Receiving '[sentname]' via secure connection ... <a href='?_src_=holder;CentcommFaxView=\ref[sent]'>view message</a>"
|
||||
|
||||
for(var/client/C in admins)
|
||||
if(R_ADMIN & C.holder.rights)
|
||||
C << msg
|
||||
|
||||
|
||||
proc/SendFax(var/sent, var/sentname, var/mob/Sender, var/dpt)
|
||||
|
||||
for(var/obj/machinery/faxmachine/F in allfaxes)
|
||||
if( F.department == dpt )
|
||||
if(! (F.stat & (BROKEN|NOPOWER) ) )
|
||||
|
||||
flick("faxreceive", F)
|
||||
|
||||
// give the sprite some time to flick
|
||||
spawn(20)
|
||||
var/obj/item/weapon/paper/P = new /obj/item/weapon/paper( F.loc )
|
||||
P.name = "[sentname]"
|
||||
P.info = "[sent]"
|
||||
P.update_icon()
|
||||
|
||||
playsound(F.loc, "sound/items/polaroid1.ogg", 50, 1)
|
||||
@@ -31,7 +31,6 @@ datum/controller/game_controller
|
||||
|
||||
var/last_thing_processed
|
||||
var/mob/list/expensive_mobs = list()
|
||||
var/rebuild_active_areas = 0
|
||||
|
||||
var/list/shuttle_list // For debugging and VV
|
||||
var/datum/ore_distribution/asteroid_ore_map // For debugging and VV.
|
||||
@@ -277,8 +276,6 @@ datum/controller/game_controller/proc/process_diseases()
|
||||
datum/controller/game_controller/proc/process_machines()
|
||||
process_machines_sort()
|
||||
process_machines_process()
|
||||
process_machines_power()
|
||||
process_machines_rebuild()
|
||||
|
||||
/var/global/machinery_sort_required = 0
|
||||
datum/controller/game_controller/proc/process_machines_sort()
|
||||
@@ -287,49 +284,14 @@ datum/controller/game_controller/proc/process_machines_sort()
|
||||
machines = dd_sortedObjectList(machines)
|
||||
|
||||
datum/controller/game_controller/proc/process_machines_process()
|
||||
var/i = 1
|
||||
while(i<=machines.len)
|
||||
var/obj/machinery/Machine = machines[i]
|
||||
if(Machine)
|
||||
last_thing_processed = Machine.type
|
||||
if(Machine.process() != PROCESS_KILL)
|
||||
if(Machine)
|
||||
i++
|
||||
continue
|
||||
machines.Cut(i,i+1)
|
||||
|
||||
datum/controller/game_controller/proc/process_machines_power()
|
||||
var/i=1
|
||||
while(i<=active_areas.len)
|
||||
var/area/A = active_areas[i]
|
||||
if(A.powerupdate && A.master == A)
|
||||
A.powerupdate -= 1
|
||||
A.clear_usage()
|
||||
for(var/j = 1; j <= A.related.len; j++)
|
||||
var/area/SubArea = A.related[j]
|
||||
for(var/obj/machinery/M in SubArea)
|
||||
if(M)
|
||||
//check if the area has power for M's channel
|
||||
//this will keep stat updated in case the machine is moved from one area to another.
|
||||
M.power_change(A) //we've already made sure A is a master area, above.
|
||||
|
||||
if(!(M.stat & NOPOWER) && M.use_power)
|
||||
M.auto_use_power()
|
||||
|
||||
if(A.apc.len && A.master == A)
|
||||
i++
|
||||
continue
|
||||
|
||||
A.powerupdate = 0
|
||||
active_areas.Cut(i,i+1)
|
||||
|
||||
datum/controller/game_controller/proc/process_machines_rebuild()
|
||||
if(controller_iteration % 150 == 0 || rebuild_active_areas) //Every 300 seconds we retest every area/machine
|
||||
for(var/area/A in all_areas)
|
||||
if(A == A.master)
|
||||
A.powerupdate += 1
|
||||
active_areas |= A
|
||||
rebuild_active_areas = 0
|
||||
for(var/obj/machinery/Machine in machines)
|
||||
last_thing_processed = Machine.type
|
||||
if(Machine.process() != PROCESS_KILL)
|
||||
if(Machine)
|
||||
if(Machine.use_power)
|
||||
Machine.auto_use_power()
|
||||
continue
|
||||
machines -= Machine
|
||||
|
||||
|
||||
datum/controller/game_controller/proc/process_objects()
|
||||
|
||||
@@ -1,65 +1,47 @@
|
||||
#define SOLAR_UPDATE_TIME 600 //duration between two updates of the whole sun/solars positions
|
||||
|
||||
/datum/sun
|
||||
var/angle
|
||||
var/dx
|
||||
var/dy
|
||||
// var/counter = 50 // to make the vars update during 1st call
|
||||
var/rate
|
||||
var/list/solars // for debugging purposes, references solars_list at the constructor
|
||||
var/nexttime = 3600 // Replacement for var/counter to force the sun to move every X IC minutes
|
||||
var/lastAngleUpdate
|
||||
var/solar_next_update // last time the sun position was checked and adjusted
|
||||
|
||||
/datum/sun/New()
|
||||
|
||||
solars = solars_list
|
||||
rate = rand(750,1250)/1000 // 75.0% - 125.0% of standard rotation
|
||||
if(prob(50))
|
||||
rate = rand(50,200)/100 // 50% - 200% of standard rotation
|
||||
if(prob(50)) // same chance to rotate clockwise than counter-clockwise
|
||||
rate = -rate
|
||||
solar_next_update = world.time // init the timer
|
||||
angle = rand (0,360) // the station position to the sun is randomised at round start
|
||||
|
||||
/hook/startup/proc/createSun()
|
||||
sun = new /datum/sun()
|
||||
return 1
|
||||
|
||||
// calculate the sun's position given the time of day
|
||||
|
||||
// at the standard rate (100%) the angle is increase/decreased by 6 degrees every minute.
|
||||
// a full rotation thus take a game hour in that case
|
||||
/datum/sun/proc/calc_position()
|
||||
|
||||
/* counter++
|
||||
if(counter<50) // count 50 pticks (50 seconds, roughly - about a 5deg change)
|
||||
return
|
||||
counter = 0 */
|
||||
if(world.time < solar_next_update) //if less than 60 game secondes have passed, do nothing
|
||||
return;
|
||||
|
||||
angle = ((rate*world.time/100)%360 + 360)%360
|
||||
angle = (360 + angle + rate * 6) % 360 // increase/decrease the angle to the sun, adjusted by the rate
|
||||
|
||||
/*
|
||||
Yields a 45 - 75 IC minute rotational period
|
||||
Rotation rate can vary from 4.8 deg/min to 8 deg/min (288 to 480 deg/hr)
|
||||
*/
|
||||
|
||||
if(lastAngleUpdate != angle)
|
||||
for(var/obj/machinery/power/tracker/T in solars_list)
|
||||
if(!T.powernet)
|
||||
solars_list.Remove(T)
|
||||
continue
|
||||
T.set_angle(angle)
|
||||
lastAngleUpdate=angle
|
||||
|
||||
|
||||
|
||||
if(nexttime > world.time)
|
||||
return
|
||||
nexttime = nexttime + 600 // 600 world.time ticks = 1 minute
|
||||
solar_next_update += SOLAR_UPDATE_TIME // since we updated the angle, set the proper time for the next loop
|
||||
|
||||
// now calculate and cache the (dx,dy) increments for line drawing
|
||||
|
||||
var/s = sin(angle)
|
||||
var/c = cos(angle)
|
||||
|
||||
if(c == 0)
|
||||
// Either "abs(s) < abs(c)" or "abs(s) >= abs(c)"
|
||||
// In both cases, the greater is greater than 0, so, no "if 0" check is needed for the divisions
|
||||
|
||||
dx = 0
|
||||
dy = s
|
||||
|
||||
else if( abs(s) < abs(c))
|
||||
if( abs(s) < abs(c))
|
||||
|
||||
dx = s / abs(c)
|
||||
dy = c / abs(c)
|
||||
@@ -68,40 +50,9 @@
|
||||
dx = s/abs(s)
|
||||
dy = c / abs(s)
|
||||
|
||||
|
||||
for(var/obj/machinery/power/solar/S in solars_list)
|
||||
|
||||
if(!S.powernet)
|
||||
solars_list.Remove(S)
|
||||
//now tell the solar control computers to update their status and linked devices
|
||||
for(var/obj/machinery/power/solar_control/SC in solars_list)
|
||||
if(!SC.powernet)
|
||||
solars_list.Remove(SC)
|
||||
continue
|
||||
if(S.control)
|
||||
occlusion(S)
|
||||
|
||||
|
||||
|
||||
// for a solar panel, trace towards sun to see if we're in shadow
|
||||
|
||||
/datum/sun/proc/occlusion(var/obj/machinery/power/solar/S)
|
||||
|
||||
var/ax = S.x // start at the solar panel
|
||||
var/ay = S.y
|
||||
|
||||
for(var/i = 1 to 20) // 20 steps is enough
|
||||
ax += dx // do step
|
||||
ay += dy
|
||||
|
||||
var/turf/T = locate( round(ax,0.5),round(ay,0.5),S.z)
|
||||
|
||||
if(T.x == 1 || T.x==world.maxx || T.y==1 || T.y==world.maxy) // not obscured if we reach the edge
|
||||
break
|
||||
|
||||
if(T.density) // if we hit a solid turf, panel is obscured
|
||||
S.obscured = 1
|
||||
return
|
||||
|
||||
S.obscured = 0 // if hit the edge or stepped 20 times, not obscured
|
||||
S.update_solar_exposure()
|
||||
|
||||
|
||||
|
||||
|
||||
SC.update()
|
||||
|
||||
@@ -33,7 +33,6 @@ NOTE: there are two lists of areas in the end of this file: centcom and station
|
||||
var/eject = null
|
||||
|
||||
var/debug = 0
|
||||
var/powerupdate = 10 //We give everything 10 ticks to settle out it's power usage.
|
||||
var/requires_power = 1
|
||||
var/unlimited_power = 0
|
||||
var/always_unpowered = 0 //this gets overriden to 1 for space in area/New()
|
||||
|
||||
@@ -13,7 +13,6 @@
|
||||
master = src //moved outside the spawn(1) to avoid runtimes in lighting.dm when it references loc.loc.master ~Carn
|
||||
uid = ++global_uid
|
||||
related = list(src)
|
||||
active_areas += src
|
||||
all_areas += src
|
||||
|
||||
if(requires_power)
|
||||
|
||||
@@ -187,7 +187,7 @@ its easier to just keep the beam vertical.
|
||||
|
||||
|
||||
//All atoms
|
||||
/atom/proc/examine(mob/user, var/distance = -1)
|
||||
/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))
|
||||
@@ -197,7 +197,7 @@ its easier to just keep the beam vertical.
|
||||
f_name = "a "
|
||||
f_name += "<span class='danger'>blood-stained</span> [name]!"
|
||||
|
||||
user << "\icon[src] That's [f_name]"
|
||||
user << "\icon[src] That's [f_name] [sufix]"
|
||||
|
||||
if(desc)
|
||||
user << desc
|
||||
|
||||
@@ -9,13 +9,13 @@
|
||||
var/area/current_area = get_area(S)
|
||||
if(current_area.type in skipped_areas || !(S.z in config.station_levels))
|
||||
continue
|
||||
S.last_charge = S.charge
|
||||
S.last_output = S.output
|
||||
S.last_online = S.online
|
||||
S.last_charge = S.charge
|
||||
S.last_output_attempt = S.output_attempt
|
||||
S.last_input_attempt = S.input_attempt
|
||||
S.charge = 0
|
||||
S.output = 0
|
||||
S.online = 0
|
||||
S.updateicon()
|
||||
S.inputting(0)
|
||||
S.outputting(0)
|
||||
S.update_icon()
|
||||
S.power_change()
|
||||
|
||||
|
||||
@@ -36,9 +36,9 @@
|
||||
if(current_area.type in skipped_areas || isNotStationLevel(S.z))
|
||||
continue
|
||||
S.charge = S.last_charge
|
||||
S.output = S.last_output
|
||||
S.online = S.last_online
|
||||
S.updateicon()
|
||||
S.output_attempt = S.last_output_attempt
|
||||
S.input_attempt = S.last_input_attempt
|
||||
S.update_icon()
|
||||
S.power_change()
|
||||
|
||||
/proc/power_restore_quick(var/announce = 1)
|
||||
@@ -49,7 +49,8 @@
|
||||
if(isNotStationLevel(S.z))
|
||||
continue
|
||||
S.charge = S.capacity
|
||||
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.output_level = S.output_level_max
|
||||
S.output_attempt = 1
|
||||
S.input_attempt = 1
|
||||
S.update_icon()
|
||||
S.power_change()
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
mode = M
|
||||
|
||||
proc/announce_directives()
|
||||
for (var/obj/machinery/faxmachine/fax in world)
|
||||
for (var/obj/machinery/photocopier/faxmachine/fax in world)
|
||||
if (fax.department == "Captain's Office")
|
||||
var/obj/item/weapon/paper/directive_x = new(fax.loc)
|
||||
directive_x.name = "emergency action message"
|
||||
|
||||
@@ -356,6 +356,8 @@ var/global/datum/controller/occupations/job_master
|
||||
if(job)
|
||||
|
||||
//Equip custom gear loadout.
|
||||
var/list/custom_equip_slots = list() //If more than one item takes the same slot, all after the first one spawn in storage.
|
||||
var/list/custom_equip_leftovers = list()
|
||||
if(H.client.prefs.gear && H.client.prefs.gear.len && job.title != "Cyborg" && job.title != "AI")
|
||||
|
||||
for(var/thing in H.client.prefs.gear)
|
||||
@@ -376,9 +378,12 @@ var/global/datum/controller/occupations/job_master
|
||||
H << "\red Your current job or whitelist status does not permit you to spawn with [thing]!"
|
||||
continue
|
||||
|
||||
if(G.slot)
|
||||
H.equip_to_slot_or_del(new G.path(H), G.slot)
|
||||
H << "\blue Equipping you with [thing]!"
|
||||
if(G.slot && !(G.slot in custom_equip_slots))
|
||||
if(H.equip_to_slot_or_del(new G.path(H), G.slot))
|
||||
H << "\blue Equipping you with [thing]!"
|
||||
custom_equip_slots.Add(G.slot)
|
||||
else
|
||||
custom_equip_leftovers.Add(thing)
|
||||
|
||||
else
|
||||
spawn_in_storage += thing
|
||||
@@ -387,6 +392,17 @@ var/global/datum/controller/occupations/job_master
|
||||
//Equip job items.
|
||||
job.equip(H)
|
||||
job.apply_fingerprints(H)
|
||||
//If some custom items could not be equipped before, try again now.
|
||||
for(var/thing in custom_equip_leftovers)
|
||||
var/datum/gear/G = gear_datums[thing]
|
||||
if(G.slot in custom_equip_slots)
|
||||
spawn_in_storage += thing
|
||||
else
|
||||
if(H.equip_to_slot_or_del(new G.path(H), G.slot))
|
||||
H << "\blue Equipping you with [thing]!"
|
||||
custom_equip_slots.Add(G.slot)
|
||||
else
|
||||
spawn_in_storage += thing
|
||||
else
|
||||
H << "Your job is [rank] and the game just can't handle it! Please report this bug to an administrator."
|
||||
|
||||
@@ -630,4 +646,4 @@ var/global/datum/controller/occupations/job_master
|
||||
else level4++ //not selected
|
||||
|
||||
tmp_str += "HIGH=[level1]|MEDIUM=[level2]|LOW=[level3]|NEVER=[level4]|BANNED=[level5]|YOUNG=[level6]|-"
|
||||
feedback_add_details("job_preferences",tmp_str)
|
||||
feedback_add_details("job_preferences",tmp_str)
|
||||
@@ -819,7 +819,7 @@ table tr:first-child th:first-child { border: none;}
|
||||
var/list/selected = TLV[env]
|
||||
var/list/thresholds = list("lower bound", "low warning", "high warning", "upper bound")
|
||||
var/newval = input("Enter [thresholds[threshold]] for [env]", "Alarm triggers", selected[threshold]) as null|num
|
||||
if (isnull(newval) || ..() || (locked && issilicon(usr)))
|
||||
if (isnull(newval) || ..() || (locked && !issilicon(usr)))
|
||||
return
|
||||
if (newval<0)
|
||||
selected[threshold] = -1.0
|
||||
|
||||
@@ -311,6 +311,7 @@ update_flag
|
||||
release_log += "Valve was <b>opened</b> by [usr] ([usr.ckey]), starting the transfer into the [holding]<br>"
|
||||
else
|
||||
release_log += "Valve was <b>opened</b> by [usr] ([usr.ckey]), starting the transfer into the <font color='red'><b>air</b></font><br>"
|
||||
log_open()
|
||||
valve_open = !valve_open
|
||||
|
||||
if (href_list["remove_tank"])
|
||||
|
||||
@@ -184,3 +184,16 @@
|
||||
return
|
||||
|
||||
..()
|
||||
|
||||
/obj/machinery/portable_atmospherics/proc/log_open()
|
||||
if(air_contents.gas.len == 0)
|
||||
return
|
||||
|
||||
var/gases = ""
|
||||
for(var/gas in air_contents.gas)
|
||||
if(gases)
|
||||
gases += ", [gas]"
|
||||
else
|
||||
gases = gas
|
||||
log_admin("[usr] ([usr.ckey]) opened '[src.name]' containing [gases].")
|
||||
message_admins("[usr] ([usr.ckey]) opened '[src.name]' containing [gases].")
|
||||
|
||||
@@ -181,7 +181,7 @@
|
||||
origin_tech = "programming=2;powerstorage=2"
|
||||
/obj/item/weapon/circuitboard/powermonitor
|
||||
name = "Circuit board (Power Monitor)"
|
||||
build_path = /obj/machinery/power/monitor
|
||||
build_path = /obj/machinery/computer/power_monitor
|
||||
/obj/item/weapon/circuitboard/olddoor
|
||||
name = "Circuit board (DoorMex)"
|
||||
build_path = /obj/machinery/computer/pod/old
|
||||
|
||||
@@ -180,19 +180,8 @@ Class Procs:
|
||||
|
||||
//sets the use_power var and then forces an area power update
|
||||
/obj/machinery/proc/update_use_power(var/new_use_power, var/force_update = 0)
|
||||
if ((new_use_power == use_power) && !force_update)
|
||||
return //don't need to do anything
|
||||
|
||||
use_power = new_use_power
|
||||
|
||||
//force area power update
|
||||
force_power_update()
|
||||
|
||||
/obj/machinery/proc/force_power_update()
|
||||
var/area/A = get_area(src)
|
||||
if(A && A.master)
|
||||
A.master.powerupdate = 1
|
||||
|
||||
/obj/machinery/proc/auto_use_power()
|
||||
if(!powered(power_channel))
|
||||
return 0
|
||||
@@ -235,9 +224,6 @@ Class Procs:
|
||||
|
||||
src.add_fingerprint(usr)
|
||||
|
||||
var/area/A = get_area(src)
|
||||
A.master.powerupdate = 1
|
||||
|
||||
return 0
|
||||
|
||||
/obj/machinery/attack_ai(mob/user as mob)
|
||||
@@ -275,14 +261,10 @@ Class Procs:
|
||||
|
||||
src.add_fingerprint(user)
|
||||
|
||||
var/area/A = get_area(src)
|
||||
A.master.powerupdate = 1
|
||||
|
||||
return 0
|
||||
|
||||
/obj/machinery/proc/RefreshParts() //Placeholder proc for machines that are built using frames.
|
||||
return
|
||||
return 0
|
||||
|
||||
/obj/machinery/proc/assign_uid()
|
||||
uid = gl_uid
|
||||
@@ -308,6 +290,12 @@ Class Procs:
|
||||
s.set_up(5, 1, src)
|
||||
s.start()
|
||||
if (electrocute_mob(user, get_area(src), src, 0.7))
|
||||
var/area/temp_area = get_area(src)
|
||||
if(temp_area && temp_area.master)
|
||||
var/obj/machinery/power/apc/temp_apc = temp_area.master.get_apc()
|
||||
|
||||
if(temp_apc && temp_apc.terminal && temp_apc.terminal.powernet)
|
||||
temp_apc.terminal.powernet.trigger_warning()
|
||||
return 1
|
||||
else
|
||||
return 0
|
||||
|
||||
@@ -98,7 +98,7 @@
|
||||
holder.icon_state = "hudhealth-100"
|
||||
C.images += holder
|
||||
else
|
||||
holder.icon_state = "hud[RoundHealth(patient.health)]"
|
||||
holder.icon_state = "hud[RoundHealth((patient.health-config.health_threshold_crit)/(patient.species.total_health-config.health_threshold_crit)*100)]"
|
||||
C.images += holder
|
||||
|
||||
holder = patient.hud_list[STATUS_HUD]
|
||||
|
||||
@@ -102,7 +102,7 @@
|
||||
|
||||
src.loc = T
|
||||
|
||||
/obj/item/examine(mob/user)
|
||||
/obj/item/examine(mob/user, var/distance = -1)
|
||||
var/size
|
||||
switch(src.w_class)
|
||||
if(1.0)
|
||||
@@ -117,10 +117,8 @@
|
||||
size = "huge"
|
||||
else
|
||||
//if ((CLUMSY in usr.mutations) && prob(50)) t = "funny-looking"
|
||||
user << "This is a [src.blood_DNA ? "bloody " : ""]\icon[src][src.name]. It is a [size] item."
|
||||
if(src.desc)
|
||||
user << src.desc
|
||||
return
|
||||
var/custom_sufix = "It is a [size] item."
|
||||
return ..(user, distance, custom_sufix)
|
||||
|
||||
/obj/item/attack_hand(mob/user as mob)
|
||||
if (!user) return
|
||||
@@ -399,6 +397,19 @@
|
||||
if(B.contents.len < B.storage_slots && w_class <= B.max_w_class)
|
||||
return 1
|
||||
return 0
|
||||
if(slot_tie)
|
||||
if(!H.w_uniform && (slot_w_uniform in mob_equip))
|
||||
if(!disable_warning)
|
||||
H << "\red You need a jumpsuit before you can attach this [name]."
|
||||
return 0
|
||||
var/obj/item/clothing/under/uniform = H.w_uniform
|
||||
if(uniform.hastie)
|
||||
if (!disable_warning)
|
||||
H << "\red You already have [uniform.hastie] attached to your [uniform]."
|
||||
return 0
|
||||
if( !(slot_flags & SLOT_TIE) )
|
||||
return 0
|
||||
return 1
|
||||
return 0 //Unsupported slot
|
||||
//END HUMAN
|
||||
|
||||
|
||||
@@ -263,10 +263,11 @@
|
||||
|
||||
|
||||
/* Power Monitor (Mode: 43 / 433) */
|
||||
/*
|
||||
if(mode==43 || mode==433)
|
||||
var/pMonData[0]
|
||||
var/apcData[0]
|
||||
for(var/obj/machinery/power/monitor/pMon in world)
|
||||
for(var/obj/machinery/computer/power_monitor/pMon in world)
|
||||
if(!(pMon.stat & (NOPOWER|BROKEN)) )
|
||||
var/turf/monitorturf = locate(pMon.x,pMon.y,pMon.z)
|
||||
var/area/monitorarea = monitorturf.loc
|
||||
@@ -293,7 +294,7 @@
|
||||
values["apcs"] = apcData
|
||||
else
|
||||
values["powerconnected"] = 0
|
||||
|
||||
*/
|
||||
|
||||
|
||||
|
||||
@@ -592,10 +593,12 @@
|
||||
updateSelfDialog()
|
||||
else
|
||||
post_status(href_list["statdisp"])
|
||||
/*
|
||||
if("Power Select")
|
||||
var/pref = href_list["target"]
|
||||
powmonitor = locate(pref)
|
||||
loc:mode = 433
|
||||
mode = 433
|
||||
´*/
|
||||
|
||||
return 1
|
||||
|
||||
@@ -14,9 +14,10 @@
|
||||
matter = list("metal" = 750,"waste" = 750)
|
||||
|
||||
origin_tech = "powerstorage=3;syndicate=5"
|
||||
var/drain_rate = 600000 // amount of power to drain per tick
|
||||
var/drain_rate = 1000000 // amount of power to drain per tick
|
||||
var/dissipation_rate = 20000
|
||||
var/power_drained = 0 // has drained this much power
|
||||
var/max_power = 1e8 // maximum power that can be drained before exploding
|
||||
var/max_power = 5e9 // maximum power that can be drained before exploding
|
||||
var/mode = 0 // 0 = off, 1=clamped (off), 2=operating
|
||||
|
||||
|
||||
@@ -86,11 +87,12 @@
|
||||
processing_objects.Remove(src)
|
||||
|
||||
process()
|
||||
power_drained -= min(dissipation_rate, power_drained)
|
||||
if(attached)
|
||||
var/datum/powernet/PN = attached.get_powernet()
|
||||
if(PN)
|
||||
SetLuminosity(12)
|
||||
|
||||
PN.trigger_warning()
|
||||
// found a powernet, so drain up to max power from it
|
||||
var/drained = PN.draw_power(drain_rate)
|
||||
|
||||
@@ -101,8 +103,8 @@
|
||||
if(istype(T.master, /obj/machinery/power/apc))
|
||||
var/obj/machinery/power/apc/A = T.master
|
||||
if(A.operating && A.cell)
|
||||
A.cell.charge = max(0, A.cell.charge - 50)
|
||||
power_drained += 50
|
||||
A.cell.charge = max(0, A.cell.charge - (2000 * CELLRATE))
|
||||
power_drained += 2000
|
||||
|
||||
|
||||
if(power_drained > max_power * 0.95)
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
/obj/item/device/radio/headset
|
||||
name = "radio headset"
|
||||
desc = "An updated, modular intercom that fits over the head. Takes encryption keys"
|
||||
var/radio_desc = ""
|
||||
icon_state = "headset"
|
||||
item_state = "headset"
|
||||
matter = list("metal" = 75)
|
||||
@@ -17,7 +18,14 @@
|
||||
/obj/item/device/radio/headset/New()
|
||||
..()
|
||||
keyslot1 = new /obj/item/device/encryptionkey/
|
||||
recalculateChannels()
|
||||
recalculateChannels(1)
|
||||
|
||||
/obj/item/device/radio/headset/examine(mob/user)
|
||||
if(!(..(user, 1) && radio_desc))
|
||||
return
|
||||
|
||||
user << "The following channels are built-in:"
|
||||
user << radio_desc
|
||||
|
||||
/obj/item/device/radio/headset/handle_message_mode(mob/living/M as mob, message, channel)
|
||||
if (channel == "special")
|
||||
@@ -47,7 +55,7 @@
|
||||
del(keyslot1)
|
||||
keyslot1 = new /obj/item/device/encryptionkey/syndicate
|
||||
syndie = 1
|
||||
recalculateChannels()
|
||||
recalculateChannels(1)
|
||||
|
||||
/obj/item/device/radio/headset/binary
|
||||
origin_tech = "syndicate=3"
|
||||
@@ -55,60 +63,60 @@
|
||||
..()
|
||||
del(keyslot1)
|
||||
keyslot1 = new /obj/item/device/encryptionkey/binary
|
||||
recalculateChannels()
|
||||
recalculateChannels(1)
|
||||
|
||||
/obj/item/device/radio/headset/headset_sec
|
||||
name = "security radio headset"
|
||||
desc = "This is used by your elite security force. To access the security channel, use :s."
|
||||
desc = "This is used by your elite security force."
|
||||
icon_state = "sec_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/headset_sec
|
||||
|
||||
/obj/item/device/radio/headset/headset_eng
|
||||
name = "engineering radio headset"
|
||||
desc = "When the engineers wish to chat like girls. To access the engineering channel, use :e. "
|
||||
desc = "When the engineers wish to chat like girls."
|
||||
icon_state = "eng_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/headset_eng
|
||||
|
||||
/obj/item/device/radio/headset/headset_rob
|
||||
name = "robotics radio headset"
|
||||
desc = "Made specifically for the roboticists who cannot decide between departments. To access the engineering channel, use :e. For research, use :n."
|
||||
desc = "Made specifically for the roboticists who cannot decide between departments."
|
||||
icon_state = "rob_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/headset_rob
|
||||
|
||||
/obj/item/device/radio/headset/headset_med
|
||||
name = "medical radio headset"
|
||||
desc = "A headset for the trained staff of the medbay. To access the medical channel, use :m."
|
||||
desc = "A headset for the trained staff of the medbay."
|
||||
icon_state = "med_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/headset_med
|
||||
|
||||
/obj/item/device/radio/headset/headset_sci
|
||||
name = "science radio headset"
|
||||
desc = "A sciency headset. Like usual. To access the science channel, use :n."
|
||||
desc = "A sciency headset. Like usual."
|
||||
icon_state = "com_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/headset_sci
|
||||
|
||||
/obj/item/device/radio/headset/headset_medsci
|
||||
name = "medical research radio headset"
|
||||
desc = "A headset that is a result of the mating between medical and science. To access the medical channel, use :m. For science, use :n."
|
||||
desc = "A headset that is a result of the mating between medical and science."
|
||||
icon_state = "med_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/headset_medsci
|
||||
|
||||
/obj/item/device/radio/headset/headset_com
|
||||
name = "command radio headset"
|
||||
desc = "A headset with a commanding channel. To access the command channel, use :c."
|
||||
desc = "A headset with a commanding channel."
|
||||
icon_state = "com_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/headset_com
|
||||
|
||||
/obj/item/device/radio/headset/heads/captain
|
||||
name = "captain's headset"
|
||||
desc = "The headset of the boss. Channels are as follows: :c - command, :s - security, :e - engineering, :u - supply, :v - service, :m - medical, :n - science."
|
||||
desc = "The headset of the boss."
|
||||
icon_state = "com_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/heads/captain
|
||||
@@ -130,35 +138,35 @@
|
||||
|
||||
/obj/item/device/radio/headset/heads/rd
|
||||
name = "Research Director's headset"
|
||||
desc = "Headset of the researching God. To access the science channel, use :n. For command, use :c."
|
||||
desc = "Headset of the researching God."
|
||||
icon_state = "com_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/heads/rd
|
||||
|
||||
/obj/item/device/radio/headset/heads/hos
|
||||
name = "head of security's headset"
|
||||
desc = "The headset of the man who protects your worthless lifes. To access the security channel, use :s. For command, use :c."
|
||||
desc = "The headset of the man who protects your worthless lifes."
|
||||
icon_state = "com_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/heads/hos
|
||||
|
||||
/obj/item/device/radio/headset/heads/ce
|
||||
name = "chief engineer's headset"
|
||||
desc = "The headset of the guy who is in charge of morons. To access the engineering channel, use :e. For command, use :c."
|
||||
desc = "The headset of the guy who is in charge of morons"
|
||||
icon_state = "com_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/heads/ce
|
||||
|
||||
/obj/item/device/radio/headset/heads/cmo
|
||||
name = "chief medical officer's headset"
|
||||
desc = "The headset of the highly trained medical chief. To access the medical channel, use :m. For command, use :c."
|
||||
desc = "The headset of the highly trained medical chief."
|
||||
icon_state = "com_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/heads/cmo
|
||||
|
||||
/obj/item/device/radio/headset/heads/hop
|
||||
name = "head of personnel's headset"
|
||||
desc = "The headset of the guy who will one day be captain. Channels are as follows: :u - supply, :v - service, :c - command, :s - security"
|
||||
desc = "The headset of the guy who will one day be captain."
|
||||
icon_state = "com_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/heads/hop
|
||||
@@ -179,21 +187,21 @@
|
||||
*/
|
||||
/obj/item/device/radio/headset/headset_cargo
|
||||
name = "supply radio headset"
|
||||
desc = "A headset used by the QM and his slaves. To access the supply channel, use :u."
|
||||
desc = "A headset used by the QM and his slaves."
|
||||
icon_state = "cargo_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/headset_cargo
|
||||
|
||||
/obj/item/device/radio/headset/headset_service
|
||||
name = "service radio headset"
|
||||
desc = "Headset used by the service staff, tasked with keeping the station full, happy and clean. To access the service channel, use :v."
|
||||
desc = "Headset used by the service staff, tasked with keeping the station full, happy and clean."
|
||||
icon_state = "srv_headset"
|
||||
item_state = "headset"
|
||||
keyslot2 = new /obj/item/device/encryptionkey/headset_service
|
||||
|
||||
/obj/item/device/radio/headset/ert
|
||||
name = "CentCom Response Team headset"
|
||||
desc = "The headset of the boss's boss. Channels are as follows: :h - Response Team :c - command, :s - security, :e - engineering, :d - mining, :u - cargo, :v - service, :m - medical, :n - science."
|
||||
desc = "The headset of the boss's boss."
|
||||
icon_state = "com_headset"
|
||||
item_state = "headset"
|
||||
freerange = 1
|
||||
@@ -255,7 +263,7 @@
|
||||
return
|
||||
|
||||
|
||||
/obj/item/device/radio/headset/proc/recalculateChannels()
|
||||
/obj/item/device/radio/headset/proc/recalculateChannels(var/setDescription = 0)
|
||||
src.channels = list()
|
||||
src.translate_binary = 0
|
||||
src.translate_hive = 0
|
||||
@@ -303,4 +311,18 @@
|
||||
|
||||
secure_radio_connections[ch_name] = radio_controller.add_object(src, radiochannels[ch_name], RADIO_CHAT)
|
||||
|
||||
return
|
||||
if(setDescription)
|
||||
setupRadioDescription()
|
||||
|
||||
return
|
||||
|
||||
/obj/item/device/radio/headset/proc/setupRadioDescription()
|
||||
var/radio_text = ""
|
||||
for(var/i = 1 to channels.len)
|
||||
var/channel = channels[i]
|
||||
var/key = get_radio_key_from_channel(channel)
|
||||
radio_text += "[key] - [channel]"
|
||||
if(i != channels.len)
|
||||
radio_text += ", "
|
||||
|
||||
radio_desc = radio_text
|
||||
|
||||
@@ -474,7 +474,7 @@
|
||||
|
||||
|
||||
/obj/item/device/radio/examine(mob/user)
|
||||
..(user)
|
||||
. = ..()
|
||||
if ((in_range(src, user) || loc == user))
|
||||
if (b_stat)
|
||||
user.show_message("\blue \the [src] can be attached and modified!")
|
||||
|
||||
@@ -472,3 +472,50 @@
|
||||
|
||||
else
|
||||
return ..()
|
||||
|
||||
/obj/item/weapon/combitool
|
||||
name = "combi-tool"
|
||||
desc = "It even has one of those nubbins for doing the thingy."
|
||||
icon = 'icons/obj/items.dmi'
|
||||
icon_state = "combitool"
|
||||
|
||||
var/list/spawn_tools = list(
|
||||
/obj/item/weapon/screwdriver,
|
||||
/obj/item/weapon/wrench,
|
||||
/obj/item/weapon/wirecutters,
|
||||
/obj/item/weapon/kitchen/utensil/knife,
|
||||
/obj/item/weapon/kitchen/utensil/fork,
|
||||
/obj/item/weapon/hatchet
|
||||
)
|
||||
var/list/tools = list()
|
||||
var/current_tool = 1
|
||||
|
||||
/obj/item/weapon/combitool/examine()
|
||||
..()
|
||||
if(loc == usr && tools.len)
|
||||
usr << "It has the following fittings:"
|
||||
for(var/obj/item/tool in tools)
|
||||
usr << "\icon[tool] - [tool.name][tools[current_tool]==tool?" (selected)":""]"
|
||||
|
||||
/obj/item/weapon/combitool/New()
|
||||
..()
|
||||
for(var/type in spawn_tools)
|
||||
tools |= new type(src)
|
||||
|
||||
/obj/item/weapon/combitool/attack_self(mob/user as mob)
|
||||
if(++current_tool > tools.len) current_tool = 1
|
||||
var/obj/item/tool = tools[current_tool]
|
||||
if(!tool)
|
||||
user << "You can't seem to find any fittings in \the [src]."
|
||||
else
|
||||
user << "You switch \the [src] to the [tool.name] fitting."
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/combitool/attack(var/atom/target, var/mob/living/user)
|
||||
var/obj/item/tool = tools[current_tool]
|
||||
if(!tool)
|
||||
return ..()
|
||||
var/resolved = target.attackby(tool,user)
|
||||
if(!resolved && tool && target)
|
||||
tool.afterattack(target,user,1)
|
||||
return 1
|
||||
@@ -168,6 +168,8 @@
|
||||
var/obj/structure/cable/C = T.get_cable_node()
|
||||
if(C)
|
||||
if(electrocute_mob(user, C, src))
|
||||
if(C.powernet)
|
||||
C.powernet.trigger_warning()
|
||||
var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
|
||||
s.set_up(3, 1, src)
|
||||
s.start()
|
||||
|
||||
@@ -4,7 +4,6 @@
|
||||
var/global/obj/effect/datacore/data_core = null
|
||||
|
||||
|
||||
var/global/list/active_areas = list()
|
||||
var/global/list/all_areas = list()
|
||||
var/global/list/machines = list()
|
||||
var/global/list/processing_objects = list()
|
||||
|
||||
@@ -1483,61 +1483,92 @@
|
||||
log_admin("[src.owner] replied to [key_name(H)]'s illegal message with the message [input].")
|
||||
H << "You hear something crackle in your headset for a moment before a voice speaks. \"Please stand by for a message from your benefactor. Message as follows, agent. <b>\"[input]\"</b> Message ends.\""
|
||||
|
||||
else if(href_list["CentcommFaxView"])
|
||||
var/info = locate(href_list["CentcommFaxView"])
|
||||
else if(href_list["AdminFaxView"])
|
||||
var/obj/item/fax = locate(href_list["AdminFaxView"])
|
||||
if (istype(fax, /obj/item/weapon/paper))
|
||||
var/obj/item/weapon/paper/P = fax
|
||||
P.show_content(usr)
|
||||
else if (istype(fax, /obj/item/weapon/photo))
|
||||
var/obj/item/weapon/photo/H = fax
|
||||
H.show(usr)
|
||||
else if (istype(fax, /obj/item/weapon/paper_bundle))
|
||||
//having multiple people turning pages on a paper_bundle can cause issues
|
||||
//open a browse window listing the contents instead
|
||||
var/data = ""
|
||||
var/obj/item/weapon/paper_bundle/B = fax
|
||||
|
||||
for (var/page = 1, page <= B.amount, page++)
|
||||
var/obj/pageobj = B.contents[page]
|
||||
data += "<A href='?src=\ref[src];AdminFaxViewPage=[page];paper_bundle=\ref[B]'>Page [page] - [pageobj.name]</A><BR>"
|
||||
|
||||
world << data
|
||||
world << "usr = [usr]"
|
||||
|
||||
usr << browse(data, "window=[B.name]")
|
||||
else
|
||||
usr << "\red The faxed item is not viewable. This is probably a bug, and should be reported on the tracker: [fax.type]"
|
||||
|
||||
usr << browse("<HTML><HEAD><TITLE>Centcomm Fax Message</TITLE></HEAD><BODY>[info]</BODY></HTML>", "window=Centcomm Fax Message")
|
||||
else if (href_list["AdminFaxViewPage"])
|
||||
var/page = text2num(href_list["AdminFaxViewPage"])
|
||||
var/obj/item/weapon/paper_bundle/bundle = locate(href_list["paper_bundle"])
|
||||
|
||||
if (!bundle) return
|
||||
|
||||
if (istype(bundle.contents[page], /obj/item/weapon/paper))
|
||||
var/obj/item/weapon/paper/P = bundle.contents[page]
|
||||
P.show_content(src.owner, 1)
|
||||
else if (istype(bundle.contents[page], /obj/item/weapon/photo))
|
||||
var/obj/item/weapon/photo/H = bundle.contents[page]
|
||||
H.show(src.owner)
|
||||
return
|
||||
|
||||
else if(href_list["CentcommFaxReply"])
|
||||
var/mob/living/carbon/human/H = locate(href_list["CentcommFaxReply"])
|
||||
var/obj/machinery/faxmachine/fax = locate(href_list["originfax"])
|
||||
var/mob/sender = locate(href_list["CentcommFaxReply"])
|
||||
var/obj/machinery/photocopier/faxmachine/fax = locate(href_list["originfax"])
|
||||
|
||||
var/input = input(src.owner, "Please enter a message to reply to [key_name(H)] via secure connection. NOTE: BBCode does not work, but HTML tags do! Use <br> for line breaks.", "Outgoing message from Centcomm", "") as message|null
|
||||
var/input = input(src.owner, "Please enter a message to reply to [key_name(sender)] via secure connection. NOTE: BBCode does not work, but HTML tags do! Use <br> for line breaks.", "Outgoing message from Centcomm", "") as message|null
|
||||
if(!input) return
|
||||
|
||||
var/customname = input(src.owner, "Pick a title for the report", "Title") as text|null
|
||||
|
||||
// Create the reply message
|
||||
var/obj/item/weapon/paper/P = new /obj/item/weapon/paper( null ) //hopefully the null loc won't cause trouble for us
|
||||
P.name = "[command_name()]- [customname]"
|
||||
P.info = input
|
||||
P.update_icon()
|
||||
|
||||
// Stamps
|
||||
var/image/stampoverlay = image('icons/obj/bureaucracy.dmi')
|
||||
stampoverlay.icon_state = "paper_stamp-cent"
|
||||
if(!P.stamped)
|
||||
P.stamped = new
|
||||
P.stamped += /obj/item/weapon/stamp
|
||||
P.overlays += stampoverlay
|
||||
P.stamps += "<HR><i>This paper has been stamped by the Central Command Quantum Relay.</i>"
|
||||
|
||||
for(var/obj/machinery/faxmachine/F in machines)
|
||||
if(F == fax)
|
||||
if(! (F.stat & (BROKEN|NOPOWER) ) )
|
||||
|
||||
// animate! it's alive!
|
||||
flick("faxreceive", F)
|
||||
|
||||
// give the sprite some time to flick
|
||||
spawn(20)
|
||||
var/obj/item/weapon/paper/P = new /obj/item/weapon/paper( F.loc )
|
||||
P.name = "[command_name()]- [customname]"
|
||||
P.info = input
|
||||
P.update_icon()
|
||||
|
||||
playsound(F.loc, "sound/items/polaroid1.ogg", 50, 1)
|
||||
|
||||
// Stamps
|
||||
var/image/stampoverlay = image('icons/obj/bureaucracy.dmi')
|
||||
stampoverlay.icon_state = "paper_stamp-cent"
|
||||
if(!P.stamped)
|
||||
P.stamped = new
|
||||
P.stamped += /obj/item/weapon/stamp
|
||||
P.overlays += stampoverlay
|
||||
P.stamps += "<HR><i>This paper has been stamped by the Central Command Quantum Relay.</i>"
|
||||
|
||||
src.owner << "Message reply to transmitted successfully."
|
||||
log_admin("[key_name(src.owner)] replied to a fax message from [key_name(H)]: [input]")
|
||||
message_admins("[key_name_admin(src.owner)] replied to a fax message from [key_name_admin(H)]", 1)
|
||||
return
|
||||
src.owner << "/red Unable to locate fax!"
|
||||
if(fax.recievefax(P))
|
||||
src.owner << "\blue Message reply to transmitted successfully."
|
||||
log_admin("[key_name(src.owner)] replied to a fax message from [key_name(sender)]: [input]")
|
||||
message_admins("[key_name_admin(src.owner)] replied to a fax message from [key_name_admin(sender)]", 1)
|
||||
else
|
||||
src.owner << "\red Message reply failed."
|
||||
|
||||
spawn(100)
|
||||
del(P)
|
||||
return
|
||||
|
||||
else if(href_list["SolGovFaxReply"])
|
||||
//TODO
|
||||
/*
|
||||
var/mob/living/carbon/human/H = locate(href_list["SolGovFaxReply"])
|
||||
var/obj/machinery/faxmachine/fax = locate(href_list["originfax"])
|
||||
var/obj/machinery/photocopier/faxmachine/fax = locate(href_list["originfax"])
|
||||
|
||||
var/input = input(src.owner, "Please enter a message to reply to [key_name(H)] via secure connection. NOTE: BBCode does not work, but HTML tags do! Use <br> for line breaks.", "Outgoing message from Centcomm", "") as message|null
|
||||
if(!input) return
|
||||
|
||||
var/customname = input(src.owner, "Pick a title for the report", "Title") as text|null
|
||||
|
||||
for(var/obj/machinery/faxmachine/F in machines)
|
||||
for(var/obj/machinery/photocopier/faxmachine/F in machines)
|
||||
if(F == fax)
|
||||
if(! (F.stat & (BROKEN|NOPOWER) ) )
|
||||
|
||||
@@ -1567,6 +1598,7 @@
|
||||
message_admins("[key_name_admin(src.owner)] replied to a fax message from [key_name_admin(H)]", 1)
|
||||
return
|
||||
src.owner << "/red Unable to locate fax!"
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -957,7 +957,7 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
|
||||
for(var/obj/machinery/power/smes/SMES in world)
|
||||
if(SMES.anchored)
|
||||
SMES.chargemode = 1
|
||||
SMES.input_attempt = 1
|
||||
|
||||
/client/proc/setup_supermatter_engine()
|
||||
set category = "Debug"
|
||||
@@ -1017,16 +1017,16 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
|
||||
else if(istype(M,/obj/machinery/power/smes)) //This is the SMES inside the engine room. We don't need much power.
|
||||
var/obj/machinery/power/smes/SMES = M
|
||||
SMES.chargemode = 1
|
||||
SMES.chargelevel = 200000
|
||||
SMES.output = 75000
|
||||
SMES.input_attempt = 1
|
||||
SMES.input_level = 200000
|
||||
SMES.output_level = 75000
|
||||
|
||||
else if(istype(M.loc.loc,/area/engine/engine_smes)) //Set every SMES to charge and spit out 300,000 power between the 4 of them.
|
||||
if(istype(M,/obj/machinery/power/smes))
|
||||
var/obj/machinery/power/smes/SMES = M
|
||||
SMES.chargemode = 1
|
||||
SMES.chargelevel = 200000
|
||||
SMES.output = 75000
|
||||
SMES.input_attempt = 1
|
||||
SMES.input_level = 200000
|
||||
SMES.output_level = 75000
|
||||
|
||||
if(!found_the_pump && response == "Setup Completely")
|
||||
src << "\red Unable to locate air supply to fill up with coolant, adding some coolant around the supermatter"
|
||||
|
||||
@@ -161,9 +161,6 @@ var/list/debug_verbs = list (
|
||||
,/client/proc/testZAScolors
|
||||
,/client/proc/testZAScolors_remove
|
||||
,/client/proc/setup_supermatter_engine
|
||||
,/client/proc/view_power_update_stats_area
|
||||
,/client/proc/view_power_update_stats_machines
|
||||
,/client/proc/toggle_power_update_profiling
|
||||
,/client/proc/atmos_toggle_debug
|
||||
)
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ var/global/list/gear_datums = list()
|
||||
"[slot_glasses]" = list(),
|
||||
"[slot_wear_mask]" = list(),
|
||||
"[slot_w_uniform]" = list(),
|
||||
"attachments" = list(),
|
||||
"[slot_tie]" = list(),
|
||||
"[slot_wear_suit]" = list(),
|
||||
"[slot_gloves]" = list(),
|
||||
"[slot_shoes]" = list(),
|
||||
@@ -204,6 +204,13 @@ var/global/list/gear_datums = list()
|
||||
cost = 2
|
||||
slot = slot_head
|
||||
|
||||
// Wig by Earthcrusher, blame him.
|
||||
/datum/gear/philosopher_wig
|
||||
display_name = "natural philosopher's wig"
|
||||
path = /obj/item/clothing/head/philosopher_wig
|
||||
cost = 3
|
||||
slot = slot_head
|
||||
|
||||
/datum/gear/ushanka
|
||||
display_name = "ushanka"
|
||||
path = /obj/item/clothing/head/ushanka
|
||||
@@ -323,13 +330,6 @@ var/global/list/gear_datums = list()
|
||||
cost = 1
|
||||
allowed_roles = list("Captain")
|
||||
|
||||
// Wig by Earthcrusher, blame him.
|
||||
/datum/gear/philosopher_wig
|
||||
display_name = "natural philosopher's wig"
|
||||
path = /obj/item/clothing/head/philosopher_wig
|
||||
cost = 3
|
||||
slot = slot_head
|
||||
|
||||
/datum/gear/corpsecsuit
|
||||
display_name = "uniform, corporate (Security)"
|
||||
path = /obj/item/clothing/under/rank/security/corp
|
||||
@@ -363,88 +363,88 @@ var/global/list/gear_datums = list()
|
||||
/datum/gear/armband_cargo
|
||||
display_name = "armband, cargo"
|
||||
path = /obj/item/clothing/tie/armband/cargo
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/armband_emt
|
||||
display_name = "armband, EMT"
|
||||
path = /obj/item/clothing/tie/armband/medgreen
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 2
|
||||
|
||||
/datum/gear/armband_engineering
|
||||
display_name = "armband, engineering"
|
||||
path = /obj/item/clothing/tie/armband/engine
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/armband_hydroponics
|
||||
display_name = "armband, hydroponics"
|
||||
path = /obj/item/clothing/tie/armband/hydro
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/armband_medical
|
||||
display_name = "armband, medical"
|
||||
path = /obj/item/clothing/tie/armband/med
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/armband
|
||||
display_name = "armband, red"
|
||||
path = /obj/item/clothing/tie/armband
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/armband_science
|
||||
display_name = "armband, science"
|
||||
path = /obj/item/clothing/tie/armband/science
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/armpit
|
||||
display_name = "shoulder holster"
|
||||
path = /obj/item/clothing/tie/holster/armpit
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 2
|
||||
allowed_roles = list("Captain", "Head of Personnel", "Security Officer", "Head of Security")
|
||||
allowed_roles = list("Captain", "Head of Personnel", "Security Officer", "Warden", "Head of Security")
|
||||
|
||||
/datum/gear/tie_blue
|
||||
display_name = "tie, blue"
|
||||
path = /obj/item/clothing/tie/blue
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/tie_red
|
||||
display_name = "tie, red"
|
||||
path = /obj/item/clothing/tie/red
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/tie_horrible
|
||||
display_name = "tie, socially disgraceful"
|
||||
path = /obj/item/clothing/tie/horrible
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 1
|
||||
|
||||
/datum/gear/brown_vest
|
||||
display_name = "webbing, engineering"
|
||||
path = /obj/item/clothing/tie/storage/brown_vest
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 2
|
||||
allowed_roles = list("Station Engineer","Atmospheric Technician","Chief Engineer")
|
||||
|
||||
/datum/gear/black_vest
|
||||
display_name = "webbing, security"
|
||||
path = /obj/item/clothing/tie/storage/black_vest
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 2
|
||||
allowed_roles = list("Security Officer","Head of Security","Warden")
|
||||
|
||||
/datum/gear/webbing
|
||||
display_name = "webbing, simple"
|
||||
path = /obj/item/clothing/tie/storage/webbing
|
||||
sort_category = "attachments"
|
||||
slot = slot_tie
|
||||
cost = 2
|
||||
|
||||
// Suit slot
|
||||
@@ -710,11 +710,35 @@ var/global/list/gear_datums = list()
|
||||
sort_category = "utility"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/matchbook
|
||||
display_name = "matchbook"
|
||||
path = /obj/item/weapon/storage/box/matches
|
||||
/datum/gear/folder_blue
|
||||
display_name = "folder, blue"
|
||||
path = /obj/item/weapon/folder/blue
|
||||
sort_category = "utility"
|
||||
cost = 2
|
||||
cost = 1
|
||||
|
||||
/datum/gear/folder_grey
|
||||
display_name = "folder, grey"
|
||||
path = /obj/item/weapon/folder
|
||||
sort_category = "utility"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/folder_red
|
||||
display_name = "folder, red"
|
||||
path = /obj/item/weapon/folder/red
|
||||
sort_category = "utility"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/folder_white
|
||||
display_name = "folder, white"
|
||||
path = /obj/item/weapon/folder/white
|
||||
sort_category = "utility"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/folder_yellow
|
||||
display_name = "folder, yellow"
|
||||
path = /obj/item/weapon/folder/yellow
|
||||
sort_category = "utility"
|
||||
cost = 1
|
||||
|
||||
// The rest of the trash.
|
||||
|
||||
@@ -766,6 +790,12 @@ var/global/list/gear_datums = list()
|
||||
sort_category = "misc"
|
||||
cost = 1
|
||||
|
||||
/datum/gear/matchbook
|
||||
display_name = "matchbook"
|
||||
path = /obj/item/weapon/storage/box/matches
|
||||
sort_category = "misc"
|
||||
cost = 2
|
||||
|
||||
/datum/gear/comb
|
||||
display_name = "purple comb"
|
||||
path = /obj/item/weapon/haircomb
|
||||
|
||||
@@ -1,10 +1,9 @@
|
||||
//Regular syndicate space suit
|
||||
/obj/item/clothing/head/helmet/space/syndicate
|
||||
name = "red space helmet"
|
||||
desc = "Top secret space helmet."
|
||||
icon_state = "syndicate"
|
||||
item_state = "syndicate"
|
||||
desc = "Has a tag: Totally not property of an enemy corporation, honest."
|
||||
item_state = "space_helmet_syndicate"
|
||||
desc = "A crimson helmet sporting clean lines and durable plating. Engineered to look menacing."
|
||||
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 30, rad = 30)
|
||||
siemens_coefficient = 0.6
|
||||
|
||||
@@ -12,7 +11,7 @@
|
||||
name = "red space suit"
|
||||
icon_state = "syndicate"
|
||||
item_state = "space_suit_syndicate"
|
||||
desc = "Has a tag on it: Totally not property of of a hostile corporation, honest!"
|
||||
desc = "A crimson spacesuit sporting clean lines and durable plating. Robust, reliable, and slightly suspicious."
|
||||
w_class = 3
|
||||
allowed = list(/obj/item/weapon/gun,/obj/item/ammo_magazine,/obj/item/ammo_casing,/obj/item/weapon/melee/baton,/obj/item/weapon/melee/energy/sword,/obj/item/weapon/handcuffs,/obj/item/weapon/tank/emergency_oxygen)
|
||||
slowdown = 1
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
item_state = "" //no inhands
|
||||
item_color = "bluetie"
|
||||
flags = FPRINT | TABLEPASS
|
||||
slot_flags = 0
|
||||
slot_flags = SLOT_TIE
|
||||
w_class = 2.0
|
||||
var/obj/item/clothing/under/has_suit = null //the suit the tie may be attached to
|
||||
var/image/inv_overlay = null //overlay used when attached to clothing.
|
||||
@@ -390,7 +390,7 @@
|
||||
desc = "This glowing blue badge marks the holder as THE LAW."
|
||||
icon_state = "holobadge"
|
||||
item_color = "holobadge"
|
||||
slot_flags = SLOT_BELT
|
||||
slot_flags = SLOT_BELT | SLOT_TIE
|
||||
|
||||
var/emagged = 0 //Emagging removes Sec check.
|
||||
var/stored_name = null
|
||||
@@ -398,7 +398,7 @@
|
||||
/obj/item/clothing/tie/holobadge/cord
|
||||
icon_state = "holobadge-cord"
|
||||
item_color = "holobadge-cord"
|
||||
slot_flags = SLOT_MASK
|
||||
slot_flags = SLOT_MASK | SLOT_TIE
|
||||
|
||||
/obj/item/clothing/tie/holobadge/attack_self(mob/user as mob)
|
||||
if(!stored_name)
|
||||
|
||||
@@ -1145,7 +1145,6 @@
|
||||
item_color = "radi_pendant"
|
||||
flags = FPRINT|TABLEPASS
|
||||
w_class = 2.0
|
||||
slot_flags = 0
|
||||
|
||||
//////////// Masks ////////////
|
||||
|
||||
@@ -1191,7 +1190,7 @@
|
||||
slot_flags = 0
|
||||
flags = FPRINT|TABLEPASS
|
||||
w_class = 2
|
||||
slot_flags = SLOT_MASK
|
||||
slot_flags = SLOT_MASK | SLOT_TIE
|
||||
|
||||
////// Silver locket - Konaa Hirano - Konaa_Hirano
|
||||
|
||||
@@ -1205,7 +1204,7 @@
|
||||
slot_flags = 0
|
||||
flags = FPRINT|TABLEPASS
|
||||
w_class = 2
|
||||
slot_flags = SLOT_MASK
|
||||
slot_flags = SLOT_MASK | SLOT_TIE
|
||||
var/obj/item/held //Item inside locket.
|
||||
|
||||
/obj/item/clothing/tie/fluff/konaa_hirano/attack_self(mob/user as mob)
|
||||
@@ -1235,7 +1234,7 @@
|
||||
icon_state = "nasir_khayyam_1"
|
||||
flags = FPRINT|TABLEPASS
|
||||
w_class = 2
|
||||
slot_flags = SLOT_MASK
|
||||
slot_flags = SLOT_MASK | SLOT_TIE
|
||||
|
||||
////// Emerald necklace - Ty Foster - Nega
|
||||
|
||||
@@ -1463,7 +1462,7 @@
|
||||
follow_dist = 2
|
||||
var/near_dist = max(follow_dist - 3, 1)
|
||||
var/current_dist = get_dist(src, bff)
|
||||
|
||||
|
||||
if (movement_target != bff)
|
||||
if (current_dist > follow_dist && !istype(movement_target, /mob/living/simple_animal/mouse) && (bff in oview(src)))
|
||||
//stop existing movement
|
||||
@@ -1474,7 +1473,7 @@
|
||||
stop_automated_movement = 1
|
||||
movement_target = bff
|
||||
walk_to(src, movement_target, near_dist, 4)
|
||||
|
||||
|
||||
//already following and close enough, stop
|
||||
else if (current_dist <= near_dist)
|
||||
walk_to(src,0)
|
||||
@@ -1486,15 +1485,15 @@
|
||||
|
||||
/mob/living/simple_animal/cat/fluff/Life()
|
||||
..()
|
||||
if (stat || !bff)
|
||||
if (stat || !bff)
|
||||
return
|
||||
if (get_dist(src, bff) <= 1)
|
||||
if (bff.stat >= DEAD || bff.health <= config.health_threshold_softcrit)
|
||||
if (prob((bff.stat < DEAD)? 50 : 15))
|
||||
if (prob((bff.stat < DEAD)? 50 : 15))
|
||||
audible_emote(pick("meows in distress.", "meows anxiously."))
|
||||
else
|
||||
if (prob(5))
|
||||
visible_emote(pick("nuzzles [bff].",
|
||||
if (prob(5))
|
||||
visible_emote(pick("nuzzles [bff].",
|
||||
"brushes against [bff].",
|
||||
"rubs against [bff].",
|
||||
"purrs."))
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
|
||||
/obj/item/weapon/evidencebag/attack_self(mob/user as mob)
|
||||
if(contents.len)
|
||||
var/obj/item/I = stored_item
|
||||
var/obj/item/I = contents[1]
|
||||
user.visible_message("[user] takes [I] out of [src]", "You take [I] out of [src].",\
|
||||
"You hear someone rustle around in a plastic bag, and remove something.")
|
||||
overlays.Cut() //remove the overlays
|
||||
|
||||
@@ -73,6 +73,8 @@
|
||||
return has_organ("chest")
|
||||
if(slot_in_backpack)
|
||||
return 1
|
||||
if(slot_tie)
|
||||
return 1
|
||||
|
||||
/mob/living/carbon/human/u_equip(obj/item/W as obj)
|
||||
if(!W) return 0
|
||||
@@ -202,13 +204,6 @@
|
||||
if(!istype(W)) return
|
||||
if(!has_organ_for_slot(slot)) return
|
||||
|
||||
if(W == src.l_hand)
|
||||
src.l_hand = null
|
||||
update_inv_l_hand() //So items actually disappear from hands.
|
||||
else if(W == src.r_hand)
|
||||
src.r_hand = null
|
||||
update_inv_r_hand()
|
||||
|
||||
W.loc = src
|
||||
switch(slot)
|
||||
if(slot_back)
|
||||
@@ -311,10 +306,20 @@
|
||||
if(src.get_active_hand() == W)
|
||||
src.u_equip(W)
|
||||
W.loc = src.back
|
||||
if(slot_tie)
|
||||
var/obj/item/clothing/under/uniform = src.w_uniform
|
||||
uniform.attackby(W,src)
|
||||
else
|
||||
src << "\red You are trying to eqip this item to an unsupported inventory slot. How the heck did you manage that? Stop it..."
|
||||
return
|
||||
|
||||
if(W == src.l_hand)
|
||||
src.l_hand = null
|
||||
update_inv_l_hand() //So items actually disappear from hands.
|
||||
else if(W == src.r_hand)
|
||||
src.r_hand = null
|
||||
update_inv_r_hand()
|
||||
|
||||
W.layer = 20
|
||||
|
||||
return
|
||||
@@ -801,4 +806,4 @@ It can still be worn/put on as normal.
|
||||
if(source && target)
|
||||
if(source.machine == target)
|
||||
target.show_inv(source)
|
||||
del(src)
|
||||
del(src)
|
||||
@@ -1707,7 +1707,7 @@
|
||||
if(stat == 2)
|
||||
holder.icon_state = "hudhealth-100" // X_X
|
||||
else
|
||||
var/percentage_health = RoundHealth(((0.0+health)/species.total_health)*100)
|
||||
var/percentage_health = RoundHealth((health-config.health_threshold_crit)/(species.total_health-config.health_threshold_crit)*100)
|
||||
holder.icon_state = "hud[percentage_health]"
|
||||
hud_list[HEALTH_HUD] = holder
|
||||
|
||||
|
||||
@@ -612,4 +612,7 @@
|
||||
if(slot_back in equip_slots)
|
||||
equip_slots |= slot_in_backpack
|
||||
|
||||
if(slot_w_uniform in equip_slots)
|
||||
equip_slots |= slot_tie
|
||||
|
||||
equip_slots |= slot_legcuffed
|
||||
@@ -172,6 +172,7 @@ var/list/slot_equipment_priority = list( \
|
||||
slot_glasses,\
|
||||
slot_belt,\
|
||||
slot_s_store,\
|
||||
slot_tie,\
|
||||
slot_l_store,\
|
||||
slot_r_store\
|
||||
)
|
||||
|
||||
@@ -0,0 +1,218 @@
|
||||
var/list/obj/machinery/photocopier/faxmachine/allfaxes = list()
|
||||
var/list/admin_departments = list("Central Command", "Sol Government")
|
||||
var/list/alldepartments = list()
|
||||
|
||||
var/list/adminfaxes = list() //cache for faxes that have been sent to admins
|
||||
|
||||
/obj/machinery/photocopier/faxmachine
|
||||
name = "fax machine"
|
||||
icon = 'icons/obj/library.dmi'
|
||||
icon_state = "fax"
|
||||
insert_anim = "faxsend"
|
||||
req_one_access = list(access_lawyer, access_heads, access_armory) //Warden needs to be able to Fax solgov too.
|
||||
|
||||
use_power = 1
|
||||
idle_power_usage = 30
|
||||
active_power_usage = 200
|
||||
|
||||
var/obj/item/weapon/card/id/scan = null // identification
|
||||
var/authenticated = 0
|
||||
var/sendcooldown = 0 // to avoid spamming fax messages
|
||||
|
||||
var/department = "Unknown" // our department
|
||||
|
||||
var/destination = "Central Command" // the department we're sending to
|
||||
|
||||
/obj/machinery/photocopier/faxmachine/New()
|
||||
..()
|
||||
allfaxes += src
|
||||
|
||||
if( !(("[department]" in alldepartments) || ("[department]" in admin_departments)) )
|
||||
alldepartments |= department
|
||||
|
||||
/obj/machinery/photocopier/faxmachine/attack_hand(mob/user as mob)
|
||||
user.set_machine(src)
|
||||
|
||||
var/dat = "Fax Machine<BR>"
|
||||
|
||||
var/scan_name
|
||||
if(scan)
|
||||
scan_name = scan.name
|
||||
else
|
||||
scan_name = "--------"
|
||||
|
||||
dat += "Confirm Identity: <a href='byond://?src=\ref[src];scan=1'>[scan_name]</a><br>"
|
||||
|
||||
if(authenticated)
|
||||
dat += "<a href='byond://?src=\ref[src];logout=1'>{Log Out}</a>"
|
||||
else
|
||||
dat += "<a href='byond://?src=\ref[src];auth=1'>{Log In}</a>"
|
||||
|
||||
dat += "<hr>"
|
||||
|
||||
if(authenticated)
|
||||
dat += "<b>Logged in to:</b> Central Command Quantum Entanglement Network<br><br>"
|
||||
|
||||
if(copyitem)
|
||||
dat += "<a href='byond://?src=\ref[src];remove=1'>Remove Item</a><br><br>"
|
||||
|
||||
if(sendcooldown)
|
||||
dat += "<b>Transmitter arrays realigning. Please stand by.</b><br>"
|
||||
|
||||
else
|
||||
|
||||
dat += "<a href='byond://?src=\ref[src];send=1'>Send</a><br>"
|
||||
dat += "<b>Currently sending:</b> [copyitem.name]<br>"
|
||||
dat += "<b>Sending to:</b> <a href='byond://?src=\ref[src];dept=1'>[destination]</a><br>"
|
||||
|
||||
else
|
||||
if(sendcooldown)
|
||||
dat += "Please insert paper to send via secure connection.<br><br>"
|
||||
dat += "<b>Transmitter arrays realigning. Please stand by.</b><br>"
|
||||
else
|
||||
dat += "Please insert paper to send via secure connection.<br><br>"
|
||||
|
||||
else
|
||||
dat += "Proper authentication is required to use this device.<br><br>"
|
||||
|
||||
if(copyitem)
|
||||
dat += "<a href ='byond://?src=\ref[src];remove=1'>Remove Item</a><br>"
|
||||
|
||||
user << browse(dat, "window=copier")
|
||||
onclose(user, "copier")
|
||||
return
|
||||
|
||||
/obj/machinery/photocopier/faxmachine/Topic(href, href_list)
|
||||
if(href_list["send"])
|
||||
if(copyitem)
|
||||
if (destination in admin_departments)
|
||||
send_admin_fax(usr, destination)
|
||||
else
|
||||
sendfax(destination)
|
||||
|
||||
if (sendcooldown)
|
||||
spawn(sendcooldown) // cooldown time
|
||||
sendcooldown = 0
|
||||
|
||||
else if(href_list["remove"])
|
||||
if(copyitem)
|
||||
copyitem.loc = usr.loc
|
||||
usr.put_in_hands(copyitem)
|
||||
usr << "<span class='notice'>You take \the [copyitem] out of \the [src].</span>"
|
||||
copyitem = null
|
||||
updateUsrDialog()
|
||||
|
||||
if(href_list["scan"])
|
||||
if (scan)
|
||||
if(ishuman(usr))
|
||||
scan.loc = usr.loc
|
||||
if(!usr.get_active_hand())
|
||||
usr.put_in_hands(scan)
|
||||
scan = null
|
||||
else
|
||||
scan.loc = src.loc
|
||||
scan = null
|
||||
else
|
||||
var/obj/item/I = usr.get_active_hand()
|
||||
if (istype(I, /obj/item/weapon/card/id))
|
||||
usr.drop_item()
|
||||
I.loc = src
|
||||
scan = I
|
||||
authenticated = 0
|
||||
|
||||
if(href_list["dept"])
|
||||
var/lastdestination = destination
|
||||
destination = input(usr, "Which department?", "Choose a department", "") as null|anything in (alldepartments + admin_departments)
|
||||
if(!destination) destination = lastdestination
|
||||
|
||||
if(href_list["auth"])
|
||||
if ( (!( authenticated ) && (scan)) )
|
||||
if (check_access(scan))
|
||||
authenticated = 1
|
||||
|
||||
if(href_list["logout"])
|
||||
authenticated = 0
|
||||
|
||||
updateUsrDialog()
|
||||
|
||||
/obj/machinery/photocopier/faxmachine/proc/sendfax(var/destination)
|
||||
if(stat & (BROKEN|NOPOWER))
|
||||
return
|
||||
|
||||
use_power(200)
|
||||
|
||||
var/success = 0
|
||||
for(var/obj/machinery/photocopier/faxmachine/F in allfaxes)
|
||||
if( F.department == destination )
|
||||
success = F.recievefax(copyitem)
|
||||
|
||||
if (success)
|
||||
visible_message("[src] beeps, \"Message transmitted successfully.\"")
|
||||
//sendcooldown = 600
|
||||
else
|
||||
visible_message("[src] beeps, \"Error transmitting message.\"")
|
||||
|
||||
/obj/machinery/photocopier/faxmachine/proc/recievefax(var/obj/item/incoming)
|
||||
if(stat & (BROKEN|NOPOWER))
|
||||
return 0
|
||||
|
||||
if(department == "Unknown")
|
||||
return 0 //You can't send faxes to "Unknown"
|
||||
|
||||
flick("faxreceive", src)
|
||||
playsound(loc, "sound/items/polaroid1.ogg", 50, 1)
|
||||
|
||||
// give the sprite some time to flick
|
||||
sleep(20)
|
||||
|
||||
if (istype(incoming, /obj/item/weapon/paper))
|
||||
copy(incoming)
|
||||
else if (istype(incoming, /obj/item/weapon/photo))
|
||||
photocopy(incoming)
|
||||
else if (istype(incoming, /obj/item/weapon/paper_bundle))
|
||||
bundlecopy(incoming)
|
||||
else
|
||||
return 0
|
||||
|
||||
use_power(active_power_usage)
|
||||
return 1
|
||||
|
||||
/obj/machinery/photocopier/faxmachine/proc/send_admin_fax(var/mob/sender, var/destination)
|
||||
if(stat & (BROKEN|NOPOWER))
|
||||
return
|
||||
|
||||
use_power(200)
|
||||
|
||||
var/obj/item/rcvdcopy
|
||||
if (istype(copyitem, /obj/item/weapon/paper))
|
||||
rcvdcopy = copy(copyitem)
|
||||
else if (istype(copyitem, /obj/item/weapon/photo))
|
||||
rcvdcopy = photocopy(copyitem)
|
||||
else if (istype(copyitem, /obj/item/weapon/paper_bundle))
|
||||
rcvdcopy = bundlecopy(copyitem)
|
||||
else
|
||||
visible_message("[src] beeps, \"Error transmitting message.\"")
|
||||
return
|
||||
|
||||
rcvdcopy.loc = null //hopefully this shouldn't cause trouble
|
||||
adminfaxes += rcvdcopy
|
||||
|
||||
//message badmins that a fax has arrived
|
||||
switch(destination)
|
||||
if ("Central Command")
|
||||
message_admins(sender, "CENTCOMM FAX", rcvdcopy, "CentcommFaxReply", "#006100")
|
||||
if ("Sol Government")
|
||||
message_admins(sender, "SOL GOVERNMENT FAX", rcvdcopy, "CentcommFaxReply", "#1F66A0")
|
||||
//message_admins(sender, "SOL GOVERNMENT FAX", rcvdcopy, "SolGovFaxReply", "#1F66A0")
|
||||
|
||||
sendcooldown = 1800
|
||||
sleep(50)
|
||||
visible_message("[src] beeps, \"Message transmitted successfully.\"")
|
||||
|
||||
|
||||
/obj/machinery/photocopier/faxmachine/proc/message_admins(var/mob/sender, var/faxname, var/obj/item/sent, var/reply_type, font_colour="#006100")
|
||||
var/msg = "\blue <b><font color='[font_colour]'>[faxname]: </font>[key_name(sender, 1)] (<A HREF='?_src_=holder;adminplayeropts=\ref[sender]'>PP</A>) (<A HREF='?_src_=vars;Vars=\ref[sender]'>VV</A>) (<A HREF='?_src_=holder;subtlemessage=\ref[sender]'>SM</A>) (<A HREF='?_src_=holder;adminplayerobservejump=\ref[sender]'>JMP</A>) (<A HREF='?_src_=holder;secretsadmin=check_antagonist'>CA</A>) (<a href='?_src_=holder;[reply_type]=\ref[sender];originfax=\ref[src]'>REPLY</a>)</b>: Receiving '[sent.name]' via secure connection ... <a href='?_src_=holder;AdminFaxView=\ref[sent]'>view message</a>"
|
||||
|
||||
for(var/client/C in admins)
|
||||
if(R_ADMIN & C.holder.rights)
|
||||
C << msg
|
||||
@@ -60,20 +60,20 @@
|
||||
icon_state = "paper"
|
||||
|
||||
/obj/item/weapon/paper/examine(mob/user)
|
||||
// ..() //We don't want them to see the dumb "this is a paper" thing every time.
|
||||
// I didn't like the idea that people can read tiny pieces of paper from across the room.
|
||||
// Now you need to be next to the paper in order to read it.
|
||||
if(in_range(user, src))
|
||||
if(!(istype(user, /mob/living/carbon/human) || istype(user, /mob/dead/observer) || istype(user, /mob/living/silicon)))
|
||||
user << browse("<HTML><HEAD><TITLE>[name]</TITLE></HEAD><BODY>[stars(info)][stamps]</BODY></HTML>", "window=[name]")
|
||||
onclose(user, "[name]")
|
||||
else
|
||||
user << browse("<HTML><HEAD><TITLE>[name]</TITLE></HEAD><BODY>[info][stamps]</BODY></HTML>", "window=[name]")
|
||||
onclose(user, "[name]")
|
||||
show_content(usr)
|
||||
else
|
||||
user << "<span class='notice'>It is too far away.</span>"
|
||||
return
|
||||
|
||||
/obj/item/weapon/paper/proc/show_content(var/mob/user, var/forceshow=0)
|
||||
if(!(istype(user, /mob/living/carbon/human) || istype(user, /mob/dead/observer) || istype(user, /mob/living/silicon)) && !forceshow)
|
||||
user << browse("<HTML><HEAD><TITLE>[name]</TITLE></HEAD><BODY>[stars(info)][stamps]</BODY></HTML>", "window=[name]")
|
||||
onclose(user, "[name]")
|
||||
else
|
||||
user << browse("<HTML><HEAD><TITLE>[name]</TITLE></HEAD><BODY>[info][stamps]</BODY></HTML>", "window=[name]")
|
||||
onclose(user, "[name]")
|
||||
|
||||
/obj/item/weapon/paper/verb/rename()
|
||||
set name = "Rename paper"
|
||||
set category = "Object"
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
user << "<span class='notice'>You add [(W.name == "photo") ? "the photo" : W.name] to [(src.name == "paper bundle") ? "the paper bundle" : src.name].</span>"
|
||||
user.drop_from_inventory(W)
|
||||
W.loc = src
|
||||
else if(istype(W, /obj/item/weapon/flame/lighter))
|
||||
else if(istype(W, /obj/item/weapon/flame))
|
||||
burnpaper(W, user)
|
||||
else if(istype(W, /obj/item/weapon/paper_bundle))
|
||||
user.drop_from_inventory(W)
|
||||
@@ -69,7 +69,7 @@
|
||||
return
|
||||
|
||||
|
||||
/obj/item/weapon/paper_bundle/proc/burnpaper(obj/item/weapon/flame/lighter/P, mob/user)
|
||||
/obj/item/weapon/paper_bundle/proc/burnpaper(obj/item/weapon/flame/P, mob/user)
|
||||
var/class = "<span class='warning'>"
|
||||
|
||||
if(P.lit && !user.restrained())
|
||||
@@ -93,55 +93,51 @@
|
||||
else
|
||||
user << "\red You must hold \the [P] steady to burn \the [src]."
|
||||
|
||||
|
||||
/obj/item/weapon/paper_bundle/examine(mob/user)
|
||||
if(..(user, 1))
|
||||
src.attack_self(user)
|
||||
src.show_content(user)
|
||||
else
|
||||
user << "<span class='notice'>It is too far away.</span>"
|
||||
return
|
||||
|
||||
/obj/item/weapon/paper_bundle/proc/show_content(mob/user as mob)
|
||||
var/dat
|
||||
var/obj/item/weapon/W = src[page]
|
||||
switch(screen)
|
||||
if(0)
|
||||
dat+= "<DIV STYLE='float:left; text-align:left; width:33.33333%'></DIV>"
|
||||
dat+= "<DIV STYLE='float:left; text-align:center; width:33.33333%'><A href='?src=\ref[src];remove=1'>Remove [(istype(W, /obj/item/weapon/paper)) ? "paper" : "photo"]</A></DIV>"
|
||||
dat+= "<DIV STYLE='float:left; text-align:right; width:33.33333%'><A href='?src=\ref[src];next_page=1'>Next Page</A></DIV><BR><HR>"
|
||||
if(1)
|
||||
dat+= "<DIV STYLE='float:left; text-align:left; width:33.33333%'><A href='?src=\ref[src];prev_page=1'>Previous Page</A></DIV>"
|
||||
dat+= "<DIV STYLE='float:left; text-align:center; width:33.33333%'><A href='?src=\ref[src];remove=1'>Remove [(istype(W, /obj/item/weapon/paper)) ? "paper" : "photo"]</A></DIV>"
|
||||
dat+= "<DIV STYLE='float:left; text-align:right; width:33.33333%'><A href='?src=\ref[src];next_page=1'>Next Page</A></DIV><BR><HR>"
|
||||
if(2)
|
||||
dat+= "<DIV STYLE='float:left; text-align:left; width:33.33333%'><A href='?src=\ref[src];prev_page=1'>Previous Page</A></DIV>"
|
||||
dat+= "<DIV STYLE='float:left; text-align:center; width:33.33333%'><A href='?src=\ref[src];remove=1'>Remove [(istype(W, /obj/item/weapon/paper)) ? "paper" : "photo"]</A></DIV><BR><HR>"
|
||||
dat+= "<DIV STYLE='float;left; text-align:right; with:33.33333%'></DIV>"
|
||||
if(istype(src[page], /obj/item/weapon/paper))
|
||||
var/obj/item/weapon/paper/P = W
|
||||
if(!(istype(usr, /mob/living/carbon/human) || istype(usr, /mob/dead/observer) || istype(usr, /mob/living/silicon)))
|
||||
dat+= "<HTML><HEAD><TITLE>[P.name]</TITLE></HEAD><BODY>[stars(P.info)][P.stamps]</BODY></HTML>"
|
||||
else
|
||||
dat+= "<HTML><HEAD><TITLE>[P.name]</TITLE></HEAD><BODY>[P.info][P.stamps]</BODY></HTML>"
|
||||
user << browse(dat, "window=[name]")
|
||||
else if(istype(src[page], /obj/item/weapon/photo))
|
||||
var/obj/item/weapon/photo/P = W
|
||||
user << browse_rsc(P.img, "tmp_photo.png")
|
||||
user << browse(dat + "<html><head><title>[P.name]</title></head>" \
|
||||
+ "<body style='overflow:hidden'>" \
|
||||
+ "<div> <img src='tmp_photo.png' width = '180'" \
|
||||
+ "[P.scribble ? "<div> Written on the back:<br><i>[P.scribble]</i>" : ]"\
|
||||
+ "</body></html>", "window=[name]")
|
||||
|
||||
/obj/item/weapon/paper_bundle/attack_self(mob/user as mob)
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/human_user = user
|
||||
var/dat
|
||||
var/obj/item/weapon/W = src[page]
|
||||
switch(screen)
|
||||
if(0)
|
||||
dat+= "<DIV STYLE='float:left; text-align:left; width:33.33333%'></DIV>"
|
||||
dat+= "<DIV STYLE='float:left; text-align:center; width:33.33333%'><A href='?src=\ref[src];remove=1'>Remove [(istype(W, /obj/item/weapon/paper)) ? "paper" : "photo"]</A></DIV>"
|
||||
dat+= "<DIV STYLE='float:left; text-align:right; width:33.33333%'><A href='?src=\ref[src];next_page=1'>Next Page</A></DIV><BR><HR>"
|
||||
if(1)
|
||||
dat+= "<DIV STYLE='float:left; text-align:left; width:33.33333%'><A href='?src=\ref[src];prev_page=1'>Previous Page</A></DIV>"
|
||||
dat+= "<DIV STYLE='float:left; text-align:center; width:33.33333%'><A href='?src=\ref[src];remove=1'>Remove [(istype(W, /obj/item/weapon/paper)) ? "paper" : "photo"]</A></DIV>"
|
||||
dat+= "<DIV STYLE='float:left; text-align:right; width:33.33333%'><A href='?src=\ref[src];next_page=1'>Next Page</A></DIV><BR><HR>"
|
||||
if(2)
|
||||
dat+= "<DIV STYLE='float:left; text-align:left; width:33.33333%'><A href='?src=\ref[src];prev_page=1'>Previous Page</A></DIV>"
|
||||
dat+= "<DIV STYLE='float:left; text-align:center; width:33.33333%'><A href='?src=\ref[src];remove=1'>Remove [(istype(W, /obj/item/weapon/paper)) ? "paper" : "photo"]</A></DIV><BR><HR>"
|
||||
dat+= "<DIV STYLE='float;left; text-align:right; with:33.33333%'></DIV>"
|
||||
if(istype(src[page], /obj/item/weapon/paper))
|
||||
var/obj/item/weapon/paper/P = W
|
||||
if(!(istype(usr, /mob/living/carbon/human) || istype(usr, /mob/dead/observer) || istype(usr, /mob/living/silicon)))
|
||||
dat+= "<HTML><HEAD><TITLE>[P.name]</TITLE></HEAD><BODY>[stars(P.info)][P.stamps]</BODY></HTML>"
|
||||
else
|
||||
dat+= "<HTML><HEAD><TITLE>[P.name]</TITLE></HEAD><BODY>[P.info][P.stamps]</BODY></HTML>"
|
||||
human_user << browse(dat, "window=[name]")
|
||||
P.add_fingerprint(usr)
|
||||
else if(istype(src[page], /obj/item/weapon/photo))
|
||||
var/obj/item/weapon/photo/P = W
|
||||
human_user << browse_rsc(P.img, "tmp_photo.png")
|
||||
human_user << browse(dat + "<html><head><title>[P.name]</title></head>" \
|
||||
+ "<body style='overflow:hidden'>" \
|
||||
+ "<div> <img src='tmp_photo.png' width = '180'" \
|
||||
+ "[P.scribble ? "<div> Written on the back:<br><i>[P.scribble]</i>" : ]"\
|
||||
+ "</body></html>", "window=[name]")
|
||||
P.add_fingerprint(usr)
|
||||
add_fingerprint(usr)
|
||||
update_icon()
|
||||
src.show_content(user)
|
||||
add_fingerprint(usr)
|
||||
update_icon()
|
||||
return
|
||||
|
||||
|
||||
/obj/item/weapon/paper_bundle/Topic(href, href_list)
|
||||
..()
|
||||
if((src in usr.contents) || (istype(src.loc, /obj/item/weapon/folder) && (src.loc in usr.contents)))
|
||||
|
||||
@@ -2,210 +2,159 @@
|
||||
name = "photocopier"
|
||||
icon = 'icons/obj/library.dmi'
|
||||
icon_state = "bigscanner"
|
||||
var/insert_anim = "bigscanner1"
|
||||
anchored = 1
|
||||
density = 1
|
||||
use_power = 1
|
||||
idle_power_usage = 30
|
||||
active_power_usage = 200
|
||||
power_channel = EQUIP
|
||||
var/obj/item/weapon/paper/copy = null //what's in the copier!
|
||||
var/obj/item/weapon/photo/photocopy = null
|
||||
var/obj/item/weapon/paper_bundle/bundle = null
|
||||
var/obj/item/copyitem = null //what's in the copier!
|
||||
var/copies = 1 //how many copies to print!
|
||||
var/toner = 30 //how much toner is left! woooooo~
|
||||
var/maxcopies = 10 //how many copies can be copied at once- idea shamelessly stolen from bs12's copier!
|
||||
|
||||
attack_ai(mob/user as mob)
|
||||
return attack_hand(user)
|
||||
/obj/machinery/photocopier/attack_ai(mob/user as mob)
|
||||
return attack_hand(user)
|
||||
|
||||
attack_hand(mob/user as mob)
|
||||
user.set_machine(src)
|
||||
/obj/machinery/photocopier/attack_hand(mob/user as mob)
|
||||
user.set_machine(src)
|
||||
|
||||
var/dat = "Photocopier<BR><BR>"
|
||||
if(copy || photocopy || bundle)
|
||||
dat += "<a href='byond://?src=\ref[src];remove=1'>Remove Paper</a><BR>"
|
||||
if(toner)
|
||||
dat += "<a href='byond://?src=\ref[src];copy=1'>Copy</a><BR>"
|
||||
dat += "Printing: [copies] copies."
|
||||
dat += "<a href='byond://?src=\ref[src];min=1'>-</a> "
|
||||
dat += "<a href='byond://?src=\ref[src];add=1'>+</a><BR><BR>"
|
||||
else if(toner)
|
||||
dat += "Please insert paper to copy.<BR><BR>"
|
||||
if(istype(user,/mob/living/silicon))
|
||||
dat += "<a href='byond://?src=\ref[src];aipic=1'>Print photo from database</a><BR><BR>"
|
||||
dat += "Current toner level: [toner]"
|
||||
if(!toner)
|
||||
dat +="<BR>Please insert a new toner cartridge!"
|
||||
user << browse(dat, "window=copier")
|
||||
onclose(user, "copier")
|
||||
return
|
||||
|
||||
Topic(href, href_list)
|
||||
if(href_list["copy"])
|
||||
if(copy)
|
||||
for(var/i = 0, i < copies, i++)
|
||||
if(toner > 0)
|
||||
copy(copy)
|
||||
sleep(15)
|
||||
else
|
||||
break
|
||||
updateUsrDialog()
|
||||
else if(photocopy)
|
||||
for(var/i = 0, i < copies, i++)
|
||||
if(toner > 0)
|
||||
photocopy(photocopy)
|
||||
sleep(15)
|
||||
else
|
||||
break
|
||||
updateUsrDialog()
|
||||
else if(bundle)
|
||||
for(var/i = 0, i < copies, i++)
|
||||
if(toner <= 0)
|
||||
break
|
||||
var/obj/item/weapon/paper_bundle/p = new /obj/item/weapon/paper_bundle (src)
|
||||
var/j = 0
|
||||
for(var/obj/item/weapon/W in bundle)
|
||||
if(toner <= 0)
|
||||
usr << "<span class='notice'>The photocopier couldn't finish the printjob.</span>"
|
||||
break
|
||||
else if(istype(W, /obj/item/weapon/paper))
|
||||
W = copy(W)
|
||||
else if(istype(W, /obj/item/weapon/photo))
|
||||
W = photocopy(W)
|
||||
W.loc = p
|
||||
p.amount++
|
||||
j++
|
||||
p.amount--
|
||||
p.loc = src.loc
|
||||
p.update_icon()
|
||||
p.icon_state = "paper_words"
|
||||
p.name = bundle.name
|
||||
p.pixel_y = rand(-8, 8)
|
||||
p.pixel_x = rand(-9, 9)
|
||||
sleep(15*j)
|
||||
updateUsrDialog()
|
||||
else if(href_list["remove"])
|
||||
if(copy)
|
||||
copy.loc = usr.loc
|
||||
usr.put_in_hands(copy)
|
||||
usr << "<span class='notice'>You take the paper out of \the [src].</span>"
|
||||
copy = null
|
||||
updateUsrDialog()
|
||||
else if(photocopy)
|
||||
photocopy.loc = usr.loc
|
||||
usr.put_in_hands(photocopy)
|
||||
usr << "<span class='notice'>You take the photo out of \the [src].</span>"
|
||||
photocopy = null
|
||||
updateUsrDialog()
|
||||
else if(bundle)
|
||||
bundle.loc = usr.loc
|
||||
usr.put_in_hands(bundle)
|
||||
usr << "<span class='notice'>You take the paper bundle out of \the [src].</span>"
|
||||
bundle = null
|
||||
updateUsrDialog()
|
||||
else if(href_list["min"])
|
||||
if(copies > 1)
|
||||
copies--
|
||||
updateUsrDialog()
|
||||
else if(href_list["add"])
|
||||
if(copies < maxcopies)
|
||||
copies++
|
||||
updateUsrDialog()
|
||||
else if(href_list["aipic"])
|
||||
if(!istype(usr,/mob/living/silicon)) return
|
||||
if(toner >= 5)
|
||||
var/mob/living/silicon/tempAI = usr
|
||||
var/obj/item/device/camera/siliconcam/camera = tempAI.aiCamera
|
||||
|
||||
if(!camera)
|
||||
return
|
||||
var/obj/item/weapon/photo/selection = camera.selectpicture()
|
||||
if (!selection)
|
||||
return
|
||||
|
||||
var/obj/item/weapon/photo/p = photocopy(selection)
|
||||
p.loc = src.loc
|
||||
if (p.desc == "")
|
||||
p.desc += "Copy by [tempAI.name]"
|
||||
else
|
||||
p.desc += " - Copy by [tempAI.name]"
|
||||
var/dat = "Photocopier<BR><BR>"
|
||||
if(copyitem)
|
||||
dat += "<a href='byond://?src=\ref[src];remove=1'>Remove Item</a><BR>"
|
||||
if(toner)
|
||||
dat += "<a href='byond://?src=\ref[src];copy=1'>Copy</a><BR>"
|
||||
dat += "Printing: [copies] copies."
|
||||
dat += "<a href='byond://?src=\ref[src];min=1'>-</a> "
|
||||
dat += "<a href='byond://?src=\ref[src];add=1'>+</a><BR><BR>"
|
||||
else if(toner)
|
||||
dat += "Please insert something to copy.<BR><BR>"
|
||||
if(istype(user,/mob/living/silicon))
|
||||
dat += "<a href='byond://?src=\ref[src];aipic=1'>Print photo from database</a><BR><BR>"
|
||||
dat += "Current toner level: [toner]"
|
||||
if(!toner)
|
||||
dat +="<BR>Please insert a new toner cartridge!"
|
||||
user << browse(dat, "window=copier")
|
||||
onclose(user, "copier")
|
||||
return
|
||||
|
||||
/obj/machinery/photocopier/Topic(href, href_list)
|
||||
if(href_list["copy"])
|
||||
if(stat & (BROKEN|NOPOWER))
|
||||
return
|
||||
|
||||
for(var/i = 0, i < copies, i++)
|
||||
if(toner <= 0)
|
||||
break
|
||||
|
||||
if (istype(copyitem, /obj/item/weapon/paper))
|
||||
copy(copyitem)
|
||||
sleep(15)
|
||||
else if (istype(copyitem, /obj/item/weapon/photo))
|
||||
photocopy(copyitem)
|
||||
sleep(15)
|
||||
else if (istype(copyitem, /obj/item/weapon/paper_bundle))
|
||||
var/obj/item/weapon/paper_bundle/B = bundlecopy(copyitem)
|
||||
sleep(15*B.amount)
|
||||
else
|
||||
usr << "<span class='notice'>The photocopier couldn't finish the printjob.</span>"
|
||||
usr << "<span class='warning'>\The [copyitem] can't be copied by \the [src].</span>"
|
||||
break
|
||||
|
||||
use_power(active_power_usage)
|
||||
updateUsrDialog()
|
||||
else if(href_list["remove"])
|
||||
if(copyitem)
|
||||
copyitem.loc = usr.loc
|
||||
usr.put_in_hands(copyitem)
|
||||
usr << "<span class='notice'>You take \the [copyitem] out of \the [src].</span>"
|
||||
copyitem = null
|
||||
updateUsrDialog()
|
||||
else if(href_list["min"])
|
||||
if(copies > 1)
|
||||
copies--
|
||||
updateUsrDialog()
|
||||
else if(href_list["add"])
|
||||
if(copies < maxcopies)
|
||||
copies++
|
||||
updateUsrDialog()
|
||||
else if(href_list["aipic"])
|
||||
if(!istype(usr,/mob/living/silicon)) return
|
||||
if(stat & (BROKEN|NOPOWER)) return
|
||||
|
||||
if(toner >= 5)
|
||||
var/mob/living/silicon/tempAI = usr
|
||||
var/obj/item/device/camera/siliconcam/camera = tempAI.aiCamera
|
||||
|
||||
attackby(obj/item/O as obj, mob/user as mob)
|
||||
if(istype(O, /obj/item/weapon/paper))
|
||||
if(!copy && !photocopy && !bundle)
|
||||
user.drop_item()
|
||||
copy = O
|
||||
O.loc = src
|
||||
user << "<span class='notice'>You insert the paper into \the [src].</span>"
|
||||
flick("bigscanner1", src)
|
||||
updateUsrDialog()
|
||||
else
|
||||
user << "<span class='notice'>There is already something in \the [src].</span>"
|
||||
else if(istype(O, /obj/item/weapon/photo))
|
||||
if(!copy && !photocopy && !bundle)
|
||||
user.drop_item()
|
||||
photocopy = O
|
||||
O.loc = src
|
||||
user << "<span class='notice'>You insert the photo into \the [src].</span>"
|
||||
flick("bigscanner1", src)
|
||||
updateUsrDialog()
|
||||
else
|
||||
user << "<span class='notice'>There is already something in \the [src].</span>"
|
||||
else if(istype(O, /obj/item/weapon/paper_bundle))
|
||||
if(!copy && !photocopy && !bundle)
|
||||
user.drop_item()
|
||||
bundle = O
|
||||
O.loc = src
|
||||
user << "<span class='notice'>You insert the bundle into \the [src].</span>"
|
||||
flick("bigscanner1", src)
|
||||
updateUsrDialog()
|
||||
else if(istype(O, /obj/item/device/toner))
|
||||
if(toner == 0)
|
||||
user.drop_item()
|
||||
del(O)
|
||||
toner = 30
|
||||
user << "<span class='notice'>You insert the toner cartridge into \the [src].</span>"
|
||||
updateUsrDialog()
|
||||
else
|
||||
user << "<span class='notice'>This cartridge is not yet ready for replacement! Use up the rest of the toner.</span>"
|
||||
else if(istype(O, /obj/item/weapon/wrench))
|
||||
playsound(loc, 'sound/items/Ratchet.ogg', 50, 1)
|
||||
anchored = !anchored
|
||||
user << "<span class='notice'>You [anchored ? "wrench" : "unwrench"] \the [src].</span>"
|
||||
return
|
||||
if(!camera)
|
||||
return
|
||||
var/datum/picture/selection = camera.selectpicture()
|
||||
if (!selection)
|
||||
return
|
||||
|
||||
ex_act(severity)
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
del(src)
|
||||
if(2.0)
|
||||
if(prob(50))
|
||||
del(src)
|
||||
else
|
||||
if(toner > 0)
|
||||
new /obj/effect/decal/cleanable/blood/oil(get_turf(src))
|
||||
toner = 0
|
||||
var/obj/item/weapon/photo/p = new /obj/item/weapon/photo (src.loc)
|
||||
p.construct(selection)
|
||||
if (p.desc == "")
|
||||
p.desc += "Copied by [tempAI.name]"
|
||||
else
|
||||
if(prob(50))
|
||||
if(toner > 0)
|
||||
new /obj/effect/decal/cleanable/blood/oil(get_turf(src))
|
||||
toner = 0
|
||||
return
|
||||
p.desc += " - Copied by [tempAI.name]"
|
||||
toner -= 5
|
||||
sleep(15)
|
||||
updateUsrDialog()
|
||||
|
||||
blob_act()
|
||||
if(prob(50))
|
||||
del(src)
|
||||
/obj/machinery/photocopier/attackby(obj/item/O as obj, mob/user as mob)
|
||||
if(istype(O, /obj/item/weapon/paper) || istype(O, /obj/item/weapon/photo) || istype(O, /obj/item/weapon/paper_bundle))
|
||||
if(!copyitem)
|
||||
user.drop_item()
|
||||
copyitem = O
|
||||
O.loc = src
|
||||
user << "<span class='notice'>You insert \the [O] into \the [src].</span>"
|
||||
flick(insert_anim, src)
|
||||
updateUsrDialog()
|
||||
else
|
||||
if(toner > 0)
|
||||
new /obj/effect/decal/cleanable/blood/oil(get_turf(src))
|
||||
toner = 0
|
||||
return
|
||||
user << "<span class='notice'>There is already something in \the [src].</span>"
|
||||
else if(istype(O, /obj/item/device/toner))
|
||||
if(toner <= 10) //allow replacing when low toner is affecting the print darkness
|
||||
user.drop_item()
|
||||
user << "<span class='notice'>You insert the toner cartridge into \the [src].</span>"
|
||||
var/obj/item/device/toner/T = O
|
||||
toner += T.toner_amount
|
||||
del(O)
|
||||
updateUsrDialog()
|
||||
else
|
||||
user << "<span class='notice'>This cartridge is not yet ready for replacement! Use up the rest of the toner.</span>"
|
||||
else if(istype(O, /obj/item/weapon/wrench))
|
||||
playsound(loc, 'sound/items/Ratchet.ogg', 50, 1)
|
||||
anchored = !anchored
|
||||
user << "<span class='notice'>You [anchored ? "wrench" : "unwrench"] \the [src].</span>"
|
||||
return
|
||||
|
||||
/obj/machinery/photocopier/ex_act(severity)
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
del(src)
|
||||
if(2.0)
|
||||
if(prob(50))
|
||||
del(src)
|
||||
else
|
||||
if(toner > 0)
|
||||
new /obj/effect/decal/cleanable/blood/oil(get_turf(src))
|
||||
toner = 0
|
||||
else
|
||||
if(prob(50))
|
||||
if(toner > 0)
|
||||
new /obj/effect/decal/cleanable/blood/oil(get_turf(src))
|
||||
toner = 0
|
||||
return
|
||||
|
||||
/obj/machinery/photocopier/blob_act()
|
||||
if(prob(50))
|
||||
del(src)
|
||||
else
|
||||
if(toner > 0)
|
||||
new /obj/effect/decal/cleanable/blood/oil(get_turf(src))
|
||||
toner = 0
|
||||
return
|
||||
|
||||
/obj/machinery/photocopier/proc/copy(var/obj/item/weapon/paper/copy)
|
||||
var/obj/item/weapon/paper/c = new /obj/item/weapon/paper (loc)
|
||||
@@ -239,6 +188,8 @@
|
||||
c.overlays += img
|
||||
c.updateinfolinks()
|
||||
toner--
|
||||
if(toner == 0)
|
||||
visible_message("<span class='notice'>A red light on \the [src] flashes, indicating that it is out of toner.</span>")
|
||||
return c
|
||||
|
||||
|
||||
@@ -258,9 +209,34 @@
|
||||
toner -= 5 //photos use a lot of ink!
|
||||
if(toner < 0)
|
||||
toner = 0
|
||||
visible_message("<span class='notice'>A red light on \the [src] flashes, indicating that it is out of toner.</span>")
|
||||
return p
|
||||
|
||||
//If need_toner is 0, the copies will still be lightened when low on toner, however it will not be prevented from printing. TODO: Implement print queues for fax machines and get rid of need_toner
|
||||
/obj/machinery/photocopier/proc/bundlecopy(var/obj/item/weapon/paper_bundle/bundle, var/need_toner=1)
|
||||
var/obj/item/weapon/paper_bundle/p = new /obj/item/weapon/paper_bundle (src)
|
||||
for(var/obj/item/weapon/W in bundle)
|
||||
if(toner <= 0 && need_toner)
|
||||
toner = 0
|
||||
visible_message("<span class='notice'>A red light on \the [src] flashes, indicating that it is out of toner.</span>")
|
||||
break
|
||||
|
||||
if(istype(W, /obj/item/weapon/paper))
|
||||
W = copy(W)
|
||||
else if(istype(W, /obj/item/weapon/photo))
|
||||
W = photocopy(W)
|
||||
W.loc = p
|
||||
p.amount++
|
||||
//p.amount--
|
||||
p.loc = src.loc
|
||||
p.update_icon()
|
||||
p.icon_state = "paper_words"
|
||||
p.name = bundle.name
|
||||
p.pixel_y = rand(-8, 8)
|
||||
p.pixel_x = rand(-9, 9)
|
||||
return p
|
||||
|
||||
/obj/item/device/toner
|
||||
name = "toner cartridge"
|
||||
icon_state = "tonercartridge"
|
||||
var/toner_amount = 30
|
||||
|
||||
@@ -1082,10 +1082,10 @@
|
||||
if(!area.requires_power)
|
||||
return
|
||||
|
||||
|
||||
lastused_light = area.usage(LIGHT)
|
||||
lastused_equip = area.usage(EQUIP)
|
||||
lastused_environ = area.usage(ENVIRON)
|
||||
area.clear_usage()
|
||||
|
||||
lastused_total = lastused_light + lastused_equip + lastused_environ
|
||||
|
||||
@@ -1096,45 +1096,33 @@
|
||||
var/last_ch = charging
|
||||
|
||||
var/excess = surplus()
|
||||
var/power_excess = 0
|
||||
|
||||
var/perapc = 0
|
||||
if(terminal && terminal.powernet)
|
||||
perapc = terminal.powernet.perapc
|
||||
if(!src.avail())
|
||||
main_status = 0
|
||||
else if(excess < 0)
|
||||
main_status = 1
|
||||
else
|
||||
main_status = 2
|
||||
|
||||
if(debug)
|
||||
log_debug( "Status: [main_status] - Excess: [excess] - Last Equip: [lastused_equip] - Last Light: [lastused_light]")
|
||||
|
||||
if(area.powerupdate)
|
||||
log_debug("power update in [area.name] / [name]")
|
||||
log_debug("Status: [main_status] - Excess: [excess] - Last Equip: [lastused_equip] - Last Light: [lastused_light] - Longterm: [longtermpower]")
|
||||
|
||||
if(cell && !shorted)
|
||||
//var/cell_charge = cell.charge
|
||||
var/cell_maxcharge = cell.maxcharge
|
||||
// draw power from cell as before to power the area
|
||||
var/cellused = min(cell.charge, CELLRATE * lastused_total) // clamp deduction to a max, amount left in cell
|
||||
cell.use(cellused)
|
||||
|
||||
// Calculate how much power the APC will try to get from the grid.
|
||||
var/target_draw = lastused_total
|
||||
if (src.attempt_charging())
|
||||
target_draw += min((cell_maxcharge - cell.charge), (cell_maxcharge*CHARGELEVEL))/CELLRATE
|
||||
target_draw = min(target_draw, perapc) //limit power draw by perapc
|
||||
|
||||
// try to draw power from the grid
|
||||
var/power_drawn = 0
|
||||
if (src.avail())
|
||||
power_drawn = draw_power(target_draw) //get some power from the powernet
|
||||
|
||||
//figure out how much power is left over after meeting demand
|
||||
power_excess = power_drawn - lastused_total
|
||||
|
||||
if (power_excess < 0) //couldn't get enough power from the grid, we will need to take from the power cell.
|
||||
|
||||
charging = 0
|
||||
|
||||
var/required_power = -power_excess
|
||||
if(cell.charge >= required_power*CELLRATE) // can we draw enough from cell to cover what's left over?
|
||||
cell.use(required_power*CELLRATE)
|
||||
|
||||
else if (autoflag != 0) // not enough power available to run the last tick!
|
||||
if(excess > lastused_total) // if power excess recharge the cell
|
||||
// by the same amount just used
|
||||
var/draw = draw_power(cellused/CELLRATE) // draw the power needed to charge this cell
|
||||
cell.give(draw * CELLRATE)
|
||||
else // no excess, and not enough per-apc
|
||||
if( (cell.charge/CELLRATE + excess) >= lastused_total) // can we draw enough from cell+grid to cover last usage?
|
||||
var/draw = draw_power(excess)
|
||||
cell.charge = min(cell.maxcharge, cell.charge + CELLRATE * draw) //recharge with what we can
|
||||
charging = 0
|
||||
else // not enough power available to run the last tick!
|
||||
charging = 0
|
||||
chargecount = 0
|
||||
// This turns everything off in the case that there is still a charge left on the battery, just not enough to run the room.
|
||||
equipment = autoset(equipment, 0)
|
||||
@@ -1142,13 +1130,6 @@
|
||||
environ = autoset(environ, 0)
|
||||
autoflag = 0
|
||||
|
||||
//Set external power status
|
||||
if (!power_drawn)
|
||||
main_status = 0
|
||||
else if (power_excess < 0)
|
||||
main_status = 1
|
||||
else
|
||||
main_status = 2
|
||||
|
||||
// Set channels depending on how much charge we have left
|
||||
|
||||
@@ -1158,7 +1139,6 @@
|
||||
else if(longtermpower > -10)
|
||||
longtermpower -= 2
|
||||
|
||||
|
||||
if(cell.charge >= 1250 || longtermpower > 0) // Put most likely at the top so we don't check it last, effeciency 101
|
||||
if(autoflag != 3)
|
||||
equipment = autoset(equipment, 1)
|
||||
@@ -1191,28 +1171,33 @@
|
||||
autoflag = 0
|
||||
|
||||
// now trickle-charge the cell
|
||||
|
||||
if(src.attempt_charging())
|
||||
if (power_excess > 0) // check to make sure we have enough to charge
|
||||
cell.give(power_excess*CELLRATE) // actually recharge the cell
|
||||
if(excess > 0) // check to make sure we have enough to charge
|
||||
// Max charge is capped to % per second constant
|
||||
var/ch = min(excess*CELLRATE, cell.maxcharge*CHARGELEVEL)
|
||||
|
||||
ch = draw_power(ch/CELLRATE) // Removes the power we're taking from the grid
|
||||
cell.give(ch*CELLRATE) // actually recharge the cell
|
||||
|
||||
else
|
||||
charging = 0 // stop charging
|
||||
chargecount = 0
|
||||
|
||||
// show cell as fully charged if so
|
||||
if(cell.charge >= cell_maxcharge)
|
||||
if(cell.charge >= cell.maxcharge)
|
||||
cell.charge = cell.maxcharge
|
||||
charging = 2
|
||||
|
||||
//if we have excess power for long enough, think about re-enable charging.
|
||||
if(chargemode)
|
||||
if(!charging)
|
||||
//last_surplus() overestimates the amount of power available for charging, but it's equivalent to what APCs were doing before.
|
||||
if(src.last_surplus()*CELLRATE >= cell_maxcharge*CHARGELEVEL)
|
||||
if(excess > cell.maxcharge*CHARGELEVEL)
|
||||
chargecount++
|
||||
else
|
||||
chargecount = 0
|
||||
charging = 0
|
||||
|
||||
if(chargecount >= 10)
|
||||
|
||||
chargecount = 0
|
||||
charging = 1
|
||||
|
||||
@@ -1230,7 +1215,6 @@
|
||||
area.poweralert(0, src)
|
||||
autoflag = 0
|
||||
|
||||
|
||||
// update icon & area power if anything changed
|
||||
|
||||
if(last_lt != lighting || last_eq != equipment || last_en != environ)
|
||||
|
||||
@@ -23,9 +23,9 @@
|
||||
name = "power cell rack PSU"
|
||||
desc = "A rack of power cells working as a PSU."
|
||||
charge = 0 //you dont really want to make a potato PSU which already is overloaded
|
||||
online = 0
|
||||
chargelevel = 0
|
||||
output = 0
|
||||
output_attempt = 0
|
||||
input_level = 0
|
||||
output_level = 0
|
||||
input_level_max = 0
|
||||
output_level_max = 0
|
||||
icon_state = "gsmes"
|
||||
@@ -37,9 +37,9 @@
|
||||
/obj/machinery/power/smes/batteryrack/substation
|
||||
name = "Substation PSU"
|
||||
desc = "A rack of power cells working as a PSU. This one seems to be equipped for higher power loads."
|
||||
output = 150000
|
||||
chargelevel = 150000
|
||||
online = 1
|
||||
output_level = 150000
|
||||
input_level = 150000
|
||||
output_attempt = 1
|
||||
|
||||
// One high capacity cell, two regular cells. Lots of room for engineer upgrades
|
||||
// Also five basic capacitors. Again, upgradeable.
|
||||
@@ -89,13 +89,13 @@
|
||||
capacity = C * 40 //Basic cells are such crap. Hyper cells needed to get on normal SMES levels.
|
||||
|
||||
|
||||
/obj/machinery/power/smes/batteryrack/updateicon()
|
||||
/obj/machinery/power/smes/batteryrack/update_icon()
|
||||
overlays.Cut()
|
||||
if(stat & BROKEN) return
|
||||
|
||||
if (online)
|
||||
if (output_attempt)
|
||||
overlays += image('icons/obj/power.dmi', "gsmes_outputting")
|
||||
if(charging)
|
||||
if(inputting)
|
||||
overlays += image('icons/obj/power.dmi', "gsmes_charging")
|
||||
|
||||
var/clevel = chargedisplay()
|
||||
@@ -113,7 +113,7 @@
|
||||
if(open_hatch)
|
||||
if(istype(W, /obj/item/weapon/crowbar))
|
||||
if (charge < (capacity / 100))
|
||||
if (!online && !chargemode)
|
||||
if (!output_attempt && !input_attempt)
|
||||
playsound(get_turf(src), 'sound/items/Crowbar.ogg', 50, 1)
|
||||
var/obj/machinery/constructable_frame/machine_frame/M = new /obj/machinery/constructable_frame/machine_frame(src.loc)
|
||||
M.state = 2
|
||||
@@ -130,7 +130,7 @@
|
||||
user << "<span class='warning'>Better let [src] discharge before dismantling it.</span>"
|
||||
else if ((istype(W, /obj/item/weapon/stock_parts/capacitor) && (capacitors_amount < 5)) || (istype(W, /obj/item/weapon/cell) && (cells_amount < 5)))
|
||||
if (charge < (capacity / 100))
|
||||
if (!online && !chargemode)
|
||||
if (!output_attempt && !input_attempt)
|
||||
user.drop_item()
|
||||
component_parts += W
|
||||
W.loc = src
|
||||
@@ -163,13 +163,13 @@
|
||||
return
|
||||
|
||||
|
||||
/obj/machinery/power/smes/batteryrack/makeshift/updateicon()
|
||||
/obj/machinery/power/smes/batteryrack/makeshift/update_icon()
|
||||
overlays.Cut()
|
||||
if(stat & BROKEN) return
|
||||
|
||||
if (online)
|
||||
if (output_attempt)
|
||||
overlays += image('icons/obj/power.dmi', "gsmes_outputting")
|
||||
if(charging)
|
||||
if(inputting)
|
||||
overlays += image('icons/obj/power.dmi', "gsmes_charging")
|
||||
if (overcharge_percent > 100)
|
||||
overlays += image('icons/obj/power.dmi', "gsmes_overcharge")
|
||||
@@ -234,35 +234,35 @@
|
||||
|
||||
//store machine state to see if we need to update the icon overlays
|
||||
var/last_disp = chargedisplay()
|
||||
var/last_chrg = charging
|
||||
var/last_onln = online
|
||||
var/last_chrg = inputting
|
||||
var/last_onln = output_attempt
|
||||
var/last_overcharge = overcharge_percent
|
||||
|
||||
if(terminal)
|
||||
if(chargemode)
|
||||
var/target_load = min((capacity-charge)/SMESRATE, chargelevel) // charge at set rate, limited to spare capacity
|
||||
if(input_attempt)
|
||||
var/target_load = min((capacity-charge)/SMESRATE, input_level) // charge at set rate, limited to spare capacity
|
||||
var/actual_load = draw_power(target_load) // add the load to the terminal side network
|
||||
charge += actual_load * SMESRATE // increase the charge
|
||||
|
||||
if (actual_load >= target_load) // did the powernet have enough power available for us?
|
||||
charging = 1
|
||||
inputting = 1
|
||||
else
|
||||
charging = 0
|
||||
inputting = 0
|
||||
|
||||
if(online) // if outputting
|
||||
lastout = min( charge/SMESRATE, output) //limit output to that stored
|
||||
charge -= lastout*SMESRATE // reduce the storage (may be recovered in /restore() if excessive)
|
||||
add_avail(lastout) // add output to powernet (smes side)
|
||||
if(output_attempt) // if outputting
|
||||
output_used = min( charge/SMESRATE, output_level) //limit output to that stored
|
||||
charge -= output_used*SMESRATE // reduce the storage (may be recovered in /restore() if excessive)
|
||||
add_avail(output_used) // add output to powernet (smes side)
|
||||
if(charge < 0.0001)
|
||||
online = 0 // stop output if charge falls to zero
|
||||
outputting(0) // stop output if charge falls to zero
|
||||
|
||||
overcharge_percent = round((charge / capacity) * 100)
|
||||
if (overcharge_percent > 115) //115% is the minimum overcharge for anything to happen
|
||||
overcharge_consequences()
|
||||
|
||||
// only update icon if state changed
|
||||
if(last_disp != chargedisplay() || last_chrg != charging || last_onln != online || ((overcharge_percent > 100) ^ (last_overcharge > 100)))
|
||||
updateicon()
|
||||
if(last_disp != chargedisplay() || last_chrg != inputting || last_onln != output_attempt || ((overcharge_percent > 100) ^ (last_overcharge > 100)))
|
||||
update_icon()
|
||||
return
|
||||
|
||||
#undef SMESRATE
|
||||
|
||||
@@ -233,30 +233,6 @@ obj/structure/cable/proc/cableColor(var/colorC)
|
||||
color_n = colorC
|
||||
color = color_n
|
||||
|
||||
////////////////////////////////////////////
|
||||
// Power related
|
||||
///////////////////////////////////////////
|
||||
|
||||
obj/structure/cable/proc/add_avail(var/amount)
|
||||
if(powernet)
|
||||
powernet.newavail += amount
|
||||
|
||||
obj/structure/cable/proc/add_load(var/amount)
|
||||
if(powernet)
|
||||
powernet.load += amount
|
||||
|
||||
obj/structure/cable/proc/surplus()
|
||||
if(powernet)
|
||||
return powernet.avail-powernet.load
|
||||
else
|
||||
return 0
|
||||
|
||||
obj/structure/cable/proc/avail()
|
||||
if(powernet)
|
||||
return powernet.avail
|
||||
else
|
||||
return 0
|
||||
|
||||
/////////////////////////////////////////////////
|
||||
// Cable laying helpers
|
||||
////////////////////////////////////////////////
|
||||
|
||||
@@ -601,11 +601,11 @@
|
||||
|
||||
#define LIGHTING_POWER_FACTOR 20 //20W per unit luminosity
|
||||
|
||||
/*
|
||||
/obj/machinery/light/process()//TODO: remove/add this from machines to save on processing as needed ~Carn PRIORITY
|
||||
|
||||
/obj/machinery/light/process()
|
||||
if(on)
|
||||
use_power(luminosity * LIGHTING_POWER_FACTOR, LIGHT)
|
||||
*/
|
||||
|
||||
|
||||
// called when area power state changes
|
||||
/obj/machinery/light/power_change()
|
||||
|
||||
@@ -352,7 +352,7 @@
|
||||
source_area.use_power(drained_energy/CELLRATE)
|
||||
else if (istype(power_source,/datum/powernet))
|
||||
var/drained_power = drained_energy/CELLRATE //convert from "joules" to "watts"
|
||||
PN.load+=drained_power
|
||||
drained_power = PN.draw_power(drained_power)
|
||||
else if (istype(power_source, /obj/item/weapon/cell))
|
||||
cell.use(drained_energy)
|
||||
return drained_energy
|
||||
|
||||
@@ -1,136 +0,0 @@
|
||||
// the power monitoring computer
|
||||
// for the moment, just report the status of all APCs in the same powernet
|
||||
/obj/machinery/power/monitor
|
||||
name = "power monitoring computer"
|
||||
desc = "It monitors power levels across the station."
|
||||
icon = 'icons/obj/computer.dmi'
|
||||
icon_state = "power"
|
||||
|
||||
//computer stuff
|
||||
density = 1
|
||||
anchored = 1.0
|
||||
var/circuit = /obj/item/weapon/circuitboard/powermonitor
|
||||
use_power = 1
|
||||
idle_power_usage = 300
|
||||
active_power_usage = 300
|
||||
|
||||
/obj/machinery/power/monitor/New()
|
||||
..()
|
||||
var/obj/structure/cable/attached = null
|
||||
var/turf/T = loc
|
||||
if(isturf(T))
|
||||
attached = locate() in T
|
||||
if(attached)
|
||||
powernet = attached.get_powernet()
|
||||
|
||||
/obj/machinery/power/monitor/attack_ai(mob/user)
|
||||
add_fingerprint(user)
|
||||
|
||||
if(stat & (BROKEN|NOPOWER))
|
||||
return
|
||||
interact(user)
|
||||
|
||||
/obj/machinery/power/monitor/attack_hand(mob/user)
|
||||
add_fingerprint(user)
|
||||
|
||||
if(stat & (BROKEN|NOPOWER))
|
||||
return
|
||||
interact(user)
|
||||
|
||||
/obj/machinery/power/monitor/interact(mob/user)
|
||||
|
||||
if ( (get_dist(src, user) > 1 ) || (stat & (BROKEN|NOPOWER)) )
|
||||
if (!istype(user, /mob/living/silicon))
|
||||
user.unset_machine()
|
||||
user << browse(null, "window=powcomp")
|
||||
return
|
||||
|
||||
|
||||
user.set_machine(src)
|
||||
var/t = "<TT><B>Power Monitoring</B><HR>"
|
||||
|
||||
t += "<BR><HR><A href='?src=\ref[src];update=1'>Refresh</A>"
|
||||
t += "<BR><HR><A href='?src=\ref[src];close=1'>Close</A>"
|
||||
|
||||
if(!powernet)
|
||||
t += "\red No connection"
|
||||
else
|
||||
|
||||
var/list/L = list()
|
||||
for(var/obj/machinery/power/terminal/term in powernet.nodes)
|
||||
if(istype(term.master, /obj/machinery/power/apc))
|
||||
var/obj/machinery/power/apc/A = term.master
|
||||
L += A
|
||||
|
||||
t += "<PRE>Total power: [powernet.avail] W<BR>Total load: [num2text(powernet.viewload,10)] W<BR>"
|
||||
|
||||
t += "<FONT SIZE=-1>"
|
||||
|
||||
if(L.len > 0)
|
||||
var/total_demand = 0
|
||||
t += "Area Eqp./Lgt./Env. Load Cell<HR>"
|
||||
|
||||
var/list/S = list(" Off","AOff"," On", " AOn")
|
||||
var/list/chg = list("N","C","F")
|
||||
|
||||
for(var/obj/machinery/power/apc/A in L)
|
||||
|
||||
t += copytext(add_tspace("\The [A.area]", 30), 1, 30)
|
||||
t += " [S[A.equipment+1]] [S[A.lighting+1]] [S[A.environ+1]] [add_lspace(A.lastused_total, 6)] [A.cell ? "[add_lspace(round(A.cell.percent()), 3)]% [chg[A.charging+1]]" : " N/C"]<BR>"
|
||||
total_demand += A.lastused_total
|
||||
|
||||
t += "<HR>Total demand: [total_demand] W</FONT>"
|
||||
t += "</PRE></TT>"
|
||||
|
||||
user << browse(t, "window=powcomp;size=420x900")
|
||||
onclose(user, "powcomp")
|
||||
|
||||
|
||||
/obj/machinery/power/monitor/Topic(href, href_list)
|
||||
..()
|
||||
if( href_list["close"] )
|
||||
usr << browse(null, "window=powcomp")
|
||||
usr.unset_machine()
|
||||
return
|
||||
if( href_list["update"] )
|
||||
src.updateDialog()
|
||||
return
|
||||
|
||||
|
||||
/obj/machinery/power/monitor/power_change()
|
||||
..()
|
||||
if(stat & BROKEN)
|
||||
icon_state = "broken"
|
||||
else
|
||||
if (stat & NOPOWER)
|
||||
spawn(rand(0, 15))
|
||||
src.icon_state = "c_unpowered"
|
||||
else
|
||||
icon_state = initial(icon_state)
|
||||
|
||||
|
||||
//copied from computer.dm
|
||||
/obj/machinery/power/monitor/attackby(I as obj, user as mob)
|
||||
if(istype(I, /obj/item/weapon/screwdriver) && circuit)
|
||||
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
|
||||
if(do_after(user, 20))
|
||||
var/obj/structure/computerframe/A = new /obj/structure/computerframe( src.loc )
|
||||
var/obj/item/weapon/circuitboard/M = new circuit( A )
|
||||
A.circuit = M
|
||||
A.anchored = 1
|
||||
for (var/obj/C in src)
|
||||
C.loc = src.loc
|
||||
if (src.stat & BROKEN)
|
||||
user << "\blue The broken glass falls out."
|
||||
new /obj/item/weapon/shard( src.loc )
|
||||
A.state = 3
|
||||
A.icon_state = "3"
|
||||
else
|
||||
user << "\blue You disconnect the monitor."
|
||||
A.state = 4
|
||||
A.icon_state = "4"
|
||||
M.deconstruct(src)
|
||||
del(src)
|
||||
else
|
||||
src.attack_hand(user)
|
||||
return
|
||||
@@ -12,6 +12,8 @@
|
||||
var/perapc_excess = 0
|
||||
var/netexcess = 0 // excess power on the powernet (typically avail-load)
|
||||
|
||||
var/problem = 0 // If this is not 0 there is some sort of issue in the powernet. Monitors will display warnings.
|
||||
|
||||
/datum/powernet/New()
|
||||
powernets += src
|
||||
|
||||
@@ -72,11 +74,19 @@
|
||||
M.powernet = src
|
||||
nodes[M] = M
|
||||
|
||||
// Triggers warning for certain amount of ticks
|
||||
/datum/powernet/proc/trigger_warning(var/duration_ticks = 20)
|
||||
problem = max(duration_ticks, problem)
|
||||
|
||||
|
||||
//handles the power changes in the powernet
|
||||
//called every ticks by the powernet controller
|
||||
/datum/powernet/proc/reset()
|
||||
var/numapc = 0
|
||||
|
||||
if(problem > 0)
|
||||
problem = max(problem - 1, 0)
|
||||
|
||||
if(nodes && nodes.len) // Added to fix a bad list bug -- TLE
|
||||
for(var/obj/machinery/power/terminal/term in nodes)
|
||||
if( istype( term.master, /obj/machinery/power/apc ) )
|
||||
|
||||
@@ -0,0 +1,94 @@
|
||||
/*
|
||||
********** POWERNET SENSOR **********
|
||||
- Simple machine which detects power levels in cables under it.
|
||||
- Used with power_monitor.dm to measure power levels around station.
|
||||
- Can have ID tag for organisation purposes.
|
||||
*/
|
||||
|
||||
/obj/machinery/power/sensor
|
||||
name = "Powernet Sensor"
|
||||
desc = "Small machine which transmits data about specific powernet"
|
||||
anchored = 1
|
||||
density = 0
|
||||
layer = 2.46 // Above cables, but should be below floors.
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "floor_beacon" // If anyone wants to make better sprite, feel free to do so without asking me.
|
||||
|
||||
var/name_tag = "#UNKN#" // ID tag displayed in list of powernet sensors. Each sensor should have it's own tag!
|
||||
var/long_range = 0 // If 1, sensor reading will show on all computers, regardless of Zlevel
|
||||
|
||||
/obj/machinery/power/sensor/New()
|
||||
..()
|
||||
name = "[name_tag] - Powernet Sensor" // Auto-name according to name_tag
|
||||
|
||||
/obj/machinery/power/sensor/proc/RefreshGrid()
|
||||
connect_to_network()
|
||||
|
||||
/obj/machinery/power/sensor/proc/ReturnReading()
|
||||
var/out = ""
|
||||
RefreshGrid() // First try to refresh the grid.
|
||||
if(!powernet) // No powernet.
|
||||
out = "# SYSTEM ERROR - NO POWERNET #"
|
||||
return out
|
||||
|
||||
// Attempt to locate APCs in powernet
|
||||
var/list/L = list()
|
||||
for(var/obj/machinery/power/terminal/term in powernet.nodes)
|
||||
if(istype(term.master, /obj/machinery/power/apc))
|
||||
var/obj/machinery/power/apc/A = term.master
|
||||
L += A
|
||||
|
||||
if(L.len <= 0) // No APCs found.
|
||||
out = "<b>No APCs located in connected powernet!</b>"
|
||||
else // APCs found. Create very ugly (but working!) HTML table.
|
||||
var/total_load = 0
|
||||
out += "<table><tr><th>Name<th>EQUIP<th>LIGHT<th>ENVIRON<th>CELL<th>LOAD"
|
||||
|
||||
// These lists are used as replacement for number based APC settings
|
||||
var/list/S = list("M-OFF","A-OFF","M-ON", "A-ON")
|
||||
var/list/chg = list("N","C","F")
|
||||
|
||||
// Split to multiple lines to make it more readable
|
||||
for(var/obj/machinery/power/apc/A in L)
|
||||
out += "<tr><td>\The [A.area]" // Add area name
|
||||
out += "<td>[S[A.equipment+1]]<td>[S[A.lighting+1]]<td>[S[A.environ+1]]" // Show status of channels
|
||||
if(A.cell)
|
||||
out += "<td>[round(A.cell.percent())]% - [chg[A.charging+1]]"
|
||||
else
|
||||
out += "<td>NO CELL"
|
||||
var/load = A.lastused_total // Load.
|
||||
total_load += load
|
||||
if(load > 1000)
|
||||
load = "~[round(load/100)/10]kW" // If above 1000W convert to Kilowatts.
|
||||
else
|
||||
load = "[round(load)]W" // Below 1000W, leave it in Watts
|
||||
out += "<td>[load]" // Add load info
|
||||
|
||||
if (total_load > 1000)
|
||||
total_load = "~[round(total_load/100)/10] kW"
|
||||
else
|
||||
total_load = "[round(total_load)] W"
|
||||
|
||||
out += "</table><br><b>TOTAL GRID LOAD: [total_load]</b>"
|
||||
|
||||
var/textavail = powernet.avail
|
||||
if(textavail > 1000)
|
||||
textavail = "[round(textavail/100)/10] kW"
|
||||
else
|
||||
textavail = "[textavail] W"
|
||||
out += "<br><b>TOTAL AVAILABLE: [textavail]</b>"
|
||||
|
||||
if(powernet.problem)
|
||||
out += "<br><b>WARNING: Abnormal grid activity detected!</b>"
|
||||
return out
|
||||
|
||||
/obj/machinery/power/sensor/proc/check_grid_warning()
|
||||
RefreshGrid()
|
||||
if(powernet)
|
||||
if(powernet.problem)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
// Has to be here as we need it to be in Machines list.
|
||||
/obj/machinery/power/sensor/process()
|
||||
return 1
|
||||
@@ -0,0 +1,185 @@
|
||||
/*
|
||||
********** SENSOR MONITOR **********
|
||||
- Remotely monitors sensors around the station and displays their readings.
|
||||
- Should filter out most duplicities.
|
||||
*/
|
||||
|
||||
/obj/machinery/computer/power_monitor
|
||||
name = "Power Monitor"
|
||||
desc = "Computer designed to remotely monitor power levels around the station"
|
||||
icon = 'icons/obj/computer.dmi'
|
||||
icon_state = "power"
|
||||
|
||||
//computer stuff
|
||||
density = 1
|
||||
anchored = 1.0
|
||||
circuit = /obj/item/weapon/circuitboard/powermonitor
|
||||
var/list/grid_sensors = null
|
||||
var/update_counter = 0 // Next icon update when this reaches 5 (ie every 5 ticks)
|
||||
var/active_sensor = null
|
||||
use_power = 1
|
||||
idle_power_usage = 300
|
||||
active_power_usage = 300
|
||||
|
||||
// Update icon every 5 ticks.
|
||||
/obj/machinery/computer/power_monitor/process()
|
||||
update_counter++
|
||||
if(update_counter > 4)
|
||||
update_icon()
|
||||
|
||||
/obj/machinery/computer/power_monitor/New()
|
||||
..()
|
||||
refresh_sensors()
|
||||
|
||||
|
||||
/obj/machinery/computer/power_monitor/proc/refresh_sensors()
|
||||
grid_sensors = list()
|
||||
for(var/obj/machinery/power/sensor/S in machines)
|
||||
if((S.loc.z == src.loc.z) || (S.long_range)) // Consoles have range on their Z-Level. Sensors with long_range var will work between Z levels.
|
||||
if(S.name_tag == "#UNKN#") // Default name. Shouldn't happen!
|
||||
error("Powernet sensor with unset ID Tag! [S.x]X [S.y]Y [S.z]Z")
|
||||
else
|
||||
grid_sensors += S
|
||||
|
||||
|
||||
/obj/machinery/computer/power_monitor/attack_ai(mob/user)
|
||||
add_fingerprint(user)
|
||||
|
||||
if(stat & (BROKEN|NOPOWER))
|
||||
return
|
||||
interact(user)
|
||||
|
||||
/obj/machinery/computer/power_monitor/attack_hand(mob/user)
|
||||
add_fingerprint(user)
|
||||
|
||||
if(stat & (BROKEN|NOPOWER))
|
||||
return
|
||||
interact(user)
|
||||
|
||||
/obj/machinery/computer/power_monitor/interact(mob/user)
|
||||
|
||||
if ( (get_dist(src, user) > 1 ) || (stat & (BROKEN|NOPOWER)) )
|
||||
if (!istype(user, /mob/living/silicon))
|
||||
user.unset_machine()
|
||||
user << browse(null, "window=powcomp")
|
||||
return
|
||||
|
||||
refresh_sensors()
|
||||
|
||||
user.set_machine(src)
|
||||
var/t = "<TT><B>Station Power Monitoring</B><HR>"
|
||||
if(active_sensor)
|
||||
|
||||
t += "<BR><A href='?src=\ref[src];update=1'>Refresh</A>"
|
||||
t += "<BR><A href='?src=\ref[src];clear=1'>Sensor List</A>"
|
||||
t += "<BR><A href='?src=\ref[src];close=1'>Close</A><BR><HR>"
|
||||
|
||||
if(!grid_sensors)
|
||||
t += "Unable to connect to sensor!"
|
||||
else
|
||||
var/obj/machinery/power/sensor/OKS = null
|
||||
for(var/obj/machinery/power/sensor/S in grid_sensors)
|
||||
if(S.name_tag == active_sensor)
|
||||
OKS = S
|
||||
if(OKS)
|
||||
t += "<B>[OKS.name_tag] - Sensor Reading</B><BR>"
|
||||
t += OKS.ReturnReading()
|
||||
else
|
||||
t += "Unable to connect to sensor!"
|
||||
|
||||
|
||||
else
|
||||
t += "<BR><A href='?src=\ref[src];update=1'>Refresh</A>"
|
||||
t += "<BR><A href='?src=\ref[src];close=1'>Close</A><BR><HR>"
|
||||
if((!grid_sensors) || (!grid_sensors.len))
|
||||
t += "<B>ERROR - No Active Sensors Detected!</B>"
|
||||
else
|
||||
for(var/obj/machinery/power/sensor/S in grid_sensors) // Show all data from current Z level.
|
||||
if(S.check_grid_warning()) // Display grids with active alarms in bold text
|
||||
t += "<B><A href='?src=\ref[src];setsensor=[S.name_tag]'>[S.name]</A></B><BR>"
|
||||
else
|
||||
t += "<A href='?src=\ref[src];setsensor=[S.name_tag]'>[S.name]</A><BR>"
|
||||
|
||||
|
||||
|
||||
user << browse(t, "window=powcomp;size=600x900")
|
||||
onclose(user, "powcomp")
|
||||
|
||||
|
||||
/obj/machinery/computer/power_monitor/Topic(href, href_list)
|
||||
..()
|
||||
if( href_list["close"] )
|
||||
usr << browse(null, "window=powcomp")
|
||||
usr.unset_machine()
|
||||
return
|
||||
if( href_list["update"] )
|
||||
src.updateDialog()
|
||||
return
|
||||
if( href_list["clear"] )
|
||||
active_sensor = null
|
||||
src.updateDialog()
|
||||
return
|
||||
if( href_list["setsensor"] )
|
||||
active_sensor = href_list["setsensor"]
|
||||
src.updateDialog()
|
||||
|
||||
/obj/machinery/computer/power_monitor/update_icon()
|
||||
update_counter = 0 // Reset the icon update counter.
|
||||
if(stat & BROKEN)
|
||||
icon_state = "powerb"
|
||||
return
|
||||
if(stat & NOPOWER)
|
||||
icon_state = "power0"
|
||||
return
|
||||
if(check_warnings())
|
||||
icon_state = "power_alert"
|
||||
return
|
||||
|
||||
icon_state = "power"
|
||||
|
||||
/obj/machinery/computer/power_monitor/proc/check_warnings()
|
||||
var/warn = 0
|
||||
if(grid_sensors)
|
||||
for(var/obj/machinery/power/sensor/S in grid_sensors)
|
||||
if(S.check_grid_warning())
|
||||
warn = 1
|
||||
return warn
|
||||
|
||||
|
||||
/obj/machinery/computer/power_monitor/power_change()
|
||||
..()
|
||||
|
||||
// Leaving this here to preserve that delayed shutdown effect when power goes out.
|
||||
if (stat & NOPOWER)
|
||||
spawn(rand(0, 15))
|
||||
update_icon()
|
||||
else
|
||||
update_icon()
|
||||
|
||||
/*
|
||||
//copied from computer.dm
|
||||
/obj/machinery/power/monitor/attackby(I as obj, user as mob)
|
||||
if(istype(I, /obj/item/weapon/screwdriver) && circuit)
|
||||
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
|
||||
if(do_after(user, 20))
|
||||
var/obj/structure/computerframe/A = new /obj/structure/computerframe( src.loc )
|
||||
var/obj/item/weapon/circuitboard/M = new circuit( A )
|
||||
A.circuit = M
|
||||
A.anchored = 1
|
||||
for (var/obj/C in src)
|
||||
C.loc = src.loc
|
||||
if (src.stat & BROKEN)
|
||||
user << "\blue The broken glass falls out."
|
||||
new /obj/item/weapon/shard( src.loc )
|
||||
A.state = 3
|
||||
A.icon_state = "3"
|
||||
else
|
||||
user << "\blue You disconnect the monitor."
|
||||
A.state = 4
|
||||
A.icon_state = "4"
|
||||
M.deconstruct(src)
|
||||
del(src)
|
||||
else
|
||||
src.attack_hand(user)
|
||||
return
|
||||
*/
|
||||
@@ -11,27 +11,31 @@
|
||||
density = 1
|
||||
anchored = 1
|
||||
use_power = 0
|
||||
//directwired = 0
|
||||
var/output = 50000 //Amount of power it tries to output
|
||||
var/lastout = 0 //Amount of power it actually outputs to the powernet
|
||||
var/loaddemand = 0 //For use in restore()
|
||||
var/capacity = 5e6 //Maximum amount of power it can hold
|
||||
var/charge = 1.0e6 //Current amount of power it holds
|
||||
var/charging = 0 //1 if it's actually charging, 0 if not
|
||||
var/chargemode = 0 //1 if it's trying to charge, 0 if not.
|
||||
//var/chargecount = 0
|
||||
var/chargelevel = 0 //Amount of power it tries to charge from powernet
|
||||
var/online = 1 //1 if it's outputting power, 0 if not.
|
||||
var/name_tag = null
|
||||
var/obj/machinery/power/terminal/terminal = null
|
||||
|
||||
var/capacity = 5e6 // maximum charge
|
||||
var/charge = 1e6 // actual charge
|
||||
|
||||
var/input_attempt = 0 // 1 = attempting to charge, 0 = not attempting to charge
|
||||
var/inputting = 0 // 1 = actually inputting, 0 = not inputting
|
||||
var/input_level = 50000 // amount of power the SMES attempts to charge by
|
||||
var/input_level_max = 200000 // cap on input_level
|
||||
var/input_available = 0 // amount of charge available from input last tick
|
||||
|
||||
var/output_attempt = 1 // 1 = attempting to output, 0 = not attempting to output
|
||||
var/outputting = 1 // 1 = actually outputting, 0 = not outputting
|
||||
var/output_level = 50000 // amount of power the SMES attempts to output
|
||||
var/output_level_max = 200000 // cap on output_level
|
||||
var/output_used = 0 // amount of power actually outputted. may be less than output_level if the powernet returns excess power
|
||||
|
||||
//Holders for powerout event.
|
||||
var/last_output = 0
|
||||
var/last_charge = 0
|
||||
var/last_online = 0
|
||||
var/last_output_attempt = 0
|
||||
var/last_input_attempt = 0
|
||||
var/last_charge = 0
|
||||
|
||||
var/open_hatch = 0
|
||||
var/name_tag = null
|
||||
var/building_terminal = 0 //Suggestions about how to avoid clickspam building several terminals accepted!
|
||||
var/input_level_max = 200000
|
||||
var/output_level_max = 200000
|
||||
var/obj/machinery/power/terminal/terminal = null
|
||||
|
||||
/obj/machinery/power/smes/drain_power(var/drain_check)
|
||||
|
||||
@@ -69,21 +73,21 @@
|
||||
terminal.master = src
|
||||
if(!terminal.powernet)
|
||||
terminal.connect_to_network()
|
||||
updateicon()
|
||||
update_icon()
|
||||
return
|
||||
|
||||
/obj/machinery/power/smes/proc/updateicon()
|
||||
/obj/machinery/power/smes/update_icon()
|
||||
overlays.Cut()
|
||||
if(stat & BROKEN) return
|
||||
|
||||
overlays += image('icons/obj/power.dmi', "smes-op[online]")
|
||||
overlays += image('icons/obj/power.dmi', "smes-op[outputting]")
|
||||
|
||||
if(charging == 2)
|
||||
if(inputting == 2)
|
||||
overlays += image('icons/obj/power.dmi', "smes-oc2")
|
||||
else if (charging == 1)
|
||||
else if (inputting == 1)
|
||||
overlays += image('icons/obj/power.dmi', "smes-oc1")
|
||||
else
|
||||
if(chargemode)
|
||||
if(input_attempt)
|
||||
overlays += image('icons/obj/power.dmi', "smes-oc0")
|
||||
|
||||
var/clevel = chargedisplay()
|
||||
@@ -99,57 +103,62 @@
|
||||
|
||||
|
||||
/obj/machinery/power/smes/process()
|
||||
|
||||
if(stat & BROKEN) return
|
||||
|
||||
//store machine state to see if we need to update the icon overlays
|
||||
var/last_disp = chargedisplay()
|
||||
var/last_chrg = charging
|
||||
var/last_onln = online
|
||||
var/last_chrg = inputting
|
||||
var/last_onln = outputting
|
||||
|
||||
if(terminal)
|
||||
//If chargemod is set, try to charge
|
||||
//Use charging to let the player know whether we were able to obtain our target load.
|
||||
//TODO: Add a meter to tell players how much charge we are actually getting, and only set charging to 0 when we are unable to get any charge at all.
|
||||
if(chargemode)
|
||||
var/target_load = min((capacity-charge)/SMESRATE, chargelevel) // charge at set rate, limited to spare capacity
|
||||
var/actual_load = draw_power(target_load) // add the load to the terminal side network
|
||||
charge += actual_load * SMESRATE // increase the charge
|
||||
//inputting
|
||||
if(input_attempt)
|
||||
var/target_load = min((capacity-charge)/SMESRATE, input_level) // charge at set rate, limited to spare capacity
|
||||
var/actual_load = draw_power(target_load) // add the load to the terminal side network
|
||||
charge += actual_load * SMESRATE // increase the charge
|
||||
|
||||
if (actual_load >= target_load) // Did we charge at full rate?
|
||||
charging = 2
|
||||
else if (actual_load) // If not, did we charge at least partially?
|
||||
charging = 1
|
||||
else // Or not at all?
|
||||
charging = 0
|
||||
if (actual_load >= target_load) // Did we charge at full rate?
|
||||
inputting = 2
|
||||
else if (actual_load) // If not, did we charge at least partially?
|
||||
inputting = 1
|
||||
else // Or not at all?
|
||||
inputting = 0
|
||||
|
||||
if(online) // if outputting
|
||||
lastout = min( charge/SMESRATE, output) //limit output to that stored
|
||||
charge -= lastout*SMESRATE // reduce the storage (may be recovered in /restore() if excessive)
|
||||
add_avail(lastout) // add output to powernet (smes side)
|
||||
if(charge < 0.0001)
|
||||
online = 0 // stop output if charge falls to zero
|
||||
//outputting
|
||||
if(outputting)
|
||||
output_used = min( charge/SMESRATE, output_level) //limit output to that stored
|
||||
|
||||
charge -= output_used*SMESRATE // reduce the storage (may be recovered in /restore() if excessive)
|
||||
|
||||
add_avail(output_used) // add output to powernet (smes side)
|
||||
|
||||
if(output_used < 0.0001) // either from no charge or set to 0
|
||||
outputting = 0
|
||||
investigate_log("lost power and turned <font color='red'>off</font>","singulo")
|
||||
else if(output_attempt && charge > output_level && output_level > 0)
|
||||
outputting = 1
|
||||
else
|
||||
output_used = 0
|
||||
|
||||
// only update icon if state changed
|
||||
if(last_disp != chargedisplay() || last_chrg != charging || last_onln != online)
|
||||
updateicon()
|
||||
if(last_disp != chargedisplay() || last_chrg != inputting || last_onln != outputting)
|
||||
update_icon()
|
||||
|
||||
|
||||
return
|
||||
|
||||
// called after all power processes are finished
|
||||
// restores charge level to smes if there was excess this ptick
|
||||
|
||||
|
||||
/obj/machinery/power/smes/proc/restore()
|
||||
if(stat & BROKEN)
|
||||
return
|
||||
|
||||
if(!online)
|
||||
loaddemand = 0
|
||||
if(!outputting)
|
||||
output_used = 0
|
||||
return
|
||||
|
||||
var/excess = powernet.netexcess // this was how much wasn't used on the network last ptick, minus any removed by other SMESes
|
||||
|
||||
excess = min(lastout, excess) // clamp it to how much was actually output by this SMES last ptick
|
||||
excess = min(output_used, excess) // clamp it to how much was actually output by this SMES last ptick
|
||||
|
||||
excess = min((capacity-charge)/SMESRATE, excess) // for safety, also limit recharge by space capacity of SMES (shouldn't happen)
|
||||
|
||||
@@ -157,13 +166,13 @@
|
||||
|
||||
var/clev = chargedisplay()
|
||||
|
||||
charge += excess * SMESRATE
|
||||
charge += excess * SMESRATE // restore unused power
|
||||
powernet.netexcess -= excess // remove the excess from the powernet, so later SMESes don't try to use it
|
||||
|
||||
loaddemand = lastout-excess
|
||||
output_used -= excess
|
||||
|
||||
if(clev != chargedisplay() )
|
||||
updateicon()
|
||||
if(clev != chargedisplay() ) //if needed updates the icons overlay
|
||||
update_icon()
|
||||
return
|
||||
|
||||
//Will return 1 on failure
|
||||
@@ -280,14 +289,14 @@
|
||||
var/data[0]
|
||||
data["nameTag"] = name_tag
|
||||
data["storedCapacity"] = round(100.0*charge/capacity, 0.1)
|
||||
data["charging"] = charging
|
||||
data["chargeMode"] = chargemode
|
||||
data["chargeLevel"] = chargelevel
|
||||
data["charging"] = inputting
|
||||
data["chargeMode"] = input_attempt
|
||||
data["chargeLevel"] = input_level
|
||||
data["chargeMax"] = input_level_max
|
||||
data["outputOnline"] = online
|
||||
data["outputLevel"] = output
|
||||
data["outputOnline"] = output_attempt
|
||||
data["outputLevel"] = output_level
|
||||
data["outputMax"] = output_level_max
|
||||
data["outputLoad"] = round(loaddemand)
|
||||
data["outputLoad"] = round(output_used)
|
||||
|
||||
// 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)
|
||||
@@ -318,40 +327,34 @@
|
||||
if (!istype(src.loc, /turf) && !istype(usr, /mob/living/silicon/))
|
||||
return 0 // Do not update ui
|
||||
|
||||
for(var/area/A in active_areas)
|
||||
A.master.powerupdate = 3
|
||||
|
||||
|
||||
if( href_list["cmode"] )
|
||||
chargemode = !chargemode
|
||||
if(!chargemode)
|
||||
charging = 0
|
||||
updateicon()
|
||||
inputting(!inputting)
|
||||
update_icon()
|
||||
|
||||
else if( href_list["online"] )
|
||||
online = !online
|
||||
updateicon()
|
||||
outputting(!outputting)
|
||||
update_icon()
|
||||
else if( href_list["input"] )
|
||||
switch( href_list["input"] )
|
||||
if("min")
|
||||
chargelevel = 0
|
||||
input_level = 0
|
||||
if("max")
|
||||
chargelevel = input_level_max
|
||||
input_level = input_level_max
|
||||
if("set")
|
||||
chargelevel = input(usr, "Enter new input level (0-[input_level_max])", "SMES Input Power Control", chargelevel) as num
|
||||
chargelevel = max(0, min(input_level_max, chargelevel)) // clamp to range
|
||||
input_level = input(usr, "Enter new input level (0-[input_level_max])", "SMES Input Power Control", input_level) as num
|
||||
input_level = max(0, min(input_level_max, input_level)) // clamp to range
|
||||
|
||||
else if( href_list["output"] )
|
||||
switch( href_list["output"] )
|
||||
if("min")
|
||||
output = 0
|
||||
output_level = 0
|
||||
if("max")
|
||||
output = output_level_max
|
||||
output_level = output_level_max
|
||||
if("set")
|
||||
output = input(usr, "Enter new output level (0-[output_level_max])", "SMES Output Power Control", output) as num
|
||||
output = max(0, min(output_level_max, output)) // clamp to range
|
||||
output_level = input(usr, "Enter new output level (0-[output_level_max])", "SMES Output Power Control", output_level) as num
|
||||
output_level = max(0, min(output_level_max, output_level)) // clamp to range
|
||||
|
||||
investigate_log("input/output; [chargelevel>output?"<font color='green'>":"<font color='red'>"][chargelevel]/[output]</font> | Output-mode: [online?"<font color='green'>on</font>":"<font color='red'>off</font>"] | Input-mode: [chargemode?"<font color='green'>auto</font>":"<font color='red'>off</font>"] by [usr.key]","singulo")
|
||||
investigate_log("input/output; [input_level>output_level?"<font color='green'>":"<font color='red'>"][input_level]/[output_level]</font> | Output-mode: [output_attempt?"<font color='green'>on</font>":"<font color='red'>off</font>"] | Input-mode: [input_attempt?"<font color='green'>auto</font>":"<font color='red'>off</font>"] by [usr.key]","singulo")
|
||||
|
||||
return 1
|
||||
|
||||
@@ -383,27 +386,33 @@
|
||||
smoke.attach(src)
|
||||
smoke.start()
|
||||
|
||||
/obj/machinery/power/smes/proc/inputting(var/do_input)
|
||||
input_attempt = do_input
|
||||
if(!input_attempt)
|
||||
inputting = 0
|
||||
|
||||
/obj/machinery/power/smes/proc/outputting(var/do_output)
|
||||
output_attempt = do_output
|
||||
if(!output_attempt)
|
||||
outputting = 0
|
||||
|
||||
/obj/machinery/power/smes/emp_act(severity)
|
||||
online = 0
|
||||
charging = 0
|
||||
output = 0
|
||||
inputting(rand(0,1))
|
||||
outputting(rand(0,1))
|
||||
output_level = rand(0, output_level_max)
|
||||
input_level = rand(0, input_level_max)
|
||||
charge -= 1e6/severity
|
||||
if (charge < 0)
|
||||
charge = 0
|
||||
spawn(100)
|
||||
output = initial(output)
|
||||
charging = initial(charging)
|
||||
online = initial(online)
|
||||
update_icon()
|
||||
..()
|
||||
|
||||
|
||||
|
||||
/obj/machinery/power/smes/magical
|
||||
name = "magical power storage unit"
|
||||
desc = "A high-capacity superconducting magnetic energy storage (SMES) unit. Magically produces power."
|
||||
capacity = 9000000
|
||||
output = 250000
|
||||
output_level = 250000
|
||||
|
||||
/obj/machinery/power/smes/magical/process()
|
||||
charge = 5000000
|
||||
|
||||
@@ -177,7 +177,7 @@
|
||||
A.set_broken()
|
||||
|
||||
// Failing SMES has special icon overlay.
|
||||
/obj/machinery/power/smes/buildable/updateicon()
|
||||
/obj/machinery/power/smes/buildable/update_icon()
|
||||
if (failing)
|
||||
overlays.Cut()
|
||||
overlays += image('icons/obj/power.dmi', "smes-crit")
|
||||
@@ -199,7 +199,7 @@
|
||||
user << "<span class='warning'>Safety circuit of [src] is preventing modifications while it's charged!</span>"
|
||||
return
|
||||
|
||||
if (online || chargemode)
|
||||
if (output_attempt || input_attempt)
|
||||
user << "<span class='warning'>Turn off the [src] first!</span>"
|
||||
return
|
||||
|
||||
|
||||
@@ -195,10 +195,10 @@ var/list/solars_list = list()
|
||||
|
||||
T = locate( round(ax,0.5),round(ay,0.5),z)
|
||||
|
||||
if(T.x == 1 || T.x==world.maxx || T.y==1 || T.y==world.maxy) // not obscured if we reach the edge
|
||||
if(!T || T.x == 1 || T.x==world.maxx || T.y==1 || T.y==world.maxy) // not obscured if we reach the edge
|
||||
break
|
||||
|
||||
if(T.density) // if we hit a solid turf, panel is obscured
|
||||
if(T.opacity) // if we hit a solid turf, panel is obscured
|
||||
obscured = 1
|
||||
return
|
||||
|
||||
@@ -386,7 +386,8 @@ var/list/solars_list = list()
|
||||
/obj/machinery/power/solar_control/interact(mob/user)
|
||||
|
||||
var/t = "<B><span class='highlight'>Generated power</span></B> : [round(lastgen)] W<BR>"
|
||||
t += "<B><span class='highlight'>Orientation</span></B>: [rate_control(src,"cdir","[cdir]°",1,15)] ([angle2text(cdir)])<BR>"
|
||||
t += "<B><span class='highlight'>Star Orientation</span></B>: [sun.angle]° ([angle2text(sun.angle)])<BR>"
|
||||
t += "<B><span class='highlight'>Array Orientation</span></B>: [rate_control(src,"cdir","[cdir]°",1,15)] ([angle2text(cdir)])<BR>"
|
||||
t += "<B><span class='highlight'>Tracking:</B><div class='statusDisplay'>"
|
||||
switch(track)
|
||||
if(0)
|
||||
|
||||
@@ -146,6 +146,7 @@
|
||||
"You wonder what the creator's mouth was shaped like")]."
|
||||
if(4)
|
||||
name = "statuette"
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
item_type = "statuette"
|
||||
icon_state = "statuette"
|
||||
additional_desc = "It depicts a [pick("small","ferocious","wild","pleasing","hulking")] \
|
||||
@@ -154,6 +155,8 @@
|
||||
if(prob(25))
|
||||
new_item = new /obj/item/weapon/vampiric(src.loc)
|
||||
if(5)
|
||||
name = "instrument"
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
item_type = "instrument"
|
||||
icon_state = "instrument"
|
||||
if(prob(30))
|
||||
@@ -256,17 +259,17 @@
|
||||
if(16)
|
||||
apply_prefix = 0
|
||||
if(prob(25))
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
item_type = "smooth green crystal"
|
||||
icon_state = "Green lump"
|
||||
else if(prob(33))
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
item_type = "irregular purple crystal"
|
||||
icon_state = "Phazon"
|
||||
else if(prob(50))
|
||||
else
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
item_type = "rough red crystal"
|
||||
icon_state = "changerock"
|
||||
else
|
||||
item_type = "smooth red crystal"
|
||||
icon_state = "ore"
|
||||
additional_desc = pick("It shines faintly as it catches the light.","It appears to have a faint inner glow.","It seems to draw you inward as you look it at.","Something twinkles faintly as you look at it.","It's mesmerizing to behold.")
|
||||
|
||||
apply_material_decorations = 0
|
||||
@@ -285,8 +288,8 @@
|
||||
if(18)
|
||||
new_item = new /obj/item/device/radio/beacon(src.loc)
|
||||
talkative = 0
|
||||
new_item.icon_state = "unknown[rand(1,4)]"
|
||||
new_item.icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
new_item.icon_state = "unknown[rand(1,4)]"
|
||||
new_item.desc = ""
|
||||
if(19)
|
||||
apply_prefix = 0
|
||||
@@ -339,10 +342,10 @@
|
||||
if(26)
|
||||
//energy gun
|
||||
var/spawn_type = pick(\
|
||||
/obj/item/weapon/gun/energy/laser/practice,\
|
||||
/obj/item/weapon/gun/energy/laser,\
|
||||
/obj/item/weapon/gun/energy/xray,\
|
||||
/obj/item/weapon/gun/energy/laser/captain)
|
||||
/obj/item/weapon/gun/energy/laser/practice/xenoarch,\
|
||||
/obj/item/weapon/gun/energy/laser/xenoarch,\
|
||||
/obj/item/weapon/gun/energy/xray/xenoarch,\
|
||||
/obj/item/weapon/gun/energy/laser/captain/xenoarch)
|
||||
if(spawn_type)
|
||||
var/obj/item/weapon/gun/energy/new_gun = new spawn_type(src.loc)
|
||||
new_item = new_gun
|
||||
@@ -451,7 +454,7 @@
|
||||
//robot remains
|
||||
apply_prefix = 0
|
||||
item_type = "[pick("mechanical","robotic","cyborg")] [pick("remains","chassis","debris")]"
|
||||
icon = 'icons/effects/blood.dmi'
|
||||
icon = 'icons/mob/robots.dmi'
|
||||
icon_state = "remainsrobot"
|
||||
additional_desc = pick("Almost mistakeable for the remains of a modern cyborg.",\
|
||||
"They are barely recognisable as anything other than a pile of waste metals.",\
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
//snowflake guns for xenoarch because you can't override the update_icon() proc inside the giant mess that is find creation
|
||||
/obj/item/weapon/gun/energy/laser/xenoarch
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
update_icon()
|
||||
return
|
||||
|
||||
/obj/item/weapon/gun/energy/laser/practice/xenoarch
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
update_icon()
|
||||
return
|
||||
|
||||
/obj/item/weapon/gun/energy/laser/practice/xenoarch
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
update_icon()
|
||||
return
|
||||
|
||||
/obj/item/weapon/gun/energy/xray/xenoarch
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
update_icon()
|
||||
return
|
||||
|
||||
/obj/item/weapon/gun/energy/laser/captain/xenoarch
|
||||
icon = 'icons/obj/xenoarchaeology.dmi'
|
||||
update_icon()
|
||||
return
|
||||
@@ -73,7 +73,8 @@
|
||||
//update the sample bag
|
||||
filled_bag.icon_state = "evidence"
|
||||
var/image/I = image("icon"=R, "layer"=FLOAT_LAYER)
|
||||
filled_bag.underlays += I
|
||||
filled_bag.overlays += I
|
||||
filled_bag.overlays += "evidence"
|
||||
filled_bag.w_class = 1
|
||||
|
||||
user << "\blue You take a core sample of the [item_to_sample]."
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
var/strengthen_rate = 0.2
|
||||
var/max_strengthen_rate = 0.5 //the maximum rate that the generator can increase the average field strength
|
||||
var/dissipation_rate = 0.030 //the percentage of the shield strength that needs to be replaced each second
|
||||
var/min_dissipation = 0.1 //will dissipate by at least this rate in renwicks per field tile (otherwise field would never dissipate completely as dissipation is a percentage)
|
||||
var/min_dissipation = 0.01 //will dissipate by at least this rate in renwicks per field tile (otherwise field would never dissipate completely as dissipation is a percentage)
|
||||
var/powered = 0
|
||||
var/check_powered = 1
|
||||
var/obj/machinery/shield_capacitor/owned_capacitor
|
||||
|
||||
@@ -185,7 +185,7 @@ var/MAX_EXPLOSION_RANGE = 14
|
||||
#define SLOT_POCKET 2048 //this is to allow items with a w_class of 3 or 4 to fit in pockets.
|
||||
#define SLOT_DENYPOCKET 4096 //this is to deny items with a w_class of 2 or 1 to fit in pockets.
|
||||
#define SLOT_TWOEARS 8192
|
||||
#define SLOT_LEGS = 16384
|
||||
#define SLOT_TIE 16384
|
||||
|
||||
//FLAGS BITMASK
|
||||
#define STOPSPRESSUREDMAGE 1 //This flag is used on the flags variable for SUIT and HEAD items which stop pressure damage. Note that the flag 1 was previous used as ONBACK, so it is possible for some code to use (flags & 1) when checking if something can be put on your back. Replace this code with (inv_flags & SLOT_BACK) if you see it anywhere
|
||||
@@ -264,6 +264,7 @@ var/MAX_EXPLOSION_RANGE = 14
|
||||
#define slot_legcuffed 19
|
||||
#define slot_r_ear 20
|
||||
#define slot_legs 21
|
||||
#define slot_tie 22
|
||||
|
||||
//Cant seem to find a mob bitflags area other than the powers one
|
||||
|
||||
|
||||
|
Before Width: | Height: | Size: 150 KiB After Width: | Height: | Size: 151 KiB |
|
Before Width: | Height: | Size: 152 KiB After Width: | Height: | Size: 152 KiB |
|
Before Width: | Height: | Size: 262 KiB After Width: | Height: | Size: 262 KiB |
|
Before Width: | Height: | Size: 57 KiB After Width: | Height: | Size: 58 KiB |
|
Before Width: | Height: | Size: 92 KiB After Width: | Height: | Size: 92 KiB |
|
Before Width: | Height: | Size: 72 KiB After Width: | Height: | Size: 72 KiB |
|
Before Width: | Height: | Size: 58 KiB After Width: | Height: | Size: 58 KiB |
@@ -0,0 +1,120 @@
|
||||
"aa" = (/turf/space,/area/space)
|
||||
"ab" = (/turf/simulated/wall/r_wall,/area/space)
|
||||
"ac" = (/obj/machinery/power/solar{id = "portsolar"; name = "Port Solar Array"},/obj/structure/cable/yellow{d2 = 4; icon_state = "0-4"},/turf/simulated/floor/airless{icon_state = "solarpanel"},/area/solar/port)
|
||||
"ad" = (/obj/structure/cable/yellow{d1 = 2; d2 = 4; icon_state = "2-4"},/obj/structure/cable/yellow{d1 = 2; d2 = 8; icon_state = "2-8"},/turf/simulated/floor/plating,/area/solar/port)
|
||||
"ae" = (/obj/machinery/power/solar{id = "portsolar"; name = "Port Solar Array"},/obj/structure/cable/yellow{d2 = 8; icon_state = "0-8"},/turf/simulated/floor/airless{icon_state = "solarpanel"},/area/solar/port)
|
||||
"af" = (/obj/structure/cable/yellow{d1 = 1; d2 = 2; icon_state = "1-2"},/obj/structure/cable/yellow{d1 = 2; d2 = 4; icon_state = "2-4"},/obj/structure/cable/yellow{d1 = 2; d2 = 8; icon_state = "2-8"},/turf/simulated/floor/plating,/area/solar/port)
|
||||
"ag" = (/obj/structure/grille,/obj/structure/window/reinforced{dir = 1},/obj/structure/window/reinforced{dir = 4},/obj/structure/window/reinforced{dir = 8},/turf/simulated/floor/plating/airless,/area/maintenance/portsolar)
|
||||
"ah" = (/turf/simulated/wall/r_wall,/area/maintenance/portsolar)
|
||||
"ai" = (/turf/simulated/wall/r_wall,/area/engine/workshop)
|
||||
"aj" = (/turf/simulated/floor/plating,/area/solar/port)
|
||||
"ak" = (/obj/structure/cable/yellow,/turf/simulated/floor/plating,/area/solar/port)
|
||||
"al" = (/obj/structure/grille,/obj/structure/window/reinforced{dir = 1},/obj/structure/window/reinforced,/obj/structure/window/reinforced{dir = 8},/turf/simulated/floor/plating/airless,/area/maintenance/portsolar)
|
||||
"am" = (/obj/structure/grille,/obj/structure/window/reinforced{dir = 1},/obj/structure/window/reinforced,/turf/simulated/floor/plating/airless,/area/maintenance/portsolar)
|
||||
"an" = (/obj/structure/grille,/obj/structure/window/reinforced,/obj/structure/window/reinforced{dir = 4},/turf/simulated/floor/plating/airless,/area/maintenance/portsolar)
|
||||
"ao" = (/obj/structure/sign/securearea{desc = "A warning sign which reads 'EXTERNAL AIRLOCK'"; icon_state = "space"; layer = 4; name = "EXTERNAL AIRLOCK"; pixel_x = -32; pixel_y = 0},/obj/machinery/atmospherics/portables_connector,/obj/machinery/portable_atmospherics/canister/air{filled = 0.05},/turf/simulated/floor/plating{dir = 1; icon_state = "warnplatecorner"},/area/maintenance/portsolar)
|
||||
"ap" = (/obj/machinery/power/terminal{dir = 4},/obj/machinery/light/small{dir = 1},/obj/structure/cable/yellow{d2 = 2; icon_state = "0-2"},/turf/simulated/floor/plating,/area/maintenance/portsolar)
|
||||
"aq" = (/obj/structure/cable{d2 = 2; icon_state = "0-2"; pixel_y = 0},/obj/machinery/power/smes/buildable{charge = 0},/turf/simulated/floor/plating,/area/maintenance/portsolar)
|
||||
"ar" = (/obj/structure/sign/securearea{desc = "A warning sign which reads 'HIGH VOLTAGE'"; icon_state = "shock"; name = "HIGH VOLTAGE"; pixel_y = 0},/turf/simulated/wall/r_wall,/area/maintenance/portsolar)
|
||||
"as" = (/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"at" = (/obj/machinery/power/terminal{dir = 4},/obj/structure/cable{d2 = 2; icon_state = "0-2"; pixel_y = 0},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"au" = (/obj/machinery/power/smes/buildable{charge = 0},/obj/structure/cable/green{d2 = 2; icon_state = "0-2"},/obj/structure/cable/green{d2 = 4; icon_state = "0-4"},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"av" = (/obj/structure/cable/green{d1 = 4; d2 = 8; icon_state = "4-8"},/obj/machinery/light{dir = 1},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"aw" = (/obj/structure/cable/green{d1 = 4; d2 = 8; icon_state = "4-8"},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"ax" = (/obj/structure/cable/green{d1 = 2; d2 = 8; icon_state = "2-8"},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"ay" = (/obj/structure/dispenser{phorontanks = 0},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"az" = (/obj/machinery/power/tracker,/obj/structure/cable/yellow{d2 = 4; icon_state = "0-4"},/turf/simulated/floor/airless/catwalk{icon_state = "catwalk4"},/area/solar/port)
|
||||
"aA" = (/obj/structure/cable/yellow{d1 = 4; d2 = 8; icon_state = "4-8"},/turf/simulated/floor/plating,/area/solar/port)
|
||||
"aB" = (/obj/structure/cable/yellow{d2 = 8; icon_state = "0-8"},/turf/simulated/floor/plating,/area/solar/port)
|
||||
"aC" = (/obj/structure/cable/yellow{d2 = 4; icon_state = "0-4"},/turf/simulated/floor/plating,/area/solar/port)
|
||||
"aD" = (/obj/machinery/access_button{command = "cycle_exterior"; frequency = 1379; layer = 3.3; master_tag = "robotics_solar_airlock"; name = "exterior access button"; pixel_x = 25; pixel_y = 25; req_access_txt = "0"},/obj/structure/cable/yellow{d1 = 4; d2 = 8; icon_state = "4-8"},/turf/simulated/floor/plating,/area/solar/port)
|
||||
"aE" = (/obj/machinery/door/airlock/external{frequency = 1379; icon_state = "door_locked"; id_tag = "robotics_solar_outer"; locked = 1; name = "Engineering External Access"; req_access = null; req_access_txt = "10;13"},/obj/structure/cable/yellow{d1 = 4; d2 = 8; icon_state = "4-8"},/turf/simulated/floor/plating,/area/maintenance/portsolar)
|
||||
"aF" = (/obj/machinery/atmospherics/unary/vent_pump/high_volume{dir = 4; frequency = 1379; id_tag = "robotics_solar_pump"},/obj/machinery/embedded_controller/radio/airlock/airlock_controller{tag_airpump = "robotics_solar_pump"; tag_exterior_door = "robotics_solar_outer"; frequency = 1379; id_tag = "robotics_solar_airlock"; tag_interior_door = "robotics_solar_inner"; layer = 3.3; pixel_x = 0; pixel_y = -25; req_access_txt = "13"; tag_chamber_sensor = "robotics_solar_sensor"},/obj/machinery/airlock_sensor{frequency = 1379; id_tag = "robotics_solar_sensor"; layer = 3.3; pixel_x = 12; pixel_y = -25},/obj/structure/cable/yellow{d1 = 4; d2 = 8; icon_state = "4-8"},/obj/effect/decal/warning_stripes,/turf/simulated/floor/plating,/area/maintenance/portsolar)
|
||||
"aG" = (/obj/machinery/door/airlock/external{frequency = 1379; icon_state = "door_locked"; id_tag = "robotics_solar_inner"; locked = 1; name = "Engineering External Access"; req_access = null; req_access_txt = "13"},/obj/machinery/atmospherics/pipe/simple/visible{dir = 4},/obj/structure/cable/yellow{d1 = 4; d2 = 8; icon_state = "4-8"},/turf/simulated/floor/plating,/area/maintenance/portsolar)
|
||||
"aH" = (/obj/machinery/access_button{command = "cycle_interior"; frequency = 1379; layer = 3.3; master_tag = "robotics_solar_airlock"; name = "interior access button"; pixel_x = -25; pixel_y = -25; req_access_txt = "0"},/obj/machinery/atmospherics/pipe/simple/visible{tag = "icon-intact (NORTHWEST)"; icon_state = "intact"; dir = 9},/obj/structure/cable/yellow{d1 = 4; d2 = 8; icon_state = "4-8"},/obj/structure/cable/yellow{d1 = 2; d2 = 8; icon_state = "2-8"},/turf/simulated/floor/plating{icon_state = "warnplate"; dir = 8},/area/maintenance/portsolar)
|
||||
"aI" = (/obj/structure/cable/yellow{d1 = 1; d2 = 8; icon_state = "1-8"},/turf/simulated/floor/plating,/area/maintenance/portsolar)
|
||||
"aJ" = (/obj/structure/cable{d1 = 1; d2 = 4; icon_state = "1-4"},/obj/structure/cable{d1 = 2; d2 = 4; icon_state = "2-4"},/turf/simulated/floor/plating,/area/maintenance/portsolar)
|
||||
"aK" = (/obj/structure/cable{d1 = 4; d2 = 8; icon_state = "4-8"; pixel_x = 0},/turf/simulated/floor/plating,/area/maintenance/portsolar)
|
||||
"aL" = (/obj/structure/cable{d1 = 4; d2 = 8; icon_state = "4-8"; pixel_x = 0},/obj/structure/cable{d1 = 2; d2 = 4; icon_state = "2-4"},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"aM" = (/obj/structure/cable{d1 = 4; d2 = 8; icon_state = "4-8"; pixel_x = 0},/obj/structure/cable{d1 = 1; d2 = 8; icon_state = "1-8"},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"aN" = (/obj/machinery/power/breakerbox/activated,/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"aO" = (/obj/item/stack/cable_coil,/obj/item/stack/cable_coil,/obj/item/stack/cable_coil,/obj/item/stack/cable_coil,/obj/item/stack/cable_coil,/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"aP" = (/obj/effect/landmark/start{name = "AI"},/obj/effect/landmark/start{name = "Assistant"},/obj/effect/landmark/start{name = "Atmospheric Technician"},/obj/effect/landmark/start{name = "Bartender"},/obj/effect/landmark/start{name = "Captain"},/obj/effect/landmark/start{name = "Cargo Technician"},/obj/effect/landmark/start{name = "Chaplain"},/obj/effect/landmark/start{name = "Chef"},/obj/effect/landmark/start{name = "Chemist"},/obj/effect/landmark/start{name = "Chief Engineer"},/obj/effect/landmark/start{name = "Chief Medical Officer"},/obj/effect/landmark/start{name = "Cyborg"},/obj/effect/landmark/start{name = "Detective"},/obj/effect/landmark/start{name = "Gardener"},/obj/effect/landmark/start{name = "Geneticist"},/obj/effect/landmark/start{name = "Head of Personnel"},/obj/effect/landmark/start{name = "Head of Security"},/obj/effect/landmark/start{name = "Internal Affairs Agent"},/obj/effect/landmark/start{name = "Janitor"},/obj/effect/landmark/start{name = "Librarian"},/obj/effect/landmark/start{name = "Medical Doctor"},/obj/effect/landmark/start{name = "Psychiatrist"},/obj/effect/landmark/start{name = "Quartermaster"},/obj/effect/landmark/start{name = "Research Director"},/obj/effect/landmark/start{name = "Roboticist"},/obj/effect/landmark/start{name = "Scientist"},/obj/effect/landmark/start{name = "Security Officer"},/obj/effect/landmark/start{name = "Shaft Miner"},/obj/effect/landmark/start{name = "Station Engineer"},/obj/effect/landmark/start{name = "Warden"},/obj/effect/landmark/start{name = "Xenobiologist"},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"aQ" = (/obj/structure/cable/green{d1 = 1; d2 = 2; icon_state = "1-2"},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"aR" = (/obj/machinery/portable_atmospherics/canister/oxygen,/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"aS" = (/obj/structure/cable/yellow{d2 = 2; icon_state = "0-2"},/turf/simulated/floor/plating,/area/solar/port)
|
||||
"aT" = (/obj/structure/grille,/obj/structure/window/reinforced{dir = 1},/obj/structure/window/reinforced{dir = 4},/turf/simulated/floor/plating/airless,/area/maintenance/portsolar)
|
||||
"aU" = (/obj/machinery/power/solar_control{id = "portsolar"; name = "Aft Port Solar Control"; track = 0},/obj/structure/cable/yellow,/turf/simulated/floor/plating{dir = 4; icon_state = "warnplatecorner"},/area/maintenance/portsolar)
|
||||
"aV" = (/turf/simulated/floor/plating,/area/maintenance/portsolar)
|
||||
"aW" = (/obj/machinery/camera{c_tag = "Aft Port Solar Control"; dir = 1},/obj/machinery/alarm{dir = 1; pixel_y = -22},/obj/machinery/power/apc{dir = 4; name = "east bump"; pixel_x = 24},/obj/structure/cable,/turf/simulated/floor/plating,/area/maintenance/portsolar)
|
||||
"aX" = (/obj/structure/cable{d1 = 1; d2 = 2; icon_state = "1-2"},/obj/machinery/light{dir = 8},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"aY" = (/obj/machinery/atmospherics/unary/vent_pump/on{dir = 4},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"aZ" = (/obj/machinery/atmospherics/pipe/simple/hidden{tag = "icon-intact (EAST)"; icon_state = "intact"; dir = 4},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"ba" = (/obj/machinery/atmospherics/unary/vent_scrubber/on{dir = 8},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"bb" = (/obj/machinery/light{icon_state = "tube1"; dir = 4},/obj/item/clothing/shoes/magboots,/obj/item/clothing/suit/space/rig/engineering,/obj/item/clothing/mask/breath,/obj/item/clothing/head/helmet/space/rig/engineering,/obj/item/clothing/gloves/yellow,/obj/item/device/multitool,/obj/item/weapon/wirecutters,/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"bc" = (/obj/structure/cable/yellow{d1 = 1; d2 = 2; icon_state = "1-2"},/obj/structure/cable/yellow{d1 = 1; d2 = 8; icon_state = "1-8"},/obj/structure/cable/yellow{d1 = 1; d2 = 4; icon_state = "1-4"},/turf/simulated/floor/plating,/area/solar/port)
|
||||
"bd" = (/obj/structure/grille,/obj/structure/window/reinforced,/obj/structure/window/reinforced{dir = 4},/obj/structure/window/reinforced{dir = 8},/turf/simulated/floor/plating/airless,/area/maintenance/portsolar)
|
||||
"be" = (/obj/structure/cable{d1 = 1; d2 = 2; icon_state = "1-2"},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"bf" = (/obj/structure/cable/green{d1 = 2; d2 = 4; icon_state = "2-4"},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"bg" = (/obj/structure/cable/green{d2 = 8; icon_state = "0-8"},/obj/structure/cable/green{d2 = 4; icon_state = "0-4"},/obj/machinery/power/apc{dir = 2; name = "south bump"; pixel_y = -24},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"bh" = (/obj/structure/cable/green{d1 = 4; d2 = 8; icon_state = "4-8"},/obj/machinery/alarm{dir = 1; pixel_y = -22},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"bi" = (/obj/structure/cable/green{d1 = 1; d2 = 2; icon_state = "1-2"},/obj/structure/cable/green{d1 = 1; d2 = 8; icon_state = "1-8"},/turf/simulated/floor/plating,/area/engine/workshop)
|
||||
"bj" = (/obj/machinery/computer/station_alert,/turf/simulated/floor/plating,/area/engine/engine_monitoring)
|
||||
"bk" = (/turf/simulated/wall/r_wall,/area/engine/engine_smes)
|
||||
"bl" = (/obj/structure/cable{d1 = 1; d2 = 2; icon_state = "1-2"},/turf/simulated/floor/plating,/area/engine/engine_smes)
|
||||
"bm" = (/obj/machinery/light{icon_state = "tube1"; dir = 4},/obj/structure/cable/green{d1 = 1; d2 = 2; icon_state = "1-2"},/turf/simulated/floor/plating,/area/engine/engine_smes)
|
||||
"bn" = (/turf/simulated/wall/r_wall,/area/engine/engine_monitoring)
|
||||
"bo" = (/obj/structure/cable/green{d1 = 1; d2 = 2; icon_state = "1-2"},/turf/simulated/floor/plating,/area/engine/engine_monitoring)
|
||||
"bp" = (/obj/structure/cable/green{d1 = 1; d2 = 4; icon_state = "1-4"},/turf/simulated/floor/plating,/area/engine/engine_smes)
|
||||
"bq" = (/obj/machinery/light_switch{pixel_x = 0; pixel_y = 27},/obj/machinery/power/apc{dir = 4; name = "east bump"; pixel_x = 24},/obj/structure/cable/green{d2 = 8; icon_state = "0-8"},/turf/simulated/floor/plating,/area/engine/engine_smes)
|
||||
"br" = (/obj/machinery/power/apc{dir = 8; name = "west bump"; pixel_x = -24},/obj/structure/cable/green{d2 = 4; icon_state = "0-4"},/turf/simulated/floor/plating,/area/engine/engine_monitoring)
|
||||
"bs" = (/obj/structure/cable/green{d1 = 1; d2 = 8; icon_state = "1-8"},/obj/structure/cable/green{d1 = 1; d2 = 2; icon_state = "1-2"},/turf/simulated/floor/plating,/area/engine/engine_monitoring)
|
||||
"bt" = (/obj/machinery/alarm{dir = 8; icon_state = "alarm0"; pixel_x = 24},/turf/simulated/floor/plating,/area/engine/engine_monitoring)
|
||||
"bu" = (/turf/simulated/floor/plating,/area/engine/engine_smes)
|
||||
"bv" = (/obj/structure/cable/yellow{d1 = 2; d2 = 4; icon_state = "2-4"},/turf/simulated/floor/plating,/area/engine/engine_smes)
|
||||
"bw" = (/obj/structure/cable/yellow{d1 = 4; d2 = 8; icon_state = "4-8"},/turf/simulated/floor/plating,/area/engine/engine_smes)
|
||||
"bx" = (/obj/structure/cable/yellow{d1 = 4; d2 = 8; icon_state = "4-8"},/turf/simulated/floor/plating,/area/engine/engine_monitoring)
|
||||
"by" = (/obj/structure/cable/yellow{d1 = 4; d2 = 8; icon_state = "4-8"},/obj/structure/cable/green{d1 = 1; d2 = 2; icon_state = "1-2"},/turf/simulated/floor/plating,/area/engine/engine_monitoring)
|
||||
"bz" = (/obj/machinery/power/monitor{name = "Engine Power Monitoring"},/obj/structure/cable/yellow{d2 = 8; icon_state = "0-8"},/turf/simulated/floor/plating,/area/engine/engine_monitoring)
|
||||
"bA" = (/obj/structure/cable/yellow{d1 = 1; d2 = 8; icon_state = "1-8"},/obj/structure/cable/yellow{d1 = 1; d2 = 4; icon_state = "1-4"},/turf/simulated/floor/plating,/area/solar/port)
|
||||
"bB" = (/obj/machinery/power/smes/buildable{charge = 1e+007; input_level = 500000; input_attempt = 1; cur_coils = 4; output_level = 500000},/obj/structure/cable,/turf/simulated/floor{icon_state = "vault"; dir = 8},/area/engine/engine_smes)
|
||||
"bC" = (/obj/machinery/power/terminal{dir = 8},/obj/structure/cable/yellow{d2 = 4; icon_state = "0-4"},/turf/simulated/floor/plating,/area/engine/engine_smes)
|
||||
"bD" = (/obj/machinery/alarm{dir = 8; icon_state = "alarm0"; pixel_x = 24},/obj/structure/cable/yellow{d1 = 2; d2 = 8; icon_state = "2-8"},/obj/structure/cable/yellow{d1 = 1; d2 = 2; icon_state = "1-2"},/obj/machinery/light{icon_state = "tube1"; dir = 4},/turf/simulated/floor/plating,/area/engine/engine_smes)
|
||||
"bE" = (/obj/machinery/light,/turf/simulated/floor/plating,/area/engine/engine_monitoring)
|
||||
"bF" = (/obj/structure/cable/green{d1 = 1; d2 = 4; icon_state = "1-4"},/turf/simulated/floor/plating,/area/engine/engine_monitoring)
|
||||
"bG" = (/obj/machinery/light,/obj/machinery/power/monitor{name = "Engine Power Monitoring"},/obj/structure/cable/green{d2 = 8; icon_state = "0-8"},/turf/simulated/floor/plating,/area/engine/engine_monitoring)
|
||||
"bH" = (/obj/structure/cable/yellow{d1 = 1; d2 = 2; icon_state = "1-2"},/turf/simulated/floor/plating,/area/engine/engine_smes)
|
||||
"bI" = (/turf/simulated/floor/plating,/area/engine/engine_monitoring)
|
||||
"bJ" = (/turf/simulated/wall/r_wall,/area/engine/engine_room)
|
||||
"bK" = (/obj/item/stack/sheet/mineral/phoron{amount = 1000},/turf/simulated/floor/plating,/area/engine/engine_room)
|
||||
"bL" = (/obj/structure/cable/yellow{d1 = 1; d2 = 2; icon_state = "1-2"},/obj/structure/cable/yellow{d1 = 2; d2 = 4; icon_state = "2-4"},/turf/simulated/floor/plating,/area/engine/engine_room)
|
||||
"bM" = (/obj/machinery/power/terminal{dir = 4},/obj/structure/cable/yellow{d2 = 8; icon_state = "0-8"},/turf/simulated/floor/plating{icon_state = "warnplate"; dir = 1},/area/engine/engine_room)
|
||||
"bN" = (/obj/structure/cable/yellow{d2 = 4; icon_state = "0-4"},/obj/machinery/power/smes/buildable{charge = 2e+006},/turf/simulated/floor/plating{icon_state = "warnplate"; dir = 1},/area/engine/engine_room)
|
||||
"bO" = (/obj/structure/cable/cyan{d1 = 4; d2 = 8; icon_state = "4-8"},/turf/simulated/floor/plating{icon_state = "warnplate"; dir = 8},/area/engine/engine_room)
|
||||
"bP" = (/obj/machinery/power/apc/super{dir = 1; name = "north bump"; pixel_y = 24},/obj/structure/cable/cyan{d2 = 8; icon_state = "0-8"},/turf/simulated/floor/plating,/area/engine/engine_room)
|
||||
"bQ" = (/obj/machinery/light,/turf/simulated/floor/plating,/area/engine/engine_room)
|
||||
"bR" = (/obj/structure/cable/yellow,/obj/machinery/power/port_gen/pacman{anchored = 1},/turf/simulated/floor/plating,/area/engine/engine_room)
|
||||
"bS" = (/turf/simulated/floor/plating,/area/engine/engine_room)
|
||||
"bT" = (/obj/machinery/alarm{dir = 1; pixel_y = -22},/turf/simulated/floor/plating,/area/engine/engine_room)
|
||||
"bU" = (/obj/machinery/light{icon_state = "tube1"; dir = 4},/turf/simulated/floor/plating,/area/engine/engine_room)
|
||||
|
||||
(1,1,1) = {"
|
||||
aaaaaaaaabaaaaaaabaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
||||
aaaaaaacadaeaaacadaeaaacadaeaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
||||
aaaaaaacafaeaaacafaeaaacafaeaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
||||
aaaaaaacafaeaaacafaeaaacafaeaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
||||
aaaaaaacafaeaaacafaeaaacafaeaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
||||
abababacafaeabacafaeabacafaeabababababaaaaagahahahahaiaiaiaiaiaiaiai
|
||||
abajajajakajajajakajajajakajajajajajajalamanaoapaqarasatauavawaxayai
|
||||
azaAaAaBaCaAaAaBaCaAaAaBaCaAaAaAaAaAaDaEaFaGaHaIaJaKaLaMaNaOaPaQaRai
|
||||
abajajajaSajajajaSajajajaSajajajajajajalamaTaUaVaWahaXaYaZbaasaQbbai
|
||||
abababacbcaeabacbcaeabacbcaeabababababaaaabdahahahahbebfawbgbhbibjai
|
||||
aaaaaaacbcaeaaacbcaeaaacbcaeaaaaaaaaaaaaaaaaaaaaaabkblbmbkbkbnbobnbn
|
||||
aaaaaaacbcaeaaacbcaeaaacbcaeaaaaaaaaaaaaaaaaaaaaaabkblbpbqbkbrbsbtbn
|
||||
aaaaaaacbcaeaaacbcaeaaacbcaeaaaaaaaaaaaaaaaaaaaaaabkblbubvbwbxbybzbn
|
||||
aaaaaaacbAaeaaacbAaeaaacbAaeaaaaaaaaaaaaaaaaaaaaaabkbBbCbDbkbEbFbGbn
|
||||
aaaaaaaaabaaaaaaabaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaabkbkbubHbkbnbIbnbn
|
||||
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabJbKbLbMbNbObPbJ
|
||||
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabJbQbRbSbSbTbUbJ
|
||||
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabJbJbJbJbJbJbJbJ
|
||||
"}
|
||||