mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 10:43:20 +00:00
@@ -1,8 +1,8 @@
|
||||
/obj/machinery/driver_button
|
||||
name = "mass driver button"
|
||||
/obj/machinery/button
|
||||
name = "button"
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "launcherbtt"
|
||||
desc = "A remote control switch for a mass driver."
|
||||
desc = "A remote control switch for something."
|
||||
var/id = null
|
||||
var/active = 0
|
||||
anchored = 1.0
|
||||
@@ -10,38 +10,10 @@
|
||||
idle_power_usage = 2
|
||||
active_power_usage = 4
|
||||
|
||||
/obj/machinery/ignition_switch
|
||||
name = "ignition switch"
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "launcherbtt"
|
||||
desc = "A remote control switch for a mounted igniter."
|
||||
var/id = null
|
||||
var/active = 0
|
||||
anchored = 1.0
|
||||
use_power = 1
|
||||
idle_power_usage = 2
|
||||
active_power_usage = 4
|
||||
/obj/machinery/button/attack_ai(mob/user as mob)
|
||||
return src.attack_hand(user)
|
||||
|
||||
/obj/machinery/flasher_button
|
||||
name = "flasher button"
|
||||
desc = "A remote control switch for a mounted flasher."
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "launcherbtt"
|
||||
var/id = null
|
||||
var/active = 0
|
||||
anchored = 1.0
|
||||
use_power = 1
|
||||
idle_power_usage = 2
|
||||
active_power_usage = 4
|
||||
|
||||
/obj/machinery/crema_switch
|
||||
desc = "Burn baby burn!"
|
||||
name = "crematorium igniter"
|
||||
icon = 'icons/obj/power.dmi'
|
||||
icon_state = "crema_switch"
|
||||
anchored = 1.0
|
||||
req_access = list(access_crematorium)
|
||||
var/on = 0
|
||||
var/area/area = null
|
||||
var/otherarea = null
|
||||
var/id = 1
|
||||
/obj/machinery/button/attackby(obj/item/weapon/W, mob/user as mob)
|
||||
if(istype(W, /obj/item/device/detective_scanner))
|
||||
return
|
||||
return src.attack_hand(user)
|
||||
@@ -148,30 +148,20 @@
|
||||
else
|
||||
icon_state = "doorctrl0"
|
||||
|
||||
/obj/machinery/driver_button/attack_ai(mob/user as mob)
|
||||
return src.attack_hand(user)
|
||||
/obj/machinery/button/driver
|
||||
name = "mass driver button"
|
||||
desc = "A remote control switch for a mass driver."
|
||||
|
||||
/obj/machinery/driver_button/attackby(obj/item/weapon/W, mob/user as mob)
|
||||
|
||||
if(istype(W, /obj/item/device/detective_scanner))
|
||||
/obj/machinery/button/driver/attack_hand(mob/user as mob)
|
||||
if(..())
|
||||
return
|
||||
return src.attack_hand(user)
|
||||
|
||||
/obj/machinery/driver_button/attack_hand(mob/user as mob)
|
||||
|
||||
src.add_fingerprint(usr)
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
return
|
||||
if(active)
|
||||
return
|
||||
add_fingerprint(user)
|
||||
|
||||
use_power(5)
|
||||
|
||||
active = 1
|
||||
icon_state = "launcheract"
|
||||
|
||||
for(var/obj/machinery/door/blast/M in world)
|
||||
for(var/obj/machinery/door/blast/M in machines)
|
||||
if (M.id == src.id)
|
||||
spawn( 0 )
|
||||
M.open()
|
||||
@@ -179,13 +169,13 @@
|
||||
|
||||
sleep(20)
|
||||
|
||||
for(var/obj/machinery/mass_driver/M in world)
|
||||
for(var/obj/machinery/mass_driver/M in machines)
|
||||
if(M.id == src.id)
|
||||
M.drive()
|
||||
|
||||
sleep(50)
|
||||
|
||||
for(var/obj/machinery/door/blast/M in world)
|
||||
for(var/obj/machinery/door/blast/M in machines)
|
||||
if (M.id == src.id)
|
||||
spawn( 0 )
|
||||
M.close()
|
||||
|
||||
@@ -119,17 +119,13 @@
|
||||
user.show_message(text("\red [src] is now secured."))
|
||||
src.overlays += "[base_state]-s"
|
||||
|
||||
/obj/machinery/flasher_button/attack_ai(mob/user as mob)
|
||||
return src.attack_hand(user)
|
||||
/obj/machinery/button/flasher
|
||||
name = "flasher button"
|
||||
desc = "A remote control switch for a mounted flasher."
|
||||
|
||||
/obj/machinery/flasher_button/attackby(obj/item/weapon/W, mob/user as mob)
|
||||
return src.attack_hand(user)
|
||||
/obj/machinery/button/flasher/attack_hand(mob/user as mob)
|
||||
|
||||
/obj/machinery/flasher_button/attack_hand(mob/user as mob)
|
||||
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
return
|
||||
if(active)
|
||||
if(..())
|
||||
return
|
||||
|
||||
use_power(5)
|
||||
|
||||
@@ -32,42 +32,23 @@
|
||||
on_icon = "surgery"
|
||||
////////////////////SWITCH///////////////////////////////////////
|
||||
|
||||
/obj/machinery/holosign_switch
|
||||
/obj/machinery/button/holosign
|
||||
name = "holosign switch"
|
||||
icon = 'icons/obj/power.dmi'
|
||||
icon_state = "light1"
|
||||
desc = "A remote control switch for holosign."
|
||||
var/id = null
|
||||
var/active = 0
|
||||
anchored = 1.0
|
||||
use_power = 1
|
||||
idle_power_usage = 2
|
||||
active_power_usage = 4
|
||||
icon = 'icons/obj/power.dmi'
|
||||
icon_state = "crema_switch"
|
||||
|
||||
/obj/machinery/holosign_switch/attack_ai(mob/user as mob)
|
||||
return src.attack_hand(user)
|
||||
/
|
||||
|
||||
/obj/machinery/holosign_switch/attackby(obj/item/weapon/W, mob/user as mob)
|
||||
if(istype(W, /obj/item/device/detective_scanner))
|
||||
return
|
||||
return src.attack_hand(user)
|
||||
|
||||
/obj/machinery/holosign_switch/attack_hand(mob/user as mob)
|
||||
src.add_fingerprint(usr)
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
/obj/machinery/button/holosign/attack_hand(mob/user as mob)
|
||||
if(..())
|
||||
return
|
||||
add_fingerprint(user)
|
||||
|
||||
use_power(5)
|
||||
|
||||
active = !active
|
||||
if(active)
|
||||
icon_state = "light1"
|
||||
else
|
||||
icon_state = "light0"
|
||||
icon_state = "light[active]"
|
||||
|
||||
for(var/obj/machinery/holosign/M in world)
|
||||
for(var/obj/machinery/holosign/M in machines)
|
||||
if (M.id == src.id)
|
||||
spawn( 0 )
|
||||
M.toggle()
|
||||
|
||||
@@ -115,17 +115,13 @@
|
||||
ignite()
|
||||
..(severity)
|
||||
|
||||
/obj/machinery/ignition_switch/attack_ai(mob/user as mob)
|
||||
return src.attack_hand(user)
|
||||
/obj/machinery/button/ignition
|
||||
name = "ignition switch"
|
||||
desc = "A remote control switch for a mounted igniter."
|
||||
|
||||
/obj/machinery/ignition_switch/attackby(obj/item/weapon/W, mob/user as mob)
|
||||
return src.attack_hand(user)
|
||||
/obj/machinery/button/ignition/attack_hand(mob/user as mob)
|
||||
|
||||
/obj/machinery/ignition_switch/attack_hand(mob/user as mob)
|
||||
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
return
|
||||
if(active)
|
||||
if(..())
|
||||
return
|
||||
|
||||
use_power(5)
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
/obj/machinery/light_switch/New()
|
||||
..()
|
||||
spawn(5)
|
||||
src.area = src.loc.loc
|
||||
src.area = get_area(src)
|
||||
|
||||
if(otherarea)
|
||||
src.area = locate(text2path("/area/[otherarea]"))
|
||||
@@ -32,10 +32,7 @@
|
||||
if(stat & NOPOWER)
|
||||
icon_state = "light-p"
|
||||
else
|
||||
if(on)
|
||||
icon_state = "light1"
|
||||
else
|
||||
icon_state = "light0"
|
||||
icon_state = "light[on]"
|
||||
|
||||
/obj/machinery/light_switch/examine(mob/user)
|
||||
if(..(user, 1))
|
||||
|
||||
@@ -379,12 +379,21 @@
|
||||
//Foreach goto(99)
|
||||
return
|
||||
|
||||
/obj/machinery/crema_switch/attack_hand(mob/user as mob)
|
||||
/obj/machinery/button/crematorium
|
||||
name = "crematorium igniter"
|
||||
desc = "Burn baby burn!"
|
||||
icon = 'icons/obj/power.dmi'
|
||||
icon_state = "crema_switch"
|
||||
req_access = list(access_crematorium)
|
||||
id = 1
|
||||
|
||||
/obj/machinery/button/crematorium/attack_hand(mob/user as mob)
|
||||
if(..())
|
||||
return
|
||||
if(src.allowed(usr))
|
||||
for (var/obj/structure/crematorium/C in world)
|
||||
if (C.id == id)
|
||||
if (!C.cremating)
|
||||
C.cremate(user)
|
||||
else
|
||||
usr << "\red Access denied."
|
||||
return
|
||||
usr << "<span class='warning'>Access denied.</span>"
|
||||
|
||||
@@ -470,3 +470,38 @@
|
||||
|
||||
update_icon() //icon_state has to be set manually
|
||||
return
|
||||
|
||||
/obj/structure/window/reinforced/polarized
|
||||
name = "electrochromic window"
|
||||
desc = "Adjusts its tint with voltage. Might take a few good hits to shatter it."
|
||||
var/id
|
||||
|
||||
/obj/structure/window/reinforced/polarized/proc/toggle()
|
||||
if(opacity)
|
||||
animate(src, color="#FFFFFF", time=5)
|
||||
SetOpacity(0)
|
||||
else
|
||||
animate(src, color="#222222", time=5)
|
||||
SetOpacity(1)
|
||||
|
||||
/obj/machinery/button/windowtint
|
||||
name = "window tint control"
|
||||
icon = 'icons/obj/power.dmi'
|
||||
icon_state = "light1"
|
||||
desc = "A remote control switch for polarized windows."
|
||||
var/range = 7
|
||||
|
||||
/obj/machinery/button/windowtint/attack_hand(mob/user as mob)
|
||||
if(..())
|
||||
return 1
|
||||
|
||||
use_power(5)
|
||||
|
||||
active = !active
|
||||
icon_state = "light[active]"
|
||||
|
||||
for(var/obj/structure/window/reinforced/polarized/W in range(src,range))
|
||||
if (W.id == src.id || !W.id)
|
||||
spawn( 0 )
|
||||
W.toggle()
|
||||
return
|
||||
Reference in New Issue
Block a user