Temporary picts

Shari gogypsy at bellsouth.net
Thu Mar 21 08:30:00 EST 2002


>>So the solution has to be to avoid modal dialogs. You could do that by
>>creating your own dialog stack and storing it as a substack in your main
>>stack. You'd fill the text field with the appropriate response and set
>>the button labels to whatever you want. Then display it as modeless:
>>
>>   modeless "myDialog"
>
>This would definitely be an option for the current project...

Didn't work *sigh*

Tried three versions.  All had the same result as using the answer 
command.  The first half of "darn you.wav" plays, and the last half 
of "talk to you" plays, and all the rest gets cut off.

So it will have to be the long version.

Wishful versions (5 lines of code):

put "darn you.wav,aaah.wav,goodie.wav,oh yeah.wav,talk to you.wav" 
into soundList
     repeat with x = 1 to the number of items of soundList
       play (item x of soundList)
     end repeat
     answer "some info"

put "darn you.wav,aaah.wav,goodie.wav,oh yeah.wav,talk to you.wav" 
into soundList
     repeat with x = 1 to the number of items of soundList
       play (item x of soundList)
     end repeat
     go cd "info" of stack "dLog" in a new window

put "darn you.wav,aaah.wav,goodie.wav,oh yeah.wav,talk to you.wav" 
into soundList
     repeat with x = 1 to the number of items of soundList
       play (item x of soundList)
     end repeat
     go cd "info" of stack "dLog" as modeless

put "darn you.wav,aaah.wav,goodie.wav,oh yeah.wav,talk to you.wav" 
into soundList
     repeat with x = 1 to the number of items of soundList
       play (item x of soundList)
     end repeat
     go cd "info" of stack "dLog" as modal

Working version (about 50 lines of code) and requires a player on each card:

set the startTime of player "Music" to "0"
     set the currentTime of player "Music" to "0"
     put the effective filename of this stack into wit
     set the itemdelimiter to "/"
     put "darn you.wav" into the last item of wit
     set the fileName of player "Music" to wit
     set the callbacks of player "Music" to "531,end1"
     start player "Music"

on end1
   put the effective filename of this stack into wit
   set the itemdelimiter to "/"
   put "aaah.wav" into the last item of wit
   set the fileName of player "Music" to wit
   set the startTime of player "Music" to "0"
   set the currentTime of player "Music" to "0"
   set the callbacks of player "Music" to "1020,end2"
   start player "Music"
end end1

on end2
   put the effective filename of this stack into wit
   set the itemdelimiter to "/"
   put "goodie.wav" into the last item of wit
   set the fileName of player "Music" to wit
   set the startTime of player "Music" to "0"
   set the currentTime of player "Music" to "0"
   set the callbacks of player "Music" to "472,end3"
   start player "Music"
end end2

on end3
   put the effective filename of this stack into wit
   set the itemdelimiter to "/"
   put "oh yeah.wav" into the last item of wit
   set the fileName of player "Music" to wit
   set the startTime of player "Music" to "0"
   set the currentTime of player "Music" to "0"
   set the callbacks of player "Music" to "628,end4"
   start player "Music"
end end3

on end4
   put the effective filename of this stack into wit
   set the itemdelimiter to "/"
   put "talk to you.wav" into the last item of wit
   set the fileName of player "Music" to wit
   set the startTime of player "Music" to "0"
   set the currentTime of player "Music" to "0"
   set the callbacks of player "Music" to empty
   start player "Music"
end end4
-- 
--Shareware Games for the Mac--
http://www.gypsyware.com



More information about the metacard mailing list