mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 02:16:05 +00:00
@@ -93,7 +93,8 @@
|
||||
if(!emagged)
|
||||
locked = FALSE
|
||||
emagged = TRUE
|
||||
user.visible_message("\The [user] shorts out the lock on the interface on \the [src].","<span class='warning'>You short out the lock.</span>")
|
||||
if(user)
|
||||
user.visible_message("\The [user] shorts out the lock on the interface on \the [src].","<span class='warning'>You short out the lock.</span>")
|
||||
|
||||
/obj/machinery/power/rust_fuel_injector/attackby(var/obj/item/W, var/mob/user)
|
||||
if(..())
|
||||
|
||||
@@ -51,7 +51,8 @@
|
||||
spark(src, 5)
|
||||
return 1
|
||||
else
|
||||
to_chat(user, "You fail to hack \the [src]'s controls.")
|
||||
if(user)
|
||||
to_chat(user, "You fail to hack \the [src]'s controls.")
|
||||
playsound(get_turf(src), 'sound/effects/sparks4.ogg', 75, 1)
|
||||
|
||||
/obj/machinery/shield_capacitor/wrenchAnchor(var/mob/user)
|
||||
|
||||
@@ -82,7 +82,8 @@
|
||||
spark(src, 5)
|
||||
return 1
|
||||
else
|
||||
to_chat(user, "You fail to hack \the [src]'s controls.")
|
||||
if(user)
|
||||
to_chat(user, "You fail to hack \the [src]'s controls.")
|
||||
playsound(get_turf(src), 'sound/effects/sparks4.ogg', 75, 1)
|
||||
|
||||
/obj/machinery/shield_gen/wrenchAnchor(var/mob/user)
|
||||
|
||||
@@ -117,7 +117,8 @@
|
||||
if(!emagged)
|
||||
locked = 0
|
||||
emagged = 1
|
||||
user.visible_message("[user.name] emags the [src.name].","<span class='warning'>You short out the lock.</span>")
|
||||
if(user)
|
||||
user.visible_message("[user.name] emags the [src.name].","<span class='warning'>You short out the lock.</span>")
|
||||
return 1
|
||||
return -1
|
||||
|
||||
|
||||
@@ -662,7 +662,8 @@
|
||||
if(!emagged)
|
||||
emagged = 1
|
||||
connected.emagged = 1
|
||||
to_chat(user, "<span class='warning'>You short out the safety features of \the [src], and feel like a MAN! </span>")
|
||||
if(user)
|
||||
to_chat(user, "<span class='warning'>You short out the safety features of \the [src], and feel like a MAN! </span>")
|
||||
available_options = list("Thermoregulate" = 50,"Rare" = 500,"Medium" = 600,"Well Done" = 700)
|
||||
update_icon()
|
||||
connected.name = "THE MANCROWAVE"
|
||||
|
||||
@@ -54,14 +54,16 @@
|
||||
if (src.health <= 0)
|
||||
src.explode()
|
||||
|
||||
/obj/machinery/bot/proc/Emag(mob/user as mob)
|
||||
/obj/machinery/bot/proc/Emag(mob/user)
|
||||
if(locked)
|
||||
locked = 0
|
||||
emagged = 1
|
||||
to_chat(user, "<span class='warning'>You remove [src]'s control restrictions. Opening up its maintenance panel and swiping again will cause [src] to malfunction.</span>")
|
||||
if(user)
|
||||
to_chat(user, "<span class='warning'>You remove [src]'s control restrictions. Opening up its maintenance panel and swiping again will cause [src] to malfunction.</span>")
|
||||
if(!locked && open)
|
||||
emagged = 2
|
||||
to_chat(user, "<span class='warning'>You cause a malfunction in [src]'s behavioral matrix.</span>")
|
||||
if(user)
|
||||
to_chat(user, "<span class='warning'>You cause a malfunction in [src]'s behavioral matrix.</span>")
|
||||
|
||||
/obj/machinery/bot/npc_tamper_act(mob/living/L)
|
||||
if(on)
|
||||
|
||||
@@ -50,7 +50,6 @@
|
||||
return ..()
|
||||
|
||||
/obj/machinery/sweet/emag(mob/user)
|
||||
if(emagged == 0)
|
||||
user.simple_message("<span class='warning'>You inexplicably short out the [src.name].</span>")
|
||||
emagged = 1
|
||||
return
|
||||
if(!emagged && user)
|
||||
to_chat(user, "<span class='warning'>You inexplicably short out the [src.name].</span>")
|
||||
emagged = !emagged
|
||||
|
||||
@@ -285,7 +285,8 @@
|
||||
if(emagged)
|
||||
return //No spamming
|
||||
emagged = 1
|
||||
visible_message("<span class='warning'>[user] swipes a card into the holodeck reader.</span>","<span class='notice'>You swipe the electromagnetic card into the holocard reader.</span>")
|
||||
if(user)
|
||||
visible_message("<span class='warning'>[user] swipes a card into the holodeck reader.</span>","<span class='notice'>You swipe the electromagnetic card into the holocard reader.</span>")
|
||||
visible_message("<span class='warning'>Warning: Power surge detected. Automatic shutoff and derezing protocols have been corrupted. Please contact Nanotrasen maintenance and cease all operation immediately.</span>")
|
||||
log_game("[key_name(usr)] emagged the Holodeck Control Computer")
|
||||
src.updateUsrDialog()
|
||||
|
||||
@@ -435,7 +435,8 @@ var/shuttle_call/shuttle_calls[0]
|
||||
/obj/machinery/computer/communications/emag(mob/user as mob)
|
||||
if(!emagged)
|
||||
emagged = 1
|
||||
to_chat(user, "Syndicate routing data uploaded!")
|
||||
if(user)
|
||||
to_chat(user, "Syndicate routing data uploaded!")
|
||||
new/obj/effect/effect/sparks(get_turf(src))
|
||||
playsound(loc,"sparks",50,1)
|
||||
authenticated = 2
|
||||
|
||||
@@ -21,7 +21,8 @@
|
||||
to_chat(user, "<span class='warning'>The buttons don't seem to do anything.</span>")
|
||||
|
||||
/obj/machinery/computer/fluff/emag(mob/user)
|
||||
to_chat(user, "<span class='notice'>You hold the cryptographic sequencer up to the ID scanner. Nothing happens.</span>")
|
||||
if(user)
|
||||
to_chat(user, "<span class='notice'>You hold the cryptographic sequencer up to the ID scanner. Nothing happens.</span>")
|
||||
|
||||
////Shuttle fluffputers
|
||||
/obj/machinery/computer/fluff/shuttle_control /*fluff shuttle console 1 */
|
||||
|
||||
@@ -60,7 +60,8 @@
|
||||
spawn(100*length(src.linkedServer.decryptkey)) UnmagConsole()
|
||||
message = rebootmsg
|
||||
else
|
||||
to_chat(user, "<span class='notice'>A 'no server' error appears on the screen.</span>")
|
||||
if(user)
|
||||
to_chat(user, "<span class='notice'>A 'no server' error appears on the screen.</span>")
|
||||
|
||||
/obj/machinery/computer/message_monitor/update_icon()
|
||||
..()
|
||||
|
||||
@@ -3,10 +3,10 @@
|
||||
#define PRISON_STATION_AREATYPE "/area/shuttle/prison/station" //Type of the prison shuttle area for station
|
||||
#define PRISON_DOCK_AREATYPE "/area/shuttle/prison/prison" //Type of the prison shuttle area for dock
|
||||
|
||||
var/prison_shuttle_moving_to_station = 0
|
||||
var/prison_shuttle_moving_to_prison = 0
|
||||
var/prison_shuttle_at_station = 0
|
||||
var/prison_shuttle_can_send = 1
|
||||
var/prison_shuttle_moving_to_station = FALSE
|
||||
var/prison_shuttle_moving_to_prison = FALSE
|
||||
var/prison_shuttle_at_station = FALSE
|
||||
var/prison_shuttle_can_send = TRUE
|
||||
var/prison_shuttle_time = 0
|
||||
var/prison_shuttle_timeleft = 0
|
||||
|
||||
@@ -17,207 +17,201 @@ var/prison_shuttle_timeleft = 0
|
||||
req_access = list(access_security)
|
||||
circuit = "/obj/item/weapon/circuitboard/prison_shuttle"
|
||||
var/temp = null
|
||||
var/allowedtocall = 0
|
||||
var/prison_break = 0
|
||||
var/allowedtocall = FALSE
|
||||
var/prison_break = FALSE
|
||||
light_color = LIGHT_COLOR_CYAN
|
||||
|
||||
attackby(I as obj, user as mob)
|
||||
if(!..())
|
||||
src.attack_hand(user)
|
||||
/obj/machinery/computer/prison_shuttle/attackby(I as obj, user as mob)
|
||||
if(!..())
|
||||
attack_hand(user)
|
||||
|
||||
attack_ai(var/mob/user as mob)
|
||||
src.add_hiddenprint(user)
|
||||
return src.attack_hand(user)
|
||||
/obj/machinery/computer/prison_shuttle/attack_ai(var/mob/user as mob)
|
||||
add_hiddenprint(user)
|
||||
return attack_hand(user)
|
||||
|
||||
|
||||
attack_paw(var/mob/user as mob)
|
||||
return src.attack_hand(user)
|
||||
/obj/machinery/computer/prison_shuttle/attack_paw(var/mob/user as mob)
|
||||
return attack_hand(user)
|
||||
|
||||
emag(mob/user as mob)
|
||||
emagged = 1
|
||||
to_chat(user, "<span class='notice'>You disable the lock.</span>")
|
||||
/obj/machinery/computer/prison_shuttle/emag(mob/user as mob)
|
||||
if(!emagged)
|
||||
emagged = TRUE
|
||||
if(user)
|
||||
to_chat(user, "<span class='notice'>You disable the lock.</span>")
|
||||
|
||||
/obj/machinery/computer/prison_shuttle/attack_hand(var/mob/user as mob)
|
||||
if(!allowed(user) && !emagged)
|
||||
to_chat(user, "<span class='warning'>Access Denied.</span>")
|
||||
return
|
||||
if(prison_break)
|
||||
to_chat(user, "<span class='warning'>Unable to locate shuttle.</span>")
|
||||
return
|
||||
if(..())
|
||||
return
|
||||
user.set_machine(src)
|
||||
post_signal("prison")
|
||||
var/dat
|
||||
if (temp)
|
||||
dat = temp
|
||||
else
|
||||
dat += {"<BR><B>Prison Shuttle</B><HR>
|
||||
\nLocation: [prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison ? "Moving to station ([prison_shuttle_timeleft] Secs.)":prison_shuttle_at_station ? "Station":"Dock"]<BR>
|
||||
[prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison ? "\n*Shuttle already called*<BR>\n<BR>":prison_shuttle_at_station ? "\n<A href='?src=\ref[src];sendtodock=1'>Send to Dock</A><BR>\n<BR>":"\n<A href='?src=\ref[src];sendtostation=1'>Send to station</A><BR>\n<BR>"]
|
||||
\n<A href='?src=\ref[user];mach_close=computer'>Close</A>"}
|
||||
|
||||
attack_hand(var/mob/user as mob)
|
||||
if(!src.allowed(user) && (!emagged))
|
||||
to_chat(user, "<span class='warning'>Access Denied.</span>")
|
||||
user << browse(dat, "window=computer;size=575x450")
|
||||
onclose(user, "computer")
|
||||
|
||||
|
||||
/obj/machinery/computer/prison_shuttle/Topic(href, href_list)
|
||||
if(..())
|
||||
return TRUE
|
||||
|
||||
else
|
||||
usr.set_machine(src)
|
||||
|
||||
if (href_list["sendtodock"])
|
||||
if (!prison_can_move())
|
||||
to_chat(usr, "<span class='warning'>The prison shuttle is unable to leave.</span>")
|
||||
return
|
||||
if(prison_break)
|
||||
to_chat(user, "<span class='warning'>Unable to locate shuttle.</span>")
|
||||
if(!prison_shuttle_at_station|| prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison)
|
||||
return
|
||||
if(..())
|
||||
return
|
||||
user.set_machine(src)
|
||||
post_signal("prison")
|
||||
var/dat
|
||||
if (src.temp)
|
||||
dat = src.temp
|
||||
else
|
||||
dat += {"<BR><B>Prison Shuttle</B><HR>
|
||||
\nLocation: [prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison ? "Moving to station ([prison_shuttle_timeleft] Secs.)":prison_shuttle_at_station ? "Station":"Dock"]<BR>
|
||||
[prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison ? "\n*Shuttle already called*<BR>\n<BR>":prison_shuttle_at_station ? "\n<A href='?src=\ref[src];sendtodock=1'>Send to Dock</A><BR>\n<BR>":"\n<A href='?src=\ref[src];sendtostation=1'>Send to station</A><BR>\n<BR>"]
|
||||
\n<A href='?src=\ref[user];mach_close=computer'>Close</A>"}
|
||||
to_chat(usr, "<span class='notice'>The prison shuttle has been called and will arrive in [(PRISON_MOVETIME/10)] seconds.</span>")
|
||||
temp += "Shuttle sent.<BR><BR><A href='?src=\ref[src];mainmenu=1'>OK</A>"
|
||||
updateUsrDialog()
|
||||
prison_shuttle_moving_to_prison = 1
|
||||
prison_shuttle_time = world.timeofday + PRISON_MOVETIME
|
||||
spawn(0)
|
||||
prison_process()
|
||||
|
||||
user << browse(dat, "window=computer;size=575x450")
|
||||
onclose(user, "computer")
|
||||
return
|
||||
|
||||
|
||||
Topic(href, href_list)
|
||||
if(..())
|
||||
return 1
|
||||
|
||||
else
|
||||
usr.set_machine(src)
|
||||
|
||||
if (href_list["sendtodock"])
|
||||
if (!prison_can_move())
|
||||
to_chat(usr, "<span class='warning'>The prison shuttle is unable to leave.</span>")
|
||||
return
|
||||
if(!prison_shuttle_at_station|| prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison)
|
||||
return
|
||||
post_signal("prison")
|
||||
to_chat(usr, "<span class='notice'>The prison shuttle has been called and will arrive in [(PRISON_MOVETIME/10)] seconds.</span>")
|
||||
src.temp += "Shuttle sent.<BR><BR><A href='?src=\ref[src];mainmenu=1'>OK</A>"
|
||||
src.updateUsrDialog()
|
||||
prison_shuttle_moving_to_prison = 1
|
||||
prison_shuttle_time = world.timeofday + PRISON_MOVETIME
|
||||
spawn(0)
|
||||
prison_process()
|
||||
|
||||
else if (href_list["sendtostation"])
|
||||
if (!prison_can_move())
|
||||
to_chat(usr, "<span class='warning'>The prison shuttle is unable to leave.</span>")
|
||||
return
|
||||
if(prison_shuttle_at_station || prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison)
|
||||
return
|
||||
post_signal("prison")
|
||||
to_chat(usr, "<span class='notice'>The prison shuttle has been called and will arrive in [(PRISON_MOVETIME/10)] seconds.</span>")
|
||||
src.temp += "Shuttle sent.<BR><BR><A href='?src=\ref[src];mainmenu=1'>OK</A>"
|
||||
src.updateUsrDialog()
|
||||
prison_shuttle_moving_to_station = 1
|
||||
prison_shuttle_time = world.timeofday + PRISON_MOVETIME
|
||||
spawn(0)
|
||||
prison_process()
|
||||
|
||||
else if (href_list["mainmenu"])
|
||||
src.temp = null
|
||||
|
||||
src.add_fingerprint(usr)
|
||||
src.updateUsrDialog()
|
||||
return
|
||||
|
||||
|
||||
proc/prison_can_move()
|
||||
if(prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison)
|
||||
return 0
|
||||
else
|
||||
return 1
|
||||
|
||||
|
||||
proc/prison_break()
|
||||
switch(prison_break)
|
||||
if (0)
|
||||
if(!prison_shuttle_at_station || prison_shuttle_moving_to_prison)
|
||||
return
|
||||
|
||||
prison_shuttle_moving_to_prison = 1
|
||||
prison_shuttle_at_station = prison_shuttle_at_station
|
||||
|
||||
if (!prison_shuttle_moving_to_prison || !prison_shuttle_moving_to_station)
|
||||
prison_shuttle_time = world.timeofday + PRISON_MOVETIME
|
||||
spawn(0)
|
||||
prison_process()
|
||||
prison_break = 1
|
||||
if(1)
|
||||
prison_break = 0
|
||||
|
||||
|
||||
proc/post_signal(var/command)
|
||||
var/datum/radio_frequency/frequency = radio_controller.return_frequency(1311)
|
||||
if(!frequency)
|
||||
else if (href_list["sendtostation"])
|
||||
if (!prison_can_move())
|
||||
to_chat(usr, "<span class='warning'>The prison shuttle is unable to leave.</span>")
|
||||
return
|
||||
var/datum/signal/status_signal = getFromPool(/datum/signal)
|
||||
status_signal.source = src
|
||||
status_signal.transmission_method = 1
|
||||
status_signal.data["command"] = command
|
||||
frequency.post_signal(src, status_signal)
|
||||
if(prison_shuttle_at_station || prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison)
|
||||
return
|
||||
post_signal("prison")
|
||||
to_chat(usr, "<span class='notice'>The prison shuttle has been called and will arrive in [(PRISON_MOVETIME/10)] seconds.</span>")
|
||||
temp += "Shuttle sent.<BR><BR><A href='?src=\ref[src];mainmenu=1'>OK</A>"
|
||||
updateUsrDialog()
|
||||
prison_shuttle_moving_to_station = 1
|
||||
prison_shuttle_time = world.timeofday + PRISON_MOVETIME
|
||||
spawn(0)
|
||||
prison_process()
|
||||
|
||||
else if (href_list["mainmenu"])
|
||||
temp = null
|
||||
|
||||
add_fingerprint(usr)
|
||||
updateUsrDialog()
|
||||
|
||||
|
||||
/obj/machinery/computer/prison_shuttle/proc/prison_can_move()
|
||||
if(prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison)
|
||||
return FALSE
|
||||
else
|
||||
return TRUE
|
||||
|
||||
|
||||
/obj/machinery/computer/prison_shuttle/proc/prison_break()
|
||||
if (!prison_break)
|
||||
if(!prison_shuttle_at_station || prison_shuttle_moving_to_prison)
|
||||
return
|
||||
|
||||
prison_shuttle_moving_to_prison = 1
|
||||
prison_shuttle_at_station = prison_shuttle_at_station
|
||||
|
||||
if (!prison_shuttle_moving_to_prison || !prison_shuttle_moving_to_station)
|
||||
prison_shuttle_time = world.timeofday + PRISON_MOVETIME
|
||||
spawn(0)
|
||||
prison_process()
|
||||
prison_break = TRUE
|
||||
else
|
||||
prison_break = FALSE
|
||||
|
||||
|
||||
/obj/machinery/computer/prison_shuttle/proc/post_signal(var/command)
|
||||
var/datum/radio_frequency/frequency = radio_controller.return_frequency(1311)
|
||||
if(!frequency)
|
||||
return
|
||||
var/datum/signal/status_signal = getFromPool(/datum/signal)
|
||||
status_signal.source = src
|
||||
status_signal.transmission_method = 1
|
||||
status_signal.data["command"] = command
|
||||
frequency.post_signal(src, status_signal)
|
||||
|
||||
|
||||
proc/prison_process()
|
||||
while(prison_shuttle_time - world.timeofday > 0)
|
||||
var/ticksleft = prison_shuttle_time - world.timeofday
|
||||
/obj/machinery/computer/prison_shuttle/proc/prison_process()
|
||||
while(prison_shuttle_time - world.timeofday > 0)
|
||||
var/ticksleft = prison_shuttle_time - world.timeofday
|
||||
|
||||
if(ticksleft > 1e5)
|
||||
prison_shuttle_time = world.timeofday + 10 // midnight rollover
|
||||
if(ticksleft > 1e5)
|
||||
prison_shuttle_time = world.timeofday + 10 // midnight rollover
|
||||
|
||||
prison_shuttle_timeleft = (ticksleft / 10)
|
||||
sleep(5)
|
||||
prison_shuttle_moving_to_station = 0
|
||||
prison_shuttle_moving_to_prison = 0
|
||||
prison_shuttle_timeleft = (ticksleft / 10)
|
||||
sleep(5)
|
||||
prison_shuttle_moving_to_station = FALSE
|
||||
prison_shuttle_moving_to_prison = FALSE
|
||||
|
||||
switch(prison_shuttle_at_station)
|
||||
if(!prison_shuttle_at_station)
|
||||
prison_shuttle_at_station = TRUE
|
||||
if (prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison)
|
||||
return
|
||||
|
||||
if(0)
|
||||
prison_shuttle_at_station = 1
|
||||
if (prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison)
|
||||
return
|
||||
if (!prison_can_move())
|
||||
to_chat(usr, "<span class='warning'>The prison shuttle is unable to leave.</span>")
|
||||
return
|
||||
|
||||
if (!prison_can_move())
|
||||
to_chat(usr, "<span class='warning'>The prison shuttle is unable to leave.</span>")
|
||||
return
|
||||
var/area/start_location = locate(/area/shuttle/prison/prison)
|
||||
var/area/end_location = locate(/area/shuttle/prison/station)
|
||||
|
||||
var/area/start_location = locate(/area/shuttle/prison/prison)
|
||||
var/area/end_location = locate(/area/shuttle/prison/station)
|
||||
var/list/dstturfs = list()
|
||||
var/throwy = world.maxy
|
||||
|
||||
var/list/dstturfs = list()
|
||||
var/throwy = world.maxy
|
||||
for(var/turf/T in end_location)
|
||||
dstturfs += T
|
||||
if(T.y < throwy)
|
||||
throwy = T.y
|
||||
// hey you, get out of the way!
|
||||
for(var/turf/T in dstturfs)
|
||||
// find the turf to move things to
|
||||
var/turf/D = locate(T.x, throwy - 1, 1)
|
||||
//var/turf/E = get_step(D, SOUTH)
|
||||
for(var/atom/movable/AM as mob|obj in T)
|
||||
AM.Move(D)
|
||||
if(istype(T, /turf/simulated))
|
||||
qdel(T)
|
||||
T = null
|
||||
start_location.move_contents_to(end_location)
|
||||
|
||||
for(var/turf/T in end_location)
|
||||
dstturfs += T
|
||||
if(T.y < throwy)
|
||||
throwy = T.y
|
||||
// hey you, get out of the way!
|
||||
for(var/turf/T in dstturfs)
|
||||
// find the turf to move things to
|
||||
var/turf/D = locate(T.x, throwy - 1, 1)
|
||||
//var/turf/E = get_step(D, SOUTH)
|
||||
for(var/atom/movable/AM as mob|obj in T)
|
||||
AM.Move(D)
|
||||
if(istype(T, /turf/simulated))
|
||||
qdel(T)
|
||||
T = null
|
||||
start_location.move_contents_to(end_location)
|
||||
else
|
||||
prison_shuttle_at_station = FALSE
|
||||
if (prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison)
|
||||
return
|
||||
|
||||
if(1)
|
||||
prison_shuttle_at_station = 0
|
||||
if (prison_shuttle_moving_to_station || prison_shuttle_moving_to_prison)
|
||||
return
|
||||
if (!prison_can_move())
|
||||
to_chat(usr, "<span class='warning'>The prison shuttle is unable to leave.</span>")
|
||||
return
|
||||
|
||||
if (!prison_can_move())
|
||||
to_chat(usr, "<span class='warning'>The prison shuttle is unable to leave.</span>")
|
||||
return
|
||||
var/area/start_location = locate(/area/shuttle/prison/station)
|
||||
var/area/end_location = locate(/area/shuttle/prison/prison)
|
||||
|
||||
var/area/start_location = locate(/area/shuttle/prison/station)
|
||||
var/area/end_location = locate(/area/shuttle/prison/prison)
|
||||
var/list/dstturfs = list()
|
||||
var/throwy = world.maxy
|
||||
|
||||
var/list/dstturfs = list()
|
||||
var/throwy = world.maxy
|
||||
for(var/turf/T in end_location)
|
||||
dstturfs += T
|
||||
if(T.y < throwy)
|
||||
throwy = T.y
|
||||
|
||||
for(var/turf/T in end_location)
|
||||
dstturfs += T
|
||||
if(T.y < throwy)
|
||||
throwy = T.y
|
||||
|
||||
// hey you, get out of the way!
|
||||
for(var/turf/T in dstturfs)
|
||||
// find the turf to move things to
|
||||
var/turf/D = locate(T.x, throwy - 1, 1)
|
||||
//var/turf/E = get_step(D, SOUTH)
|
||||
for(var/atom/movable/AM as mob|obj in T)
|
||||
AM.Move(D)
|
||||
if(istype(T, /turf/simulated))
|
||||
qdel(T)
|
||||
start_location.move_contents_to(end_location)
|
||||
return
|
||||
// hey you, get out of the way!
|
||||
for(var/turf/T in dstturfs)
|
||||
// find the turf to move things to
|
||||
var/turf/D = locate(T.x, throwy - 1, 1)
|
||||
//var/turf/E = get_step(D, SOUTH)
|
||||
for(var/atom/movable/AM as mob|obj in T)
|
||||
AM.Move(D)
|
||||
if(istype(T, /turf/simulated))
|
||||
qdel(T)
|
||||
start_location.move_contents_to(end_location)
|
||||
|
||||
@@ -236,4 +236,5 @@
|
||||
/obj/machinery/computer/robotics/emag(mob/user)
|
||||
..()
|
||||
req_access = list()
|
||||
to_chat(user, "You disable the console's access requirement.")
|
||||
if(user)
|
||||
to_chat(user, "You disable the console's access requirement.")
|
||||
@@ -65,7 +65,11 @@
|
||||
if(!emagged)
|
||||
new/obj/effect/effect/sparks(get_turf(src))
|
||||
playsound(loc,"sparks",50,1)
|
||||
var/choice = alert(user, "Would you like to launch the shuttle?","Shuttle control", "Launch", "Cancel")
|
||||
var/choice = "Cancel"
|
||||
if(user)
|
||||
choice = alert(user, "Would you like to launch the shuttle?","Shuttle control", "Launch", "Cancel")
|
||||
else
|
||||
choice = "Launch" //What can go wrong?
|
||||
if(emergency_shuttle.location == 1)
|
||||
switch(choice)
|
||||
if("Launch")
|
||||
|
||||
@@ -502,6 +502,7 @@
|
||||
/obj/machinery/computer/shuttle_control/emag(mob/user as mob)
|
||||
..()
|
||||
src.req_access = list()
|
||||
to_chat(usr, "You disable the console's access requirement.")
|
||||
if(user)
|
||||
to_chat(user, "You disable the console's access requirement.")
|
||||
|
||||
#undef MAX_SHUTTLE_NAME_LEN
|
||||
|
||||
@@ -259,8 +259,8 @@ var/specops_shuttle_timeleft = 0
|
||||
return attack_hand(user)
|
||||
|
||||
/obj/machinery/computer/specops_shuttle/emag(mob/user as mob)
|
||||
to_chat(user, "<span class='notice'>The electronic systems in this console are far too advanced for your primitive hacking peripherals.</span>")
|
||||
return
|
||||
if(user)
|
||||
to_chat(user, "<span class='notice'>The electronic systems in this console are far too advanced for your primitive hacking peripherals.</span>")
|
||||
|
||||
/obj/machinery/computer/specops_shuttle/attack_hand(var/mob/user as mob)
|
||||
if(!allowed(user))
|
||||
|
||||
@@ -186,8 +186,8 @@ var/syndicate_elite_shuttle_timeleft = 0
|
||||
return attack_hand(user)
|
||||
|
||||
/obj/machinery/computer/syndicate_elite_shuttle/emag(mob/user as mob)
|
||||
to_chat(user, "<span class='notice'>The electronic systems in this console are far too advanced for your primitive hacking peripherals.</span>")
|
||||
return
|
||||
if(user)
|
||||
to_chat(user, "<span class='notice'>The electronic systems in this console are far too advanced for your primitive hacking peripherals.</span>")
|
||||
|
||||
/obj/machinery/computer/syndicate_elite_shuttle/attack_hand(var/mob/user as mob)
|
||||
if(!allowed(user))
|
||||
|
||||
@@ -81,10 +81,11 @@ for reference:
|
||||
src.icon_state = "barrier[src.locked]"
|
||||
|
||||
/obj/machinery/deployable/barrier/emag(mob/user)
|
||||
if (src.emagged == 0)
|
||||
src.emagged = 1
|
||||
src.req_access = 0
|
||||
to_chat(user, "You break the ID authentication lock on the [src].")
|
||||
if(!emagged)
|
||||
emagged = 1
|
||||
req_access = list()
|
||||
if(user)
|
||||
to_chat(user, "You break the ID authentication lock on the [src].")
|
||||
spark(src, 2)
|
||||
desc = "A deployable barrier. Swipe your ID card to lock/unlock it. Seems like it's malfunctioning"
|
||||
return
|
||||
|
||||
@@ -303,8 +303,9 @@
|
||||
return ..()
|
||||
|
||||
/obj/machinery/door/window/emag(mob/user)
|
||||
var used_emag = (/obj/item/weapon/card/emag in user.contents) //TODO: Find a better way of checking this
|
||||
return hackOpen(used_emag, user)
|
||||
if(user)
|
||||
var/used_emag = (/obj/item/weapon/card/emag in user.contents) //TODO: Find a better way of checking this
|
||||
return hackOpen(used_emag, user)
|
||||
|
||||
/obj/machinery/door/window/proc/hackOpen(obj/item/I, mob/user)
|
||||
operating = -1
|
||||
|
||||
@@ -91,9 +91,10 @@ var/list/mass_drivers = list()
|
||||
/obj/machinery/mass_driver/emag(mob/user)
|
||||
if(!emagged)
|
||||
emagged = 1
|
||||
to_chat(user, "You hack the Mass Driver, radically increasing the force at which it'll throw things. Better not stand in its way.")
|
||||
if(user)
|
||||
to_chat(user, "You hack the Mass Driver, radically increasing the force at which it'll throw things. Better not stand in its way.")
|
||||
return 1
|
||||
return -1
|
||||
return -1 //GROSS
|
||||
|
||||
////////////////MASS BUMPER///////////////////
|
||||
|
||||
|
||||
@@ -199,7 +199,8 @@ Status: []<BR>"},
|
||||
|
||||
/obj/machinery/porta_turret/emag(mob/user)
|
||||
if(!emagged)
|
||||
to_chat(user, "<span class='warning'>You short out [src]'s threat assessment circuits.</span>")
|
||||
if(user)
|
||||
to_chat(user, "<span class='warning'>You short out [src]'s threat assessment circuits.</span>")
|
||||
if(anchored) //this is like this because the turret itself is invisible when retracted, so the cover displays the message instead
|
||||
cover.visible_message("<span class='warning'>[src] hums oddly...</span>", "<span class='warning'>You hear an odd humming.</span>")
|
||||
else //But when unsecured the cover is gone, so it shows the message itself
|
||||
@@ -207,7 +208,7 @@ Status: []<BR>"},
|
||||
if(istype(installed, /obj/item/weapon/gun/energy/tag/red) || istype(installed, /obj/item/weapon/gun/energy/tag/red))
|
||||
installed.projectile_type = /obj/item/projectile/beam/lasertag/omni //if you manage to get this gun back out, good for you
|
||||
emagged = 1
|
||||
req_access = null
|
||||
req_access = list()
|
||||
on = 0 // turns off the turret temporarily
|
||||
sleep(60) // 6 seconds for the traitor to gtfo of the area before the turret decides to ruin his shit
|
||||
if(anchored) //Can't turn on if not secure
|
||||
|
||||
@@ -235,5 +235,6 @@
|
||||
if(!emagged)
|
||||
playsound(get_turf(src), 'sound/effects/sparks4.ogg', 75, 1)
|
||||
emagged = 1
|
||||
to_chat(user, "<span class='notice'>You you disable the security protocols</span>")
|
||||
if(user)
|
||||
to_chat(user, "<span class='notice'>You you disable the security protocols</span>")
|
||||
return 1
|
||||
|
||||
@@ -147,6 +147,7 @@
|
||||
if(!emagged)
|
||||
playsound(get_turf(src), 'sound/effects/sparks4.ogg', 75, 1)
|
||||
emagged = 1
|
||||
to_chat(user, "<span class='notice'>You you disable the security protocols</span>")
|
||||
if(user)
|
||||
to_chat(user, "<span class='notice'>You you disable the security protocols</span>")
|
||||
return 1
|
||||
return
|
||||
|
||||
@@ -282,7 +282,8 @@
|
||||
if(!emagged)
|
||||
playsound(get_turf(src), 'sound/effects/sparks4.ogg', 75, 1)
|
||||
emagged = 1
|
||||
to_chat(user, "<span class='notice'>You you disable the security protocols</span>")
|
||||
if(user)
|
||||
to_chat(user, "<span class='notice'>You you disable the security protocols</span>")
|
||||
src.updateUsrDialog()
|
||||
return 1
|
||||
/obj/machinery/computer/telecomms/traffic/proc/canAccess(var/mob/user)
|
||||
|
||||
@@ -346,11 +346,12 @@
|
||||
|
||||
/obj/machinery/turretid/emag(mob/user)
|
||||
if(!emagged)
|
||||
to_chat(user, "<span class='warning'>You short out the turret controls' access analysis module.</span>")
|
||||
emagged = 1
|
||||
locked = 0
|
||||
if(user.machine==src)
|
||||
src.attack_hand(user)
|
||||
if(user)
|
||||
to_chat(user, "<span class='warning'>You short out the turret controls' access analysis module.</span>")
|
||||
if(user.machine==src)
|
||||
src.attack_hand(user)
|
||||
return 1
|
||||
return
|
||||
|
||||
|
||||
@@ -343,9 +343,10 @@ var/global/num_vending_terminals = 1
|
||||
/obj/machinery/vending/emag(mob/user)
|
||||
if(!emagged)
|
||||
emagged = 1
|
||||
to_chat(user, "You short out the product lock on \the [src]")
|
||||
if(user)
|
||||
to_chat(user, "You short out the product lock on \the [src]")
|
||||
return 1
|
||||
return -1
|
||||
return -1 //Fucking gross
|
||||
|
||||
/obj/machinery/vending/npc_tamper_act(mob/living/L)
|
||||
if(!panel_open)
|
||||
@@ -2573,8 +2574,9 @@ var/global/num_vending_terminals = 1
|
||||
|
||||
/obj/machinery/vending/nazivend/emag(mob/user)
|
||||
if(!emagged)
|
||||
to_chat(user, "<span class='warning'>As you slide the card into the machine, you hear something unlocking inside. The machine emits an evil glow.</span>")
|
||||
message_admins("[key_name_admin(user)] unlocked a Nazivend's DANGERMODE!")
|
||||
if(user)
|
||||
to_chat(user, "<span class='warning'>As you slide the card into the machine, you hear something unlocking inside. The machine emits an evil glow.</span>")
|
||||
message_admins("[key_name_admin(user)] unlocked a Nazivend's DANGERMODE!")
|
||||
contraband[/obj/item/clothing/head/helmet/space/rig/nazi] = 3
|
||||
contraband[/obj/item/clothing/suit/space/rig/nazi] = 3
|
||||
contraband[/obj/item/weapon/gun/energy/plasma/MP40k] = 4
|
||||
@@ -2654,8 +2656,9 @@ var/global/num_vending_terminals = 1
|
||||
|
||||
/obj/machinery/vending/sovietvend/emag(mob/user)
|
||||
if(!emagged)
|
||||
to_chat(user, "<span class='warning'>As you slide the card into the machine, you hear something unlocking inside. The machine emits an evil glow.</span>")
|
||||
message_admins("[key_name_admin(user)] unlocked a Sovietvend's DANGERMODE!")
|
||||
if(user)
|
||||
to_chat(user, "<span class='warning'>As you slide the card into the machine, you hear something unlocking inside. The machine emits an evil glow.</span>")
|
||||
message_admins("[key_name_admin(user)] unlocked a Sovietvend's DANGERMODE!")
|
||||
contraband[/obj/item/clothing/head/helmet/space/rig/soviet] = 3
|
||||
contraband[/obj/item/clothing/suit/space/rig/soviet] = 3
|
||||
contraband[/obj/item/weapon/gun/energy/laser/LaserAK] = 4
|
||||
|
||||
@@ -30,9 +30,11 @@
|
||||
/obj/item/weapon/cookiesynth/proc/Emag(mob/user)
|
||||
emagged = !emagged
|
||||
if(emagged)
|
||||
to_chat(user,"<span class='warning'>You short out the [src]'s reagent safety checker!</span>")
|
||||
if(user)
|
||||
to_chat(user,"<span class='warning'>You short out the [src]'s reagent safety checker!</span>")
|
||||
else
|
||||
to_chat(user,"<span class='warning'>You reset the [src]'s reagent safety checker!</span>")
|
||||
if(user)
|
||||
to_chat(user,"<span class='warning'>You reset the [src]'s reagent safety checker!</span>")
|
||||
toxin = 0
|
||||
|
||||
/obj/item/weapon/cookiesynth/attack_self(mob/user)
|
||||
|
||||
@@ -200,7 +200,8 @@
|
||||
/obj/machinery/computer/library/checkout/emag(mob/user)
|
||||
if(!emagged)
|
||||
src.emagged = 1
|
||||
to_chat(user, "<span class='notice'>You override the library computer's printing restrictions.</span>")
|
||||
if(user)
|
||||
to_chat(user, "<span class='notice'>You override the library computer's printing restrictions.</span>")
|
||||
return 1
|
||||
return
|
||||
|
||||
|
||||
@@ -444,7 +444,8 @@ var/global/list/loopModeNames=list(
|
||||
|
||||
/obj/machinery/media/jukebox/emag(mob/user)
|
||||
if(!emagged)
|
||||
user.visible_message("<span class='warning'>[user.name] slides something into the [src.name]'s card-reader.</span>","<span class='warning'>You short out the [src.name].</span>")
|
||||
if(user)
|
||||
user.visible_message("<span class='warning'>[user.name] slides something into the [src.name]'s card-reader.</span>","<span class='warning'>You short out the [src.name].</span>")
|
||||
wires.CutWireIndex(JUKE_CONFIG)
|
||||
short()
|
||||
return
|
||||
|
||||
@@ -350,9 +350,10 @@
|
||||
return
|
||||
|
||||
/obj/machinery/cloning/clonepod/emag(mob/user as mob)
|
||||
if (isnull(occupant))
|
||||
if(isnull(occupant))
|
||||
return
|
||||
to_chat(user, "You force an emergency ejection.")
|
||||
if(user)
|
||||
to_chat(user, "You force an emergency ejection.")
|
||||
locked = FALSE
|
||||
go_out()
|
||||
return
|
||||
|
||||
@@ -110,7 +110,8 @@
|
||||
/obj/machinery/computer/cloning/emag(mob/user)
|
||||
if(!emagged)
|
||||
emagged = 1
|
||||
user.visible_message("<span class='warning'>[user] slides something into \the [src]'s card-reader.</span>","<span class='warning'>You disable \the [src]'s safety overrides.</span>")
|
||||
if(user)
|
||||
user.visible_message("<span class='warning'>[user] slides something into \the [src]'s card-reader.</span>","<span class='warning'>You disable \the [src]'s safety overrides.</span>")
|
||||
|
||||
/obj/machinery/computer/cloning/attack_paw(mob/user as mob)
|
||||
return attack_hand(user)
|
||||
|
||||
@@ -245,7 +245,8 @@
|
||||
if(!emagged)
|
||||
locked = 0
|
||||
emagged = 1
|
||||
user.visible_message("<span class='danger'>[user] shorts out \the [src]'s lock.</span>", "<span class='warning'>You short out \the [src]'s lock.</span>")
|
||||
if(user)
|
||||
user.visible_message("<span class='danger'>[user] shorts out \the [src]'s lock.</span>", "<span class='warning'>You short out \the [src]'s lock.</span>")
|
||||
return
|
||||
|
||||
/obj/machinery/power/emitter/wrenchAnchor(var/mob/user)
|
||||
|
||||
@@ -221,7 +221,8 @@ won't update every console in existence) but it's more of a hassle to do. Also,
|
||||
/obj/machinery/computer/rdconsole/emag(mob/user)
|
||||
playsound(get_turf(src), 'sound/effects/sparks4.ogg', 75, 1)
|
||||
emagged = 1
|
||||
to_chat(user, "<span class='notice'>You disable the security protocols</span>")
|
||||
if(user)
|
||||
to_chat(user, "<span class='notice'>You disable the security protocols</span>")
|
||||
|
||||
/obj/machinery/computer/rdconsole/proc/deconstruct_item(mob/user)
|
||||
linked_destroy.busy = 1
|
||||
|
||||
@@ -116,7 +116,8 @@ proc/move_research_shuttle()
|
||||
else
|
||||
to_chat(usr, "<span class='notice'>Shuttle is already moving.</span>")
|
||||
|
||||
/obj/machinery/computer/research_shuttle/emag(mob/user as mob)
|
||||
/obj/machinery/computer/research_shuttle/emag(mob/user)
|
||||
..()
|
||||
src.req_access = list()
|
||||
to_chat(usr, "You disable the console's access requirement.")
|
||||
if(user)
|
||||
to_chat(usr, "You disable the console's access requirement.")
|
||||
|
||||
Reference in New Issue
Block a user