|
Post by Wayne Rayner on Dec 2, 2009 23:21:19 GMT -5
' Declare variables dim filename$, sound '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ' main loop printr "Enter Filename" input filename$
if sound = loadsound (filename$) then playsound (sound) printr "you are playing" sound else printr "You have encountered error 1 which means sound hasn't loaded" endif
This is the code to try and get the user to load a sound. every time I get sound = loadsound (filename$) sound returns a value of 0
Wayne Rayner
|
|
|
Post by Adam on Dec 2, 2009 23:39:56 GMT -5
you have to load the sound before you compare it
' Declare variables dim filename$, sound '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ' main loop printr "Enter Filename" input filename$ sound = loadsound (filename$) if sound then playsound (sound) printr "you are playing" sound else printr "You have encountered error 1 which means sound hasn't loaded" endif
|
|
|
Post by Wayne Rayner on Dec 2, 2009 23:58:41 GMT -5
Thanks that worked. SO thats basically version 0.02 of my Music Player. Seems to be getting along quite well
Like you dp (avatar) did you girlfreind draw it or did you.
Wayne Rayner
|
|
|
Post by Adam on Dec 3, 2009 0:00:54 GMT -5
my girlfriend did, you should look at my kill joy post
|
|
|
Post by Wayne Rayner on Dec 3, 2009 0:03:57 GMT -5
Just did lol
|
|