mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-13 11:43:31 +00:00
-Cleaned up computers. Fixes Issue 1195
-Made computers use idle_power_usage and active_power_usage that it used from the MC. I'm sure something is likely to break because I removed a lot of snowflake code. I tried to test all the computers with what I can but if you find something odd then please tell me. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@5369 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -87,6 +87,8 @@ obj/machinery/computer/general_air_control
|
|||||||
var/datum/radio_frequency/radio_connection
|
var/datum/radio_frequency/radio_connection
|
||||||
|
|
||||||
attack_hand(mob/user)
|
attack_hand(mob/user)
|
||||||
|
if(..(user))
|
||||||
|
return
|
||||||
user << browse(return_text(),"window=computer")
|
user << browse(return_text(),"window=computer")
|
||||||
user.set_machine(src)
|
user.set_machine(src)
|
||||||
onclose(user, "computer")
|
onclose(user, "computer")
|
||||||
@@ -95,39 +97,6 @@ obj/machinery/computer/general_air_control
|
|||||||
..()
|
..()
|
||||||
src.updateDialog()
|
src.updateDialog()
|
||||||
|
|
||||||
attackby(I as obj, user as mob)
|
|
||||||
if(istype(I, /obj/item/weapon/screwdriver))
|
|
||||||
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
|
|
||||||
if(do_after(user, 20))
|
|
||||||
if (src.stat & BROKEN)
|
|
||||||
user << "\blue The broken glass falls out."
|
|
||||||
var/obj/structure/computerframe/A = new /obj/structure/computerframe( src.loc )
|
|
||||||
new /obj/item/weapon/shard( src.loc )
|
|
||||||
var/obj/item/weapon/circuitboard/air_management/M = new /obj/item/weapon/circuitboard/air_management( A )
|
|
||||||
for (var/obj/C in src)
|
|
||||||
C.loc = src.loc
|
|
||||||
M.frequency = src.frequency
|
|
||||||
A.circuit = M
|
|
||||||
A.state = 3
|
|
||||||
A.icon_state = "3"
|
|
||||||
A.anchored = 1
|
|
||||||
del(src)
|
|
||||||
else
|
|
||||||
user << "\blue You disconnect the monitor."
|
|
||||||
var/obj/structure/computerframe/A = new /obj/structure/computerframe( src.loc )
|
|
||||||
var/obj/item/weapon/circuitboard/air_management/M = new /obj/item/weapon/circuitboard/air_management( A )
|
|
||||||
for (var/obj/C in src)
|
|
||||||
C.loc = src.loc
|
|
||||||
M.frequency = src.frequency
|
|
||||||
A.circuit = M
|
|
||||||
A.state = 4
|
|
||||||
A.icon_state = "4"
|
|
||||||
A.anchored = 1
|
|
||||||
del(src)
|
|
||||||
else
|
|
||||||
src.attack_hand(user)
|
|
||||||
return
|
|
||||||
|
|
||||||
receive_signal(datum/signal/signal)
|
receive_signal(datum/signal/signal)
|
||||||
if(!signal || signal.encryption) return
|
if(!signal || signal.encryption) return
|
||||||
|
|
||||||
@@ -294,38 +263,6 @@ Max Output Pressure: [output_pressure] kPa<BR>"}
|
|||||||
var/cutoff_temperature = 2000
|
var/cutoff_temperature = 2000
|
||||||
var/on_temperature = 1200
|
var/on_temperature = 1200
|
||||||
|
|
||||||
attackby(I as obj, user as mob)
|
|
||||||
if(istype(I, /obj/item/weapon/screwdriver))
|
|
||||||
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
|
|
||||||
if(do_after(user, 20))
|
|
||||||
if (src.stat & BROKEN)
|
|
||||||
user << "\blue The broken glass falls out."
|
|
||||||
var/obj/structure/computerframe/A = new /obj/structure/computerframe( src.loc )
|
|
||||||
new /obj/item/weapon/shard( src.loc )
|
|
||||||
var/obj/item/weapon/circuitboard/injector_control/M = new /obj/item/weapon/circuitboard/injector_control( A )
|
|
||||||
for (var/obj/C in src)
|
|
||||||
C.loc = src.loc
|
|
||||||
M.frequency = src.frequency
|
|
||||||
A.circuit = M
|
|
||||||
A.state = 3
|
|
||||||
A.icon_state = "3"
|
|
||||||
A.anchored = 1
|
|
||||||
del(src)
|
|
||||||
else
|
|
||||||
user << "\blue You disconnect the monitor."
|
|
||||||
var/obj/structure/computerframe/A = new /obj/structure/computerframe( src.loc )
|
|
||||||
var/obj/item/weapon/circuitboard/injector_control/M = new /obj/item/weapon/circuitboard/injector_control( A )
|
|
||||||
for (var/obj/C in src)
|
|
||||||
C.loc = src.loc
|
|
||||||
M.frequency = src.frequency
|
|
||||||
A.circuit = M
|
|
||||||
A.state = 4
|
|
||||||
A.icon_state = "4"
|
|
||||||
A.anchored = 1
|
|
||||||
del(src)
|
|
||||||
else
|
|
||||||
src.attack_hand(user)
|
|
||||||
return
|
|
||||||
|
|
||||||
process()
|
process()
|
||||||
if(automation)
|
if(automation)
|
||||||
|
|||||||
@@ -25,6 +25,8 @@
|
|||||||
return
|
return
|
||||||
|
|
||||||
attack_hand(var/mob/user as mob)
|
attack_hand(var/mob/user as mob)
|
||||||
|
if(..(user))
|
||||||
|
return
|
||||||
src.add_fingerprint(usr)
|
src.add_fingerprint(usr)
|
||||||
var/dat = {"
|
var/dat = {"
|
||||||
<html>
|
<html>
|
||||||
|
|||||||
@@ -198,6 +198,8 @@
|
|||||||
|
|
||||||
/obj/machinery/computer/HolodeckControl/process()
|
/obj/machinery/computer/HolodeckControl/process()
|
||||||
|
|
||||||
|
if(!..())
|
||||||
|
return
|
||||||
if(active)
|
if(active)
|
||||||
|
|
||||||
if(!checkInteg(linkedholodeck))
|
if(!checkInteg(linkedholodeck))
|
||||||
|
|||||||
@@ -76,7 +76,5 @@
|
|||||||
|
|
||||||
|
|
||||||
/obj/machinery/computer/operating/process()
|
/obj/machinery/computer/operating/process()
|
||||||
if(!(stat & (NOPOWER|BROKEN)) )
|
if(..())
|
||||||
use_power(500)
|
|
||||||
|
|
||||||
src.updateDialog()
|
src.updateDialog()
|
||||||
|
|||||||
@@ -108,9 +108,7 @@
|
|||||||
return
|
return
|
||||||
|
|
||||||
/obj/machinery/computer/aifixer/process()
|
/obj/machinery/computer/aifixer/process()
|
||||||
if(stat & (NOPOWER|BROKEN))
|
if(..())
|
||||||
return
|
|
||||||
|
|
||||||
src.updateDialog()
|
src.updateDialog()
|
||||||
return
|
return
|
||||||
|
|
||||||
@@ -144,3 +142,19 @@
|
|||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
|
/obj/machinery/computer/aifixer/update_icon()
|
||||||
|
..()
|
||||||
|
// Broken / Unpowered
|
||||||
|
if((stat & BROKEN) || (stat & NOPOWER))
|
||||||
|
overlays = null
|
||||||
|
|
||||||
|
// Working / Powered
|
||||||
|
else
|
||||||
|
if (occupant)
|
||||||
|
switch (occupant.stat)
|
||||||
|
if (0)
|
||||||
|
overlays += image('icons/obj/computer.dmi', "ai-fixer-full")
|
||||||
|
if (2)
|
||||||
|
overlays += image('icons/obj/computer.dmi', "ai-fixer-404")
|
||||||
|
else
|
||||||
|
overlays += image('icons/obj/computer.dmi', "ai-fixer-empty")
|
||||||
|
|||||||
@@ -219,18 +219,6 @@
|
|||||||
src.blocked = 0
|
src.blocked = 0
|
||||||
return
|
return
|
||||||
|
|
||||||
/obj/machinery/computer/arcade/power_change()
|
|
||||||
|
|
||||||
if(stat & BROKEN)
|
|
||||||
icon_state = "arcadeb"
|
|
||||||
else
|
|
||||||
if( powered() )
|
|
||||||
icon_state = initial(icon_state)
|
|
||||||
stat &= ~NOPOWER
|
|
||||||
else
|
|
||||||
spawn(rand(0, 15))
|
|
||||||
src.icon_state = "arcade0"
|
|
||||||
stat |= NOPOWER
|
|
||||||
|
|
||||||
/obj/machinery/computer/arcade/attackby(I as obj, user as mob)
|
/obj/machinery/computer/arcade/attackby(I as obj, user as mob)
|
||||||
if(istype(I, /obj/item/weapon/card/emag) && !emagged)
|
if(istype(I, /obj/item/weapon/card/emag) && !emagged)
|
||||||
|
|||||||
@@ -12,10 +12,11 @@
|
|||||||
var/datum/radio_frequency/radio_connection
|
var/datum/radio_frequency/radio_connection
|
||||||
|
|
||||||
|
|
||||||
initialize()
|
/obj/machinery/computer/atmos_alert/initialize()
|
||||||
|
..()
|
||||||
set_frequency(receive_frequency)
|
set_frequency(receive_frequency)
|
||||||
|
|
||||||
receive_signal(datum/signal/signal)
|
/obj/machinery/computer/atmos_alert/receive_signal(datum/signal/signal)
|
||||||
if(!signal || signal.encryption) return
|
if(!signal || signal.encryption) return
|
||||||
|
|
||||||
var/zone = signal.data["zone"]
|
var/zone = signal.data["zone"]
|
||||||
@@ -33,22 +34,27 @@
|
|||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
proc/set_frequency(new_frequency)
|
/obj/machinery/computer/atmos_alert/proc/set_frequency(new_frequency)
|
||||||
radio_controller.remove_object(src, receive_frequency)
|
radio_controller.remove_object(src, receive_frequency)
|
||||||
receive_frequency = new_frequency
|
receive_frequency = new_frequency
|
||||||
radio_connection = radio_controller.add_object(src, receive_frequency, RADIO_ATMOSIA)
|
radio_connection = radio_controller.add_object(src, receive_frequency, RADIO_ATMOSIA)
|
||||||
|
|
||||||
|
|
||||||
attack_hand(mob/user)
|
/obj/machinery/computer/atmos_alert/attack_hand(mob/user)
|
||||||
|
if(..(user))
|
||||||
|
return
|
||||||
user << browse(return_text(),"window=computer")
|
user << browse(return_text(),"window=computer")
|
||||||
user.set_machine(src)
|
user.set_machine(src)
|
||||||
onclose(user, "computer")
|
onclose(user, "computer")
|
||||||
|
|
||||||
process()
|
/obj/machinery/computer/atmos_alert/process()
|
||||||
..()
|
if(..())
|
||||||
src.updateDialog()
|
src.updateDialog()
|
||||||
|
|
||||||
update_icon()
|
/obj/machinery/computer/atmos_alert/update_icon()
|
||||||
|
..()
|
||||||
|
if(stat & (NOPOWER|BROKEN))
|
||||||
|
return
|
||||||
if(priority_alarms.len)
|
if(priority_alarms.len)
|
||||||
icon_state = "alert:2"
|
icon_state = "alert:2"
|
||||||
|
|
||||||
@@ -60,7 +66,7 @@
|
|||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
proc/return_text()
|
/obj/machinery/computer/atmos_alert/proc/return_text()
|
||||||
var/priority_text
|
var/priority_text
|
||||||
var/minor_text
|
var/minor_text
|
||||||
|
|
||||||
@@ -88,7 +94,7 @@
|
|||||||
return output
|
return output
|
||||||
|
|
||||||
|
|
||||||
Topic(href, href_list)
|
/obj/machinery/computer/atmos_alert/Topic(href, href_list)
|
||||||
if(..())
|
if(..())
|
||||||
return
|
return
|
||||||
|
|
||||||
@@ -105,26 +111,3 @@
|
|||||||
minor_alarms -= zone
|
minor_alarms -= zone
|
||||||
update_icon()
|
update_icon()
|
||||||
return
|
return
|
||||||
|
|
||||||
attackby(I as obj, user as mob)
|
|
||||||
if(istype(I, /obj/item/weapon/screwdriver))
|
|
||||||
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/atmos_alert/M = new /obj/item/weapon/circuitboard/atmos_alert( A )
|
|
||||||
for (var/obj/C in src)
|
|
||||||
C.loc = src.loc
|
|
||||||
A.circuit = M
|
|
||||||
A.anchored = 1
|
|
||||||
|
|
||||||
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"
|
|
||||||
|
|
||||||
del(src)
|
|
||||||
|
|||||||
@@ -88,6 +88,12 @@
|
|||||||
density = 0
|
density = 0
|
||||||
circuit = null
|
circuit = null
|
||||||
|
|
||||||
|
/obj/machinery/computer/security/telescreen/update_icon()
|
||||||
|
icon_state = initial(icon_state)
|
||||||
|
if(stat & BROKEN)
|
||||||
|
icon_state += "b"
|
||||||
|
return
|
||||||
|
|
||||||
/obj/machinery/computer/security/telescreen/entertainment
|
/obj/machinery/computer/security/telescreen/entertainment
|
||||||
name = "entertainment monitor"
|
name = "entertainment monitor"
|
||||||
desc = "Damn, they better have /tg/thechannel on these things."
|
desc = "Damn, they better have /tg/thechannel on these things."
|
||||||
|
|||||||
@@ -454,15 +454,14 @@
|
|||||||
break
|
break
|
||||||
return selected_record
|
return selected_record
|
||||||
|
|
||||||
/obj/machinery/computer/cloning/power_change()
|
/obj/machinery/computer/cloning/update_icon()
|
||||||
|
|
||||||
if(stat & BROKEN)
|
if(stat & BROKEN)
|
||||||
icon_state = "commb"
|
icon_state = "commb"
|
||||||
else
|
else
|
||||||
if( powered() )
|
if(stat & NOPOWER)
|
||||||
icon_state = initial(icon_state)
|
|
||||||
stat &= ~NOPOWER
|
|
||||||
else
|
|
||||||
spawn(rand(0, 15))
|
|
||||||
src.icon_state = "c_unpowered"
|
src.icon_state = "c_unpowered"
|
||||||
stat |= NOPOWER
|
stat |= NOPOWER
|
||||||
|
else
|
||||||
|
icon_state = initial(icon_state)
|
||||||
|
stat &= ~NOPOWER
|
||||||
@@ -35,7 +35,7 @@
|
|||||||
|
|
||||||
|
|
||||||
/obj/machinery/computer/communications/process()
|
/obj/machinery/computer/communications/process()
|
||||||
..()
|
if(..())
|
||||||
if(state != STATE_STATUSDISPLAY)
|
if(state != STATE_STATUSDISPLAY)
|
||||||
src.updateDialog()
|
src.updateDialog()
|
||||||
|
|
||||||
|
|||||||
@@ -3,16 +3,27 @@
|
|||||||
icon = 'icons/obj/computer.dmi'
|
icon = 'icons/obj/computer.dmi'
|
||||||
density = 1
|
density = 1
|
||||||
anchored = 1.0
|
anchored = 1.0
|
||||||
var/obj/item/weapon/circuitboard/circuit = null //if circuit==null, computer can't disassemble
|
use_power = 1
|
||||||
|
idle_power_usage = 300
|
||||||
|
active_power_usage = 300
|
||||||
|
var/obj/item/weapon/circuitboard/circuit = null //if circuit==null, computer can't disassembly
|
||||||
|
var/processing = 0
|
||||||
|
|
||||||
|
/obj/machinery/computer/New()
|
||||||
New()
|
|
||||||
..()
|
..()
|
||||||
spawn(2)
|
if(ticker)
|
||||||
|
initialize()
|
||||||
|
|
||||||
|
|
||||||
|
/obj/machinery/computer/initialize()
|
||||||
power_change()
|
power_change()
|
||||||
|
|
||||||
|
/obj/machinery/computer/process()
|
||||||
|
if(stat & (NOPOWER|BROKEN))
|
||||||
|
return 0
|
||||||
|
return 1
|
||||||
|
|
||||||
meteorhit(var/obj/O as obj)
|
/obj/machinery/computer/meteorhit(var/obj/O as obj)
|
||||||
for(var/x in verbs)
|
for(var/x in verbs)
|
||||||
verbs -= x
|
verbs -= x
|
||||||
set_broken()
|
set_broken()
|
||||||
@@ -22,12 +33,12 @@
|
|||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
emp_act(severity)
|
/obj/machinery/computer/emp_act(severity)
|
||||||
if(prob(20/severity)) set_broken()
|
if(prob(20/severity)) set_broken()
|
||||||
..()
|
..()
|
||||||
|
|
||||||
|
|
||||||
ex_act(severity)
|
/obj/machinery/computer/ex_act(severity)
|
||||||
switch(severity)
|
switch(severity)
|
||||||
if(1.0)
|
if(1.0)
|
||||||
del(src)
|
del(src)
|
||||||
@@ -48,64 +59,44 @@
|
|||||||
else
|
else
|
||||||
return
|
return
|
||||||
|
|
||||||
bullet_act(var/obj/item/projectile/Proj)
|
/obj/machinery/computer/bullet_act(var/obj/item/projectile/Proj)
|
||||||
if(prob(Proj.damage))
|
if(prob(Proj.damage))
|
||||||
set_broken()
|
set_broken()
|
||||||
..()
|
..()
|
||||||
|
|
||||||
|
|
||||||
blob_act()
|
/obj/machinery/computer/blob_act()
|
||||||
if (prob(75))
|
if (prob(75))
|
||||||
for(var/x in verbs)
|
for(var/x in verbs)
|
||||||
verbs -= x
|
verbs -= x
|
||||||
set_broken()
|
set_broken()
|
||||||
density = 0
|
density = 0
|
||||||
|
|
||||||
|
/obj/machinery/computer/update_icon()
|
||||||
power_change()
|
..()
|
||||||
if(!istype(src,/obj/machinery/computer/security/telescreen))
|
icon_state = initial(icon_state)
|
||||||
|
// Broken
|
||||||
if(stat & BROKEN)
|
if(stat & BROKEN)
|
||||||
icon_state = initial(icon_state)
|
|
||||||
icon_state += "b"
|
icon_state += "b"
|
||||||
if (istype(src,/obj/machinery/computer/aifixer))
|
|
||||||
overlays = null
|
|
||||||
|
|
||||||
else if(powered())
|
// Powered
|
||||||
icon_state = initial(icon_state)
|
else if(stat & NOPOWER)
|
||||||
stat &= ~NOPOWER
|
|
||||||
if (istype(src,/obj/machinery/computer/aifixer))
|
|
||||||
var/obj/machinery/computer/aifixer/O = src
|
|
||||||
if (O.occupant)
|
|
||||||
switch (O.occupant.stat)
|
|
||||||
if (0)
|
|
||||||
overlays += image('icons/obj/computer.dmi', "ai-fixer-full")
|
|
||||||
if (2)
|
|
||||||
overlays += image('icons/obj/computer.dmi', "ai-fixer-404")
|
|
||||||
else
|
|
||||||
overlays += image('icons/obj/computer.dmi', "ai-fixer-empty")
|
|
||||||
else
|
|
||||||
spawn(rand(0, 15))
|
|
||||||
//icon_state = "c_unpowered"
|
|
||||||
icon_state = initial(icon_state)
|
icon_state = initial(icon_state)
|
||||||
icon_state += "0"
|
icon_state += "0"
|
||||||
stat |= NOPOWER
|
|
||||||
if (istype(src,/obj/machinery/computer/aifixer))
|
|
||||||
overlays = null
|
|
||||||
|
|
||||||
|
|
||||||
process()
|
|
||||||
if(stat & (NOPOWER|BROKEN))
|
/obj/machinery/computer/power_change()
|
||||||
return
|
..()
|
||||||
use_power(250)
|
update_icon()
|
||||||
|
|
||||||
|
|
||||||
proc/set_broken()
|
/obj/machinery/computer/proc/set_broken()
|
||||||
icon_state = initial(icon_state)
|
|
||||||
icon_state += "b"
|
|
||||||
stat |= BROKEN
|
stat |= BROKEN
|
||||||
|
update_icon()
|
||||||
|
|
||||||
|
|
||||||
attackby(I as obj, user as mob)
|
/obj/machinery/computer/attackby(I as obj, user as mob)
|
||||||
if(istype(I, /obj/item/weapon/screwdriver) && circuit)
|
if(istype(I, /obj/item/weapon/screwdriver) && circuit)
|
||||||
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
|
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
|
||||||
if(do_after(user, 20))
|
if(do_after(user, 20))
|
||||||
|
|||||||
@@ -9,37 +9,37 @@
|
|||||||
var/list/tracked = list( )
|
var/list/tracked = list( )
|
||||||
|
|
||||||
|
|
||||||
New()
|
/obj/machinery/computer/crew/New()
|
||||||
tracked = list()
|
tracked = list()
|
||||||
..()
|
..()
|
||||||
|
|
||||||
|
|
||||||
attack_ai(mob/user)
|
/obj/machinery/computer/crew/attack_ai(mob/user)
|
||||||
attack_hand(user)
|
attack_hand(user)
|
||||||
interact(user)
|
interact(user)
|
||||||
|
|
||||||
|
|
||||||
attack_hand(mob/user)
|
/obj/machinery/computer/crew/attack_hand(mob/user)
|
||||||
add_fingerprint(user)
|
add_fingerprint(user)
|
||||||
if(stat & (BROKEN|NOPOWER))
|
if(stat & (BROKEN|NOPOWER))
|
||||||
return
|
return
|
||||||
interact(user)
|
interact(user)
|
||||||
|
|
||||||
|
|
||||||
power_change()
|
/obj/machinery/computer/crew/update_icon()
|
||||||
|
|
||||||
if(stat & BROKEN)
|
if(stat & BROKEN)
|
||||||
icon_state = "broken"
|
icon_state = "broken"
|
||||||
else
|
else
|
||||||
if( powered() )
|
if(stat & NOPOWER)
|
||||||
icon_state = initial(icon_state)
|
|
||||||
stat &= ~NOPOWER
|
|
||||||
else
|
|
||||||
spawn(rand(0, 15))
|
|
||||||
src.icon_state = "c_unpowered"
|
src.icon_state = "c_unpowered"
|
||||||
stat |= NOPOWER
|
stat |= NOPOWER
|
||||||
|
else
|
||||||
|
icon_state = initial(icon_state)
|
||||||
|
stat &= ~NOPOWER
|
||||||
|
|
||||||
|
|
||||||
Topic(href, href_list)
|
/obj/machinery/computer/crew/Topic(href, href_list)
|
||||||
if(..()) return
|
if(..()) return
|
||||||
if (src.z > 6)
|
if (src.z > 6)
|
||||||
usr << "\red <b>Unable to establish a connection</b>: \black You're too far away from the station!"
|
usr << "\red <b>Unable to establish a connection</b>: \black You're too far away from the station!"
|
||||||
@@ -53,9 +53,10 @@
|
|||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
interact(mob/user)
|
/obj/machinery/computer/crew/interact(mob/user)
|
||||||
if( (get_dist(src, user) > 1 ) || (stat & (BROKEN|NOPOWER)) )
|
if(stat & (BROKEN|NOPOWER))
|
||||||
if(!istype(user, /mob/living/silicon))
|
return
|
||||||
|
if(!istype(user, /mob/living/silicon) && get_dist(src, user) > 1)
|
||||||
user.unset_machine()
|
user.unset_machine()
|
||||||
user << browse(null, "window=powcomp")
|
user << browse(null, "window=powcomp")
|
||||||
return
|
return
|
||||||
@@ -105,7 +106,7 @@
|
|||||||
onclose(user, "crewcomp")
|
onclose(user, "crewcomp")
|
||||||
|
|
||||||
|
|
||||||
proc/scan()
|
/obj/machinery/computer/crew/proc/scan()
|
||||||
for(var/obj/item/clothing/under/C in world)
|
for(var/obj/item/clothing/under/C in world)
|
||||||
if((C.has_sensor) && (istype(C.loc, /mob/living/carbon/human)))
|
if((C.has_sensor) && (istype(C.loc, /mob/living/carbon/human)))
|
||||||
var/check = 0
|
var/check = 0
|
||||||
|
|||||||
@@ -65,7 +65,7 @@
|
|||||||
..()
|
..()
|
||||||
return
|
return
|
||||||
|
|
||||||
/obj/machinery/computer/message_monitor/power_change()
|
/obj/machinery/computer/message_monitor/update_icon()
|
||||||
..()
|
..()
|
||||||
if(stat & (NOPOWER|BROKEN))
|
if(stat & (NOPOWER|BROKEN))
|
||||||
return
|
return
|
||||||
@@ -74,7 +74,7 @@
|
|||||||
else
|
else
|
||||||
icon_state = normal_icon
|
icon_state = normal_icon
|
||||||
|
|
||||||
/obj/machinery/computer/message_monitor/process()
|
/obj/machinery/computer/message_monitor/initialize()
|
||||||
//Is the server isn't linked to a server, and there's a server available, default it to the first one in the list.
|
//Is the server isn't linked to a server, and there's a server available, default it to the first one in the list.
|
||||||
if(!linkedServer)
|
if(!linkedServer)
|
||||||
if(message_servers && message_servers.len > 0)
|
if(message_servers && message_servers.len > 0)
|
||||||
|
|||||||
@@ -146,7 +146,8 @@
|
|||||||
|
|
||||||
|
|
||||||
/obj/machinery/computer/pod/process()
|
/obj/machinery/computer/pod/process()
|
||||||
..()
|
if(!..())
|
||||||
|
return
|
||||||
if(timing)
|
if(timing)
|
||||||
if(time > 0)
|
if(time > 0)
|
||||||
time = round(time) - 1
|
time = round(time) - 1
|
||||||
|
|||||||
@@ -126,10 +126,6 @@
|
|||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
/obj/machinery/power/monitor/process()
|
|
||||||
if(!(stat & (NOPOWER|BROKEN)) )
|
|
||||||
use_power(250)
|
|
||||||
|
|
||||||
/obj/machinery/power/monitor/power_change()
|
/obj/machinery/power/monitor/power_change()
|
||||||
|
|
||||||
if(stat & BROKEN)
|
if(stat & BROKEN)
|
||||||
|
|||||||
@@ -63,9 +63,7 @@
|
|||||||
|
|
||||||
|
|
||||||
process()
|
process()
|
||||||
if(stat & (NOPOWER|BROKEN))
|
if(!..())
|
||||||
return
|
|
||||||
use_power(500)
|
|
||||||
src.updateDialog()
|
src.updateDialog()
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|||||||
@@ -116,6 +116,8 @@ proc/move_mining_shuttle()
|
|||||||
var/location = 0 //0 = station, 1 = mining base
|
var/location = 0 //0 = station, 1 = mining base
|
||||||
|
|
||||||
/obj/machinery/computer/mining_shuttle/attack_hand(user as mob)
|
/obj/machinery/computer/mining_shuttle/attack_hand(user as mob)
|
||||||
|
if(..(user))
|
||||||
|
return
|
||||||
src.add_fingerprint(usr)
|
src.add_fingerprint(usr)
|
||||||
var/dat
|
var/dat
|
||||||
dat = text("<center>Mining shuttle:<br> <b><A href='?src=\ref[src];move=[1]'>Send</A></b></center>")
|
dat = text("<center>Mining shuttle:<br> <b><A href='?src=\ref[src];move=[1]'>Send</A></b></center>")
|
||||||
|
|||||||
Reference in New Issue
Block a user