Difference between revisions of "Osiris/API/TeleportToPosition"

From Divinity Engine Wiki
Jump to: navigation, search
m
m
Line 5: Line 5:
 
===== Notes =====
 
===== Notes =====
 
* If '''_SourceObject''' is a character, then the '''_Y''' coordinate will be ignored and the character will snap to the floor at the destination location. If the destination location is not valid on the [[AI_grid|AI grid]], the game will find a nearby valid location on the AI grid and place the character there.
 
* If '''_SourceObject''' is a character, then the '''_Y''' coordinate will be ignored and the character will snap to the floor at the destination location. If the destination location is not valid on the [[AI_grid|AI grid]], the game will find a nearby valid location on the AI grid and place the character there.
* See [[Osiris/API/TeleportTo|TeleportTo]] for other notes that also apply to this call.
+
* See [[Osiris/API/TeleportTo|TeleportTo]] for other notes that also apply to this call, but note that this variant does '''not''' include the experimental support for teleporting triggers (it won't do anything for them). If you wish to teleport a trigger, use '''TeleportToPosition''' with a ``Helper_Invisible_A`` and then a regular [[[[Osiris/API/TeleportTo|TeleportTo]] call to teleport the trigger to this helper.
 +
 
 
===== See Also =====
 
===== See Also =====
 
* [[Osiris/API/TeleportTo|TeleportTo]]
 
* [[Osiris/API/TeleportTo|TeleportTo]]
  
 
[[Category:Osiris Calls|TeleportToPosition]]
 
[[Category:Osiris Calls|TeleportToPosition]]

Revision as of 13:40, 16 May 2018

Full Definition(s)
  • call TeleportToPosition((GUIDSTRING)_SourceObject, (REAL)_X, (REAL)_Y, (REAL)_Z, (STRING)_Event, (INTEGER)_TeleportLinkedCharacters)
Description

Teleports the object _SourceObject to the coordinates (_X, _Y, _Z). Once the object arrives there, the event _Event will be sent to _SourceObject. If _SourceObject is a player character and _TeleportLinkedCharacters is 1, then all characters currently chained to _SourceObject will also be teleported.

Notes
  • If _SourceObject is a character, then the _Y coordinate will be ignored and the character will snap to the floor at the destination location. If the destination location is not valid on the AI grid, the game will find a nearby valid location on the AI grid and place the character there.
  • See TeleportTo for other notes that also apply to this call, but note that this variant does not include the experimental support for teleporting triggers (it won't do anything for them). If you wish to teleport a trigger, use TeleportToPosition with a ``Helper_Invisible_A`` and then a regular [[TeleportTo call to teleport the trigger to this helper.
See Also