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

String Value wont change no matter what? no error message.

why does this not work, its in a scriptin a textbutton.

function clicked(player)
	script.Parent.Parent.ReporterName.Value = "Report1"
	script.Parent.Parent.ReportName.Value = "Report2"
end

script.Parent.MouseButton1Down:connect(clicked)

1 comment

0

Is this in a LocalScript, or a Script?

2 answers

What you are doing is right except you aren't adding Wait()

function clicked()
    	script.Parent.Parent.ReporterName.Value = "Report1"
	wait(1)
   	 script.Parent.Parent.ReportName.Value = "Report2"
	wait(1)
end

script.Parent.MouseButton1Down:connect(clicked)

2 comments

0

Why add waits? >->

0

aww, y do I have to explain T_T.... Probably because the value will stay at Report2, and won't change

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