Jump to content

[HELP] About a teleport by command


28WL

Recommended Posts

When you write this command /Teleport, you go to: posX="-2016.80005" posY="130.2" posZ="5001" rotX="0" rotY="0" rotZ="0".

How It should look like, what I need to do?

addCommandHandler ( "Teleport", 
    function ( Teleport ) 
        if isAccountInGroup ( { "Owner", "Admin" }, getAccountName ( getPlayerAccount ( Teleport ) ) ) then 
            setTimer(function() 
  
            end, 1000, 1) 
        else 
            outputChatBox ("* You have no acces to that command.", Teleport ) 
        end 
    end 
) 

Link to comment
addCommandHandler ( "Teleport", 
    function ( Teleport ) 
        if isAccountInGroup ( { "Owner", "Admin" }, getAccountName ( getPlayerAccount ( Teleport ) ) ) then 
            setElementPosition ( Teleport, -2016.80005, 130.2, 5001 ) 
        else 
            outputChatBox ("* You have no acces to that command.", Teleport ) 
        end 
    end 
) 

P.S: isAccountInGroup is defined somewhere on the script, right?

Link to comment

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...