ID:146072
 
Code:
        verb
Play_Music(s as sound)
alert("Would you like this sound to repeat?","Yes","No","Cancel")
if("Yes")
world<<(s,1)
if("No")
world<<(s,0)
if("Cancel")
return


Problem description:
verbs.dm:5:error::invalid expression
verbs.dm:7:error::invalid expression
(They used to be from different lines but I changed the line number to be relative with the snippet.
Set the alert() to a var and then do if(var=="Yes")
In response to Kalzar
Isn't there a way to make it work using the set-up I have? I've seen it done...in fact hold on I have some source with that in it.
In response to Lunaofthemoon
Okay nevermind I just noticed I described the thing wrong. Thanks anyways lol
In response to Lunaofthemoon
        verb
Play_Music(s as sound)
var/a=alert("Would you like this sound to repeat?","Yes","No","Cancel")
if(a=="Yes")
world<< sound(s,1)
if(a=="No")
world<< sound(s,0)
if(a=="Cancel")
return


Try that. If that doesn't work, do s as file instead. I'm not sure if as sound is an arguement.
In response to Kalzar
It is.