mirror of
https://github.com/Sandstorm-Station/Sandstorm-Station-13.git
synced 2026-07-23 06:04:41 +01:00
48 lines
1.5 KiB
Plaintext
48 lines
1.5 KiB
Plaintext
///SCI TELEPAD///
|
|
/obj/machinery/telepad
|
|
name = "telepad"
|
|
desc = "A bluespace telepad used for teleporting objects to and from a location."
|
|
icon = 'icons/obj/telescience.dmi'
|
|
icon_state = "pad-idle"
|
|
anchored = 1
|
|
use_power = 1
|
|
idle_power_usage = 200
|
|
active_power_usage = 5000
|
|
var/efficiency
|
|
|
|
/obj/machinery/telepad/Initialize()
|
|
. = ..()
|
|
var/obj/item/circuitboard/machine/B = new /obj/item/circuitboard/machine/telesci_pad(null)
|
|
B.apply_default_parts(src)
|
|
|
|
/obj/item/circuitboard/machine/telesci_pad
|
|
name = "Telepad (Machine Board)"
|
|
build_path = /obj/machinery/telepad
|
|
req_components = list(
|
|
/obj/item/stack/ore/bluespace_crystal = 2,
|
|
/obj/item/stock_parts/capacitor = 1,
|
|
/obj/item/stack/cable_coil = 1,
|
|
/obj/item/stack/sheet/glass = 1)
|
|
def_components = list(/obj/item/stack/ore/bluespace_crystal = /obj/item/stack/ore/bluespace_crystal/artificial)
|
|
|
|
/obj/machinery/telepad/RefreshParts()
|
|
var/E
|
|
for(var/obj/item/stock_parts/capacitor/C in component_parts)
|
|
E += C.rating
|
|
efficiency = E
|
|
|
|
/obj/machinery/telepad/attackby(obj/item/I, mob/user, params)
|
|
if(default_deconstruction_screwdriver(user, "pad-idle-o", "pad-idle", I))
|
|
return
|
|
if(panel_open)
|
|
if(istype(I, /obj/item/multitool))
|
|
var/obj/item/multitool/M = I
|
|
M.buffer = src
|
|
to_chat(user, "<span class='caution'>You save the data in the [I.name]'s buffer.</span>")
|
|
return 1
|
|
if(exchange_parts(user, I))
|
|
return
|
|
if(default_deconstruction_crowbar(I))
|
|
return
|
|
return ..()
|