How can make a spit capture multiple arguments rather just a space? Since I was making an admin panel and usually the space wat the split, but I’m making a message system where I want the command split to capture the ENTIRE message which is multiple arguments.
I’m not sure what exactly you’re trying to explain here, but I might know what you want to achieve.
Do you want a table to return every argument starting from a certain index as one string?
Example:
-- where arguments is {"player", "This", "is", "a", "test"}
local player = findPlayer(arguments[1])
local reason = arguments[2] -- you want it to return "This is a test" instead of "This"?
if player then player:Kick(reason) end
I’m trying to make a :split capture a ENTIRE message. How can I do that, if you can’t how can I make when you type :kill in the chat the 3rd part of the message is the reason. Where how can I make the reason work without a split.
ohhhh I see, you could use it with parentheses. An example is when I made a kick command, when using in the chat it would be /kick playerName (reason). If you want to know how to do that, it’s in this video I made: