I’m currently trying to write a command whereby a player can change his “role” in a squad, which displays his roleplay name.
For Example: “James Jackson-01”
I want to create a command which would work like so:
The difficult part of this is that I need to have only the number changing in the name. From memory, I think I can use something about exploding a string, but I have absolutely no idea where to start with that.
Help is appreciated<3 If I haven’t made anything clear, please say!
EDIT: Got it by doing
local choice = arguments
local parts = string.Explode( “:”, player:Name() )
local newname = choice … “:” … parts