Trigger teleport: Difference between revisions
		
		
		
		
		
		Jump to navigation
		Jump to search
		
				
		
 Tip:You can use env_fade to smoothen the player's perspective while teleporting (0.6 seconds is a good duration to start with). If you're intending to teleport players in multiplayer, remember to set the triggering player only flag!
Tip:You can use env_fade to smoothen the player's perspective while teleporting (0.6 seconds is a good duration to start with). If you're intending to teleport players in multiplayer, remember to set the triggering player only flag!
 Note:Along with
Note:Along with  Fistful of Frags. It has been confirmed by the developer to be intentional.
 Fistful of Frags. It has been confirmed by the developer to be intentional.
 Bug:Some SDK versions list trigger_teleport flag 32 as "Preserve angles even when a local landmark is not specified" but are in conflict due to the newer flags above. To achieve the angle-preserving behavior, you can instead specify !activator for the landmark property.  [todo tested in ?]
Bug:Some SDK versions list trigger_teleport flag 32 as "Preserve angles even when a local landmark is not specified" but are in conflict due to the newer flags above. To achieve the angle-preserving behavior, you can instead specify !activator for the landmark property.  [todo tested in ?]
		
	
| mNo edit summary | No edit summary | ||
| (9 intermediate revisions by 6 users not shown) | |||
| Line 1: | Line 1: | ||
| {{ | {{LanguageBar}} | ||
| {{TabsBar|main=gs2|base=trigger_teleport}} | |||
| {{CD|CTriggerTeleport|file1=triggers.cpp}} | {{CD|CTriggerTeleport|file1=triggers.cpp}} | ||
| {{entity|trigger_teleport | {{this is a|brush entity|name=trigger_teleport}} | ||
| It is a [[trigger]] that teleports [[entity|entities]] that touch its volume.  Entities are teleported to the ''Remote Destination'', and have their angles set to that of the ''Remote Destination'''s angles.  If a ''Local Destination Landmark'' is specified, teleported entities are offset from the target by their initial offset from the landmark, and their angles are left alone. | It is a [[trigger]] that teleports [[entity|entities]] that touch its volume.  Entities are teleported to the ''Remote Destination'', and have their angles set to that of the ''Remote Destination'''s angles.  If a ''Local Destination Landmark'' is specified, teleported entities are offset from the target by their initial offset from the landmark, and their angles are left alone. | ||
| {{tip|You can use {{ent|env_fade}} to smoothen the player's perspective while teleporting (0.6 seconds is a good duration to start with). If you're intending to teleport players in multiplayer, remember to set the [[Env_fade#Flags|''triggering player only'' flag]]!}} | {{tip|You can use {{ent|env_fade}} to smoothen the player's perspective while teleporting (0.6 seconds is a good duration to start with). If you're intending to teleport players in multiplayer, remember to set the [[Env_fade#Flags|''triggering player only'' flag]]!}} | ||
| {{code  | {{Note|Along with <code>trigger_teleport_relative</code>, <code>trigger_teleport</code> is able to be created but is non-functional in {{fof|4}}. It has been confirmed by the developer to be intentional.}} | ||
| {{ | |||
| == Keyvalues == | |||
| {{KV Targetname}} | |||
| {{KV|Remote Destination|intn=target|target_destination|The entity specifying the point to which entities should be teleported.  Usually either a [[info_teleport_destination]] or [[info_target]].{{note|''Any'' entity can be used as the teleport destination, including players.}}{{tip|This can be changed if necessary by using {{Ent|AddOutput}}.}}{{warning|{{csgo}} Teleport to a killed teleport destination entity will crash your client/server.}}}} | |||
| {{KV|Local Destination Landmark|intn=landmark|target_destination|If specified, then teleported entities are offset from the target by their initial offset from the landmark.}} | {{KV|Local Destination Landmark|intn=landmark|target_destination|If specified, then teleported entities are offset from the target by their initial offset from the landmark.}} | ||
| {{ | :{{expand|[[File:Landmark in action.gif|512px]]<br/><center>'''Local Destination Landmark Usage'''</center><center>Player position relative to the landmark (when teleported) is transferred to the destination.<br/><small>Click to enlarge if GIF does not play</small></center>|title=Example}} | ||
| {{KV BaseTrigger}} | |||
| == Flags == | |||
| {{Fl BaseTrigger}} | |||
| {{bug|Some SDK versions list trigger_teleport flag 32 as "Preserve angles even when a local landmark is not specified" but are in conflict due to the newer flags above. To achieve the angle-preserving behavior, you can instead specify [[!activator]] for the landmark property.}} | |||
| == Inputs == | |||
| {{I BaseTrigger}} | |||
| == Outputs == | |||
| {{O BaseTrigger}} | |||
| == See also == | |||
| * [[Teleporters]] | |||
| * {{ent|point_teleport}} | |||
| * {{ent|info_teleport_destination}} | |||
| == | * {{ent|trigger_teleport_relative}} | ||
| {{ | |||
| {{ | |||
| {{ | |||
| {{sensor brush}} | {{sensor brush}} | ||
Latest revision as of 04:34, 10 March 2025
|  Class hierarchy | 
|---|
| CTriggerTeleport | 
|  triggers.cpp | 
trigger_teleport  is a   brush entity  available in all  Source games.
It is a trigger that teleports entities that touch its volume.  Entities are teleported to the Remote Destination, and have their angles set to that of the Remote Destination's angles.  If a Local Destination Landmark is specified, teleported entities are offset from the target by their initial offset from the landmark, and their angles are left alone.
 Source games.
It is a trigger that teleports entities that touch its volume.  Entities are teleported to the Remote Destination, and have their angles set to that of the Remote Destination's angles.  If a Local Destination Landmark is specified, teleported entities are offset from the target by their initial offset from the landmark, and their angles are left alone.
 Tip:You can use env_fade to smoothen the player's perspective while teleporting (0.6 seconds is a good duration to start with). If you're intending to teleport players in multiplayer, remember to set the triggering player only flag!
Tip:You can use env_fade to smoothen the player's perspective while teleporting (0.6 seconds is a good duration to start with). If you're intending to teleport players in multiplayer, remember to set the triggering player only flag! Note:Along with
Note:Along with trigger_teleport_relative, trigger_teleport is able to be created but is non-functional in  Fistful of Frags. It has been confirmed by the developer to be intentional.
 Fistful of Frags. It has been confirmed by the developer to be intentional.Keyvalues
- Name (targetname) <string>[ Edit ]
- The name that other entities refer to this entity by, via Inputs/Outputs or other keyvalues (e.g. parentnameortarget).
 Also displayed in Hammer's 2D views and Entity Report.See also: Generic Keyvalues, Inputs and Outputs available to all entities
- Remote Destination (target) <targetname>
- The entity specifying the point to which entities should be teleported.  Usually either a info_teleport_destination or info_target. Note:Any entity can be used as the teleport destination, including players. Note:Any entity can be used as the teleport destination, including players. Tip:This can be changed if necessary by using AddOutput. Tip:This can be changed if necessary by using AddOutput.
- Local Destination Landmark (landmark) <targetname>
- If specified, then teleported entities are offset from the target by their initial offset from the landmark.
- Example  - Local Destination Landmark Usage - Player position relative to the landmark (when teleported) is transferred to the destination. 
 Click to enlarge if GIF does not play
| 
 
 | 
Flags
| 
 
 
 
 
 
 
 
 | 
 Bug:Some SDK versions list trigger_teleport flag 32 as "Preserve angles even when a local landmark is not specified" but are in conflict due to the newer flags above. To achieve the angle-preserving behavior, you can instead specify !activator for the landmark property.  [todo tested in ?]
Bug:Some SDK versions list trigger_teleport flag 32 as "Preserve angles even when a local landmark is not specified" but are in conflict due to the newer flags above. To achieve the angle-preserving behavior, you can instead specify !activator for the landmark property.  [todo tested in ?]Inputs
| 
 
 
 
 | 
Outputs
| 
 
 
 
 
 
 | 



































