forked from ParadiseSS13/Paradise
-
Notifications
You must be signed in to change notification settings - Fork 0
/
access_helpers.dm
463 lines (320 loc) · 14.3 KB
/
access_helpers.dm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
/obj/effect/mapping_helpers/airlock/access
layer = DOOR_HELPER_LAYER
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(airlock.req_access_txt == "0")
// Overwrite if there is no access set, otherwise add onto existing access
if(airlock.req_one_access_txt == "0")
airlock.req_one_access_txt = "[access]"
else
airlock.req_one_access_txt += ";[access]"
else
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(airlock.req_one_access_txt == "0")
if(airlock.req_access_txt == "0")
airlock.req_access_txt = "[access]"
else
airlock.req_access_txt += ";[access]"
else
log_world("[src] at [AREACOORD(src)] tried to set req_access, but req_one_access was already set!")
// -------------------- Req Any (Only requires ONE of the given accesses to open)
// -------------------- Command access helpers
/obj/effect/mapping_helpers/airlock/access/any/command
icon_state = "access_helper_com"
/obj/effect/mapping_helpers/airlock/access/any/command/general
access = ACCESS_HEADS
/obj/effect/mapping_helpers/airlock/access/any/command/ai_upload
access = ACCESS_AI_UPLOAD
/obj/effect/mapping_helpers/airlock/access/any/command/teleporter
access = ACCESS_TELEPORTER
/obj/effect/mapping_helpers/airlock/access/any/command/eva
access = ACCESS_EVA
/obj/effect/mapping_helpers/airlock/access/any/supply/expedition
access = ACCESS_EXPEDITION
/obj/effect/mapping_helpers/airlock/access/any/command/hop
access = ACCESS_HOP
/obj/effect/mapping_helpers/airlock/access/any/command/captain
access = ACCESS_CAPTAIN
/obj/effect/mapping_helpers/airlock/access/any/command/blueshield
access = ACCESS_BLUESHIELD
/obj/effect/mapping_helpers/airlock/access/any/command/ntrep
access = ACCESS_NTREP
/obj/effect/mapping_helpers/airlock/access/any/command/magistrate
access = ACCESS_MAGISTRATE
// -------------------- Engineering access helpers
/obj/effect/mapping_helpers/airlock/access/any/engineering
icon_state = "access_helper_eng"
/obj/effect/mapping_helpers/airlock/access/any/engineering/general
access = ACCESS_ENGINE
/obj/effect/mapping_helpers/airlock/access/any/engineering/equipment
access = ACCESS_ENGINE_EQUIP
/obj/effect/mapping_helpers/airlock/access/any/engineering/construction
access = ACCESS_CONSTRUCTION
/obj/effect/mapping_helpers/airlock/access/any/engineering/maintenance
access = ACCESS_MAINT_TUNNELS
/obj/effect/mapping_helpers/airlock/access/any/engineering/external
access = ACCESS_EXTERNAL_AIRLOCKS
/obj/effect/mapping_helpers/airlock/access/any/engineering/tech_storage
access = ACCESS_TECH_STORAGE
/obj/effect/mapping_helpers/airlock/access/any/engineering/atmos
access = ACCESS_ATMOSPHERICS
/obj/effect/mapping_helpers/airlock/access/any/engineering/tcoms
access = ACCESS_TCOMSAT
/obj/effect/mapping_helpers/airlock/access/any/engineering/ce
access = ACCESS_CE
// -------------------- Medical access helpers
/obj/effect/mapping_helpers/airlock/access/any/medical
icon_state = "access_helper_med"
/obj/effect/mapping_helpers/airlock/access/any/medical/general
access = ACCESS_MEDICAL
/obj/effect/mapping_helpers/airlock/access/any/medical/morgue
access = ACCESS_MORGUE
/obj/effect/mapping_helpers/airlock/access/any/medical/chemistry
access = ACCESS_CHEMISTRY
/obj/effect/mapping_helpers/airlock/access/any/medical/virology
access = ACCESS_VIROLOGY
/obj/effect/mapping_helpers/airlock/access/any/medical/surgery
access = ACCESS_SURGERY
/obj/effect/mapping_helpers/airlock/access/any/medical/cmo
access = ACCESS_CMO
/obj/effect/mapping_helpers/airlock/access/any/medical/psychology
access = ACCESS_PSYCHIATRIST
/obj/effect/mapping_helpers/airlock/access/any/medical/genetics
access = ACCESS_GENETICS
/obj/effect/mapping_helpers/airlock/access/any/medical/paramedic
access = ACCESS_PARAMEDIC
// -------------------- Science access helpers
/obj/effect/mapping_helpers/airlock/access/any/science
icon_state = "access_helper_sci"
/obj/effect/mapping_helpers/airlock/access/any/science/research
access = ACCESS_RESEARCH
/obj/effect/mapping_helpers/airlock/access/any/science/tox
access = ACCESS_TOX
/obj/effect/mapping_helpers/airlock/access/any/science/tox_storage
access = ACCESS_TOX_STORAGE
/obj/effect/mapping_helpers/airlock/access/any/science/robotics
access = ACCESS_ROBOTICS
/obj/effect/mapping_helpers/airlock/access/any/science/xenobio
access = ACCESS_XENOBIOLOGY
/obj/effect/mapping_helpers/airlock/access/any/science/minisat
access = ACCESS_MINISAT
/obj/effect/mapping_helpers/airlock/access/any/science/rd
access = ACCESS_RD
// -------------------- Security access helpers
/obj/effect/mapping_helpers/airlock/access/any/security
icon_state = "access_helper_sec"
/obj/effect/mapping_helpers/airlock/access/any/security/general
access = ACCESS_SECURITY
/obj/effect/mapping_helpers/airlock/access/any/security/forensics
access = ACCESS_FORENSICS_LOCKERS
/obj/effect/mapping_helpers/airlock/access/any/security/doors
access = ACCESS_SEC_DOORS
/obj/effect/mapping_helpers/airlock/access/any/security/brig
access = ACCESS_BRIG
/obj/effect/mapping_helpers/airlock/access/any/security/armory
access = ACCESS_ARMORY
/obj/effect/mapping_helpers/airlock/access/any/security/court
access = ACCESS_COURT
/obj/effect/mapping_helpers/airlock/access/any/security/hos
access = ACCESS_HOS
/obj/effect/mapping_helpers/airlock/access/any/security/iaa
access = ACCESS_INTERNAL_AFFAIRS
// -------------------- Service access helpers
/obj/effect/mapping_helpers/airlock/access/any/service
icon_state = "access_helper_serv"
/obj/effect/mapping_helpers/airlock/access/any/service/kitchen
access = ACCESS_KITCHEN
/obj/effect/mapping_helpers/airlock/access/any/service/bar
access = ACCESS_BAR
/obj/effect/mapping_helpers/airlock/access/any/service/hydroponics
access = ACCESS_HYDROPONICS
/obj/effect/mapping_helpers/airlock/access/any/service/janitor
access = ACCESS_JANITOR
/obj/effect/mapping_helpers/airlock/access/any/service/chapel_office
access = ACCESS_CHAPEL_OFFICE
/obj/effect/mapping_helpers/airlock/access/any/service/crematorium
access = ACCESS_CREMATORIUM
/obj/effect/mapping_helpers/airlock/access/any/service/library
access = ACCESS_LIBRARY
/obj/effect/mapping_helpers/airlock/access/any/service/theatre
access = ACCESS_THEATRE
/obj/effect/mapping_helpers/airlock/access/any/service/clown
access = ACCESS_CLOWN
/obj/effect/mapping_helpers/airlock/access/any/service/mime
access = ACCESS_MIME
// -------------------- Supply access helpers
/obj/effect/mapping_helpers/airlock/access/any/supply
icon_state = "access_helper_sup"
/obj/effect/mapping_helpers/airlock/access/any/supply/general
name = "cargo office"
access = ACCESS_CARGO
/obj/effect/mapping_helpers/airlock/access/any/supply/cargo_bay
access = ACCESS_CARGO_BAY
/obj/effect/mapping_helpers/airlock/access/any/supply/supply_shuttle
access = ACCESS_SUPPLY_SHUTTLE
/obj/effect/mapping_helpers/airlock/access/any/supply/mail_sorting
access = ACCESS_MAILSORTING
/obj/effect/mapping_helpers/airlock/access/any/supply/mining
access = ACCESS_MINING
/obj/effect/mapping_helpers/airlock/access/any/supply/mining_station
access = ACCESS_MINING_STATION
/obj/effect/mapping_helpers/airlock/access/any/supply/mineral_storage
access = ACCESS_MINERAL_STOREROOM
/obj/effect/mapping_helpers/airlock/access/any/supply/qm
access = ACCESS_QM
/obj/effect/mapping_helpers/airlock/access/any/supply/vault
access = ACCESS_HEADS_VAULT
/obj/effect/mapping_helpers/airlock/access/any/supply/mule_bot
access = ACCESS_CARGO_BOT
// -------------------- Req All (Requires ALL of the given accesses to open)
// -------------------- Command access helpers
/obj/effect/mapping_helpers/airlock/access/all/command
icon_state = "access_helper_com"
/obj/effect/mapping_helpers/airlock/access/all/command/general
access = ACCESS_HEADS
/obj/effect/mapping_helpers/airlock/access/all/command/ai_upload
access = ACCESS_AI_UPLOAD
/obj/effect/mapping_helpers/airlock/access/all/command/teleporter
access = ACCESS_TELEPORTER
/obj/effect/mapping_helpers/airlock/access/all/command/eva
access = ACCESS_EVA
/obj/effect/mapping_helpers/airlock/access/all/supply/expedition
access = ACCESS_EXPEDITION
/obj/effect/mapping_helpers/airlock/access/all/command/hop
access = ACCESS_HOP
/obj/effect/mapping_helpers/airlock/access/all/command/captain
access = ACCESS_CAPTAIN
/obj/effect/mapping_helpers/airlock/access/all/command/blueshield
access = ACCESS_BLUESHIELD
/obj/effect/mapping_helpers/airlock/access/all/command/ntrep
access = ACCESS_NTREP
/obj/effect/mapping_helpers/airlock/access/all/command/magistrate
access = ACCESS_MAGISTRATE
// -------------------- Engineering access helpers
/obj/effect/mapping_helpers/airlock/access/all/engineering
icon_state = "access_helper_eng"
/obj/effect/mapping_helpers/airlock/access/all/engineering/general
access = ACCESS_ENGINE
/obj/effect/mapping_helpers/airlock/access/all/engineering/equipment
access = ACCESS_ENGINE_EQUIP
/obj/effect/mapping_helpers/airlock/access/all/engineering/construction
access = ACCESS_CONSTRUCTION
/obj/effect/mapping_helpers/airlock/access/all/engineering/maintenance
access = ACCESS_MAINT_TUNNELS
/obj/effect/mapping_helpers/airlock/access/all/engineering/external
access = ACCESS_EXTERNAL_AIRLOCKS
/obj/effect/mapping_helpers/airlock/access/all/engineering/tech_storage
access = ACCESS_TECH_STORAGE
/obj/effect/mapping_helpers/airlock/access/all/engineering/atmos
access = ACCESS_ATMOSPHERICS
/obj/effect/mapping_helpers/airlock/access/all/engineering/tcoms
access = ACCESS_TCOMSAT
/obj/effect/mapping_helpers/airlock/access/all/engineering/ce
access = ACCESS_CE
// -------------------- Medical access helpers
/obj/effect/mapping_helpers/airlock/access/all/medical
icon_state = "access_helper_med"
/obj/effect/mapping_helpers/airlock/access/all/medical/general
access = ACCESS_MEDICAL
/obj/effect/mapping_helpers/airlock/access/all/medical/morgue
access = ACCESS_MORGUE
/obj/effect/mapping_helpers/airlock/access/all/medical/chemistry
access = ACCESS_CHEMISTRY
/obj/effect/mapping_helpers/airlock/access/all/medical/virology
access = ACCESS_VIROLOGY
/obj/effect/mapping_helpers/airlock/access/all/medical/surgery
access = ACCESS_SURGERY
/obj/effect/mapping_helpers/airlock/access/all/medical/cmo
access = ACCESS_CMO
/obj/effect/mapping_helpers/airlock/access/all/medical/paramedic
access = ACCESS_PARAMEDIC
/obj/effect/mapping_helpers/airlock/access/all/medical/psychology
access = ACCESS_PSYCHIATRIST
/obj/effect/mapping_helpers/airlock/access/all/medical/genetics
access = ACCESS_GENETICS
// -------------------- Science access helpers
/obj/effect/mapping_helpers/airlock/access/all/science
icon_state = "access_helper_sci"
/obj/effect/mapping_helpers/airlock/access/all/science/research
access = ACCESS_RESEARCH
/obj/effect/mapping_helpers/airlock/access/all/science/tox
access = ACCESS_TOX
/obj/effect/mapping_helpers/airlock/access/all/science/tox_storage
access = ACCESS_TOX_STORAGE
/obj/effect/mapping_helpers/airlock/access/all/science/robotics
access = ACCESS_ROBOTICS
/obj/effect/mapping_helpers/airlock/access/all/science/xenobio
access = ACCESS_XENOBIOLOGY
/obj/effect/mapping_helpers/airlock/access/all/science/minisat
access = ACCESS_MINISAT
/obj/effect/mapping_helpers/airlock/access/all/science/rd
access = ACCESS_RD
// -------------------- Security access helpers
/obj/effect/mapping_helpers/airlock/access/all/security
icon_state = "access_helper_sec"
/obj/effect/mapping_helpers/airlock/access/all/security/general
access = ACCESS_SECURITY
/obj/effect/mapping_helpers/airlock/access/all/security/forensics
access = ACCESS_FORENSICS_LOCKERS
/obj/effect/mapping_helpers/airlock/access/all/security/doors
access = ACCESS_SEC_DOORS
/obj/effect/mapping_helpers/airlock/access/all/security/brig
access = ACCESS_BRIG
/obj/effect/mapping_helpers/airlock/access/all/security/armory
access = ACCESS_ARMORY
/obj/effect/mapping_helpers/airlock/access/all/security/court
access = ACCESS_COURT
/obj/effect/mapping_helpers/airlock/access/all/security/hos
access = ACCESS_HOS
/obj/effect/mapping_helpers/airlock/access/all/security/iaa
access = ACCESS_INTERNAL_AFFAIRS
// -------------------- Service access helpers
/obj/effect/mapping_helpers/airlock/access/all/service
icon_state = "access_helper_serv"
/obj/effect/mapping_helpers/airlock/access/all/service/kitchen
access = ACCESS_KITCHEN
/obj/effect/mapping_helpers/airlock/access/all/service/bar
access = ACCESS_BAR
/obj/effect/mapping_helpers/airlock/access/all/service/hydroponics
access = ACCESS_HYDROPONICS
/obj/effect/mapping_helpers/airlock/access/all/service/janitor
access = ACCESS_JANITOR
/obj/effect/mapping_helpers/airlock/access/all/service/chapel_office
access = ACCESS_CHAPEL_OFFICE
/obj/effect/mapping_helpers/airlock/access/all/service/crematorium
access = ACCESS_CREMATORIUM
/obj/effect/mapping_helpers/airlock/access/all/service/library
access = ACCESS_LIBRARY
/obj/effect/mapping_helpers/airlock/access/all/service/theatre
access = ACCESS_THEATRE
/obj/effect/mapping_helpers/airlock/access/all/service/clown
access = ACCESS_CLOWN
/obj/effect/mapping_helpers/airlock/access/all/service/mime
access = ACCESS_MIME
// -------------------- Supply access helpers
/obj/effect/mapping_helpers/airlock/access/all/supply
icon_state = "access_helper_sup"
/obj/effect/mapping_helpers/airlock/access/all/supply/general
name = "cargo office"
access = ACCESS_CARGO
/obj/effect/mapping_helpers/airlock/access/all/supply/cargo_bay
access = ACCESS_CARGO_BAY
/obj/effect/mapping_helpers/airlock/access/all/supply/supply_shuttle
access = ACCESS_SUPPLY_SHUTTLE
/obj/effect/mapping_helpers/airlock/access/all/supply/mail_sorting
access = ACCESS_MAILSORTING
/obj/effect/mapping_helpers/airlock/access/all/supply/mining
access = ACCESS_MINING
/obj/effect/mapping_helpers/airlock/access/all/supply/mining_station
access = ACCESS_MINING_STATION
/obj/effect/mapping_helpers/airlock/access/all/supply/mineral_storage
access = ACCESS_MINERAL_STOREROOM
/obj/effect/mapping_helpers/airlock/access/all/supply/qm
access = ACCESS_QM
/obj/effect/mapping_helpers/airlock/access/all/supply/vault
access = ACCESS_HEADS_VAULT
/obj/effect/mapping_helpers/airlock/access/all/supply/mule_bot
access = ACCESS_CARGO_BOT