Solved offline player's prefix

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

PuchiGFX

Member
Jan 26, 2017
246
5
18
How can i get the prefix from an offline player?
Im using LuckPerms and skript 2.4.1 (paperspigot 1.15.2)
 
Code:
command example <offlineplayer>:
    trigger:
        broadcast "%arg-offlineplayer's prefix%"
this should work though I haven't tested
 
Code:
command example <offlineplayer>:
    trigger:
        broadcast "%arg-offlineplayer's prefix%"
this should work though I haven't tested
That doesnt work.
Anyways i found the way:
Code:
import:
    ch.njol.skript.hooks.VaultHook

expression offline prefix of %offlineplayer%:
    get:
        return VaultHook.chat.getPlayerPrefix(null, expr-1)   

command /test [<offline player>]:
    trigger:
        send "%colored offline prefix of arg-1%"
It needs skript-mirror and vault (obviusly) to work
 
Status
Not open for further replies.