I don't quite understand why the block is needed. Blocks within the same sprites but in different scripts don't run simultaneously, either.
So do elaborate more.
Offline
dvd4 wrote:
The ST got rid of it in the alpha, so I doubt they will bring it back
blog post wrote:
The current plan is to make “run without screen refresh” an option for custom blocks you create.
Offline
scimonster wrote:
dvd4 wrote:
The ST got rid of it in the alpha, so I doubt they will bring it back
blog post wrote:
The current plan is to make “run without screen refresh” an option for custom blocks you create.
I see.
Offline
jontmy00 wrote:
I don't quite understand why the block is needed. Blocks within the same sprites but in different scripts don't run simultaneously, either.
So do elaborate more.
Different scripts do run simultaneously.
What he wants is a block to run two sets of blocks in the same script simultaneously without making extra scripts, like this:
However, the example above is useless because you cant move ten steps whilst turning 15 degrees, the way scripts run together is by "interleaving" blocks unless a script is waiting. So if you had these scripts:
turn left (15) degrees wait (1) secs move (10) steps
pen down set [variable v] to (5)
set x to (4) set pen color to [#FF0000] go to x:(6) y:(12)then scratch would check each script in turn. First it checks the first script, and turns 15 degrees. Then it checks the second script, and puts the pen down. Then it checks the third script and sets x to 4. Since there are no more scripts, it goes back to the first one. The next block is wait 1 secs, so it does that. Then it checks the second script and does the next block, which is to set the variable to 5. Then it checks the third script, and sets the pen colour to red. But it can't do the next block of the first script, because it still needs to wait 1 second. It cant do anything with the next script as that is finished. So it goes to the third script and puts the sprite at (6, 12) and that script is now finished. Script 1 can't go on until one second later, after which the sprite moves 10 steps.
Last edited by joefarebrother (2012-10-22 13:08:58)
Offline
If you want two (or more) scripts to run at the same time, just use messages:
when gf clicked broadcast [RunMyScripts v]These two scripts will then run at the same time:
when I receive [RunMyScripts v] repeat (180) turn (1) degrees end when I receive [RunMyScripts v] repeat (100) move (1) steps end
Last edited by BoltBait (2012-10-22 14:19:32)
Offline
joefarebrother wrote:
jontmy00 wrote:
I don't quite understand why the block is needed. Blocks within the same sprites but in different scripts don't run simultaneously, either.
So do elaborate more.Different scripts do run simultaneously.
What he wants is a block to run two sets of blocks in the same script simultaneously without making extra scripts, like this:
http://i48.tinypic.com/2ykkro8.png
However, the example above is useless because you cant move ten steps whilst turning 15 degrees, the way scripts run together is by "interleaving" blocks unless a script is waiting. So if you had these scripts:turn left (15) degrees wait (1) secs move (10) stepspen down set [variable v] to (5)set x to (4) set pen color to [#FF0000] go to x:(6) y:(12)then scratch would check each script in turn. First it checks the first script, and turns 15 degrees. Then it checks the second script, and puts the pen down. Then it checks the third script and sets x to 4. Since there are no more scripts, it goes back to the first one. The next block is wait 1 secs, so it does that. Then it checks the second script and does the next block, which is to set the variable to 5. Then it checks the third script, and sets the pen colour to red. But it can't do the next block of the first script, because it still needs to wait 1 second. It cant do anything with the next script as that is finished. So it goes to the third script and puts the sprite at (6, 12) and that script is now finished. Script 1 can't go on until one second later, after which the sprite moves 10 steps.
At no point does it execute two blocks at the same time, it will only do two sequences of blocks at a time.
The removed "all at once" block would have kept scratch focused on that script alone and will not do anything with other scripts unless it hits wait () secs or wait until <>, or the end of the all at once block.
Atomic speed and turbo speed are different things.
Offline
dvd4 wrote:
joefarebrother wrote:
jontmy00 wrote:
I don't quite understand why the block is needed. Blocks within the same sprites but in different scripts don't run simultaneously, either.
So do elaborate more.Different scripts do run simultaneously.
What he wants is a block to run two sets of blocks in the same script simultaneously without making extra scripts, like this:
http://i48.tinypic.com/2ykkro8.png
However, the example above is useless because you cant move ten steps whilst turning 15 degrees, the way scripts run together is by "interleaving" blocks unless a script is waiting. So if you had these scripts:turn left (15) degrees wait (1) secs move (10) stepspen down set [variable v] to (5)set x to (4) set pen color to [#FF0000] go to x:(6) y:(12)then scratch would check each script in turn. First it checks the first script, and turns 15 degrees. Then it checks the second script, and puts the pen down. Then it checks the third script and sets x to 4. Since there are no more scripts, it goes back to the first one. The next block is wait 1 secs, so it does that. Then it checks the second script and does the next block, which is to set the variable to 5. Then it checks the third script, and sets the pen colour to red. But it can't do the next block of the first script, because it still needs to wait 1 second. It cant do anything with the next script as that is finished. So it goes to the third script and puts the sprite at (6, 12) and that script is now finished. Script 1 can't go on until one second later, after which the sprite moves 10 steps.
At no point does it execute two blocks at the same time, it will only do two sequences of blocks at a time.
The removed "all at once" block would have kept scratch focused on that script alone and will not do anything with other scripts unless it hits wait () secs or wait until <>, or the end of the all at once block.Atomic speed and turbo speed are different things.
I know. When did I say otherwise?
The removed "all at once" block was for atomic speed, now procedures have the option of being atomic. I didn't mention anything about turbo speed in the above post.
Offline
joefarebrother wrote:
dvd4 wrote:
joefarebrother wrote:
Different scripts do run simultaneously.
What he wants is a block to run two sets of blocks in the same script simultaneously without making extra scripts, like this:
http://i48.tinypic.com/2ykkro8.png
However, the example above is useless because you cant move ten steps whilst turning 15 degrees, the way scripts run together is by "interleaving" blocks unless a script is waiting. So if you had these scripts:turn left (15) degrees wait (1) secs move (10) stepspen down set [variable v] to (5)set x to (4) set pen color to [#FF0000] go to x:(6) y:(12)then scratch would check each script in turn. First it checks the first script, and turns 15 degrees. Then it checks the second script, and puts the pen down. Then it checks the third script and sets x to 4. Since there are no more scripts, it goes back to the first one. The next block is wait 1 secs, so it does that. Then it checks the second script and does the next block, which is to set the variable to 5. Then it checks the third script, and sets the pen colour to red. But it can't do the next block of the first script, because it still needs to wait 1 second. It cant do anything with the next script as that is finished. So it goes to the third script and puts the sprite at (6, 12) and that script is now finished. Script 1 can't go on until one second later, after which the sprite moves 10 steps.
At no point does it execute two blocks at the same time, it will only do two sequences of blocks at a time.
The removed "all at once" block would have kept scratch focused on that script alone and will not do anything with other scripts unless it hits wait () secs or wait until <>, or the end of the all at once block.Atomic speed and turbo speed are different things.
I know. When did I say otherwise?
The removed "all at once" block was for atomic speed, now procedures have the option of being atomic. I didn't mention anything about turbo speed in the above post.
you didn't ?
Offline
dvd4 wrote:
joefarebrother wrote:
dvd4 wrote:
Atomic speed and turbo speed are different things.I know. When did I say otherwise?
The removed "all at once" block was for atomic speed, now procedures have the option of being atomic. I didn't mention anything about turbo speed in the above post.you didn't ?
No.
Offline
joefarebrother wrote:
dvd4 wrote:
joefarebrother wrote:
I know. When did I say otherwise?
The removed "all at once" block was for atomic speed, now procedures have the option of being atomic. I didn't mention anything about turbo speed in the above post.you didn't ?
No.
I'm pretty sure it wasn't Atomic.
Offline
joefarebrother wrote:
stuff
I know. When did I say otherwise?
The removed "all at once" block was for atomic speed, now procedures have the option of being atomic. I didn't mention anything about turbo speed in the above post.
How do you know? I can't find that feature.
Offline
Firedrake969 wrote:
joefarebrother wrote:
stuff
I know. When did I say otherwise?
The removed "all at once" block was for atomic speed, now procedures have the option of being atomic. I didn't mention anything about turbo speed in the above post.How do you know? I can't find that feature.
Offline
Wes64 wrote:
Firedrake969 wrote:
joefarebrother wrote:
stuff
I know. When did I say otherwise?
The removed "all at once" block was for atomic speed, now procedures have the option of being atomic. I didn't mention anything about turbo speed in the above post.How do you know? I can't find that feature.
wiki knows all
Offline