Solved Tab complete for player name in command

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

Ouma Shu

Member
Dec 25, 2017
45
2
0
32
London
Hi, I'm trying to do a /report skript, but the problem is that when I parse an arg to an offline player, when the player is online the tab completion for that player doesn't seem to work. Here is the skript:
Code:
command /report [<text>] [<text>]:
    trigger:
        set {_player} to arg-1 parsed as player
        if arg-2 is set:
            if {_player} is online:
                broadcast "&7&m--------------------"
                broadcast "   &4&lREPORTS    "
                broadcast " "
                broadcast "&7%executor% ha segnalato"
                broadcast "&e%{_player}%"
                broadcast "&7per %arg-2%"
                broadcast "&7&m--------------------"
            else if {_player} is offline:
                send "&f%arg-1% è offline!" to executor
        else if arg-2 is not set:
            send "&c&lR&ceport>&7 Devi specificare un &amotivo&7 per la segnalazione!" to executor
So, if you didn't understand what I mean, I'll do an example:
If I write "/report Pl" and I do tab, it will auto-write player name. "/report Player"
[doublepost=1553308839,1553296767][/doublepost]I solved this, for all who don't know how to do that:
Use [<offline player>] instead of parsing text into player.
 
Status
Not open for further replies.