if script.Parent.Parent.Control.Value == 0 then while true do script.Parent.a.SurfaceGui.TextLabel.Text = "This train is Not in service" script.Parent.b.SurfaceGui.TextLabel.Text = "Please exit this train" script.Parent.b.SurfaceGui.TextLabel.TextColor3 = "[255,0,0]" wait(5) script.Parent.a.SurfaceGui.TextLabel.Text = "and wait for the next train" script.Parent.b.SurfaceGui.TextLabel.Text = "Thanks for your patience." script.Parent.b.SurfaceGui.TextLabel.TextColor3 = "[255,0,0]" wait(5) end end
it dosen't work How should l make the TextColor3 Change ?
You need to change text color 3 like brick color. Like this
TextLabel.TextColor3 = BrickColor.Red().Color--change the color to whatever you like :)
To add on to what SirTwoFace said, you do not HAVE to do it like a BrickColor, since it's a Color3 value. However, Color3 only takes a number between 0 and 1, so if you want to do it by 255, you must divide it by 255.
On top of that, it is not a string, so don't put it in quotes. It should be like this:
TextLabel.TextColor3 = Color3.new(1,0,0) --Or, TextLabel.TextColor3 = Color3.new(255/255,0,0) --Same thing as before
Your code:
if script.Parent.Parent.Control.Value == 0 then while true do script.Parent.a.SurfaceGui.TextLabel.Text = "This train is not in service" script.Parent.b.SurfaceGui.TextLabel.Text = "Please exit this train" script.Parent.b.SurfaceGui.TextLabel.TextColor3 = "[255,0,0]" --<- TextColor3 is ***NOT*** a string. It's a freaking Color3. wait(5) script.Parent.a.SurfaceGui.TextLabel.Text = "and wait for the next train" script.Parent.b.SurfaceGui.TextLabel.Text = "Thanks for your patience." script.Parent.b.SurfaceGui.TextLabel.TextColor3 = "[255,0,0]" wait(5) end end
Here is mine:
if script.Parent.Parent.Control.Value == 0 then while true do script.Parent.a.SurfaceGui.TextLabel.Text = 'This train is not in service.' script.Parent.b.SurfaceGui.TextLabel.Text = 'Please exit this train.' script.Parent.b.SurfaceGui.TextLabel.TextColor3 = Color3.new(255/255, 0/255, 0/255) wait(5) script.Parent.a.SurfaceGui.TextLabel.Text = "and wait for the next train" script.Parent.b.SurfaceGui.TextLabel.Text = "Thanks for your patience." script.Parent.b.SurfaceGui.TextLabel.TextColor3 = Color3.new(255/255, 0/255, 0/255) wait(5) end end