How to add a Deus Ex style door
The security keypad is one of the more common things you run into in Deus Ex, so you'll undoubtedly want some in your maps.
Download example map (52K), Provided by Vu Ngoc Toan
First, you'll need to add the keypad into your map. Make sure "Classes" is selected in the Browse drop-down, and expand the following items: Decoration, DeusExDecoration, ElectronicDevices, HackableDevices, and Keypad. Now select either Keypad1, Keypad2, or Keypad3. All three types work exactly the same, but they will look different in the game:
Move the cursor into one of the 2D views and right-click where you want the keypad to go. Select it and rotate/move it to where you want it. A good rule of thumb is to place it around 60 to 80 units above the floor. That translates to 4-5 grid squares if you have the grid size set to 16. Of course, you can get as creative as you want, as long as the keypad is accessible.
Normally you will assign a 4 or 5 digit number to the keypad that is the code for unlocking or deactivating whatever object it's attached to. You can also use the "#" and "*" keys, but that would go against the normal Deus Ex convention. Make sure the keypad object in your map is selected, right-click it, and select Properties. Expand the Keypad item, and enter the code you want to assign in the validCode field. If you want the door to unlock and open when the user has entered the correct code or hacked the keypad, set the bToggleLock to False, otherwise leave it True and the door will only unlock.
If you don't want the player to be able to hack your keypad with multi-tools, go into the HackableDevices property and set bHackable to False. Usually this will be set to True, unless it opens up something really special that you want to save for later. If you want to allow you keypad to be hacked, set the "strength" (how many multi-tools is takes to bypass your keypad), by using the hackStrength value. A value of 0.2 will set it to 20%. So, for example, a player who has not upgraded their electronics skills will need two multi-tools to hack a 20% strength keypad.
Now for the fun part. You can use a keypad to do a variety of things, but here we'll just set it up for its most common use - unlocking a door. Since regular Unreal movers do not have a "locked" property, you will need to attach your keypad to a DeusExMover. For more information, see How to add a Deus Ex style door. The DeusExMover in your map must have bIsDoor set to True and you'll normally want to set bLocked to True. (otherwise, what's the point of the keypad, right?) I would also set bHighlight to True.
Select the DeusExMover object in your map that is the door you want to associate with your new keypad. Right-click to get to its properties and expand the Events item. Fill in the Tag value with something, such as Door1. Remember this name, write it down, or copy it into the Windows clipboard with Ctrl-C.
Now go back to your keypad and pull up its properties. Expand its Events item and put the name you gave your door into the Event field. You should now see a red line connecting the keypad to your door. If you don't, you did something wrong.
Rebuild your geometry with F8, save your level, and give it a try.
There are uses for a keypad other than unlocking a door, so experiment!
Back to main page