Pick up the crowbar of research scientist Gordon Freeman, who finds himself on an alien-infested Earth being picked to the bone, its resources depleted, its populace dwindling. Freeman is thrust into the unenviable role of rescuing the world from the wrong he unleashed back at Black Mesa. And a lot of people, people he cares about, are counting on him.

Post tutorial Report RSS Automatic Sliding Doors

Learn how to create Star Trek style doors that slide into the ceiling when a player approaches.

Posted by on - Intermediate Mapping/Technical

In this tutorial, you will learn how to create a simple automatic sliding door that opens when the player approaches. It’s just like on Star Trek! This tutorial assumes intermediate knowledge of Hammer.


First, create a small basic room. Mine is about 214 by 378 units, and it doesn’t need to be much bigger.
Tutorial Image
Next, create a brush in the center of the room about the shape that you want your door. Press ‘control+T’ and tie it to a “Func_door” entity. Change the following properties:

Name: Door01
Speed: 135
Move direction: (Click the arrow) Up
Tutorial Image
All of the other properties are optional.

Create walls around your door. Don’t worry, the door won’t get stuck on them.
Tutorial Image

Create a “Logic_Compare” entity somewhere on the map.
Tutorial Image
Set its name to “Compare” and set the following output:

My Output Named: OnEqualTo
Target Entities Named: Door01
Via This Input: Close

Next, create a brush textured with the “tools/toolstrigger” texture on the floor extending on each side of your door, (see picture). Use Control+T to tie it to a “Trigger_Multiple”, and give it the outputs shown in the picture below.
Tutorial Image

The properties are:

My Output Named: OnEndTouchALl
Target Entities Named: Compare
Via This Input: Set Value
Parameter override of : 0

My Output Named: OnStartTouch
Target Entities Named: Compare
Via This Input: Set Value
Parameter override of : 1

My Output Named: OnStartTouch
Target Entities Named: Door01
Via This Input: Open
Parameter override of : 0

My Output Named: OnStartTouch
Target Entities Named: Compare
Via This Input: Compare
Parameter override of : 0
After A Delay In Seconds Of: 4.00

Finally, create an “info_player_start” somewhere on the map, if you haven’t done so already.
Tutorial Image

You’re finished! Now you have futuristic automatic sliding doors that retract into the ceiling! It may be a good idea to include an area for the door to slide into, rather that clipping through the ceiling.

The Finished map (Ceiling cut away)
The Finished map (Ceiling cut away)

As always, for questions or feedback, you can email (hambandito@gmail.com) or PM me.

-Psalm

Post comment Comments
Psalm Author
Psalm - - 32 comments

Tutorial updated to include the written properties.

Reply Good karma+1 vote
KaptianKrunch
KaptianKrunch - - 35 comments

very very nice its cool to see an organization giving back to the community keep it up guys

Reply Good karma Bad karma+1 vote
KaptianKrunch
KaptianKrunch - - 35 comments

might zoom in on the key parts instead of the whole thing now that I read over the whole thing lol good tut though

Reply Good karma Bad karma+1 vote
Psalm Author
Psalm - - 32 comments

I'm a bit confused by the above comment... which organization are you referring to, KaptianKrunch?

Reply Good karma+1 vote
Sallycin
Sallycin - - 635 comments

I'm also confused. I think he might believe this is by the Art Institute Online since it's sponsered by them.

@KaptianKrunch

This is all by Psalm as far as I know.

Reply Good karma Bad karma+1 vote
Arkanj3l
Arkanj3l - - 174 comments

I use func_movelinear for the most part. It is more general purpose, and therefore more handy through practice. However you need a good knowledge of the I/O system.

Reply Good karma Bad karma+1 vote
Sallycin
Sallycin - - 635 comments

The output is readable, but it can be pretty hard to make out. A written out version wouldn't go amiss. Nevertheless, another great review.

Reply Good karma Bad karma+1 vote
INtense! Staff
INtense! - - 4,100 comments

Another top tutorial. Keep them coming!

Reply Good karma+2 votes
Psalm Author
Psalm - - 32 comments

I do hope that you can read the outputs for the trigger in the picture... let me know if you can't, and I'll update the tutorial with the written outputs.

Reply Good karma+1 vote
Psalm Author
Psalm - - 32 comments

Indeed, I'm not affiliated with Moddb's new sponsor, though a few of the other tutorials are by the AIO.

Reply Good karma+1 vote
laserpanda
laserpanda - - 181 comments

Another great tutorial. I'm trying to make a map now where you defend a house from waves of combine using your tutorials.

Reply Good karma Bad karma+1 vote
micmac
micmac - - 6 comments

hey nice tutorial, except i encountered a problem. whenever i run the map i get the door all right but the damn things sideways and on an angle! its rather annoying.. but im sure its just something stupid on my part... so good tutorial!

Reply Good karma Bad karma+1 vote
Psalm Author
Psalm - - 32 comments

If it keeps happening, PM me and I'll try to help you out. :D

Reply Good karma+1 vote
fiddlerkain9
fiddlerkain9 - - 4 comments

You set the direction of the brush to those angles within the editor. You need to set the "move" to a specific direction not the actual brush itself.

Just reset where it says Pitch/Yaw/Roll to 0 0 0.


Reply Good karma Bad karma+1 vote
lemminglord
lemminglord - - 2 comments

Thank you for the great tutorial, but I have a problem. I have tied the rigger to the trigger_multiple, but when I go to make the outputs, the little symbol in the bottom left hand corner has a red slash through it, and the output name box is greyed out! What am I doing wrong?

Reply Good karma Bad karma+1 vote
Psalm Author
Psalm - - 32 comments

I know that the above question was posted more than two weeks ago, but if you're still watching lemminglord, then the red slash means that an output in invalid for whatever reason, such as having the target entity set to a non-existent object. Check to see that the name of the object your trigger is referring to is correct.

It's much easier for questions for me about tutorials to be emailed or PM'd, as otherwise I'd have to search through the comments of every single tutorial.

Reply Good karma+1 vote
Kaemon
Kaemon - - 2 comments

No offense, I'm far away from being an expert doing maps and such, but I was trying and doing this tutorial, when I found (It's my guess) an easier way of doing this door.

In my opinion, you dont need the Logic Compare for this at all.
I just put on the Trigger Multiple:

- On Start Touch / Door / Open
- On End Touch All / Door / Close

And thats all.
In the Door's Key Value "Delay Before Reset" I put -1 so it doesnt close if you stay under it, and I did the Trigger Multiple taller so you can "End Touch It" if you jump.

As told, I'm not an expert at all; is there something special your Logic Compare version does that I must be missing? (Serious question, and for this kind of door)

Reply Good karma Bad karma+4 votes
Stevokenevo
Stevokenevo - - 68 comments

Hey, good tutorial.

What kaemon says also works for me, but if you put -1 for the 'delay before reset' the trigger then stops after one use and you have to touch the door to open it. You can work around that by testing different delays out in the properties and outputs tabs.

But like kaemon said, is there another benefit to using the logic_compare?

Reply Good karma Bad karma+1 vote
Post a comment

Your comment will be anonymous unless you join the community. Or sign in with your social account: