Hello,
I was wondering if it is possible to teleport the party to an object ingame (presure plate connected to a script)
For intance another presure plate or something like floor_dirt_23 ?
And how would you do that?
teleporting to object ingame
Re: teleporting to object ingame
A teleporter component has a teleport target you can set, either via the editor or in a LUA script:
setTeleportTarget(level, x, y, elevation)
If you want to teleport to an object, just set the teleport target values to the location of the object. Even easier, in the editor you can click the "?" next tot select target and click on the object you want to teleport too.
Now, if the object moves and you want to always teleport to it, you have to set the teleport target to that of the object's current X, Y, level and elevation every time it moves. Of course, if you use the teleporter and teleport on top of some objects, like a monster for example, you will tele-frag him!
setTeleportTarget(level, x, y, elevation)
If you want to teleport to an object, just set the teleport target values to the location of the object. Even easier, in the editor you can click the "?" next tot select target and click on the object you want to teleport too.
Now, if the object moves and you want to always teleport to it, you have to set the teleport target to that of the object's current X, Y, level and elevation every time it moves. Of course, if you use the teleporter and teleport on top of some objects, like a monster for example, you will tele-frag him!