mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-24 20:47:10 +01:00
@@ -12,6 +12,8 @@ var/global/list/airlocks = list() //list of all airlocks
|
||||
var/global/list/singularities = list() //list of all singularities
|
||||
var/global/list/janitorial_equipment = list() //list of janitorial equipment
|
||||
var/global/list/crafting_recipes = list() //list of all crafting recipes
|
||||
var/global/list/prisoncomputer_list = list()
|
||||
var/global/list/cell_logs = list()
|
||||
|
||||
var/global/list/all_areas = list()
|
||||
var/global/list/machines = list()
|
||||
|
||||
@@ -20,6 +20,14 @@
|
||||
/obj/machinery/computer/prisoner/attack_ai(var/mob/user as mob)
|
||||
return src.attack_hand(user)
|
||||
|
||||
/obj/machinery/computer/prisoner/New()
|
||||
prisoncomputer_list += src
|
||||
return ..()
|
||||
|
||||
/obj/machinery/computer/prisoner/Destroy()
|
||||
prisoncomputer_list -= src
|
||||
return ..()
|
||||
|
||||
/obj/machinery/computer/prisoner/attack_hand(var/mob/user as mob)
|
||||
if(..())
|
||||
return 1
|
||||
|
||||
@@ -120,7 +120,7 @@
|
||||
else
|
||||
security["empty"] = 1
|
||||
return data
|
||||
|
||||
|
||||
/obj/machinery/computer/secure_data/Topic(href, href_list)
|
||||
if(..())
|
||||
return 1
|
||||
@@ -141,6 +141,12 @@
|
||||
qdel(R)
|
||||
update_all_mob_security_hud()
|
||||
setTemp("<h3>All records deleted.</h3>")
|
||||
if("del_alllogs2")
|
||||
if(cell_logs.len)
|
||||
setTemp("<h3>All cell logs deleted.</h3>")
|
||||
cell_logs.Cut()
|
||||
else
|
||||
to_chat(usr, "<span class='notice'>Error; No cell logs to delete.</span>")
|
||||
if("del_r2")
|
||||
if(active2)
|
||||
qdel(active2)
|
||||
@@ -254,6 +260,12 @@
|
||||
buttons[++buttons.len] = list("name" = "No", "icon" = "times", "href" = null, "status" = null)
|
||||
setTemp("<h3>Are you sure you wish to delete all records?</h3>", buttons)
|
||||
|
||||
else if(href_list["del_alllogs"])
|
||||
var/list/buttons = list()
|
||||
buttons[++buttons.len] = list("name" = "Yes", "icon" = "check", "href" = "del_alllogs2=1", "status" = null)
|
||||
buttons[++buttons.len] = list("name" = "No", "icon" = "times", "href" = null, "status" = null)
|
||||
setTemp("<h3>Are you sure you wish to delete all cell logs?</h3>", buttons)
|
||||
|
||||
else if(href_list["del_rg"])
|
||||
if(active1)
|
||||
var/list/buttons = list()
|
||||
@@ -342,6 +354,24 @@
|
||||
create_record_photo(active1)
|
||||
printing = 0
|
||||
|
||||
else if(href_list["printlogs"])
|
||||
if(cell_logs.len && !printing)
|
||||
var/obj/item/weapon/paper/P = input(usr, "Select log to print", "Available Cell Logs") as null|anything in cell_logs
|
||||
if(!P)
|
||||
return 0
|
||||
printing = 1
|
||||
playsound(loc, "sound/goonstation/machines/printer_dotmatrix.ogg", 50, 1)
|
||||
to_chat(usr, "<span class='notice'>Printing file [P.name].</span>")
|
||||
sleep(50)
|
||||
var/obj/item/weapon/paper/log = new /obj/item/weapon/paper(loc)
|
||||
log.name = P.name
|
||||
log.info = P.info
|
||||
printing = 0
|
||||
return 1
|
||||
else
|
||||
to_chat(usr, "<span class='notice'>[src] has no logs stored or is already printing.</span>")
|
||||
|
||||
|
||||
else if(href_list["add_c"])
|
||||
if(istype(active2, /datum/data/record))
|
||||
var/a2 = active2
|
||||
@@ -454,10 +484,10 @@
|
||||
|
||||
/obj/machinery/computer/secure_data/proc/setTemp(text, list/buttons = list())
|
||||
temp = list("text" = text, "buttons" = buttons, "has_buttons" = buttons.len > 0)
|
||||
|
||||
/obj/machinery/computer/secure_data/proc/update_all_mob_security_hud()
|
||||
|
||||
/obj/machinery/computer/secure_data/proc/update_all_mob_security_hud()
|
||||
for(var/mob/living/carbon/human/H in mob_list)
|
||||
H.sec_hud_set_security_status()
|
||||
H.sec_hud_set_security_status()
|
||||
|
||||
/obj/machinery/computer/secure_data/proc/create_record_photo(datum/data/record/R)
|
||||
// basically copy-pasted from the camera code but different enough that it has to be redone
|
||||
|
||||
@@ -28,9 +28,34 @@
|
||||
var/list/obj/machinery/targets = list()
|
||||
var/timetoset = 0 // Used to set releasetime upon starting the timer
|
||||
var/obj/item/device/radio/Radio
|
||||
var/printed = 0
|
||||
maptext_height = 26
|
||||
maptext_width = 32
|
||||
|
||||
/obj/machinery/door_timer/proc/print_report()
|
||||
var/logname = input(usr, "Name of the guilty?","[id] log name")
|
||||
var/logcharges = stripped_multiline_input(usr, "What have they been charged with?","[id] log charges")
|
||||
|
||||
if(!logname || !logcharges)
|
||||
return 0
|
||||
|
||||
for(var/obj/machinery/computer/prisoner/C in prisoncomputer_list)
|
||||
var/obj/item/weapon/paper/P = new /obj/item/weapon/paper(C.loc)
|
||||
P.name = "[id] log - [logname] [worldtime2text()]"
|
||||
P.info = "<center><b>[id] - Brig record</b></center><br><hr><br>"
|
||||
P.info += {"<center>[station_name()] - Security Department</center><br>
|
||||
<center><small><b>Admission data:</b></small></center><br>
|
||||
<small><b>Log generated at:</b> [worldtime2text()]<br>
|
||||
<b>Detainee:</b> [logname]<br>
|
||||
<b>Duration:</b> [timetoset/10] seconds<br>
|
||||
<b>Charge(s):</b> [logcharges]<br>
|
||||
<b>Arresting Officer:</b> [usr.name]<br><hr><br>
|
||||
<small>This log file was generated automatically upon activation of a cell timer.</small>"}
|
||||
|
||||
playsound(C.loc, "sound/goonstation/machines/printer_dotmatrix.ogg", 50, 1)
|
||||
cell_logs += P
|
||||
return 1
|
||||
|
||||
/obj/machinery/door_timer/initialize()
|
||||
..()
|
||||
|
||||
@@ -98,9 +123,15 @@
|
||||
|
||||
// Closes and locks doors, power check
|
||||
/obj/machinery/door_timer/proc/timer_start()
|
||||
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
return 0
|
||||
|
||||
if(!printed)
|
||||
if(!print_report())
|
||||
timing = 0
|
||||
return 0
|
||||
|
||||
// Set releasetime
|
||||
releasetime = world.timeofday + timetoset
|
||||
if(!(src in machine_processing))
|
||||
@@ -134,6 +165,7 @@
|
||||
|
||||
// Reset releasetime
|
||||
releasetime = 0
|
||||
printed = 0
|
||||
|
||||
for(var/obj/machinery/door/window/brigdoor/door in targets)
|
||||
if(!door.density)
|
||||
@@ -277,6 +309,7 @@
|
||||
F.flash()
|
||||
|
||||
if(href_list["change"])
|
||||
printed = 1
|
||||
timer_start()
|
||||
|
||||
add_fingerprint(usr)
|
||||
|
||||
Reference in New Issue
Block a user