Game folder
This commit is contained in:
@@ -1,3 +1,6 @@
|
||||
#define MENU_OPERATION 1
|
||||
#define MENU_SURGERIES 2
|
||||
|
||||
/obj/machinery/computer/operating
|
||||
name = "operating computer"
|
||||
desc = "Monitors patient vitals and displays surgery steps. Can be loaded with surgery disks to perform experimental procedures."
|
||||
@@ -7,10 +10,13 @@
|
||||
var/mob/living/carbon/human/patient
|
||||
var/obj/structure/table/optable/table
|
||||
var/list/advanced_surgeries = list()
|
||||
var/datum/techweb/linked_techweb
|
||||
var/menu = MENU_OPERATION
|
||||
light_color = LIGHT_COLOR_BLUE
|
||||
|
||||
/obj/machinery/computer/operating/Initialize()
|
||||
. = ..()
|
||||
linked_techweb = SSresearch.science_tech
|
||||
find_table()
|
||||
|
||||
/obj/machinery/computer/operating/attackby(obj/item/O, mob/user, params)
|
||||
@@ -24,6 +30,13 @@
|
||||
return TRUE
|
||||
return ..()
|
||||
|
||||
/obj/machinery/computer/operating/proc/sync_surgeries()
|
||||
for(var/i in linked_techweb.researched_designs)
|
||||
var/datum/design/surgery/D = linked_techweb.researched_designs[i]
|
||||
if(!istype(D))
|
||||
continue
|
||||
advanced_surgeries |= D.surgery
|
||||
|
||||
/obj/machinery/computer/operating/proc/find_table()
|
||||
for(var/direction in GLOB.cardinals)
|
||||
table = locate(/obj/structure/table/optable, get_step(src, direction))
|
||||
@@ -41,6 +54,17 @@
|
||||
var/list/data = list()
|
||||
data["table"] = table
|
||||
if(table)
|
||||
data["menu"] = menu
|
||||
|
||||
var/list/surgeries = list()
|
||||
for(var/X in advanced_surgeries)
|
||||
var/datum/surgery/S = X
|
||||
var/list/surgery = list()
|
||||
surgery["name"] = initial(S.name)
|
||||
surgery["desc"] = initial(S.desc)
|
||||
surgeries += list(surgery)
|
||||
data["surgeries"] = surgeries
|
||||
|
||||
data["patient"] = list()
|
||||
if(table.check_patient())
|
||||
patient = table.patient
|
||||
@@ -86,4 +110,19 @@
|
||||
"alternative_step" = alternative_step,
|
||||
"alt_chems_needed" = alt_chems_needed
|
||||
))
|
||||
return data
|
||||
return data
|
||||
|
||||
/obj/machinery/computer/operating/ui_act(action, params)
|
||||
if(..())
|
||||
return
|
||||
switch(action)
|
||||
if("change_menu")
|
||||
menu = text2num(params["menu"])
|
||||
. = TRUE
|
||||
if("sync")
|
||||
sync_surgeries()
|
||||
. = TRUE
|
||||
. = TRUE
|
||||
|
||||
#undef MENU_OPERATION
|
||||
#undef MENU_SURGERIES
|
||||
@@ -9,7 +9,7 @@
|
||||
max_integrity = 200
|
||||
integrity_failure = 100
|
||||
armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 40, "acid" = 20)
|
||||
var/brightness_on = 2
|
||||
var/brightness_on = 1
|
||||
var/icon_keyboard = "generic_key"
|
||||
var/icon_screen = "generic"
|
||||
var/clockwork = FALSE
|
||||
@@ -49,14 +49,19 @@
|
||||
|
||||
/obj/machinery/computer/update_icon()
|
||||
cut_overlays()
|
||||
SSvis_overlays.remove_vis_overlay(src, managed_vis_overlays)
|
||||
if(stat & NOPOWER)
|
||||
add_overlay("[icon_keyboard]_off")
|
||||
return
|
||||
add_overlay(icon_keyboard)
|
||||
|
||||
// This whole block lets screens ignore lighting and be visible even in the darkest room
|
||||
// We can't do this for many things that emit light unfortunately because it layers over things that would be on top of it
|
||||
var/overlay_state = icon_screen
|
||||
if(stat & BROKEN)
|
||||
add_overlay("[icon_state]_broken")
|
||||
else
|
||||
add_overlay(icon_screen)
|
||||
overlay_state = "[icon_state]_broken"
|
||||
SSvis_overlays.add_vis_overlay(src, icon, overlay_state, layer, plane, dir)
|
||||
SSvis_overlays.add_vis_overlay(src, icon, overlay_state, ABOVE_LIGHTING_LAYER, ABOVE_LIGHTING_PLANE, dir, alpha=128)
|
||||
|
||||
/obj/machinery/computer/power_change()
|
||||
..()
|
||||
@@ -68,6 +73,8 @@
|
||||
return
|
||||
|
||||
/obj/machinery/computer/screwdriver_act(mob/living/user, obj/item/I)
|
||||
if(..())
|
||||
return TRUE
|
||||
if(circuit && !(flags_1&NODECONSTRUCT_1))
|
||||
to_chat(user, "<span class='notice'>You start to disconnect the monitor...</span>")
|
||||
if(I.use_tool(src, user, 20, volume=50))
|
||||
@@ -109,7 +116,7 @@
|
||||
if(!(flags_1 & NODECONSTRUCT_1))
|
||||
if(circuit) //no circuit, no computer frame
|
||||
var/obj/structure/frame/computer/A = new /obj/structure/frame/computer(src.loc)
|
||||
A.dir = dir
|
||||
A.setDir(dir)
|
||||
A.circuit = circuit
|
||||
A.setAnchored(TRUE)
|
||||
if(stat & BROKEN)
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
playsound(active_apc, 'sound/machines/terminal_alert.ogg', 50, 0)
|
||||
active_apc.locked = TRUE
|
||||
active_apc.update_icon()
|
||||
active_apc.remote_control = null
|
||||
active_apc = null
|
||||
|
||||
/obj/machinery/computer/apc_control/attack_ai(mob/user)
|
||||
@@ -121,10 +122,12 @@
|
||||
playsound(active_apc, 'sound/machines/terminal_alert.ogg', 50, 0)
|
||||
active_apc.locked = TRUE
|
||||
active_apc.update_icon()
|
||||
active_apc.remote_control = null
|
||||
active_apc = null
|
||||
to_chat(usr, "<span class='robot notice'>[icon2html(src, usr)] Connected to APC in [get_area_name(APC.area, TRUE)]. Interface request sent.</span>")
|
||||
log_activity("remotely accessed APC in [get_area_name(APC.area, TRUE)]")
|
||||
APC.ui_interact(usr, state = GLOB.not_incapacitated_state)
|
||||
APC.remote_control = src
|
||||
APC.ui_interact(usr)
|
||||
playsound(src, 'sound/machines/terminal_prompt_confirm.ogg', 50, 0)
|
||||
message_admins("[ADMIN_LOOKUPFLW(usr)] remotely accessed [APC] from [src] at [AREACOORD(src)].")
|
||||
log_game("[key_name(usr)] remotely accessed [APC] from [src] at [AREACOORD(src)].")
|
||||
|
||||
@@ -367,6 +367,15 @@
|
||||
var/gameStatus = ORION_STATUS_START
|
||||
var/canContinueEvent = 0
|
||||
|
||||
/obj/machinery/computer/arcade/orion_trail/kobayashi
|
||||
name = "Kobayashi Maru control computer"
|
||||
desc = "A test for cadets"
|
||||
icon = 'icons/obj/machines/particle_accelerator.dmi'
|
||||
icon_state = "control_boxp"
|
||||
events = list("Raiders" = 3, "Interstellar Flux" = 1, "Illness" = 3, "Breakdown" = 2, "Malfunction" = 2, "Collision" = 1, "Spaceport" = 2)
|
||||
prizes = list(/obj/item/paper/fluff/holodeck/trek_diploma = 1)
|
||||
settlers = list("Kirk","Worf","Gene")
|
||||
|
||||
/obj/machinery/computer/arcade/orion_trail/Reset()
|
||||
// Sets up the main trail
|
||||
stops = list("Pluto","Asteroid Belt","Proxima Centauri","Dead Space","Rigel Prime","Tau Ceti Beta","Black Hole","Space Outpost Beta-9","Orion Prime")
|
||||
@@ -704,7 +713,7 @@
|
||||
say("WEEWOO! WEEWOO! Spaceport security en route!")
|
||||
playsound(src, 'sound/items/weeoo1.ogg', 100, FALSE)
|
||||
for(var/i, i<=3, i++)
|
||||
var/mob/living/simple_animal/hostile/syndicate/ranged/orion/O = new/mob/living/simple_animal/hostile/syndicate/ranged/orion(get_turf(src))
|
||||
var/mob/living/simple_animal/hostile/syndicate/ranged/smg/orion/O = new/mob/living/simple_animal/hostile/syndicate/ranged/smg/orion(get_turf(src))
|
||||
O.target = usr
|
||||
|
||||
|
||||
@@ -1047,7 +1056,7 @@
|
||||
newgame()
|
||||
obj_flags |= EMAGGED
|
||||
|
||||
/mob/living/simple_animal/hostile/syndicate/ranged/orion
|
||||
/mob/living/simple_animal/hostile/syndicate/ranged/smg/orion
|
||||
name = "spaceport security"
|
||||
desc = "Premier corporate security forces for all spaceports found along the Orion Trail."
|
||||
faction = list("orion")
|
||||
|
||||
@@ -272,7 +272,7 @@ GLOBAL_LIST_EMPTY(atmos_air_controllers)
|
||||
/obj/machinery/computer/atmos_control/tank/ui_act(action, params)
|
||||
if(..() || !radio_connection)
|
||||
return
|
||||
var/datum/signal/signal = new(list("sigtype" = "command"))
|
||||
var/datum/signal/signal = new(list("sigtype" = "command", "user" = usr))
|
||||
switch(action)
|
||||
if("reconnect")
|
||||
reconnect(usr)
|
||||
|
||||
@@ -114,7 +114,7 @@
|
||||
P.play_tool_sound(src)
|
||||
to_chat(user, "<span class='notice'>You connect the monitor.</span>")
|
||||
var/obj/B = new circuit.build_path (loc, circuit)
|
||||
B.dir = dir
|
||||
B.setDir(dir)
|
||||
transfer_fingerprints_to(B)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
@@ -161,6 +161,7 @@
|
||||
icon_keyboard = null
|
||||
icon_screen = "detective_tv"
|
||||
clockwork = TRUE //it'd look weird
|
||||
pass_flags = PASSTABLE
|
||||
|
||||
/obj/machinery/computer/security/mining
|
||||
name = "outpost camera console"
|
||||
|
||||
@@ -54,9 +54,13 @@
|
||||
var/datum/action/A = V
|
||||
A.Remove(user)
|
||||
actions.Cut()
|
||||
for(var/V in eyeobj.visibleCameraChunks)
|
||||
var/datum/camerachunk/C = V
|
||||
C.remove(eyeobj)
|
||||
if(user.client)
|
||||
user.reset_perspective(null)
|
||||
eyeobj.RemoveImages()
|
||||
if(eyeobj.visible_icon && user.client)
|
||||
user.client.images -= eyeobj.user_image
|
||||
eyeobj.eye_user = null
|
||||
user.remote_control = null
|
||||
|
||||
@@ -105,7 +109,7 @@
|
||||
if(!eyeobj.eye_initialized)
|
||||
var/camera_location
|
||||
var/turf/myturf = get_turf(src)
|
||||
if(eyeobj.use_static)
|
||||
if(eyeobj.use_static != USE_STATIC_NONE)
|
||||
if((!z_lock.len || (myturf.z in z_lock)) && GLOB.cameranet.checkTurfVis(myturf))
|
||||
camera_location = myturf
|
||||
else
|
||||
@@ -148,6 +152,7 @@
|
||||
|
||||
/mob/camera/aiEye/remote
|
||||
name = "Inactive Camera Eye"
|
||||
ai_detector_visible = FALSE
|
||||
var/sprint = 10
|
||||
var/cooldown = 0
|
||||
var/acceleration = 1
|
||||
@@ -163,17 +168,12 @@
|
||||
user.see_in_dark = 2
|
||||
return 1
|
||||
|
||||
/mob/camera/aiEye/remote/RemoveImages()
|
||||
..()
|
||||
if(visible_icon)
|
||||
var/client/C = GetViewerClient()
|
||||
if(C)
|
||||
C.images -= user_image
|
||||
|
||||
/mob/camera/aiEye/remote/Destroy()
|
||||
eye_user = null
|
||||
if(origin && eye_user)
|
||||
origin.remove_eye_control(eye_user)
|
||||
origin = null
|
||||
return ..()
|
||||
. = ..()
|
||||
eye_user = null
|
||||
|
||||
/mob/camera/aiEye/remote/GetViewerClient()
|
||||
if(eye_user)
|
||||
@@ -182,15 +182,14 @@
|
||||
|
||||
/mob/camera/aiEye/remote/setLoc(T)
|
||||
if(eye_user)
|
||||
if(!isturf(eye_user.loc))
|
||||
return
|
||||
T = get_turf(T)
|
||||
if (T)
|
||||
forceMove(T)
|
||||
else
|
||||
moveToNullspace()
|
||||
if(use_static)
|
||||
GLOB.cameranet.visibility(src, GetViewerClient())
|
||||
update_ai_detect_hud()
|
||||
if(use_static != USE_STATIC_NONE)
|
||||
GLOB.cameranet.visibility(src, GetViewerClient(), null, use_static)
|
||||
if(visible_icon)
|
||||
if(eye_user.client)
|
||||
eye_user.client.images -= user_image
|
||||
|
||||
@@ -468,6 +468,7 @@
|
||||
// We store the instance rather than the path, because some
|
||||
// species (abductors, slimepeople) store state in their
|
||||
// species datums
|
||||
dna.delete_species = FALSE
|
||||
R.fields["mrace"] = dna.species
|
||||
else
|
||||
var/datum/species/rando_race = pick(GLOB.roundstart_races)
|
||||
|
||||
@@ -52,6 +52,8 @@
|
||||
/obj/machinery/computer/communications/Topic(href, href_list)
|
||||
if(..())
|
||||
return
|
||||
if(!usr.canUseTopic(src))
|
||||
return
|
||||
if(!is_station_level(z) && !is_reserved_level(z)) //Can only use in transit and on SS13
|
||||
to_chat(usr, "<span class='boldannounce'>Unable to establish a connection</span>: \black You're too far away from the station!")
|
||||
return
|
||||
@@ -144,7 +146,7 @@
|
||||
playsound(src, 'sound/machines/terminal_prompt_confirm.ogg', 50, 0)
|
||||
send2otherserver("[station_name()]", input,"Comms_Console")
|
||||
minor_announce(input, title = "Outgoing message to allied station")
|
||||
log_talk(usr,"[key_name(usr)] has sent a message to the other server: [input]",LOGSAY)
|
||||
usr.log_talk(input, LOG_SAY, tag="message to the other server")
|
||||
message_admins("[ADMIN_LOOKUPFLW(usr)] has sent a message to the other server.")
|
||||
deadchat_broadcast("<span class='deadsay bold'>[usr.real_name] has sent an outgoing message to the other station(s).</span>", usr)
|
||||
CM.lastTimeUsed = world.time
|
||||
@@ -198,10 +200,7 @@
|
||||
state = STATE_CANCELSHUTTLE
|
||||
if("cancelshuttle2")
|
||||
if(authenticated)
|
||||
if(world.time > SSshuttle.auto_call)
|
||||
say("Warning: Emergency shuttle recalls have been blocked by Central Command due to ongoing crew transfer procedures.")
|
||||
else
|
||||
SSshuttle.cancelEvac(usr)
|
||||
SSshuttle.cancelEvac(usr)
|
||||
state = STATE_DEFAULT
|
||||
if("messagelist")
|
||||
currmsg = 0
|
||||
@@ -230,12 +229,14 @@
|
||||
var/answer = text2num(href_list["answer"])
|
||||
if(!currmsg || !answer || currmsg.possible_answers.len < answer)
|
||||
state = STATE_MESSAGELIST
|
||||
currmsg.answered = answer
|
||||
log_game("[key_name(usr)] answered [currmsg.title] comm message. Answer : [currmsg.answered]")
|
||||
if(currmsg)
|
||||
currmsg.answer_callback.Invoke()
|
||||
|
||||
state = STATE_VIEWMESSAGE
|
||||
else
|
||||
if(!currmsg.answered)
|
||||
currmsg.answered = answer
|
||||
log_game("[key_name(usr)] answered [currmsg.title] comm message. Answer : [currmsg.answered]")
|
||||
if(currmsg)
|
||||
currmsg.answer_callback.InvokeAsync()
|
||||
state = STATE_VIEWMESSAGE
|
||||
updateDialog()
|
||||
if("status")
|
||||
state = STATE_STATUSDISPLAY
|
||||
if("securitylevel")
|
||||
@@ -291,7 +292,7 @@
|
||||
playsound(src, 'sound/machines/terminal_prompt_confirm.ogg', 50, 0)
|
||||
CentCom_announce(input, usr)
|
||||
to_chat(usr, "<span class='notice'>Message transmitted to Central Command.</span>")
|
||||
log_talk(usr,"[key_name(usr)] has made a CentCom announcement: [input]",LOGSAY)
|
||||
usr.log_talk(input, LOG_SAY, tag="CentCom announcement")
|
||||
deadchat_broadcast("<span class='deadsay'><span class='name'>[usr.real_name]</span> has messaged CentCom, \"[input]\" at <span class='name'>[get_area_name(usr, TRUE)]</span>.</span>", usr)
|
||||
CM.lastTimeUsed = world.time
|
||||
|
||||
@@ -308,7 +309,7 @@
|
||||
playsound(src, 'sound/machines/terminal_prompt_confirm.ogg', 50, 0)
|
||||
Syndicate_announce(input, usr)
|
||||
to_chat(usr, "<span class='danger'>SYSERR @l(19833)of(transmit.dm): !@$ MESSAGE TRANSMITTED TO SYNDICATE COMMAND.</span>")
|
||||
log_talk(usr,"[key_name(usr)] has made a Syndicate announcement: [input]",LOGSAY)
|
||||
usr.log_talk(input, LOG_SAY, tag="Syndicate announcement")
|
||||
deadchat_broadcast("<span class='deadsay'><span class='name'>[usr.real_name]</span> has messaged the Syndicate, \"[input]\" at <span class='name'>[get_area_name(usr, TRUE)]</span>.</span>", usr)
|
||||
CM.lastTimeUsed = world.time
|
||||
|
||||
@@ -328,7 +329,7 @@
|
||||
return
|
||||
Nuke_request(input, usr)
|
||||
to_chat(usr, "<span class='notice'>Request sent.</span>")
|
||||
log_talk(usr,"[key_name(usr)] has requested the nuclear codes from CentCom",LOGSAY)
|
||||
usr.log_message("has requested the nuclear codes from CentCom", LOG_SAY)
|
||||
priority_announce("The codes for the on-station nuclear self-destruct have been requested by [usr]. Confirmation or denial of this request will be sent shortly.", "Nuclear Self Destruct Codes Requested",'sound/ai/commandreport.ogg')
|
||||
CM.lastTimeUsed = world.time
|
||||
|
||||
@@ -366,11 +367,13 @@
|
||||
var/answer = text2num(href_list["answer"])
|
||||
if(!aicurrmsg || !answer || aicurrmsg.possible_answers.len < answer)
|
||||
aistate = STATE_MESSAGELIST
|
||||
aicurrmsg.answered = answer
|
||||
log_game("[key_name(usr)] answered [aicurrmsg.title] comm message. Answer : [aicurrmsg.answered]")
|
||||
if(aicurrmsg.answer_callback)
|
||||
aicurrmsg.answer_callback.Invoke()
|
||||
aistate = STATE_VIEWMESSAGE
|
||||
else
|
||||
if(!aicurrmsg.answered)
|
||||
aicurrmsg.answered = answer
|
||||
log_game("[key_name(usr)] answered [aicurrmsg.title] comm message. Answer : [aicurrmsg.answered]")
|
||||
if(aicurrmsg.answer_callback)
|
||||
aicurrmsg.answer_callback.InvokeAsync()
|
||||
aistate = STATE_VIEWMESSAGE
|
||||
if("ai-status")
|
||||
aistate = STATE_STATUSDISPLAY
|
||||
if("ai-announce")
|
||||
@@ -476,7 +479,7 @@
|
||||
if (authenticated==2)
|
||||
dat += "<BR><BR><B>Captain Functions</B>"
|
||||
dat += "<BR>\[ <A HREF='?src=[REF(src)];operation=announce'>Make a Captain's Announcement</A> \]"
|
||||
var/cross_servers_count = length(CONFIG_GET(keyed_string_list/cross_server))
|
||||
var/cross_servers_count = length(CONFIG_GET(keyed_list/cross_server))
|
||||
if(cross_servers_count)
|
||||
dat += "<BR>\[ <A HREF='?src=[REF(src)];operation=crossserver'>Send a message to [cross_servers_count == 1 ? "an " : ""]allied station[cross_servers_count > 1 ? "s" : ""]</A> \]"
|
||||
if(SSmapping.config.allow_custom_shuttles)
|
||||
|
||||
@@ -596,3 +596,4 @@
|
||||
icon_screen = "medlaptop"
|
||||
icon_keyboard = "laptop_key"
|
||||
clockwork = TRUE //it'd look weird
|
||||
pass_flags = PASSTABLE
|
||||
|
||||
@@ -136,7 +136,7 @@
|
||||
if(I && istype(I) && I.imp_in)
|
||||
var/mob/living/R = I.imp_in
|
||||
to_chat(R, "<span class='italics'>You hear a voice in your head saying: '[warning]'</span>")
|
||||
log_talk(usr,"[key_name(usr)] sent an implant message to [key_name(R)]: '[warning]'",LOGSAY)
|
||||
log_directed_talk(usr, R, warning, LOG_SAY, "implant message")
|
||||
|
||||
src.add_fingerprint(usr)
|
||||
src.updateUsrDialog()
|
||||
|
||||
@@ -38,6 +38,7 @@
|
||||
icon_screen = "seclaptop"
|
||||
icon_keyboard = "laptop_key"
|
||||
clockwork = TRUE //it'd look weird
|
||||
pass_flags = PASSTABLE
|
||||
|
||||
/obj/machinery/computer/secure_data/attackby(obj/item/O, mob/user, params)
|
||||
if(istype(O, /obj/item/card/id))
|
||||
|
||||
Reference in New Issue
Block a user