Merge pull request #12563 from kevinz000/shuttles

fixes master (shuttles not loading)
This commit is contained in:
nik707
2020-06-18 10:41:20 -05:00
committed by GitHub
7 changed files with 49 additions and 22 deletions

View File

@@ -872,6 +872,14 @@
/atom/proc/GenerateTag()
return
/**
* Called after a shuttle is loaded **from map template initially**.
*
* @params
* * port - Mobile port/shuttle
* * dock - Stationary dock the shuttle's at
* * idnum - ID number of the shuttle
*/
/atom/proc/connect_to_shuttle(obj/docking_port/mobile/port, obj/docking_port/stationary/dock, idnum, override=FALSE)
return

View File

@@ -35,11 +35,6 @@
M.unset_machine() //to properly reset the view of the users if the console is deleted.
return ..()
/obj/machinery/computer/security/connect_to_shuttle(obj/docking_port/mobile/port, obj/docking_port/stationary/dock, idnum, override=FALSE)
for(var/i in network)
network -= i
network += "[idnum][i]"
/obj/machinery/computer/security/can_interact(mob/user)
if((!hasSiliconAccessInArea(user) && !Adjacent(user)) || is_blind(user) || !in_view_range(user, src))
return FALSE
@@ -262,3 +257,12 @@
name = "AI upload monitor"
desc = "A telescreen that connects to the AI upload's camera network."
network = list("aiupload")
// Subtype that connects to shuttles.
/obj/machinery/computer/security/shuttle
circuit = /obj/item/circuitboard/computer/security/shuttle
/obj/machinery/computer/security/shuttle/connect_to_shuttle(obj/docking_port/mobile/port, obj/docking_port/stationary/dock, idnum, override=FALSE)
for(var/i in network)
network -= i
network += "[idnum][i]"

View File

@@ -57,7 +57,16 @@
. = ..()
check_setup()
/obj/machinery/shuttle/engine/Destroy()
attached_heater = FALSE
thruster_active = FALSE
return ..()
/obj/machinery/shuttle/engine/proc/check_setup()
if(!anchored)
attached_heater = null
update_engine()
return
var/heater_turf
switch(dir)
if(NORTH)
@@ -124,15 +133,6 @@
env.temperature += deltaTemperature
air_update_turf()
/obj/machinery/shuttle/engine/attackby(obj/item/I, mob/living/user, params)
check_setup()
if(default_deconstruction_screwdriver(user, icon_state_open, icon_state_closed, I))
return
if(default_pry_open(I))
return
if(panel_open)
if(default_change_direction_wrench(user, I))
return
if(default_deconstruction_crowbar(I))
return
return ..()
/obj/machinery/shuttle/engine/default_change_direction_wrench(mob/user, obj/item/I)
. = ..()
update_engine()

View File

@@ -14,6 +14,10 @@
name = "Security Cameras (Computer Board)"
build_path = /obj/machinery/computer/security
/obj/item/circuitboard/computer/security/shuttle
name = "Shuttlelinking Security Cameras (Computer Board)"
build_path = /obj/machinery/computer/security/shuttle
/obj/item/circuitboard/computer/xenobiology
name = "circuit board (Xenobiology Console)"
build_path = /obj/machinery/computer/camera_advanced/xenobio