Table of Contents

Doors

Closing and Locking

door_keep_open

(int)

Setting this on door will keep the door open, i.e. no automatic closing of door.

door_radius

(float)

Distance from door which is checked to see if there is someone, and if so then doors is not closed. Default is 20.0 meters. If it is < 0, then players near door are not checked at all.

door_delay

(float)

Number of seconds to wait before checking whether the door should be closed. If not set then default is 180.0 seconds. If it is < 0, then doors will never be closed.

key_tags

(string)

Comma separated list of tags which can be used as keys. The list is checked in the order. If the tag ends with *, then any tag starting with that prefix is accepted (note, that do not put too many of those on the list, and put them as last items on the list, as those require going through the full inventory of player every time).

key_tags_remove

(string)

Same as key_tags, but the object is removed after it is used as a key. Key_tags is checked first and then this.

takekey

(int)

If this is set true then the KeyTag set on the door is removed after it is used to open door.

door_lock_delay

(float)

Timeout after which the door is locked again in seconds. Default is 240. If it is < 0 then doors are not locked again.

door_keep_unlocked

(int)

If set then door is not relocked.

door_keep_locked

(int)

Door will automatically relock itself immediately when it is unlocked.

placeable_delay

(float)

Number of seconds after which the placeable is closed when open. Default is 60 seconds.

open_animation

(int)

Animation to use to open door, defaults to ANIMATION_LOOPING_GET_MID (13). Other usable values:

door_unlock_unlinked

(int)

If set then do not unlock the linked door when this door is unlocked.

door_lock_unlinked

(int)

If set then do not lock the linked door when this door is locked.

Destination and transfer

destination

(location)

Location where you transfer when you click on the open door. This is used first if set. Then destination string tag is used next, and then the WP_ + tag of the door third.

destination

(string)

Waypoint / object / door tag to where to transfer when the door is used. The nearest object is used if it is on the same area, if no object is found from the same area, then use the first object on other areas.

adjust_distance

(float)

Number of meters to adjust the position of player after the jump. Default is 2.0 meters for doors, and 0.0 for others.

adjust_direction

(float)

Direction where to adjust the player after the jump. Default is towards the facing of the object or away from it for doors.

adjust_facing

(float)

Number of degrees to adjust the player facing after the transfer. Default is set the player facing towards to same direction as object, and then adjust it with this. For doors default is 180.0 so player is turned away from door. For other objects this is 0.0, so player is left facing to same direction as object.

direct_transfer

(int)

If set on placeable then player is transfered directly to the target, otherwise the open animation is played first. For doors, trapdoors etc this should not be set, as they require the open animation, but for the tents, portals etc the open animation does not do anything so setting this will cause players to transfer on the first click.

placeable_entry_delay

(float)

Number of seconds after which the placeable is closed when someone enters it. Default is 10 seconds.

door_notice_distance

(float)

Number of meters how far the creatures will try to detect player if he is invisible. Default is 10.0 meters.

door_notice_multiplier

(float)

Multipler for the distance in meters from the door to creature to get the DC of the SPOT check. Default is 2.0. If creature is 7 meters from door, and this is set to 2, then the DC for the creature to SPOT the door opening is 14.

Misc settings

damage_limit

(int)

Number of hits required to break the lock. Default is DC*DC. If < 0, then player cannot break the lock regardless of damage.

Visual effects

transfer_vfx

(int)

Visual effect number to apply on the door when player goes through it. If 0, then no visual effect is played.

transfer_vfx_type

(int)

Number Type of the visual effect
0 DURATION_TYPE_INSTANT (default)
1 DURATION_TYPE_TEMPORARY
2 DURATION_TYPE_PERMANENT

transfer_vfx_duration

(float)

Duration of the effect (only for DURATION_TYPE_TEMPORARY, default is 0.0 seconds).

transfer_vfx_delay

(float)

How much the effect is delayed. Default is 0.0 seconds.

transfer_vfx_target*

(*)

Same as transfer_vfx*, but for the target door / placeable (does not work for the location).

transfer_vfx_player*

(*)

Same as transfer_vfx*, but for the player going through.

force_vfx*

(*)

Similar than transfer_vfx*, but for door, when player succeeds breaking the lock.

force_vfx_player*

(*)

Similar than force_vfx*, but for player, when player succeeds breaking the lock.

damage_vfx*

(*)

Similar than force_vfx*, but for door, when player damages it, but does not break it yet.

damage_vfx_player*

(*)

Similar than damage_vfx*, but for player.

open_vfx*

(*)

Similar than transfer_vfx*, but for door, when player opens it.

open_vfx_player*

(*)

Similar than open_vfx*, but for player.

lock_vfx*

(*)

Similar than transfer_vfx*, but for door when player locks it.

lock_vfx_player*

(*)

Similar than transfer_vfx*, but for player.

unlock_vfx*

(*)

Similar than transfer_vfx*, but for door when player unlocks it.

unlock_vfx_player*

(*)

Similar than transfer_vfx*, but for player.

Hooks

Following variables can be on the door, and they set the hooks that will be called before the actual operation happens. Those scripts will be called on the door, and the door will have following variables set “HookPC” (PC doing action), “Hook” (name of hook (i.e. OnUsed)), and they can set “HookReturn” variable to return value back to the normal default script. If they return non zero, then the normal action for the default script is skipped.

OnUsed

(string)

Hook that will be called from the _gen_door_are script.

OnAreaTransitionClick

(string)

Hook that will be called from the _gen_door_are script.

OnClose

(string)

Hook that will be called from the _gen_door_clo script.

OnDamaged

(string)

Hook that will be called from the _gen_door_dam script.

OnFailToOpen

(string)

Hook that will be called from the _gen_door_fai script.

OnLock

(string)

Hook that will be called from the _gen_door_loc script.

OnOpen

(string)

Hook that will be called from the _gen_door_ope script.

OnUnLock

(string)

Hook that will be called from the _gen_door_unl script.

Secret doors

Following variables are on the trigger of secret door. Most of them are copied to the actual door after it is created when secret door is found.

Finding the door

secret_dc

(int)

DC of the secret, if not set use the KeyTag of trigger

secret_skill

(int)

Default skill number to use for searching the secret if not set, then use SKILL_SEARCH. Cannot use ANIMAL_EMPATHY.

secret_class

(int)

Class who can easily detect. Use for example the numeric value of CLASS_TYPE_RANGER.

secret_class_dc

(int)

DC (class level + d4) for that class to detect, must be set if secret_class is set.

secret_announce

(int)

if set to true, then play voice chat when the secret is found (_gen_secret_door does this)

Revealing, Locking and Transition

secret_locked

(int)

Should the secret object be revealed as locked (set to 1), or should it be left as it is now (i.e keep the status from the resref)

secret_delay

(float)

Amount of seconds after the door is again hidden. If < 0, then it is not hidden again. If 0 then default of 30 seconds is used.

secret_keep

(int)

If set then do not hide the door.

secret_radius

(float)

If player is closer than this do not hide door. If 0.0 then use default of 5.0 meters.

location

(location)

Location where the secret object is created.

location

(string)

Name of the waypoint where the secret object is created

secret_resref

(string)

ResRef of the secret revealed. ztk_secret_w_{w,m,s} for wall doors, and ztk_secret_t_{w,s,g,gs} for trap doors.

secret_vars

(string)

Comma separated list of variables to be copied from the trigger to the item created. All door related variables above are automatically copied from the trigger to door.

reveal_tags

(string)

Comma separated list of tags of the items, which reveals the trigger to user without skill check if posessed by the user

secret_tag

(string)

New tag for the item created.

Visual effects

secret_announce_vfx*

(*)

Similar than transfer_vfx*, but for player who notices the secret.

secret_henchman_vfx*

(*)

Similar than transfer_vfx*, but for henchman who notices the secret.

secret_reveal_vfx*

(*)

Similar than transfer_vfx*, but for secret door when it appear

secret_reset_vfx*

(*)

Similar than transfer_vfx*, but for secret door when it disappears