Skip to content

Commit

Permalink
Airlock improvements, mainly external [MDB IGNORE] (#62161)
Browse files Browse the repository at this point in the history
You're in space, unauthorized personnel should not be allowed to instantly jump ship, especially if doing so could vent parts of the station. At the same time, we allow self reentry in "man-overboard" scenarios. The aim is to reduce the potential for accidents without reducing crew safety as well as increase the significance of these exterior airlocks. Also makes antags think a bit as they can't simply yeet themselves into space super easily as a braindead getaway tactic.

External airlocks now have a base req_access of ACCESS_EXTERNAL_AIRLOCKS. This is a non-functional change.
Removed airlock's safety_mode var.
Added external airlock's space_dir var. Indicates the direction anyone can enter from, but only those with access can exit to (unless the other side is considered "safe" (breathable, dense, or shuttle docked)). Cyclelinked airlocks share this value.
Created proc/is_safe_turf from proc/find_safe_turf.
Cycle-link operations now happen in proc/open rather than proc/bumpopen which was causing several triggers to be missed (AI activation, prying, etc...).
proc/try_to_activate_door now takes an argument allowing for a bypass of access requirements.
Downstreams, to port this to your maps, check every public access external airlock has the safety_mode var override removed and the outermost airlock should have space_dir set to the hazardous direction number.
  • Loading branch information
Cyberboss committed Oct 18, 2021
1 parent 796d197 commit e9a7c9a
Show file tree
Hide file tree
Showing 18 changed files with 463 additions and 439 deletions.
16 changes: 4 additions & 12 deletions _maps/RandomRuins/SpaceRuins/caravanambush.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -364,9 +364,7 @@
/turf/open/floor/plating/airless,
/area/shuttle/caravan/freighter3)
"gc" = (
/obj/machinery/door/airlock/external{
req_access_txt = "13"
},
/obj/machinery/door/airlock/external,
/obj/effect/mapping_helpers/airlock/cyclelink_helper,
/turf/open/floor/plating/airless,
/area/shuttle/caravan/freighter3)
Expand Down Expand Up @@ -560,9 +558,7 @@
/area/shuttle/caravan/freighter2)
"hs" = (
/obj/effect/decal/cleanable/dirt,
/obj/machinery/door/airlock/external{
req_access_txt = "13"
},
/obj/machinery/door/airlock/external,
/obj/effect/mapping_helpers/airlock/cyclelink_helper,
/turf/open/floor/plating/airless,
/area/shuttle/caravan/freighter2)
Expand Down Expand Up @@ -1239,19 +1235,15 @@
/turf/closed/wall/mineral/plastitanium,
/area/ruin/unpowered)
"vE" = (
/obj/machinery/door/airlock/external{
req_access_txt = "13"
},
/obj/machinery/door/airlock/external,
/obj/effect/mapping_helpers/airlock/cyclelink_helper{
dir = 1
},
/turf/open/floor/plating/airless,
/area/shuttle/caravan/freighter3)
"GL" = (
/obj/effect/decal/cleanable/dirt,
/obj/machinery/door/airlock/external{
req_access_txt = "13"
},
/obj/machinery/door/airlock/external,
/obj/effect/mapping_helpers/airlock/cyclelink_helper{
dir = 1
},
Expand Down
4 changes: 1 addition & 3 deletions _maps/RandomZLevels/research.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -528,9 +528,7 @@
/turf/open/floor/iron/white,
/area/awaymission/research/interior/engineering)
"bx" = (
/obj/machinery/door/airlock/external{
req_access_txt = "13"
},
/obj/machinery/door/airlock/external,
/turf/open/floor/plating,
/area/awaymission/research/interior/maint)
"by" = (
Expand Down

0 comments on commit e9a7c9a

Please sign in to comment.