Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » scratch bug?
- GreenFruitss
-
Scratcher
29 posts
scratch bug?

For some reason once the message gets broadcasted again, the custom block completely stops running.
- legendary34678
-
Scratcher
1000+ posts
scratch bug?
Hello! Your code as it is right now should work. Could you please post your project link here so we have more information? Thanks!
- mstone326
-
Scratcher
1000+ posts
scratch bug?
What exactly is the bug you are experiencing?
My students often will accidentally put a space in front of what they type then the code doesn't work. Be sure you don't have any extra spaces
for example
if part = “1”
is different than
if part = “ 1”
My students often will accidentally put a space in front of what they type then the code doesn't work. Be sure you don't have any extra spaces
for example
if part = “1”
is different than
if part = “ 1”
- SpaceExplorerPro
-
Scratcher
100+ posts
scratch bug?
Did you add this block?
and try putting a repeat loop.
Hope this helps.
when I start as a clone
show
and try putting a repeat loop.
Hope this helps.
- GreenFruitss
-
Scratcher
29 posts
scratch bug?
Did you add this block?when I start as a clone
show
and try putting a repeat loop.
Hope this helps.
yes, if I click the code while the project isn't running then it works
- GreenFruitss
-
Scratcher
29 posts
scratch bug?
Hello! Your code as it is right now should work. Could you please post your project link here so we have more information? Thanks!
Ok here is the unfinished project: https://turbowarp.org/734652338/editor
Go to the “Sprite1” sprite
Last edited by GreenFruitss (Sept. 24, 2022 12:15:40)
- GreenFruitss
-
Scratcher
29 posts
scratch bug?
What exactly is the bug you are experiencing?
My students often will accidentally put a space in front of what they type then the code doesn't work. Be sure you don't have any extra spaces
for example
if part = “1”
is different than
if part = “ 1”
That's probably not the issue, the variable changes the second time the message gets broadcasted so it shouldn't do anything, but for some reason it just stops the custom block
- GreenFruitss
-
Scratcher
29 posts
scratch bug?
Update: I noticed how the blocks highlight differently on turbowarp. On scratch the custom block definition highlights while it's running but then it gets unhighlighted. On turbowarp the block definition doesn't highlight but the broadcast script does.
I think what's happening is that the custom block code is actually running inside the broadcast message so it doesn't count it as a separate script.
So I guess I just have to use a ton of broadcast messages
I think what's happening is that the custom block code is actually running inside the broadcast message so it doesn't count it as a separate script.
So I guess I just have to use a ton of broadcast messages

- TheDogLover796
-
Scratcher
1000+ posts
scratch bug?
Could you supply us a link to your project? The code right now looks like it has not problem.
- legendary34678
-
Scratcher
1000+ posts
scratch bug?
It looks like part starts off as 1 and the custom block is run. Then, it changes to 2 and makes the condition to run the custom block invalid which prevents it from running. Was that intentional?
- Discussion Forums
- » Help with Scripts
-
» scratch bug?




