Dz door

==Entity Description==
Acts similarly to prop_door_rotating, but has an extra property to act like a security door that can be opened only by paying money.
==Keyvalues==
; Slave name <targetname>
: Name of any door(s) that should open and close at the same time as this one. You could also give them all the same name.
; Hardware Type <choices>
: The type of mechanism used to open the door (handle, push bar, keypad). The mechanism only appears in the game, not in Hammer.
:* None
:* Lever (i.e. door handle)
:* Push bar
:* Keypad 
; Spawn Position <choices>
: State the door should begin in. Check the door's angles to see forward/backward orientation.
:* Closed
:* Open forward
:* Open back
:* Ajar
; Ajar Angles <angle>
: If "Spawn Position" is "ajar", these are the angles to spawn at instead of being open or closed.
; Hinge Axis <axis>
; Rotation Distance <float>
: Number of degrees that the door should open, both forward and backward.
; Speed <float>
: In degrees/second.
; Fully Open Sound <string>
: Sound played when the door has finished opening.
; Fully Closed Sound <string>
: Sound played when the door has finished closing.
; Moving Sound <string>
: Sound played when the door starts to move.
; Locked Sound <string>
: Optional overrides to the sounds played by the door. Sound played when the player tries to open the door, and fails because it's locked.
; Unlocked Sound <string>
: Optional overrides to the sounds played by the door. Sound played when the door is unlocked.
; Delay Before close <int>
: Number of seconds the door waits until closing by itself. -1 means never auto-close.
; Damage Inflicted When Blocked <int>
: If an entity is blocking the door from moving, inflict this much damage per frame.
; Force Closed <bool>
: If set, this door will close no matter what. Useful for doors that have to close even if the player tries to block them with objects.
; Open Direction <choices>
: Force the door to open only forwards or only backwards. It will normally try to swing away from the entity that opened it, unless it is being blocked on the other side.
:* Both directions
:* Forward only
:* Backward only
; Glow Distance <integer>
: Distance before glow disappears.
; Does the prop glow by default? <choices>
: Make prop glow by default?
; Glow Color (R G B) <Color255>
: The color of the glow (if enabled).
; Damage Filter Name (damagefilter) <targetname>
: Name of the filter entity that controls which entities can damage us.
; Security Door <bool>
: This is a security door
== Flags ==
* 1 : Starts Open
* 2048 : Starts locked
* 4096 : Door silent (No sound, and does not alert NPCs)
* 8192 : Use closes
* 16384 : Door silent to NPCs (Does not alert NPCs)
* 32768 : Ignore player +USE
* 524288 : Start Breakable
== Inputs ==
; Open
; Close
; Toggle
: Control door state
; OpenAwayFrom <targetname>
: Open the door away from the specified entity.
; Lock
: 
; Unlock
: Lock/unlock the door.
; SetRotationDistance <float>
: Degrees of rotation that the door will open.
; SetSpeed <float>
: Set the speed at which the door rotates. 
; SetUnbreakable
: The door can't be broken.
; SetBreakable
: The door can be broken.
== Outputs ==
</onlyinclude>
== Setting up Security Doors for Danger Zone ==
Name the door in similar pattern: door1-secgate.door, this seems to be hard coded, the -secgate.door part needs to be always there with name before the hyphen.
Add a keyvalue counter_name secgate.counter this property is not part of the entity and needs to be added with SmartEdit off.
Set property Security door to Yes.
Place prop_counter next to the door and name it in similiar pattern: door1-secgate.counter, this seems to be hard coded, the -secgate.counter part needs to be always there with name before the hyphen.
Place point_dz_weaponspawn behind the door and change the Door Name property to match the name of the door, in this case it would be: door_name door1-secgate.door.
Add a keyvalue tagBehindSteelDoor 1 this property is not part of the entity and needs to be added with SmartEdit off. This will let the door know what's behind it so it can give the correct price for that item or to spawn the door open if nothing's behind it.