This creates a sliding momentary door that opens or closes in coordination with a
momentary_rot_button
that is being used (by players or triggers), and which has the name of this entity as its target.
The position of the
momentary_door
is synchronized with the
momentary_rot_button
currently driving it, meaning the button halfway in its rotation will have the door likewise halfway to its open position. Conversely, when the
momentary_rot_button
is set to auto-return, the
momentary_door
auto-returns at the same rate.
The momentary aspect of these
momentary_*
entities means you can have them be at any position at any time, instead of the usual [rotating] doors and buttons which travels automatically between the two endpoints (closed and open positions) on [each] use.
Attributes
Many properties listed do not work as expected or at all, as the entity is fundamentally different from a
func_door
and much dependent on the state of the
momentary_rot_button
actuating it.
- Name (targetname) - Property used to identify entities.
- Global Entity Name (globalname)
- Pitch Yaw Roll (angles) - Sets the pitch (up / down), yaw (left / right) and roll (bank) respectively. The compass in WorldCraft / Hammer corresponds to Yaw. The settings are not always (or not all) used.
- Master (master) - The name of a
multisource
(or game_team_master
) entity. A master must usually be active in order for the entity to work. Thus they act almost like an on/off switch, in their simplest form, and like an AND gate in the case of the multisource
. Note: momentary_door
's can always be used, regardless of the state of their master.
- Target (target) - Not used.
- Delay before fire (delay) - Not used.
- Kill Target (killtarget) - Not used.
- Render FX (renderfx) - Gives objects special render effects. Think of it as modifying whatever the Render Mode puts out. The options are as follows:
- 0 = Normal
- 1 = Slow Pulse
- 2 = Fast Pulse
- 3 = Slow Wide Pulse
- 4 = Fast Wide Pulse
- 5 = Slow Fade Away
- 6 = Fast Fade Away
- 7 = Slow Become Solid
- 8 = Fast Become Solid
- 9 = Slow Strobe
- 10 = Fast Strobe
- 11 = Faster Strobe
- 12 = Slow Flicker
- 13 = Fast Flicker
- 14 = Constant Glow
- 15 = Distort
- 16 = Hologram (Distort and Fade)
- Render Mode (rendermode) - Controls the type of rendering that is used for an object. Options are:
- 0 = Normal
- 1 = Color
- 2 = Texture
- 3 = Glow
- 4 = Solid
- 5 = Additive
- FX Amount (renderamt)
- FX Color (rendercolor)
- Move Sound (movesnd) - The sound that is played when the door opens. Options are:
- 0 = No Sound (
common/null.wav
)
- 1 = Servo (Sliding) (
doors/doormove1.wav
)
- 2 = Pneumatic (Sliding) (
doors/doormove2.wav
)
- 3 = Pneumatic (Rolling) (
doors/doormove3.wav
)
- 4 = Vacuum (
doors/doormove4.wav
)
- 5 = Power Hydraulic (
doors/doormove5.wav
)
- 6 = Large Rollers (
doors/doormove6.wav
)
- 7 = Track Door (
doors/doormove7.wav
)
- 8 = Snappy Metal Door (
doors/doormove8.wav
)
- 9 = Squeaky 1 (
doors/doormove9.wav
)
- 10 = Squeaky 2 (
doors/doormove10.wav
)
- Stop Sound (stopsnd) - The sound that is played after the door closes. Note:
momentary_door
does not play stop sounds. Options are:
- 0 = No Sound (
common/null.wav
)
- 1 = Clang with brake (
doors/doorstop1.wav
)
- 2 = Clang reverb (
doors/doorstop2.wav
)
- 3 = Ratchet Stop (
doors/doorstop3.wav
)
- 4 = Chunk (
doors/doorstop4.wav
)
- 5 = Light airbrake (
doors/doorstop5.wav
)
- 6 = Metal Slide Stop (
doors/doorstop6.wav
)
- 7 = Metal Lock Stop (
doors/doorstop7.wav
)
- 8 = Snappy Metal Stop (
doors/doorstop8.wav
)
- Locked Sound (locked_sound) - Sounds to play when the entity is 'locked'. Options are:
- 0 = None
- 2 = Access Denied
- 8 = Small zap
- 10 = Buzz
- 11 = Buzz Off
- 12 = Latch Locked
- Unlocked Sound (unlocked_sound) - Sound to play when entity is 'unlocked'. Options are:
- 0 = None
- 1 = Big zap & Warmup
- 3 = Access Granted
- 4 = Quick Combolock
- 5 = Power Deadbolt 1
- 6 = Power Deadbolt 2
- 7 = Plunger
- 8 = Small zap
- 9 = Keycard Sound
- 10 = Buzz
- 13 = Latch Unlocked
- 14 = Light Switch
- Locked Sentence (locked_sentence) - Sentence that is spoken when entity is 'locked'. Options are:
- 1 = Gen. Access Denied
- 2 = Security Lockout
- 3 = Blast Door
- 4 = Fire Door
- 5 = Chemical Door
- 6 = Radiation Door
- 7 = Gen. Containment
- 8 = Maintenance Door
- 9 = Broken Shut Door
- Unlocked Sentence (unlocked_sentence) - Sentence that is spoken when entity is 'unlocked'. Options are:
- 1 = Gen. Access Granted
- 2 = Security Disengaged
- 3 = Blast Door
- 4 = Fire Door
- 5 = Chemical Door
- 6 = Radiation Door
- 7 = General Containment
- 8 = Maintenance area
- Speed (speed) - Speed the door moves at. Defaults to 100. Always move to the position set by
momentary_rot_button
in 0.1s.
- Delay before close (wait) - Time to wait before the door closes after opening (-1 makes it stay open) An auto-returning
momentary_rot_button
immediately begins closing.
- Lip (lip) - Number of units left after move (the lip value is subtracted from the move distance).
- Damage inflicted when blocked (dmg) - How much damage the player receives if he gets stuck between the door and something solid. Defaults to 2.
- Message if triggered (message)
- Fire on close (netname)
- Health(shoot open) (health) - With a non-zero value here, the door will have to be damaged to this extent to open. (Bogus entry inherited from
func_door
.)
- Minimum light level (_minlight)
- ZHLT Lightflags (zhlt_lightflags)
- Light Origin Target (light_origin)
Flags
Same situation as the attributes; everything but (1) & (2048) doesn't work, as the entity is entirely dependent on the momentary_rot_button
actuating it.
- Starts open (1) - Door starts in its 'open' position.
- Don't link (4)
- Passable (8)
- Toggle (32)
- Use only (256) - Player must "use" to open. Enabling this prevents the entity being triggered any other way.
- Not in Deathmatch (2048)
Notes
- Setting up a
momentary_door
is similar as setting up a func_door
, except it needs a name and it must be targeted by at least one momentary_rot_button
.
- In case of multiple
momentary_rot_button
's targeting the same momentary_door
, the one being USEd (and the one that was just USEd if it's an auto-returning button) is the one dictating the door's position.
- You can use
game_counter_set
– in lieu of, or in addition to, a momentary_rot_button
– to explicitly set the door's position. Values are between 0.0 (closed) and 1.0 (open), both inclusive. Do note that if there's momentary_rot_button
(s) still targeting the door, the next time the button(s) was/were used the door will snap back to the button(s)'s position.
- To detect if the momentary door/button pair is within some range of positions (as part of gameplay – see Uplink), use the
momentary_door
(s) to push a func_pushable
through one "in range" trigger_multiple
entity, which in turn is sandwiched between two "out of range" trigger_multiple
entities, with all three triggers having the "Pushables" flag set. Tip: Use BEVEL
texture on the triggers for precise non-overlapping trigger area.
- Auto-returning
momentary_rot_button
's have a tendency to skip the final update, leaving the target momentary_door
slightly ajar. This needs to be accounted for when designing the momentary_door
. Alternatively, you can "detect" if the door is just shy of being closed using the method above, and use game_counter_set
to forcibly set the door shut (value=0).
See also
Team Fortress Classic only
Attributes
- Pitch Yaw Roll (angles) - Sets the pitch (up / down), yaw (left / right) and roll (bank) respectively. The compass in WorldCraft / Hammer corresponds to Yaw. The settings are not always (or not all) used.
- Target (target) - When an entity is activated, it triggers the entity with the name specified by Target.
- KillTarget (killtarget) - When an entity is triggered, it will remove from the game the entity specified by this property.
- Master (master) - The name of a multisource (or game_team_master) entity. A master must usually be active in order for the entity to work. Thus they act almost like an on/off switch, in their simplest form, and like an AND gate in the case of the multisource.
- Move Sound (movesnd) - These apply either to door or elevator type entities. For doors, the options are as follows:
- 0 = No Sound
- 1 = Servo (Sliding)
- 2 = Pneumatic (Sliding)
- 3 = Pneumatic (Rolling)
- 4 = Vacuum
- 5 = Power Hydraulic
- 6 = Large Rollers
- 7 = Track Door
- 8 = Snappy Metal Door
- Move Sound (movesnd) - For elevators:
- 0 = No Sound
- 1 = big elev 1
- 2 = big elev 2
- 3 = tech elev 1
- 4 = tech elev 2
- 5 = tech elev 3
- 6 = freight elev 1
- 7 = freight elev 2
- 8 = heavy elev
- 9 = rack elev
- 10 = rail elev
- 11 = squeek elev
- 12 = odd elev 1
- 13 = odd elev 2
- Stop Sound (stopsnd) - This property is found in both door and elevator type entities. For doors, the options are:
- 0 = No Sound
- 1 = Clang with brake
- 2 = Clang reverb
- 3 = Ratchet Stop
- 4 = Chunk
- 5 = Light airbrake
- 6 = Metal Slide Stop
- 7 = Metal Lock Stop
- 8 = Snappy Metal Stop
- Stop Sound (stopsnd) - Elevator options:
- 0 = no sound
- 1 = big elev stop 1
- 2 = big elev stop 2
- 3 = freight elev stop
- 4 = heavy elev stop
- 5 = rack stop
- 6 = rail stop
- 7 = squeek stop
- 8 = quick stop
- Unlocked Sound (unlocked_sound) - Sound to play when entity is 'unlocked'. Options are:
- 0 = None
- 1 = Big zap & Warmup
- 3 = Access Granted
- 4 = Quick Combolock
- 5 = Power Deadbolt 1
- 6 = Power Deadbolt 2
- 7 = Plunger
- 8 = Small zap
- 9 = Keycard Sound
- 10 = Buzz
- 13 = Latch Unlocked
- 14 = Light Switch
- Render Mode (rendermode) - Controls the type of rendering that is used for an object. Options are:
- 0 = Normal
- 1 = Color
- 2 = Texture
- 3 = Glow
- 4 = Solid
- 5 = Additive
- Render FX (renderfx) - Gives objects special render effects. Think of it as modifying whatever the Render Mode puts out. The options are as follows:
- 0 = Normal
- 1 = Slow Pulse
- 2 = Fast Pulse
- 3 = Slow Wide Pulse
- 4 = Fast Wide Pulse
- 5 = Slow Fade Away
- 6 = Fast Fade Away
- 7 = Slow Become Solid
- 8 = Fast Become Solid
- 9 = Slow Strobe
- 10 = Fast Strobe
- 11 = Faster Strobe
- 12 = Slow Flicker
- 13 = Fast Flicker
- 14 = Constant Glow
- 15 = Distort
- 16 = Hologram (Distort and Fade)
- Targetname of teamcheck goal (teamcheck) - Using this in conjunction with an info_tf_teamcheck allows you to switch the entity's team allegiance when the info_tf_teamcheck changes its team setting. The team_no property must be set to Any (0) if you use this value.
- Has item # (items_allowed) - The player must be carrying this item to use this entity. Set 0 to ignore this criterion.
- Has item from group # (h_i_g) - The player must be carrying any item from this group to use this entity. Set 0 to ignore this criterion.
- Hasn't item from group # (hasnt_item_from_group) - To use this entity, the player must not be carrying any item from this group. Set 0 to ignore this criterion.
- If item # has moved (if_item_has_moved) - A player can only use the entity if this item is not in its original spawn location. Set 0 to ignore this criterion.
- If item # hasn't moved (if_item_hasnt_moved) - A player can only use the entity if this item is in its original spawn location. Set 0 to ignore this criterion.
- If goal # active (if_goal_is_active) - Players can only use the entity if this goal is in the active state. Set 0 to ignore this criterion.
- If goal # inactive (if_goal_is_inactive) - Players can only use the entity if this goal is in the inactive state. Set 0 to ignore this criterion.
- If goal # removed (if_goal_is_removed) - Players can only use the entity if this goal is in the removed state. Set 0 to ignore this criterion.
- If group # active (if_group_is_active) - A player can only use the entity if all the goals in this group are in the active state. Set 0 to ignore this criterion.
- If group # inactive (if_group_is_inactive) - A player can only use the entity if all the goals in this group are in the inactive state. Set 0 to ignore this criterion.
- If group # removed (if_group_is_removed) - A player can only use the entity if all the goals in this group are in the removed state. Set 0 to ignore this criterion.
- Affect all on Team (maxammo_shells) - This allows an entity's effects (giving ammo, taking health, etc.) to be performed on an entire team rather than just the Activating Player. Options are:
- 0 = Disabled
- 1 = Blue
- 2 = Red
- 3 = Yellow
- 4 = Green
- Affect all not on Team (maxammo_nails) - This allows an entity's effects (giving ammo, taking health, etc.) to be performed on all players in teams other than the one selected, ignoring the Activating Player. Options are:
- 0 = Disabled
- 1 = Blue
- 2 = Red
- 3 = Yellow
- 4 = Green
- If all goals in group # active... (all_active) - When activated, the entity will check to see if all goals in a given group are active. If so, it will activate another goal, which is specified by last_impulse.
- Remove goal # (rv_g) - When the entity is activated, it will remove the goal specified here.
- Restore goal # (rs_g) - When the entity is activated, it will restore the goal specified here.
- Inactivate goals in group # (inactivate_group_no) - When the entity is activated, it will deactivate all the goals in the group specified here.
- Remove goals in group # (rv_gr) - When the entity is activated, it will remove all the goals in the group specified here.
- Restore goals in group # (rs_gr) - When the entity is activated, it will restore all the goals in the group specified here.
- Remove Spawn point # (remove_spawnpoint) - On activation, the entity will remove the info_player_teamspawn entity with the Goal # entered here. While the spawnpoint is removed, no one can spawn there.
- Restore Spawn point # (restore_spawnpoint) - On activation, the entity will restore a removed info_player_teamspawn entity with the Goal # entered here. After being restored, players can once again spawn at the spawnpoint.
- Remove spawn group # (rv_s_h) - On activation, the entity will remove the group of info_player_teamspawn entities with the Goal Group # entered here. While the spawnpoints are removed, players cannot spawn at them.
- Restore spawn group # (rs_s_h) - On activation, the entity will restore the group of removed info_player_teamspawn entities with the Goal Group # entered here. After being restored, players can once again spawn at the spawnpoints.
- Item to give (items) - Note: There are exceptions (check SmartEdit names). The Item # of an item_tfgoal entity. When the entity is activated, the Activating Player will be given this item. If the item is already being carried by a player, it will be taken from the carrier and given to the Activating Player.
- Remove item from APA (axhitme) - The Item # of an item_tfgoal entity. When the entity is activated, if the Activating Player is carrying the specified item, it will be removed from him. What happens to it then is determined by the Goal Activation property of the item.
- Name (targetname) (targetname)
- Goal Activation bitfields (g_a)
- Goal Effects bitfields (g_e)
- Goal Result bitfields (goal_result)
- delay before close, -1 stay open (wait)
- Lip (lip)
- Damage inflicted when blocked (dmg)
- Message if triggered (message)
- Delay before fire (delay)
- Fire on Close (netname)
- Health (shoot open) (health)
- Speed (speed)
- locked_sound (Locked Sound)
- FX Amount (1 - 255) (renderamt)
- FX Color (R G B) (rendercolor)
- ZHLT Light flags (zhlt_lightflags)
- Minimum light level (_minlight)
- Team allowed to activate entity (team_no)
- Player class allowed to activate entity (playerclass)
- Effect radius, 0=infinite (t_length)
- If criteria fails activate Goal# (else_goal)
- ...activate goal# (last_impulse)
- Activate goal# (activate_goal_no)
- Inactivate goal# (inactivate_goal_no)
- Activate goals in group# (activate_group_no)
- Return item # (return_item_no)
- Remove items in group # (r_i_g)
- Add/Subtract frags (frags)
- Add/Subtract lives (lives)
- Add/Subtract health (health)
- Armor Value % (armorvalue)
- Armor Class (armorclass)
- Add/Subtract shells (a_s)
- Add/Subtract nails (a_n)
- Add/Subtract rockets (a_r)
- Add/Subtract cells (a_c)
- Add/Subtract detpack (ammo_detpack)
- Add/subtract grenades #1 (no_grenades_1)
- Add/subtract grenades #2 (no_grenades_2)
- Invincibility duration (invincible_finished)
- Invisibility duration (invisible_finished)
- Quad duration (super_damage_finished)
- Rad Suit duration (radsuit_finished)
- Score to AP team (count)
- Teamcheck team point gain (increase_team)
- Blue point gain (increase_team1)
- Red point gain (increase_team2)
- Yellow point gain (increase_team3)
- Green point gain (increase_team4)
- Owned by-for msg & item glow (owned_by)
- Owned by teamcheck (owned_by_teamcheck)
- Death type (deathtype)
- Message to all (b_b)
- Message to AP (message)
- Message to AP team (b_t)
- Message to non-AP team (b_n)
- Message to owner team (b_o)
- Message to non-owner team(s) (non_owners_team_broadcast)
- Console msg. to all, %s = AP name (n_b)
- Console msg to AP team (n_t)
- Console msg. to non-AP team (n_n)
- Console msg. to owner team (n_o)
- Speak (global) (speak)
- Speak (AP) (AP_speak)
- Speak (AP team) (team_speak)
- Speak (non-AP team) (non_team_speak)
- Speak (owner team) (owners_team_speak)
- Speak (non-owner teams) (non_owners_team_speak)
- Angular Velocity (PYR) (avelocity)