DirkScripts
Docs
π’ Keypad

dirk_keypad is a small, reusable keypad resource. Put the keypad on any wall, door, safe or container. When a player uses it, the camera moves onto the keypad and they type the code with the mouse or the number keys.
It comes two ways:
- dirk_keypad, the script: the keypad models plus everything that makes them work. Your scripts use it through exports.
- dirk_keypadModel, the models only: for servers that want to drive the keypad from their own code. See Model Only.
#Features
- Real keys, not a menu. Each of the 12 keys is its own part that moves in when pressed, springs back with a small overshoot, and tips slightly toward the side you clicked.
- A live screen. The display shows the prompt, one dot per digit, and ACCESS GRANTED, ACCESS DENIED or LOCKED with a countdown.
- Checked on the server. The code, the attempt count and the lockout all live on the server. The player's game only draws the keypad and sends what they typed, so a cheater can't read the code or skip the check.
- Attempt limits. Set how many wrong codes the keypad takes before it locks, and for how long. A lockout locks it for everyone (or per player, if you choose), and the keypad on the wall shows a red padlock screen to everyone nearby.
- Light you control. Set the key backlight colour and brightness, turn the red and green LEDs on, off or blinking, and dim the screen. The keypad also throws a little real light onto the wall.
- Native sounds, heard by everyone nearby. A click on each key press, a chime on the right code and a buzz on the wrong one. They play from the keypad itself.
- 13 languages. The screen follows dirk_lib's language when dirk_lib is running, or a convar when it isn't.
- No dependencies. It runs on its own; dirk_lib is optional.
- Light on your server. The prop on the wall is a single cheap model. The detailed keypad, with its moving keys and live screen, only appears while someone is using it, and only for that player. The whole resource streams about 145 KB.
#How it works

- On the server, your script registers a keypad with its code and what happens when someone gets it right.
- On the client, your script places the
dirk_keypadprop and callsKeypad(entity, { id = ... })when a player uses it. - The detailed keypad swaps in over the wall prop, and the camera eases onto it.
- The player types the code. The server checks it and the screen shows the answer.
- If it's right, the server runs your
onGranted: open the door there, on the server.
Last updated on 30 September 2026
