This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2009-01-25 22:45:23

erbie
Scratcher
Registered: 2008-12-26
Posts: 12

PlaySound [variable] doesn't work online

In my turntable project I was using PlaySound and passing a variable for the current track.  This works fine offline, but doesn't work in the Java player - the whole thing just hangs.  Instead I had to use a nested if/then/else to play the correct track.  Tedious, but the bigger problem was having to debug things.

Offline

 

#2 2009-01-25 22:48:08

Buddy_ca111
Scratcher
Registered: 2008-08-30
Posts: 100+

Re: PlaySound [variable] doesn't work online

Some stuff just doesn't work online. If it doesn't work then tell people to dl it to make it work.


By reading this you agree to giving me your soul, money, passwords, projects, abiltys and your bases

Offline

 

#3 2009-01-26 05:52:02

Paddle2See
Scratch Team
Registered: 2007-10-27
Posts: 1000+

Re: PlaySound [variable] doesn't work online

erbie wrote:

In my turntable project I was using PlaySound and passing a variable for the current track.  This works fine offline, but doesn't work in the Java player - the whole thing just hangs.  Instead I had to use a nested if/then/else to play the correct track.  Tedious, but the bigger problem was having to debug things.

Thanks erbie.  I've previously noticed that a Random block in the Play Sound block will cause a hang in the Java player.  It's already on the bug list.  Are you saying that you found that just having a variable in the Play Sound block caused it to hang too?


http://i39.tinypic.com/2nav6o7.gif

Offline

 

#4 2009-01-26 11:40:53

erbie
Scratcher
Registered: 2008-12-26
Posts: 12

Re: PlaySound [variable] doesn't work online

Paddle2See wrote:

Are you saying that you found that just having a variable in the Play Sound block caused it to hang too?

Yes.  I tried a simple test where I had 3 sounds with a variable "sound number" = 1 and Play Sound "sound number" would hang.

Offline

 

#5 2009-01-26 14:02:51

Paddle2See
Scratch Team
Registered: 2007-10-27
Posts: 1000+

Re: PlaySound [variable] doesn't work online

erbie wrote:

Paddle2See wrote:

Are you saying that you found that just having a variable in the Play Sound block caused it to hang too?

Yes.  I tried a simple test where I had 3 sounds with a variable "sound number" = 1 and Play Sound "sound number" would hang.

Thanks, I'll update my bug report.


http://i39.tinypic.com/2nav6o7.gif

Offline

 

Board footer