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

why is this not working?

Asked by 8 years ago

Please make your question title relevant to your question content. It should be a one-sentence summary in question form.
local textcolor = script.Parent.TextColor3

while true do
    wait(1)
    textcolor = textcolor.new(0,0,255)
    wait(1)
    textcolor = textcolor.new(255,0,0)
end

I dont know how this isnt working this should be like the easiest script I can make. It keeps saying "new is not a valid member" Im like WTFFF

2 answers

Log in to vote
3
Answered by 8 years ago

Two things:

1) You forgot to add /255 after, which makes it a fraction out of something to find the color.

2) I don't recommend making TextColor3 apart of local textcolor because it messes up the way you fix the script. Instead of textcolor.new it should be Color3.new, which is why you were getting the error.

local textcolor = script.Parent

while true do
    wait(1)
    textcolor.TextColor3 = Color3.new(0/255,0/255,255/255)
    wait(1)
    textcolor.TextColor3 = Color3.new(255/255,0/255,0/255)
end

I hope this helped :)

Ad
Log in to vote
0
Answered by 8 years ago

Instead of textcolor.new try Color3.new.

Answer this question