of     1   

cade2000
#139812473Wednesday, July 09, 2014 11:48 PM GMT

while wait(1) do if script.Parent.Text == "Enter in song ID" or script.Parent.Text == "" then wait() else music = script.Parent.song music.SoundId = "http://www.roblox.com/asset/?id="..tonumber(script.Parent.Text)-1 script.Parent.Parent.Fox.song:stop() script.Parent.Parent.Radio.song:stop() script.Parent.Parent.Viva.song:stop() script.Parent.Parent.Notafraid.song:stop() script.Parent.Parent.Fix.song:stop() script.Parent.Parent.Lost.song:stop() music:play() end end I can't figure out what's wrong no matter what I do!!!! The script lets ppl put in a song id into a textbox which is the parent of this script. There is a song whose parent is also the textbox and I'm changing the song id to the id entered and playing that song. However the song ID isn't changing, and the song isn't playing...
cade2000
#139813298Wednesday, July 09, 2014 11:56 PM GMT

bump
swimguy777
#139813427Wednesday, July 09, 2014 11:57 PM GMT

Use this instead of a while loop: http://wiki.roblox.com/index.php?title=FocusLost_(Event) -[::ƧѡÎḾḠΰῩ::]-[::Helper of Scripting and Writer of Wikis::]
cade2000
#139813543Wednesday, July 09, 2014 11:58 PM GMT

Lets see if this works... Thx btw
maxomega3
#139813639Wednesday, July 09, 2014 11:59 PM GMT

Also, you don't subtract one from song IDs
cade2000
#139813751Thursday, July 10, 2014 12:00 AM GMT

Thanks man! You rock! I'm still pretty new to Lua but I think I'll pick up quickly because I have a lot of experience with other languages.

    of     1