mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-23 20:16:55 +01:00
Adds CI for simple pipe and unary connections (#26340)
* Adds CI for missing pipe connections * fix box * fix delta * fixes meta * partially fixes cere * yah * cere fix * holy shit * adds unary stuff too * im dumb * yeah
This commit is contained in:
@@ -154,3 +154,28 @@
|
||||
continue // same object, continue
|
||||
if(cable.d1 == other_cable.d1 && cable.d2 == other_cable.d2)
|
||||
Fail(T, "tile has duplicated cables.")
|
||||
|
||||
/datum/map_per_tile_test/missing_pipe_connection
|
||||
|
||||
/datum/map_per_tile_test/missing_pipe_connection/CheckTile(turf/T)
|
||||
var/obj/machinery/atmospherics/pipe/simple/pipe = locate() in T.contents
|
||||
if(isnull(pipe))
|
||||
return
|
||||
if(!pipe.node1 && !pipe.node2)
|
||||
Fail(T, "[pipe] ([pipe.type]) missing both nodes.")
|
||||
return
|
||||
if(istype(pipe, /obj/machinery/atmospherics/pipe/simple/heat_exchanging) && (pipe.node1 || pipe.node2))
|
||||
return // H/E pipes only need one end, because they don't always become full loops
|
||||
if(!pipe.node1)
|
||||
Fail(T, "[pipe] ([pipe.type]) missing node1. ([uppertext(dir2text(pipe.initialize_directions & ~(get_dir(pipe, pipe.node2))))])")
|
||||
if(!pipe.node2)
|
||||
Fail(T, "[pipe] ([pipe.type]) missing node2. ([uppertext(dir2text(pipe.initialize_directions & ~(get_dir(pipe, pipe.node1))))])")
|
||||
|
||||
/datum/map_per_tile_test/unary_device_connection
|
||||
|
||||
/datum/map_per_tile_test/unary_device_connection/CheckTile(turf/T)
|
||||
var/obj/machinery/atmospherics/unary/unary_device = locate() in T.contents
|
||||
if(isnull(unary_device))
|
||||
return
|
||||
if(!unary_device.node)
|
||||
Fail(T, "[unary_device] ([unary_device.type]) missing node. ([uppertext(dir2text(unary_device.dir))])")
|
||||
|
||||
Reference in New Issue
Block a user