I am attempting to make a moderation GUI that allows my in-game admins to teleport players, kick them etc. However, right now they need to enter in the players full name (ROBLOX instead of ROB or something) I have tried to use :findfirstchild, however that returns nil unless the players name is completely entered.
✓ ANSWER ACCEPTED
How will I automatically guess players name when entering the start of it?
1 answer
✓ Accepted answer
local SearchFor = "Lua"
for i,v in pairs(game.Players:GetPlayers()) do
if v.Name:lower():sub(1,SearchFor:len()) == SearchFor:lower() then
print(v.Name)
end
end
This discussion is preserved as it was. New answers, comments, and votes are closed.

1 comment
Thank you