Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

My game keeps printing stuff for no reason?

Asked by 4 years ago
Edited 4 years ago

Hi there! I'm trying to create a system that when someone's partial name is entered, the text will light up. I've been printing stuff to see what it's doing, but it keeps printing the same thing:

--

My code:

01while wait() do
02    local text
03 
04    if playerGui:WaitForChild("TicketGui").MainFrame.MainFrame.UserBox.Text ~= text then
05        print("text changed")
06        text = playerGui.TicketGui.MainFrame.MainFrame.UserBox.Text
07        print(text)
08        if findPlayer(playerGui.TicketGui.MainFrame.MainFrame.UserBox.Text) and playerGui.TicketGui.MainFrame.MainFrame.UserBox.Text ~= "" and playerGui.TicketGui.MainFrame.MainFrame.UserBox.Text ~= " " then
09            print("found player")
10            playerGui.TicketGui.MainFrame.MainFrame.Submit.TextTransparency = 0
11        else
12            playerGui.TicketGui.MainFrame.MainFrame.Submit.TextTransparency = .5
13        end
14    end
15end
0
I checked all the referencing, it's correct. No errors as well Also, it's only the spot where it's told to print the text where it prints "--". ParticularlyPenguin 71 — 4y

Answer this question