You should convert the command to lowercase first, and compare if the first 6 letters is ";kick ". If yes, then you can get the player by doing string.sub(lowercaseCommand, string.len(kickCommand) + 1, string.len(lowercaseCommand). Here's a concept:
local lowercaseCommand = string.lower(message)
local kickCommand = ";kick "
if string.sub(lowercaseCommand, 1, string.len(kickCommand)) == kickCommand then
local playerInCommand = string.sub(message, string.len(kickCommand) + 1, string.len(lowercaseCommand))
local player = game:GetService("Players"):FindFirstChild(playerInCommand)
if player then
player:Kick("You have been kicked")
end
end
This is a concept, you need to code the rest yourself though
2 comments
It’s because you are not calling lower on the message, so you are still comparing capitals to lower case.
oh thanks