Discuss Scratch
- bubgamer07
-
Scratcher
100+ posts
All at Once/Run in Parallel Block
But why? What’s the use of this?
all at once {
glide (1) secs to x: (0) y: (0)
say [wee!] for (1) secs
} :: controlthough i guess in that case you could just dosay [wee!]
glide (1) secs to x: (0) y: (0)
say []
- nembence
-
Scratcher
500+ posts
All at Once/Run in Parallel Block
(#63)What about this?Can you somehow change the block name or something so it doesn't get confused with the 2.0 alpha all at once block?
You could suggest one. I don't have any ideas
run in parallel {
say [Hello!] for (2) secs
}{
play note (60) for (0.25) beats
}{
rest for (0.0625) beats
play note (72) for (0.25) beats
} \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ @delInput @addInput::controlor, if growable C-blocks aren't possible:
with this one the problem is that blocks stacked together are expected to wait for each other, so maybe convert the blocks dropped in it into cap blocks
run in parallel {
say [Hello!] for (2) secs::cap
play note (60) for (0.25) beats::cap
if <(50)=(50)> then {
rest for (0.0625) beats
play note (72) for (0.25) beats
}::control cap
}::control- VedanshS933
-
Scratcher
1000+ posts
All at Once/Run in Parallel Block
(#63)What about this?Can you somehow change the block name or something so it doesn't get confused with the 2.0 alpha all at once block?
You could suggest one. I don't have any ideasrun in parallel {
say [Hello!] for (2) secs
}{
play note (60) for (0.25) beats
}{
rest for (0.0625) beats
play note (72) for (0.25) beats
} \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ @delInput @addInput::control
or, if growable C-blocks aren't possible:
with this one the problem is that blocks stacked together are expected to wait for each other, so maybe convert the blocks dropped in it into cap blocksrun in parallel {
say [Hello!] for (2) secs::cap
play note (60) for (0.25) beats::cap
if <(50)=(50)> then {
rest for (0.0625) beats
play note (72) for (0.25) beats
}::control cap
}::control
The name is nice. \
Last edited by VedanshS933 (Feb. 16, 2025 16:00:34)
- BringUpYourPost
-
Scratcher
500+ posts
All at Once/Run in Parallel Block
Threading might lead to data races.
For example, after running this script, what would foo be?
For example, after running this script, what would foo be?
set [foo v] to [1]Would it be 1*3 +1 = 4 or (1 +1) * 3 = 6
run in parallel {
set [foo v] to ((foo) * (3))
}{
set [foo v] to ((foo) + (1))
}
Last edited by BringUpYourPost (Aug. 28, 2025 00:28:20)
- Haycat2009
-
Scratcher
100+ posts
All at Once/Run in Parallel Block
This is not a duplicate because this launches two blocks at once and not run a block with run without screen refresh.
Hi!
I am proposing an All at Once or Run in Parallel block. This block would be used to run two or more blocks at once.
If you are thinking that scrtips cannot be run together, only once, then please check the workaround.
MockupAll at Once {or
} :: controlRun in Parallel {
} :: control
Workaroundscript
broadcast [hi v]
when I receive [hi v]
say [hi]
when I receive [hi v]
think [hi]
Scratch On!
Post rewritten on 26th February 2025
Shouldnt run in parallel be an E block like this:
Run in parallel{
Script 1
}and{
Script 2
}::controlLast edited by Haycat2009 (Aug. 28, 2025 01:24:11)
- VedanshS933
-
Scratcher
1000+ posts
All at Once/Run in Parallel Block
Threading might lead to data races.Yes, that could happen. I'd have to check.
For example, after running this script, what would foo be?set [foo v] to [1]Would it be 1*3 +1 = 4 or (1 +1) * 3 = 6
run in parallel {
set [foo v] to ((foo) * (3))
}{
set [foo v] to ((foo) + (1))
}
It could be.-snip-
OP was posted
Shouldnt run in parallel be an E block like this:Run in parallel{
Script 1
}and{
Script 2
}::control
Last edited by VedanshS933 (Aug. 28, 2025 10:29:11)
- not-k7e
-
Scratcher
71 posts
All at Once/Run in Parallel Block
Threading might lead to data races.Yes, that could happen. I'd have to check.
For example, after running this script, what would foo be?set [foo v] to [1]Would it be 1*3 +1 = 4 or (1 +1) * 3 = 6
run in parallel {
set [foo v] to ((foo) * (3))
}{
set [foo v] to ((foo) + (1))
}
It will happen I just gave an example.






