Solved UUID without "-" possible to trim?

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

LikeKev

Member
Dec 2, 2019
1
0
1
24
Hey, i have a problem with get the uuid! I have to trim then but i don't find a answer anywhere! Can someone please help me with that?


ex:

on connect:
if {uuid::%player%} is not set:
set {uuid::%player%} to player's uuid

i get a normal uuid like:

"2348-ajfaj-2342-asfaf"

and i want to have these without the - :
"2348ajfaj2342asfaf"
 
Code:
function trimUUID(uuid: text) :: text:
    replace every "-" with "" in {_uuid}
    return {_uuid}

command /test <player>:
    trigger:
        send "normal: %arg-1's uuid%"
        send "short: %trimUUID(arg-1's uuid)%"