Tokio Posted April 3, 2018 Share Posted April 3, 2018 (edited) I want create a script, which tp a player to me, and teleport me to a player, like in admin panel, just with command. How to make this? For example: /tpto playername , and /tpme playername. And when i teleport a player to me, the player get out from vehicle Edited April 3, 2018 by 50cent Link to comment
myonlake Posted April 3, 2018 Share Posted April 3, 2018 (edited) You could use the following functions to make such a feature. -- To create a command handler "tpme" and "tpto" addCommandHandler -- Create an ipairs loop using these functions getAlivePlayers -- To get all alive players, for /tpme getElementsByType -- To get all elements of type "player", for /tpto getPlayerName -- To get the iterated player's name and make a partial match with the name entered to the command arguments -- Upon match getElementPosition -- To get your/found player's position getElementInterior -- To get your/found player's interior getElementDimension -- To get your/found player's dimension setElementPosition -- To teleport you/found player to the coordinates setElementInterior -- To teleport you/found player to the interior setElementDimension -- To teleport you/found player to the dimension Edited April 3, 2018 by myonlake 1 Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now