Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How do I search for a Player and check their shirt?

So when I type the Player's name into a TextBox and press the GO button, I want it to search to see if the string I typed in is the name of one of the users in the server. Then, I want it to check to see if it matches a shirt ID.

Does anybody know how to do this? It would really help! Thanks!

2 answers

✓ Accepted answer

local play = game.Players:FindFirstChild(text)
if play ~= nil and play.Character ~= nil then
 local shirt = play.Character.Shirt

voila You have now defined the player shirt. dont forget end statements.

This is NOT a request. Please include any coding or research you have already done.

Here are the things that you will need to research to make this work:

MouseButton1Click event

Changed event

If statements

FindFirstChild()

Repost if the code you attempt has errors that you need help with.

This discussion is preserved as it was. New answers, comments, and votes are closed.