Space Engineers

Space Engineers

Whip's Auto Door and Airlock Script
542 Comments
Whiplash141  [author] 31 May @ 4:31pm 
This script does not control airvents at all. It simply prevents you from spacing all of your oxygen out of a simple airlock. If you want to preserve air, simply set the airvent in your airlock to always depressurize.
DoPa 31 May @ 1:33pm 
Hi, it works quite well but one thing is missing. Before the airlock opens, the pressure in the airlock should decrease and when I'm in the airlock I should blow it in again so that oxygen isn't constantly lost.
Darth Porgus 3 Feb @ 3:36pm 
Thanks for the response!
Deapri 2 Feb @ 11:29pm 
@Darth Porgus Isy's script interprets the positioning of the doors and inherits behavior based on that with control in exclusions. I feel this script offers more overall control of the setup and effective application. More setup is required however it is my opinion this script better suits my uses.
Whiplash141  [author] 2 Feb @ 10:43pm 
This is 4 years older. Aside for that I have zero clue because I only use scripts I write.
Darth Porgus 2 Feb @ 3:10pm 
How does this differ from isy's simple door script?
Deapri 19 Jan @ 3:37pm 
Which I could edit a post, anyway, the setting is Ignore all hangar doors=true set it to false
Deapri 19 Jan @ 3:36pm 
Hangar doors are excluded by default change the custom data on the programming block to enable them.
xtravince 13 Jan @ 2:10pm 
hi, this script is great thank you very much :steamthumbsup: , but when I install a hangar door it doesn't work with it, it doesn't close and there is no custom data (I waited for the refresh time)
Bacon 30 Sep, 2023 @ 9:45pm 
Thank you very much :)
Whiplash141  [author] 30 Sep, 2023 @ 9:23pm 
Of course, these scripts are here for you to use
Bacon 30 Sep, 2023 @ 8:47pm 
Can I use this script for a ship I'm currently building? I'm going to post the ship on the workshop and wanted to make sure you're good with it. :)
Whiplash141  [author] 28 Sep, 2023 @ 5:23am 
Ignorance is bliss, and it seems you have an abundance of both.

Your profile was a hilarious shrine of stupidity, but you privated it :'(
Slinkerdeer 27 Sep, 2023 @ 6:30pm 
Pfff hahahaha! sadder than I thought, knew you would also thank me for the points xD, enjoy the meaningless internet numbers
Slinkerdeer 27 Sep, 2023 @ 6:27pm 
Hahahah I knew when I made that typo you would point it out because you have literally nothing else to respond with
Whiplash141  [author] 26 Sep, 2023 @ 5:34am 
I'll label your chin with deez nutz. Also how'd you manage to misspell "auto"? The helmet must have slid over your eyes.

:missing: <- The contents of your mind represented by a texture (thanks for the free steam points, I'm enjoying them lol)
Slinkerdeer 26 Sep, 2023 @ 3:28am 
Once again, its labelled "auto door", you said "hence title" when I asked about it not auo opening the doors. Lmao how stupid can you be
aTruckgril Beverly ✿ 25 Sep, 2023 @ 5:03pm 
@Slinkerdeer do you wear that helmet when you use the stove or something? I can see reading comprehension is beyond you
Firewarrior44 25 Sep, 2023 @ 4:56pm 
> This script will close any door once it has been fully open for over 3 seconds (10 seconds for hangar doors).

The first line of the description is really unclear, please fix. Also Does Is this weapon core compatible?
Whiplash141  [author] 25 Sep, 2023 @ 4:55pm 
Also, here are some resources that you'll definitely find helpful: https://www.wikihow.com/Teach-Yourself-to-Read
Whiplash141  [author] 25 Sep, 2023 @ 4:52pm 
:jarate: <- you irl
Slinkerdeer 25 Sep, 2023 @ 4:07pm 
Oh, and enjoy the jester
Slinkerdeer 25 Sep, 2023 @ 4:07pm 
No i cant be arsed with someone who cant label something, ive used this instead - https://steamproxy.net/sharedfiles/filedetails/?id=317276089

Notice what he did..? Here, I'll make it REAL easy for you
"A very simple script to make doors open/close when the player is near them." at the top of the description. At least this modder isn't a fking moron
Whiplash141  [author] 23 Sep, 2023 @ 11:24pm 
How bout you auto close yo damn mouth and read a description

⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣀⠴
⠀⠀⠀⠀⠀⠀⠀⠀⠀⢠⡴⠑⠁⠀
⠀⢀⣠⣤⡀⠀⠀⣠⠞⠁⠀⠀⠀⠀
⢰⣿⣿⣿⣿⡆⠊⢡⠀⠀⠀⠀⠀⠀
⠈⢿⠿⣯⢈⡟⠋⡆⣄⠀⠀⠀⠀⠀
⠀⢀⠁⡱⠕⠐⠎⠪⣈⠆⠀⠀⠀⠀
⠀⠈⠋⠀⠀⠀⣠⠴⣤⠺⣥⠀⠀⠀
⠀⠀⠀⠀⢀⡜⠁⠀⠀⠀⠀⠱⣄⠀
⠀⠀⠀⠀⣭⠀⠀⠀⠀⠀⠀⠀⠘⡇
⠀⠀⠀⠀⠘⣆⠀⠀⠀⠀⠀⠀⢸⠁
⠀⠀⠀⠀⢀⣜⣂⠀⠀⠀⠀⢀⣎⡀
⠀⠀⠀⠈⠉⠀⠀⠀⠀⠀⠀⠀⠀⠀
Slinkerdeer 23 Sep, 2023 @ 6:28pm 
it says "auto door" mate. call it a fcking auto door CLOSER if thats what it is
Whiplash141  [author] 23 Sep, 2023 @ 10:27am 
Hence the name lol
Slinkerdeer 23 Sep, 2023 @ 10:24am 
I am trying to find a script that allows doors to be automatic without a sensor, this appears to only close doors and not open them when i get close enough
Whiplash141  [author] 26 Aug, 2023 @ 12:42am 
yes.
klen ghost 25 Aug, 2023 @ 11:45pm 
can the time set below 1 second (thus half a second or something like that ? ) otherwise nice script
Whiplash141  [author] 25 Aug, 2023 @ 8:15pm 
Idk what that means. If you load this script from the programmable block menu, it works fine.
frozen north 25 Aug, 2023 @ 5:32pm 
I pasted the code for an existing ship of mine, but it spat out an error. No idea why, as I am clueless with code.
Whiplash141  [author] 27 Jul, 2023 @ 5:10pm 
It's a simple airlock system. If it isn't useful for you, you don't need to use it
Patipi1 27 Jul, 2023 @ 12:57pm 
It would be good if the airlock pressure equalization would work with the help of vents, because otherwise it unfortunately does not bring so much
Whiplash141  [author] 19 Jul, 2023 @ 8:33am 
1. I always care about speed because scripts run on the main thread and
2. The script periodically refetches blocks to account for damage.
mirrorimage 19 Jul, 2023 @ 2:46am 
Whiplash141, aren't you caching references to blocks on script initialization anyway? Why do you care about lookup speed then?
Whiplash141  [author] 18 Jul, 2023 @ 11:48pm 
Nope, this is designed mainly for the auto door functionality with support for simple airlocks only
steinmy.js 15 Jul, 2023 @ 10:49am 
was wondering if there is a way to add a air vent to this script for depressuring and repressuring thanks
Whiplash141  [author] 14 Jul, 2023 @ 4:21pm 
Regex is slow as shit, so it is bad to use in the programmable block for repeated operations.
mirrorimage 14 Jul, 2023 @ 4:10am 
I would suggest to use regex patterns for blocks lookup. I use my own naming system on ships and don't want to break it just for airlocks. Casual users will be able to use it just as is, and advanced ones will be able to use the script with wide range of naming conventions.
Whiplash141  [author] 20 May, 2023 @ 7:24pm 
As long as the door is indeed a door and it has the correct name tag for your airlock, it will work. All vanilla doors work with this script.
MrDaggerK 19 May, 2023 @ 2:06pm 
I have a airlock with a sliding door and a normal door. The script won't recognize it. Is there a way to make it work for that?
CaptainRaven 22 Apr, 2023 @ 7:57pm 
@fingersniffer make sure that when your grouping your in this case Hangar 3 they have the same prefix so in this case should have "[Hangar 3] Airlock Light" and "[Hangar 3] Airlock Sounds" with "[Hangar 3] Doors" for example.
Fingersniffer 16 Apr, 2023 @ 1:31pm 
No, it does not see any Lights or Sound Blocks, I've named them as you suggested with [Hangar 3 Lights] Airlock Light and [Hangar 3 Doors] Airlock Sound respectively.
Whiplash141  [author] 15 Apr, 2023 @ 8:52am 
if you look at the block in the terminal menu, bottom right should be a little panel that has info printed on it
Fingersniffer 15 Apr, 2023 @ 8:37am 
I'm unsure what you mean. Where should I see this print out?
Whiplash141  [author] 14 Apr, 2023 @ 11:56pm 
Does the script register your light and sound blocks when you look at the information it prints out?
Fingersniffer 14 Apr, 2023 @ 10:48pm 
Oh, same with the Airlock Sound. doesn't seem to do anything.
Fingersniffer 14 Apr, 2023 @ 10:45pm 
@Whiplash This may be a stupid question, and I'm sorry if it is, I did try and go back through comments but didn't see an answer to my question. I have 2 rotating lights that I would like to turn on/off while opening & closing. I've tried grouping both into a group: [Hangar 3 Lights] Airlock Light and that didn't work, tried naming them individually: [Hangar 3 Lights] Airlock Light 1 & [Hangar 3 Lights] Airlock Light 2 (also tried without the numbers) and nothing I seem to do gets the lights to turn on/off when opening and closing the hanger doors. Then I tried adding in the Airlock Light config into the Custom Data section, and it just isn't working. I'm really hoping you can provide some insight into what I'm doing wrong. Thanks for your time and for a great script.
Whiplash141  [author] 29 Mar, 2023 @ 8:57am 
I used it yesterday so I doubt that. What _precisely_ isn't working for you?
lordfrogman 28 Mar, 2023 @ 10:56pm 
dear Mr whiplash your image converter is broken can u fix please