mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-23 20:16:55 +01:00
@@ -2,28 +2,8 @@
|
||||
Rapid Pipe Dispenser
|
||||
*/
|
||||
|
||||
#define SIMPLE_CAP 20
|
||||
#define SUPPLY_CAP 32
|
||||
#define SCRUBBERS_CAP 33
|
||||
#define HE_EXCHANGER 17
|
||||
#define CONNECTOR 4
|
||||
#define UNARY_VENT 7
|
||||
#define PASSIVE_VENT 37
|
||||
#define GAS_SCRUBBER 10
|
||||
#define INJECTOR 34
|
||||
#define GAS_SENSOR 98
|
||||
#define METER 99
|
||||
#define DISPOSALS_JUNCTION 2
|
||||
#define ATMOS_MODE 1
|
||||
#define DISPOSALS_MODE 2
|
||||
#define ROTATION_MODE 3
|
||||
#define FLIP_MODE 4
|
||||
#define DELETE_MODE 5
|
||||
#define ATMOS_PIPING 1
|
||||
#define SUPPLY_PIPING 2
|
||||
#define SCRUBBERS_PIPING 3
|
||||
#define DEVICES 4
|
||||
#define HEAT_PIPING 5
|
||||
#define RPD_COOLDOWN_TIME 4 //How long should we have to wait between dispensing pipes?
|
||||
#define RPD_WALLBUILD_TIME 40 //How long should drilling into a wall take?
|
||||
|
||||
/obj/item/rpd
|
||||
name = "rapid pipe dispenser"
|
||||
@@ -43,13 +23,13 @@
|
||||
origin_tech = "engineering=4;materials=2"
|
||||
var/datum/effect_system/spark_spread/spark_system
|
||||
var/lastused
|
||||
var/iconrotation = 0 //used to orient icons and pipes
|
||||
var/mode = 1 //Disposals, atmospherics, etc.
|
||||
var/pipetype = 1//For nanoUI menus
|
||||
var/whatpipe = 0 //What kind of pipe is it? See code/game/machinery/pipe/construction.dm for a list of defines
|
||||
var/whatdpipe = 0 //What kind of disposals pipe is it? See code/game/machinery/pipe/dispenser.dm for a list of defines
|
||||
var/spawndelay = 4 //How long should we have to wait between dispensing pipes?
|
||||
var/walldelay = 40 //How long should drilling into a wall take?
|
||||
var/iconrotation = 0 //Used to orient icons and pipes
|
||||
var/mode = RPD_ATMOS_MODE //Disposals, atmospherics, etc.
|
||||
var/pipe_category = RPD_ATMOS_PIPING//For nanoUI menus, this is a subtype of pipes e.g. scrubbers pipes, devices
|
||||
var/whatpipe = PIPE_SIMPLE_STRAIGHT //What kind of atmos pipe is it?
|
||||
var/whatdpipe = PIPE_DISPOSALS_STRAIGHT //What kind of disposals pipe is it?
|
||||
var/spawndelay = RPD_COOLDOWN_TIME
|
||||
var/walldelay = RPD_WALLBUILD_TIME
|
||||
|
||||
/obj/item/rpd/New()
|
||||
..()
|
||||
@@ -57,82 +37,112 @@
|
||||
spark_system.set_up(1, 0, src)
|
||||
spark_system.attach(src)
|
||||
|
||||
/obj/item/rpd/Destroy()
|
||||
QDEL_NULL(spark_system)
|
||||
return ..()
|
||||
|
||||
//Procs
|
||||
|
||||
/obj/item/rpd/proc/Activaterpd(delay)
|
||||
/obj/item/rpd/proc/activate_rpd(delay) //Maybe makes sparks and activates cooldown if there is a delay
|
||||
playsound(loc, "sound/machines/click.ogg", 50, 1)
|
||||
if(prob(15))
|
||||
spark_system.start()
|
||||
if(delay)
|
||||
lastused = world.time
|
||||
|
||||
/obj/item/rpd/proc/Manipulatepipes(subject, atmosverb, disposalsverb)
|
||||
if(istype(subject, /obj/item/pipe))
|
||||
call(subject, atmosverb)()
|
||||
else if(istype(subject, /obj/structure/disposalconstruct/))
|
||||
call(subject, disposalsverb)()
|
||||
/obj/item/rpd/proc/can_dispense_pipe(var/pipe_id, var/pipe_type) //Returns TRUE if this is a legit pipe we can dispense, otherwise returns FALSE
|
||||
for(var/list/L in GLOB.rpd_pipe_list)
|
||||
if(pipe_type != L["pipe_type"]) //Sometimes pipes in different categories have the same pipe_id, so we need to skip anything not in the category we want
|
||||
continue
|
||||
if(pipe_id == L["pipe_id"]) //Found the pipe, we can dispense it
|
||||
return TRUE
|
||||
|
||||
/obj/item/rpd/proc/create_atmos_pipe(mob/user, turf/T) //Make an atmos pipe, meter, or gas sensor
|
||||
if(!can_dispense_pipe(whatpipe, RPD_ATMOS_MODE))
|
||||
log_runtime(EXCEPTION("Failed to spawn [get_pipe_name(whatpipe, PIPETYPE_ATMOS)] - possible tampering detected")) //Damn dirty apes -- I mean hackers
|
||||
return
|
||||
var/obj/item/pipe/P
|
||||
if(whatpipe == PIPE_GAS_SENSOR)
|
||||
P = new /obj/item/pipe_gsensor(T)
|
||||
else if(whatpipe == PIPE_METER)
|
||||
P = new /obj/item/pipe_meter(T)
|
||||
else
|
||||
P = new(T, whatpipe, iconrotation) //Make the pipe, BUT WAIT! There's more!
|
||||
if(!iconrotation && P.is_bent_pipe()) //Automatically rotates dispensed pipes if the user selected auto-rotation
|
||||
P.dir = turn(user.dir, 135)
|
||||
else if(!iconrotation && P.pipe_type in list(PIPE_CONNECTOR, PIPE_UVENT, PIPE_SCRUBBER, PIPE_HEAT_EXCHANGE, PIPE_CAP, PIPE_SUPPLY_CAP, PIPE_SCRUBBERS_CAP, PIPE_INJECTOR, PIPE_PASV_VENT)) //Some pipes dispense oppositely to what you'd expect, but we don't want to do anything if they selected a direction
|
||||
P.flip()
|
||||
else if(iconrotation && P.is_bent_pipe()) //If user selected a rotation and the pipe is bent
|
||||
P.dir = turn(iconrotation, -45)
|
||||
else if(!iconrotation) //If user selected a rotation
|
||||
P.dir = user.dir
|
||||
to_chat(user, "<span class='notice'>[src] rapidly dispenses [P]!</span>")
|
||||
activate_rpd(TRUE)
|
||||
|
||||
/obj/item/rpd/proc/create_disposals_pipe(mob/user, turf/T) //Make a disposals pipe / construct
|
||||
if(!can_dispense_pipe(whatdpipe, RPD_DISPOSALS_MODE))
|
||||
log_runtime(EXCEPTION("Failed to spawn [get_pipe_name(whatdpipe, PIPETYPE_DISPOSAL)] - possible tampering detected"))
|
||||
return
|
||||
var/obj/structure/disposalconstruct/P = new(T, whatdpipe, iconrotation)
|
||||
if(!iconrotation) //Automatic rotation
|
||||
P.dir = user.dir
|
||||
if(!iconrotation && whatdpipe != PIPE_DISPOSALS_JUNCTION_RIGHT) //Disposals pipes are in the opposite direction to atmos pipes, so we need to flip them. Junctions don't have this quirk though
|
||||
P.flip()
|
||||
to_chat(user, "<span class='notice'>[src] rapidly dispenses [P]!</span>")
|
||||
activate_rpd(TRUE)
|
||||
|
||||
/obj/item/rpd/proc/rotate_all_pipes(mob/user, turf/T) //Rotate all pipes on a turf
|
||||
for(var/obj/item/pipe/P in T)
|
||||
P.rotate()
|
||||
for(var/obj/structure/disposalconstruct/D in T)
|
||||
D.rotate()
|
||||
|
||||
/obj/item/rpd/proc/flip_all_pipes(mob/user, turf/T) //Flip all pipes on a turf
|
||||
for(var/obj/item/pipe/P in T)
|
||||
P.flip()
|
||||
for(var/obj/structure/disposalconstruct/D in T)
|
||||
D.flip()
|
||||
|
||||
/obj/item/rpd/proc/delete_all_pipes(mob/user, turf/T) //Delete all pipes on a turf
|
||||
var/eaten
|
||||
for(var/obj/item/pipe/P in T)
|
||||
QDEL_NULL(P)
|
||||
eaten = TRUE
|
||||
for(var/obj/item/pipe_gsensor/G in T)
|
||||
QDEL_NULL(G)
|
||||
eaten = TRUE
|
||||
for(var/obj/item/pipe_meter/M in T)
|
||||
QDEL_NULL(M)
|
||||
eaten = TRUE
|
||||
for(var/obj/structure/disposalconstruct/D in T)
|
||||
if(!D.anchored)
|
||||
QDEL_NULL(D)
|
||||
eaten = TRUE
|
||||
if(eaten)
|
||||
to_chat(user, "<span class='notice'>[src] sucks up the loose pipes on [T].")
|
||||
activate_rpd()
|
||||
else
|
||||
to_chat(user, "<span class='notice'>There were no loose pipes on [T].</span>")
|
||||
|
||||
/obj/item/rpd/proc/delete_single_pipe(mob/user, obj/P) //Delete a single pipe
|
||||
to_chat(user, "<span class='notice'>[src] sucks up [P].</span>")
|
||||
QDEL_NULL(P)
|
||||
activate_rpd()
|
||||
|
||||
//Lists of things
|
||||
|
||||
var/list/pipelist = list( //id refers to the pipe_type found in construction.dm, icon refers to the name of the icon state in icons/obj/pipe-item.dmi. Icons are made with the asset-cache
|
||||
list("pipename" = "Straight pipe", "id" = 0, "category" = ATMOS_PIPING, "orientations" = 2, "icon" = "simple"),
|
||||
list("pipename" = "Bent pipe", "id" = 1, "category" = ATMOS_PIPING, "orientations" = 4, "icon" = "simple", "bendy" = 1),
|
||||
list("pipename" = "T-manifold", "id" = 5, "category" = ATMOS_PIPING, "orientations" = 4, "icon" = "manifold"),
|
||||
list("pipename" = "4-way manifold", "id" = 19, "category" = ATMOS_PIPING, "orientations" = 1, "icon" = "manifold4w"),
|
||||
list("pipename" = "Pipe cap", "id" = 20, "category" = ATMOS_PIPING, "orientations" = 4, "icon" = "cap"),
|
||||
list("pipename" = "Manual valve", "id" = 8, "category" = ATMOS_PIPING, "orientations" = 2, "icon" = "mvalve"),
|
||||
list("pipename" = "Digital valve", "id" = 35, "category" = ATMOS_PIPING, "orientations" = 2, "icon" = "dvalve"),
|
||||
list("pipename" = "Manual T-valve", "id" = 18, "category" = ATMOS_PIPING, "orientations" = 4, "icon" = "tvalve"),
|
||||
list("pipename" = "Digital T-valve", "id" = 38, "category" = ATMOS_PIPING, "orientations" = 4, "icon" = "dtvalve"),
|
||||
list("pipename" = "Straight supply pipe", "id" = 24, "category" = SUPPLY_PIPING, "orientations" = 2, "icon" = "simple"),
|
||||
list("pipename" = "Bent supply pipe", "id" = 25, "category" = SUPPLY_PIPING, "orientations" = 4, "icon" = "simple", "bendy" = 1),
|
||||
list("pipename" = "Supply T-manifold", "id" = 28, "category" = SUPPLY_PIPING, "orientations" = 4, "icon" = "manifold"),
|
||||
list("pipename" = "4-way supply manifold", "id" = 30, "category" = SUPPLY_PIPING, "orientations" = 1, "icon" = "manifold4w"),
|
||||
list("pipename" = "Supply pipe cap", "id" = 32, "category" = SUPPLY_PIPING, "orientations" = 4, "icon" = "cap"),
|
||||
list("pipename" = "Straight scrubbers pipe", "id" = 26, "category" = SCRUBBERS_PIPING, "orientations" = 2, "icon" = "simple"),
|
||||
list("pipename" = "Bent scrubbers pipe", "id" = 27, "category" = SCRUBBERS_PIPING, "orientations" = 4, "icon" = "simple", "bendy" = 1),
|
||||
list("pipename" = "Scrubbers T-manifold", "id" = 29, "category" = SCRUBBERS_PIPING, "orientations" = 4, "icon" = "manifold"),
|
||||
list("pipename" = "4-way scrubbers manifold", "id" = 31, "category" = SCRUBBERS_PIPING, "orientations" = 1, "icon" = "manifold4w"),
|
||||
list("pipename" = "Scrubbers pipe cap", "id" = 33, "category" = SCRUBBERS_PIPING, "orientations" = 4, "icon" = "cap"),
|
||||
list("pipename" = "Universal pipe adapter", "id" = 23, "category" = DEVICES, "orientations" = 2, "icon" = "universal"),
|
||||
list("pipename" = "Connector", "id" = 4, "category" = DEVICES, "orientations" = 4, "icon" = "connector"),
|
||||
list("pipename" = "Unary vent", "id" = 7, "category" = DEVICES, "orientations" = 4, "icon" = "uvent"),
|
||||
list("pipename" = "Scrubber", "id" = 10, "category" = DEVICES, "orientations" = 4, "icon" = "scrubber"),
|
||||
list("pipename" = "Gas pump", "id" = 9, "category" = DEVICES, "orientations" = 4, "icon" = "pump"),
|
||||
list("pipename" = "Volume pump", "id" = 16, "category" = DEVICES, "orientations" = 4, "icon" = "volumepump"),
|
||||
list("pipename" = "Passive gate", "id" = 15, "category" = DEVICES, "orientations" = 4, "icon" = "passivegate"),
|
||||
list("pipename" = "Gas filter", "id" = 13, "category" = DEVICES, "orientations" = 4, "icon" = "filter"),
|
||||
list("pipename" = "Gas mixer", "id" = 14, "category" = DEVICES, "orientations" = 4, "icon" = "mixer"),
|
||||
list("pipename" = "Gas sensor", "id" = 98, "category" = DEVICES, "orientations" = 1, "icon" = "sensor"),
|
||||
list("pipename" = "Meter", "id" = 99, "category" = DEVICES, "orientations" = 1, "icon" = "meter"),
|
||||
list("pipename" = "Passive vent", "id" = 37, "category" = DEVICES, "orientations" = 4, "icon" = "passive vent"),
|
||||
list("pipename" = "Dual-port vent pump", "id" = 36, "category" = DEVICES, "orientations" = 2, "icon" = "dual-port vent"),
|
||||
list("pipename" = "Air injector", "id" = 34, "category" = DEVICES, "orientations" = 4, "icon" = "injector"),
|
||||
list("pipename" = "Straight HE pipe", "id" = 2, "category" = HEAT_PIPING, "orientations" = 2, "icon" = "he"),
|
||||
list("pipename" = "Bent HE pipe", "id" = 3, "category" = HEAT_PIPING, "orientations" = 4, "icon" = "he", "bendy" = 1),
|
||||
list("pipename" = "Junction", "id" = 6, "category" = HEAT_PIPING, "orientations" = 4, "icon" = "junction"),
|
||||
list("pipename" = "Heat exchanger", "id" = 17, "category" = HEAT_PIPING, "orientations" = 4, "icon" = "heunary"))
|
||||
var/list/dpipelist = list(
|
||||
list("pipename" = "Straight pipe", "id" = 0, "orientations" = 2, "icon" = "conpipe-s"),
|
||||
list("pipename" = "Bent pipe", "id" = 1, "orientations" = 4, "icon" = "conpipe-c"),
|
||||
list("pipename" = "Junction", "id" = 2, "orientations" = 4, "icon" = "conpipe-j1"),
|
||||
list("pipename" = "Y-junction", "id" = 4, "orientations" = 4, "icon" = "conpipe-y"),
|
||||
list("pipename" = "Trunk", "id" = 5, "orientations" = 4, "icon" = "conpipe-t"),
|
||||
list("pipename" = "Bin", "id" = 6, "orientations" = 1, "icon" = "condisposal"),
|
||||
list("pipename" = "Outlet", "id" = 7, "orientations" = 4, "icon" = "outlet"),
|
||||
list("pipename" = "Chute", "id" = 8, "orientations" = 4, "icon" = "intake"))
|
||||
var/list/mainmenu = list(
|
||||
list("category" = "Atmospherics", "mode" = 1, "icon" = "wrench"),
|
||||
list("category" = "Disposals", "mode" = 2, "icon" = "recycle"),
|
||||
list("category" = "Rotate", "mode" = 3, "icon" = "rotate-right"),
|
||||
list("category" = "Flip", "mode" = 4, "icon" = "exchange"),
|
||||
list("category" = "Recycle", "mode" = 5, "icon" = "trash"))
|
||||
list("category" = "Atmospherics", "mode" = RPD_ATMOS_MODE, "icon" = "wrench"),
|
||||
list("category" = "Disposals", "mode" = RPD_DISPOSALS_MODE, "icon" = "recycle"),
|
||||
list("category" = "Rotate", "mode" = RPD_ROTATE_MODE, "icon" = "rotate-right"),
|
||||
list("category" = "Flip", "mode" = RPD_FLIP_MODE, "icon" = "exchange"),
|
||||
list("category" = "Recycle", "mode" = RPD_DELETE_MODE, "icon" = "trash"))
|
||||
var/list/pipemenu = list(
|
||||
list("pipecategory" = "Normal", "pipemode" = 1),
|
||||
list("pipecategory" = "Supply", "pipemode" = 2),
|
||||
list("pipecategory" = "Scrubber", "pipemode" = 3),
|
||||
list("pipecategory" = "Devices", "pipemode" = 4),
|
||||
list("pipecategory" = "Heat exchange", "pipemode" = 5))
|
||||
list("category" = "Normal", "pipemode" = RPD_ATMOS_PIPING),
|
||||
list("category" = "Supply", "pipemode" = RPD_SUPPLY_PIPING),
|
||||
list("category" = "Scrubber", "pipemode" = RPD_SCRUBBERS_PIPING),
|
||||
list("category" = "Devices", "pipemode" = RPD_DEVICES),
|
||||
list("category" = "Heat exchange", "pipemode" = RPD_HEAT_PIPING))
|
||||
|
||||
//NanoUI stuff
|
||||
|
||||
@@ -148,13 +158,12 @@ var/list/pipemenu = list(
|
||||
|
||||
/obj/item/rpd/ui_data(mob/user, ui_key = "main", datum/topic_state/state = inventory_state)
|
||||
var/data[0]
|
||||
data["dpipelist"] = dpipelist
|
||||
data["iconrotation"] = iconrotation
|
||||
data["mainmenu"] = mainmenu
|
||||
data["mode"] = mode
|
||||
data["pipelist"] = pipelist
|
||||
data["pipelist"] = GLOB.rpd_pipe_list
|
||||
data["pipemenu"] = pipemenu
|
||||
data["pipetype"] = pipetype
|
||||
data["pipe_category"] = pipe_category
|
||||
data["whatdpipe"] = whatdpipe
|
||||
data["whatpipe"] = whatpipe
|
||||
return data
|
||||
@@ -167,99 +176,23 @@ var/list/pipemenu = list(
|
||||
whatpipe = text2num(sanitize(href_list["whatpipe"]))
|
||||
else if(href_list["whatdpipe"])
|
||||
whatdpipe = text2num(sanitize(href_list["whatdpipe"]))
|
||||
else if(href_list["pipetype"])
|
||||
pipetype = text2num(sanitize(href_list["pipetype"]))
|
||||
else if(href_list["pipe_category"])
|
||||
pipe_category = text2num(sanitize(href_list["pipe_category"]))
|
||||
else if(href_list["mode"])
|
||||
mode = text2num(sanitize(href_list["mode"]))
|
||||
else
|
||||
return
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
//What the RPD actually does
|
||||
|
||||
/obj/item/rpd/afterattack(atom/target, mob/user, proximity)
|
||||
..()
|
||||
var/turf/T = get_turf(target)
|
||||
if(loc != user || ismob(target) || istype(target, /obj/structure/window) || !proximity || world.time < lastused + spawndelay)
|
||||
if(loc != user)
|
||||
return
|
||||
if(!(T.flags & RPD_ALLOWED_HERE))
|
||||
to_chat(user, "<span class='notice'>[src] beeps, \"Unable to interface with [T]. Please try again later.\"</span>")
|
||||
if(!proximity)
|
||||
return
|
||||
if(mode == ATMOS_MODE)
|
||||
if(istype(T, /turf/simulated/wall)) //Drilling into walls takes time
|
||||
playsound(loc, "sound/weapons/circsawhit.ogg", 50, 1)
|
||||
user.visible_message("<span class = 'notice'>[user] starts drilling a hole in [T]...</span>", "<span class = 'notice'>You start drilling a hole in [T]...</span>", "<span class = 'warning'>You hear a drill.</span>")
|
||||
if(!do_after(user, walldelay, target = T))
|
||||
return
|
||||
user.visible_message("<span class = 'notice'>[user] finishes drilling a hole in [T]!</span>", "<span class = 'notice'>You finish drilling a hole in [T]!</span>", "<span class = 'warning'>You hear clanking.</span>")
|
||||
var/obj/item/pipe/P
|
||||
if(whatpipe == GAS_SENSOR)
|
||||
P = new /obj/item/pipe_gsensor(T)
|
||||
else if(whatpipe == METER)
|
||||
P = new /obj/item/pipe_meter(T)
|
||||
else
|
||||
P = new(T, pipe_type = whatpipe, dir = user.dir)
|
||||
if(iconrotation == 0 && P.is_bent_pipe()) //Automatic rotation of dispensed pipes
|
||||
P.dir = turn(user.dir, 135)
|
||||
else if(iconrotation == 0 && P.pipe_type in list(CONNECTOR, UNARY_VENT, GAS_SCRUBBER, HE_EXCHANGER, SIMPLE_CAP, SUPPLY_CAP, SCRUBBERS_CAP, INJECTOR, PASSIVE_VENT)) //Some pipes dispense oppositely to what you'd expect, but we don't want to do anything if they selected a direction
|
||||
P.flip()
|
||||
else if(iconrotation != 0 && P.is_bent_pipe()) //If they selected a rotation and the pipe is bent
|
||||
P.dir = turn(iconrotation, -45)
|
||||
else if(iconrotation != 0)
|
||||
P.dir = iconrotation
|
||||
to_chat(user, "<span class = 'notice'>[src] rapidly dispenses [P]!</span>")
|
||||
Activaterpd(1)
|
||||
else if(mode == DISPOSALS_MODE && !istype(T, /turf/simulated/shuttle))
|
||||
if(istype(T, /turf/simulated/wall)) //No disposals pipes on walls
|
||||
to_chat(user, "<span class = 'warning'>That type of pipe won't fit on [T]!</span>")
|
||||
return
|
||||
var/obj/structure/disposalconstruct/P = new(T) //Now we make the pipe
|
||||
P.dir = iconrotation
|
||||
P.ptype = whatdpipe
|
||||
if(iconrotation == 0) //Automatic rotation
|
||||
P.dir = user.dir
|
||||
if(iconrotation == 0 && whatdpipe != DISPOSALS_JUNCTION) //Disposals pipes are in the opposite direction to atmos pipes, so we need to flip them. Junctions don't have this quirk though
|
||||
P.flip()
|
||||
P.update()
|
||||
to_chat(user, "<span class = 'notice'>[src] rapidly dispenses [P]!</span>")
|
||||
Activaterpd(1)
|
||||
else if(mode == ROTATION_MODE)
|
||||
for(var/obj/W in T)
|
||||
Manipulatepipes(W, /obj/item/pipe/verb/rotate, /obj/structure/disposalconstruct/verb/rotate)
|
||||
else if(mode == FLIP_MODE)
|
||||
for(var/obj/W in T)
|
||||
Manipulatepipes(W, /obj/item/pipe/verb/flip, /obj/structure/disposalconstruct/verb/flip)
|
||||
else if(mode == DELETE_MODE)
|
||||
var/eaten
|
||||
for(var/obj/W in T)
|
||||
if(istype(W, /obj/item/pipe) || istype(W, /obj/item/pipe_meter) || istype(W, /obj/item/pipe_gsensor) || istype(W, /obj/structure/disposalconstruct) && !W.anchored)
|
||||
QDEL_NULL(W)
|
||||
eaten = TRUE
|
||||
if(eaten)
|
||||
to_chat(user, "<span class='notice'>[src] sucks up the loose pipes on [T].")
|
||||
Activaterpd()
|
||||
else
|
||||
to_chat(user, "<span class='notice'>There were no loose pipes on [T].</span>")
|
||||
if(world.time < lastused + spawndelay)
|
||||
return
|
||||
target.rpd_act(user, src) //Handle RPD effects in separate procs
|
||||
|
||||
#undef SIMPLE_CAP
|
||||
#undef SUPPLY_CAP
|
||||
#undef SCRUBBERS_CAP
|
||||
#undef HE_EXCHANGER
|
||||
#undef CONNECTOR
|
||||
#undef UNARY_VENT
|
||||
#undef PASSIVE_VENT
|
||||
#undef GAS_SCRUBBER
|
||||
#undef INJECTOR
|
||||
#undef GAS_SENSOR
|
||||
#undef METER
|
||||
#undef DISPOSALS_JUNCTION
|
||||
#undef ATMOS_MODE
|
||||
#undef DISPOSALS_MODE
|
||||
#undef ROTATION_MODE
|
||||
#undef FLIP_MODE
|
||||
#undef DELETE_MODE
|
||||
#undef ATMOS_PIPING
|
||||
#undef SUPPLY_PIPING
|
||||
#undef SCRUBBERS_PIPING
|
||||
#undef DEVICES
|
||||
#undef HEAT_PIPING
|
||||
#undef RPD_COOLDOWN_TIME
|
||||
#undef RPD_WALLBUILD_TIME
|
||||
|
||||
@@ -69,6 +69,10 @@
|
||||
SSnanoui.close_uis(src)
|
||||
return ..()
|
||||
|
||||
/obj/rpd_act(mob/user, obj/item/rpd/our_rpd)
|
||||
var/turf/T = get_turf(src) //This preserves RPD behaviour on specific turfs
|
||||
T.rpd_act(user, our_rpd)
|
||||
|
||||
/obj/proc/process()
|
||||
set waitfor = 0
|
||||
processing_objects.Remove(src)
|
||||
|
||||
@@ -123,6 +123,9 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f
|
||||
new/obj/structure/window/reinforced/clockwork/fulltile(get_turf(src))
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/window/rpd_act()
|
||||
return
|
||||
|
||||
/obj/structure/window/singularity_pull(S, current_size)
|
||||
if(current_size >= STAGE_FIVE)
|
||||
deconstruct(FALSE)
|
||||
|
||||
Reference in New Issue
Block a user