PlayStopped message
Ken Ray
kray at sonsothunder.com
Fri Jan 17 15:08:01 EST 2003
Jez,
One quick way is to set a global variable before you load a new file, as in:
global gLoadingMovie
on loadMovie pMoviePath
put true into gLoadingMovie
set the fileName of player 1 to pMoviePath
put false into gLoadingMovie
end loadMovie
on playStopped
if not(gLoadingMovie) then
-- queue up your next movie
end if
end playStopped
Hope this helps,
Ken Ray
Sons of Thunder Software
Email: kray at sonsothunder.com
Web Site: http://www.sonsothunder.com/
----- Original Message -----
From: "Jez" <jbradshaw at blueyonder.co.uk>
To: <use-revolution at lists.runrev.com>
Sent: Friday, January 17, 2003 1:40 PM
Subject: PlayStopped message
> I want to detect when a song finishes playing in a Quicktime player
control
> so that I can queue up another song (picked at random). The PlayStopped
> message seemed to be the obvious way of capturing this event. Trouble is,
> PlayStopped is also fired when you set the filename of the player to a new
> file (resulting in an infinite loop), and when the stack is closed, though
> intruigingly is NOT fired when you invoke a "stop player" command! How can
I
> safely capture the end of a song being played ?
>
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> http://lists.runrev.com/mailman/listinfo/use-revolution
>
More information about the use-livecode
mailing list