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:
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.
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
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.