refactor: Allow using access helpers for airlock spawners. (#26141)

* Allow access helpers for airlock spawners.

* whoops

* whitespace

* add visual access helper placement indicator
This commit is contained in:
warriorstar-orion
2024-07-23 08:51:14 +00:00
committed by GitHub
parent a04ac32b09
commit 98f0931c14
12 changed files with 183 additions and 179 deletions
@@ -200,6 +200,15 @@
},
/turf/space,
/area/space)
"ft" = (
/obj/structure/cable{
d1 = 1;
d2 = 2;
icon_state = "1-2"
},
/obj/effect/mapping_helpers/airlock/access/all/engineering/equipment,
/turf/simulated/floor/plating,
/area/ruin/space/powered/casino/engine)
"fG" = (
/obj/machinery/atmospherics/pipe/simple/hidden{
dir = 10
@@ -389,9 +398,7 @@
/turf/simulated/floor/mineral/titanium/blue/airless,
/area/ruin/space/powered/casino/docked_ships)
"jh" = (
/obj/machinery/light/small{
dir = 2
},
/obj/machinery/light/small,
/obj/structure/cable{
d1 = 4;
d2 = 8;
@@ -1035,7 +1042,7 @@
/turf/simulated/floor/plating,
/area/ruin/space/powered/casino/maints)
"Aw" = (
/obj/effect/spawner/airlock/engineer,
/obj/effect/spawner/airlock,
/turf/simulated/wall,
/area/ruin/space/powered/casino/floor)
"AF" = (
@@ -1166,7 +1173,6 @@
/area/ruin/space/powered/casino/maints)
"DL" = (
/obj/machinery/light{
dir = 2;
brightness_color = "#FF0000";
color = "#FF0000"
},
@@ -3465,7 +3471,7 @@ mp
Eq
fG
jS
jS
ft
jS
wo
Xe
@@ -283,9 +283,7 @@
/turf/simulated/floor/wood,
/area/ruin/space/powered)
"Ed" = (
/obj/effect/spawner/airlock/w_to_e{
req_access_txt = 0
},
/obj/effect/spawner/airlock/w_to_e,
/turf/simulated/wall,
/area/ruin/space/powered)
"EQ" = (
@@ -7534,9 +7534,7 @@
/turf/simulated/floor/plasteel/dark,
/area/ruin/space/derelict/crew_quarters)
"Nv" = (
/obj/effect/spawner/airlock{
req_access_txt = 0
},
/obj/effect/spawner/airlock,
/turf/simulated/wall/mineral/titanium/nodecon/nodiagonal,
/area/ruin/space/derelict/arrival)
"NK" = (
@@ -7547,9 +7545,7 @@
/turf/template_noop,
/area/template_noop)
"Oh" = (
/obj/effect/spawner/airlock/w_to_e{
req_access_txt = 0
},
/obj/effect/spawner/airlock/w_to_e,
/turf/simulated/wall/mineral/titanium/nodecon/nodiagonal,
/area/ruin/space/derelict/crew_quarters)
"PR" = (
@@ -7569,9 +7565,7 @@
},
/area/ruin/space/derelict/arrival)
"Ud" = (
/obj/effect/spawner/airlock{
req_access_txt = 0
},
/obj/effect/spawner/airlock,
/turf/simulated/wall/mineral/titanium/nodecon,
/area/ruin/space/derelict/arrival)
"Xn" = (
@@ -18,9 +18,7 @@
/turf/simulated/floor/mineral/titanium/blue,
/area/shuttle/abandoned)
"em" = (
/obj/effect/spawner/airlock/w_to_e/long/square{
req_access_txt = null
},
/obj/effect/spawner/airlock/w_to_e/long/square,
/turf/simulated/wall/mineral/titanium,
/area/shuttle/abandoned)
"eo" = (
@@ -95,9 +93,7 @@
/area/shuttle/abandoned)
"nC" = (
/obj/structure/table,
/obj/item/storage/firstaid/regular{
pixel_y = 0
},
/obj/item/storage/firstaid/regular,
/turf/simulated/floor/mineral/titanium/blue,
/area/shuttle/abandoned)
"oh" = (
+88 -40
View File
@@ -24941,9 +24941,7 @@
},
/area/station/hallway/primary/central/west)
"bzN" = (
/obj/effect/spawner/airlock/w_to_e/long{
req_access_txt = 32
},
/obj/effect/spawner/airlock/w_to_e/long,
/turf/simulated/wall/r_wall,
/area/station/engineering/ai_transit_tube)
"bzO" = (
@@ -28848,6 +28846,15 @@
"bOU" = (
/turf/simulated/wall,
/area/station/medical/chemistry)
"bOY" = (
/obj/structure/cable{
d1 = 1;
d2 = 2;
icon_state = "1-2"
},
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/auxsolarport)
"bPd" = (
/obj/effect/turf_decal/stripes/line{
dir = 4
@@ -51410,7 +51417,7 @@
/area/station/medical/sleeper)
"dvb" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/e_to_w/arrivals,
/obj/effect/spawner/airlock/e_to_w,
/turf/simulated/floor/plating,
/area/station/hallway/secondary/entry/north)
"dvv" = (
@@ -54725,9 +54732,7 @@
/area/station/hallway/primary/aft/south)
"eXd" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/s_to_n/engineer{
req_access_txt = 13
},
/obj/effect/spawner/airlock/s_to_n,
/turf/simulated/floor/plating,
/area/station/maintenance/auxsolarstarboard)
"eXy" = (
@@ -64219,6 +64224,15 @@
},
/turf/simulated/floor/plasteel,
/area/station/medical/storage)
"jCt" = (
/obj/structure/cable{
d1 = 4;
d2 = 8;
icon_state = "4-8"
},
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/portsolar)
"jCu" = (
/obj/machinery/economy/vending/scidrobe,
/turf/simulated/floor/plasteel{
@@ -64713,9 +64727,7 @@
/turf/simulated/floor/plating,
/area/station/maintenance/port)
"jRo" = (
/obj/effect/spawner/airlock/s_to_n/long/square/engineer{
req_access_txt = null
},
/obj/effect/spawner/airlock/s_to_n/long/square,
/turf/simulated/wall,
/area/station/maintenance/fpmaint2)
"jRx" = (
@@ -65011,6 +65023,10 @@
icon_state = "barber"
},
/area/station/service/barber)
"jVV" = (
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/fpmaint2)
"jWg" = (
/obj/machinery/disposal,
/obj/structure/window/reinforced{
@@ -67539,6 +67555,10 @@
icon_state = "purplecorner"
},
/area/station/science/robotics)
"liR" = (
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/apmaint)
"lje" = (
/obj/structure/disposalpipe/segment{
dir = 4
@@ -71432,9 +71452,7 @@
/area/station/hallway/secondary/exit)
"nee" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/s_to_n{
req_access_txt = "11,13"
},
/obj/effect/spawner/airlock/s_to_n,
/turf/simulated/floor/plating,
/area/station/maintenance/auxsolarport)
"neo" = (
@@ -71660,9 +71678,7 @@
/area/station/medical/virology)
"nnF" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/s_to_n/engineer{
req_access_txt = 13
},
/obj/effect/spawner/airlock/s_to_n,
/turf/simulated/floor/plating,
/area/station/maintenance/fsmaint)
"noq" = (
@@ -72130,9 +72146,7 @@
/area/station/science/toxins/mixing)
"nBq" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/long/engineer{
req_access_txt = 13
},
/obj/effect/spawner/airlock/long,
/turf/simulated/floor/plating,
/area/station/maintenance/aft)
"nBs" = (
@@ -72240,6 +72254,15 @@
icon_state = "dark"
},
/area/station/science/robotics/chargebay)
"nCl" = (
/obj/structure/cable{
d1 = 4;
d2 = 8;
icon_state = "4-8"
},
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/asmaint)
"nCm" = (
/obj/structure/cable{
d1 = 1;
@@ -74405,9 +74428,7 @@
/area/station/maintenance/asmaint)
"oBF" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/s_to_n/long/engineer{
req_access_txt = null
},
/obj/effect/spawner/airlock/s_to_n/long,
/turf/simulated/floor/plating,
/area/station/maintenance/fpmaint2)
"oBJ" = (
@@ -77440,9 +77461,7 @@
/area/station/supply/miningdock)
"qaB" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/engineer{
req_access_txt = 13
},
/obj/effect/spawner/airlock,
/turf/simulated/floor/plating,
/area/station/maintenance/apmaint)
"qaI" = (
@@ -79584,6 +79603,15 @@
},
/turf/simulated/wall,
/area/space/nearstation)
"qUj" = (
/obj/structure/cable{
d1 = 1;
d2 = 2;
icon_state = "1-2"
},
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/starboardsolar)
"qUu" = (
/obj/machinery/light_switch{
dir = 4;
@@ -80653,6 +80681,10 @@
},
/turf/simulated/floor/engine,
/area/station/engineering/control)
"ruY" = (
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/fsmaint)
"rvo" = (
/obj/structure/disposalpipe/segment,
/obj/effect/spawner/window/reinforced/polarized/grilled{
@@ -82536,6 +82568,10 @@
/obj/structure/statue/cyberiad/north/east,
/turf/simulated/floor/plasteel,
/area/station/hallway/primary/central/south)
"ssO" = (
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/aft)
"ssQ" = (
/obj/structure/closet/radiation,
/obj/machinery/light{
@@ -84120,6 +84156,7 @@
/obj/machinery/light/small{
dir = 1
},
/obj/effect/mapping_helpers/airlock/access/all/engineering/construction,
/turf/simulated/floor/plating,
/area/station/maintenance/storage)
"tle" = (
@@ -84631,6 +84668,10 @@
/obj/machinery/door/firedoor,
/turf/simulated/floor/plating,
/area/station/maintenance/turbine)
"tAH" = (
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating/airless,
/area/station/maintenance/fpmaint2)
"tAS" = (
/obj/structure/door_assembly/door_assembly_mai{
anchored = 1;
@@ -86212,9 +86253,7 @@
/area/station/command/office/hop)
"unh" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/w_to_e/engineer{
req_access_txt = 13
},
/obj/effect/spawner/airlock/w_to_e,
/turf/simulated/floor/plating,
/area/station/maintenance/asmaint)
"uno" = (
@@ -86781,6 +86820,15 @@
/obj/item/book/random/triple,
/turf/simulated/floor/plating,
/area/station/maintenance/asmaint)
"uDn" = (
/obj/structure/cable{
d1 = 1;
d2 = 2;
icon_state = "1-2"
},
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/auxsolarstarboard)
"uDI" = (
/obj/effect/turf_decal/stripes/line{
dir = 9
@@ -88205,7 +88253,7 @@
/area/station/maintenance/asmaint)
"vrV" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/engineer,
/obj/effect/spawner/airlock,
/turf/simulated/floor/plating,
/area/station/maintenance/starboardsolar)
"vsw" = (
@@ -93237,7 +93285,7 @@
/area/station/maintenance/apmaint2)
"xSF" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/e_to_w/engineer,
/obj/effect/spawner/airlock/e_to_w,
/turf/simulated/floor/plating,
/area/station/maintenance/portsolar)
"xSH" = (
@@ -106226,7 +106274,7 @@ aaa
doE
aHS
aHS
aHS
jVV
aHS
pTK
aND
@@ -108273,7 +108321,7 @@ asb
asb
laU
dap
dap
bOY
dap
hoD
aEE
@@ -108336,7 +108384,7 @@ jWI
noP
ubK
coL
coL
liR
coL
doE
aaa
@@ -112133,7 +112181,7 @@ doE
doE
aHS
lcl
lcl
tAH
aHS
rMP
blG
@@ -115555,7 +115603,7 @@ aaa
aaa
aab
swl
ntD
jCt
swl
aab
aab
@@ -135517,7 +135565,7 @@ awQ
axq
axq
jOz
jOz
uDn
jOz
sDz
aHI
@@ -135885,7 +135933,7 @@ cep
hzG
cep
ghR
cep
ssO
cep
doE
aaa
@@ -137573,7 +137621,7 @@ aaa
aaa
doE
aGY
aGY
ruY
aGY
cZV
aGY
@@ -144876,7 +144924,7 @@ deN
dfa
tMT
sTF
sTF
qUj
sTF
ddE
ddE
@@ -148178,7 +148226,7 @@ aaa
aaa
aab
ycI
cNq
nCl
ycI
ciY
sKQ
+27 -32
View File
@@ -34972,6 +34972,8 @@
icon_state = "4-8"
},
/obj/machinery/light/small,
/obj/effect/mapping_helpers/airlock/access/any/science/minisat,
/obj/effect/mapping_helpers/airlock/access/any/engineering/general,
/turf/simulated/floor/plasteel/dark,
/area/station/engineering/ai_transit_tube)
"bVB" = (
@@ -58070,6 +58072,11 @@
/obj/effect/decal/cleanable/dirt,
/turf/simulated/floor/plating,
/area/station/maintenance/port)
"drw" = (
/obj/effect/turf_decal/delivery,
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plasteel,
/area/station/maintenance/port)
"drz" = (
/obj/machinery/atmospherics/pipe/simple/hidden/supply{
dir = 4
@@ -70728,6 +70735,10 @@
icon_state = "dark"
},
/area/station/turret_protected/aisat)
"hzm" = (
/obj/effect/spawner/airlock/s_to_n,
/turf/simulated/wall/r_wall,
/area/station/security/permabrig)
"hzo" = (
/turf/simulated/floor/plasteel{
icon_state = "neutralfull"
@@ -73228,9 +73239,7 @@
/area/station/science/toxins/mixing)
"iYu" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/e_to_w/engineer{
req_access_txt = 13
},
/obj/effect/spawner/airlock/e_to_w,
/turf/simulated/floor/plating,
/area/station/maintenance/auxsolarport)
"iYX" = (
@@ -74116,9 +74125,7 @@
/area/station/medical/virology)
"jEE" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/w_to_e/engineer{
req_access_txt = 13
},
/obj/effect/spawner/airlock/w_to_e,
/turf/simulated/floor/plating,
/area/station/maintenance/auxsolarstarboard)
"jEI" = (
@@ -78549,6 +78556,7 @@
/obj/structure/sign/securearea{
pixel_x = 32
},
/obj/effect/mapping_helpers/airlock/access/all/security/brig,
/turf/simulated/floor/plating,
/area/station/maintenance/starboard2)
"mnr" = (
@@ -79410,9 +79418,7 @@
/turf/simulated/floor/plasteel,
/area/station/engineering/equipmentstorage)
"mPU" = (
/obj/effect/spawner/airlock/s_to_n{
req_access_txt = 32
},
/obj/effect/spawner/airlock/s_to_n,
/turf/simulated/wall,
/area/station/engineering/gravitygenerator)
"mQc" = (
@@ -79775,12 +79781,6 @@
icon_state = "neutral"
},
/area/station/maintenance/starboard)
"mVF" = (
/obj/effect/spawner/airlock/s_to_n{
req_access_txt = 1
},
/turf/simulated/wall/r_wall,
/area/station/security/permabrig)
"mWe" = (
/obj/machinery/atmospherics/unary/vent_pump/on{
dir = 4
@@ -82544,6 +82544,7 @@
icon_state = "4-8"
},
/obj/effect/turf_decal/delivery,
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/portsolar)
"ozw" = (
@@ -86080,6 +86081,7 @@
icon_state = "4-8"
},
/obj/effect/turf_decal/delivery,
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/starboardsolar)
"qFT" = (
@@ -87573,9 +87575,7 @@
/area/station/security/storage)
"rtH" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/e_to_w/engineer{
req_access_txt = 13
},
/obj/effect/spawner/airlock/e_to_w,
/turf/simulated/floor/plating,
/area/station/maintenance/portsolar)
"rtU" = (
@@ -90672,6 +90672,7 @@
icon_state = "4-8"
},
/obj/effect/turf_decal/delivery,
/obj/effect/mapping_helpers/airlock/access/all/engineering/construction,
/turf/simulated/floor/plating,
/area/station/maintenance/auxsolarport)
"sVv" = (
@@ -90707,9 +90708,7 @@
},
/area/station/hallway/primary/central/north)
"sWx" = (
/obj/effect/spawner/airlock/e_to_w/engineer{
req_access_txt = "11,13"
},
/obj/effect/spawner/airlock/w_to_e,
/turf/simulated/wall,
/area/station/engineering/ai_transit_tube)
"sWI" = (
@@ -91124,6 +91123,7 @@
/area/station/medical/morgue)
"tls" = (
/obj/effect/turf_decal/delivery/hollow,
/obj/effect/mapping_helpers/airlock/access/all/engineering/construction,
/turf/simulated/floor/plasteel,
/area/station/engineering/gravitygenerator)
"tlz" = (
@@ -92602,9 +92602,7 @@
/area/station/service/chapel/office)
"uci" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/s_to_n{
req_access_txt = null
},
/obj/effect/spawner/airlock/s_to_n,
/turf/simulated/floor/plating,
/area/station/hallway/secondary/entry/west)
"ucl" = (
@@ -92653,9 +92651,7 @@
/area/station/medical/cloning)
"udZ" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/w_to_e/engineer{
req_access_txt = 13
},
/obj/effect/spawner/airlock/w_to_e,
/turf/simulated/floor/plating,
/area/station/maintenance/starboardsolar)
"uec" = (
@@ -94838,6 +94834,7 @@
icon_state = "4-8"
},
/obj/effect/turf_decal/delivery,
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/auxsolarstarboard)
"vzs" = (
@@ -97578,9 +97575,7 @@
},
/area/station/maintenance/fsmaint)
"wZD" = (
/obj/effect/spawner/airlock/e_to_w/engineer{
req_access_txt = 13
},
/obj/effect/spawner/airlock/e_to_w,
/turf/simulated/wall,
/area/station/maintenance/port)
"wZK" = (
@@ -119597,7 +119592,7 @@ cTi
hkk
aaa
cHA
cCq
drw
cHA
aaa
aaa
@@ -157311,7 +157306,7 @@ ygH
ygH
ygH
ygH
mVF
hzm
bda
aTM
bdf
+8 -1
View File
@@ -32475,6 +32475,7 @@
icon_state = "1-2"
},
/obj/effect/turf_decal/stripes/line,
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/starboardsolar)
"cmK" = (
@@ -33087,6 +33088,7 @@
/obj/effect/turf_decal/stripes/line{
dir = 8
},
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/portsolar)
"cpq" = (
@@ -39571,6 +39573,7 @@
/obj/structure/sign/vacuum/external{
pixel_y = 32
},
/obj/effect/mapping_helpers/airlock/access/all/engineering/external,
/turf/simulated/floor/plating,
/area/station/maintenance/apmaint)
"cOG" = (
@@ -42172,6 +42175,7 @@
/obj/effect/turf_decal/stripes/line{
dir = 4
},
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/asmaint)
"das" = (
@@ -45123,7 +45127,7 @@
/area/station/maintenance/starboardsolar)
"dUF" = (
/obj/effect/spawner/window/reinforced/grilled,
/obj/effect/spawner/airlock/e_to_w/arrivals,
/obj/effect/spawner/airlock/e_to_w,
/turf/simulated/floor/plating,
/area/station/hallway/secondary/entry/north)
"dUG" = (
@@ -48447,6 +48451,7 @@
/obj/structure/sign/vacuum/external{
pixel_x = 32
},
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/aft2)
"fpR" = (
@@ -66916,6 +66921,7 @@
/obj/effect/turf_decal/stripes/line{
dir = 1
},
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/auxsolarstarboard)
"mVB" = (
@@ -92289,6 +92295,7 @@
/obj/structure/sign/vacuum/external{
pixel_y = 32
},
/obj/effect/mapping_helpers/airlock/access/all/engineering/general,
/turf/simulated/floor/plating,
/area/station/maintenance/fsmaint)
"xRO" = (
@@ -33,7 +33,6 @@ This spawner places pipe leading up to the interior door, you will need to finis
var/tiles_in_x_direction = 1
var/tiles_in_y_direction = 1
var/id_to_link
req_access_txt = ACCESS_EXTERNAL_AIRLOCKS //If req_one_access_txt is set, this is ignored
var/door_name = "external access"
var/door_type = /obj/machinery/door/airlock/external/glass
var/one_door_interior //For square airlocks, if you set this then a) only one door will spawn, and b) you can choose if the door should go opposite to how it normally goes. Please use the define
@@ -58,6 +57,9 @@ This spawner places pipe leading up to the interior door, you will need to finis
handle_pipes_creation(turf_interior)
handle_control_placement()
for(var/obj/effect/mapping_helpers/airlock/access/access_helper in loc)
qdel(access_helper)
return INITIALIZE_HINT_QDEL
/obj/effect/spawner/airlock/proc/get_airlock_location(desired_direction) //Finds a turf to place an airlock and returns it, this turf will be in the middle of the relevant wall
@@ -198,12 +200,24 @@ This spawner places pipe leading up to the interior door, you will need to finis
created_pump.autolink_id = VENT_ID
/obj/effect/spawner/airlock/proc/set_access_helper(obj/I)
if(req_one_access_txt == "0")
I.req_access_txt = "[req_access_txt]"
var/obj/machinery/door/airlock/airlock = I
if(istype(airlock))
for(var/obj/effect/mapping_helpers/airlock/access/access_helper in loc)
access_helper.payload(airlock)
// Since airlocks are created first, we steal the payload logic
// to apply to the controls later
req_access = airlock.req_access
req_access_txt = airlock.req_access_txt
req_one_access = airlock.req_one_access
req_one_access_txt = airlock.req_one_access_txt
else
I.req_one_access_txt = "[req_one_access_txt]"
I.req_access = req_access
I.req_access_txt = req_access_txt
I.req_one_access = req_one_access
I.req_one_access_txt = req_one_access_txt
// MARK: AIRLOCK HELPERS
//Premade airlocks for mappers, probably won't need all of these but whatever
/obj/effect/spawner/airlock/s_to_n
name = "1 by 1 airlock spawner (interior south, exterior north)"
icon_state = "1x1_S_to_N"
@@ -222,7 +236,8 @@ This spawner places pipe leading up to the interior door, you will need to finis
interior_direction = WEST
exterior_direction = EAST
/// Long and thin
// MARK: LONG AIRLOCKS
/obj/effect/spawner/airlock/long
name = "long airlock spawner (interior north, exterior south)"
icon_state = "1x2_N_to_S"
@@ -233,14 +248,6 @@ This spawner places pipe leading up to the interior door, you will need to finis
icon_state = "1x2_S_to_N"
tiles_in_y_direction = 2
/obj/effect/spawner/airlock/s_to_n/long/square/engineer
req_access_txt = ACCESS_ENGINE_EQUIP
door_name = "engineering external access"
/obj/effect/spawner/airlock/s_to_n/long/engineer
req_access_txt = ACCESS_ENGINE_EQUIP
door_name = "engineering external access"
/obj/effect/spawner/airlock/e_to_w/long
name = "long airlock spawner (interior east, exterior west)"
icon_state = "1x2_E_to_W"
@@ -251,7 +258,7 @@ This spawner places pipe leading up to the interior door, you will need to finis
icon_state = "1x2_W_to_E"
tiles_in_x_direction = 2
/// Square
// MARK: SQUARE AIRLOCKS
/obj/effect/spawner/airlock/long/square
name = "square airlock spawner (interior north, exterior south)"
icon_state = "2x2_N_to_S"
@@ -306,68 +313,6 @@ This spawner places pipe leading up to the interior door, you will need to finis
tiles_in_x_direction = 3
tiles_in_y_direction = 3
/obj/effect/spawner/airlock/e_to_w/arrivals
req_access_txt = null
/obj/effect/spawner/airlock/engineer
req_access_txt = ACCESS_ENGINE_EQUIP
door_name = "engineering external access"
/obj/effect/spawner/airlock/e_to_w/engineer
req_access_txt = ACCESS_ENGINE_EQUIP
door_name = "engineering external access"
/obj/effect/spawner/airlock/w_to_e/engineer
req_access_txt = ACCESS_ENGINE_EQUIP
door_name = "engineering external access"
/obj/effect/spawner/airlock/s_to_n/engineer
req_access_txt = ACCESS_ENGINE_EQUIP
door_name = "engineering external access"
/obj/effect/spawner/airlock/long/engineer
req_access_txt = ACCESS_ENGINE_EQUIP
door_name = "engineering external access"
/obj/effect/spawner/airlock/long/square/engine
req_access_txt = ACCESS_ENGINE_EQUIP
door_name = "engine external access"
icon_state = "2x2_N_to_S_leftdoors"
door_type = /obj/machinery/door/airlock/external
one_door_interior = DOOR_NORMAL_PLACEMENT
one_door_exterior = DOOR_NORMAL_PLACEMENT
/obj/effect/spawner/airlock/long/square/engine/reversed
icon_state = "2x2_N_to_S_rightdoors"
one_door_interior = DOOR_FLIPPED_PLACEMENT
one_door_exterior = DOOR_FLIPPED_PLACEMENT
/obj/effect/spawner/airlock/w_to_e/long/square/wide/mining
door_name = "mining external access"
req_access_txt = ACCESS_MINING
/obj/effect/spawner/airlock/long/square/wide/mining
door_name = "mining external access"
req_access_txt = ACCESS_MINING
/obj/effect/spawner/airlock/e_to_w/minisat
door_name = "minisat external access"
req_access_txt = ACCESS_MINISAT
/obj/effect/spawner/airlock/long/square/e_to_s/telecoms
door_name = "telecoms external access"
req_access_txt = "61;13" //ACCESS_TCOMSAT,ACCESS_EXTERNAL_AIRLOCKS
door_type = /obj/machinery/door/airlock/external
/obj/effect/spawner/airlock/long/square/three/syndicate
name = "3 by 3 square airlock spawner (interior west, exterior north)"
icon_state = "3x3_W_to_N"
interior_direction = WEST
exterior_direction = NORTH
door_name = "ship external access"
req_access_txt = ACCESS_SYNDICATE
door_type = /obj/machinery/door/airlock/external
#undef HALF_X
#undef HALF_Y
#undef CHAMBER_LONG
+7 -1
View File
@@ -1,10 +1,13 @@
/obj/effect/mapping_helpers/airlock/access
layer = DOOR_HELPER_LAYER
layer = SPLASHSCREEN_PLANE + 0.1 // Above even airlock spawners
icon_state = "access_helper"
var/access
// These are mutually exclusive; can't have req_any and req_all
/obj/effect/mapping_helpers/airlock/access/any/payload(obj/machinery/door/airlock/airlock)
if(is_type_in_list(airlock, blacklist))
return
if(airlock.req_access_txt == "0")
// Overwrite if there is no access set, otherwise add onto existing access
if(airlock.req_one_access_txt == "0")
@@ -15,6 +18,9 @@
log_world("[src] at [AREACOORD(src)] tried to set req_one_access, but req_access was already set!")
/obj/effect/mapping_helpers/airlock/access/all/payload(obj/machinery/door/airlock/airlock)
if(is_type_in_list(airlock, blacklist))
return
if(airlock.req_one_access_txt == "0")
if(airlock.req_access_txt == "0")
airlock.req_access_txt = "[access]"
+6 -4
View File
@@ -84,18 +84,20 @@
/obj/effect/mapping_helpers/airlock/Initialize(mapload)
. = ..()
if(!mapload)
log_world("[src] spawned outside of mapload!")
return
return INITIALIZE_HINT_QDEL
/obj/effect/mapping_helpers/airlock/LateInitialize()
. = ..()
if(!(locate(/obj/machinery/door) in get_turf(src)))
log_world("[src] failed to find an airlock at [AREACOORD(src)]")
for(var/obj/machinery/door/D in get_turf(src))
if(!is_type_in_list(D, blacklist))
payload(D)
payload(D)
return INITIALIZE_HINT_QDEL
qdel(src)
/obj/effect/mapping_helpers/airlock/proc/payload(obj/machinery/door/airlock/payload)
return
Binary file not shown.

Before

Width:  |  Height:  |  Size: 81 KiB

After

Width:  |  Height:  |  Size: 84 KiB

@@ -0,0 +1,7 @@
help: "Please use access helpers for airlock spawners, placed one tile north and east of the spawner itself."
/obj/effect/spawner/airlock:
banned_variables:
- req_access
- req_access_txt
- req_one_access
- req_one_access_txt