I'm a very "noobish" scripter, What am I doing wrong?
while true do wait(0.5) if script.Parent.ScrollingFrame.Sound.IsPlaying = true then script.Parent.ScrollingFrame.Visible = false then script.Parent.SongPlayNoter.Visible = true elseif script.Parent.ScrollingFrame.Sound.IsPlayer = false then script.Parent.ScrollingFrame.Visible = true then script.Parent.SongPlayNoter.Visible = false end end
while true do wait(0.5) local isPlaying = script.Parent.ScrollingFrame.Sound.IsPlaying script.Parent.ScrollingFrame.Visible = not isPlaying script.Parent.SongPlayNoter.Visible = isPlaying end
Your script itself had two main errors; you were using "=" for comparison instead of "==", and you were indexing "isPlayer" in the second if statement.
while true do wait(0.5) if script.Parent.ScrollingFrame.Sound.IsPlaying == true then script.Parent.ScrollingFrame.Visible = false script.Parent.SongPlayNoter.Visible = true elseif script.Parent.ScrollingFrame.Sound.IsPlayer == false then script.Parent.ScrollingFrame.Visible = true script.Parent.SongPlayNoter.Visible = false end end
Just change where you put the "Then"
Error at line 3 and line 7.
I wasn't sure where the end
's were supposed to go, so II assumed they go in these places.
while wait(0.5) do if script.Parent.ScrollingFrame.Sound:Play() then script.Parent.ScrollingFrame.Visible = false script.Parent.SongPlayNoter.Visible = true elseif not script.Parent.ScrollingFrame.Sound:Play()then script.Parent.ScrollingFrame.Visible = true script.Parent.SongPlayNoter.Visible = false end end