Ok so i want to make a code so if they type the code it will give them a certain item i tried changing its text so if its text is changed to the code ?
✓ ANSWER ACCEPTED
TextBox Code Help?
1 answer
✓ Accepted answer
This is simple, but don't ask for request in the future. Only warning. What you'll need: TextBox inside a GUI, and a TextButton inside a GUI. This script is inside a localscript inside TextButton.
script.Parent.MouseButton1Click:connect(function() -- Button is clicked.
if script.Parent.Parent.TextBox.Text == "password" then -- if the word is exactly inside the box then do a function.
-- Do what you want.
else -- if it isn't it, then do something else.
print("Wrong Code.")
end
end)
Good luck.
5 comments
0
MouseButton1Click is not a valid member of TextBox
0
Put the script inside the TextButton.
0
look this is what Ihave Code(ScreenGui)<BackGround(Frame)<CodeInsert(TextBox) where do I put the textbutton?
0
I figured it out thanks
This discussion is preserved as it was. New answers, comments, and votes are closed.

4 comments
Could we see your code, we just give you the code without proof you've at least tried.
well i knid of deleted it ill do it again if youed like i promise I did
You've already got a perfectly good answer, accept it. You got lucky that someone was kind enough to give you code without anything to base it off.
Im sorry