Discuss Scratch
- Discussion Forums
- » Bugs and Glitches
- » Forever loop only repeats once
- Invisible_Factory
-
500+ posts
Forever loop only repeats once
My browser / operating system: Windows NT 10.0, Chrome 51.0.2704.79, Flash 23.0 (release 0)
Sometimes I will go to other people's projects and check them out. One thing, though is that it isn't working properly. But the owner can't find the glitch and thinks everything is normal.
So, I click “See inside” to see what was wrong. You know how if a script running and is in progress it glows? Well, I saw a script with a forever loop that didn't glow. Now according to logic, forever goes forever, and it will never stop running. So I wonder, why isn't it glowing? How is the forever loop finished?
This means that the forever loop turned into a
which defies the purpose of the forever loop. However, it occurs rarely, maybe once a week, and it has never happened on my own project. I have seen this happen twice.
Also, I tried to manually click on the forever loop to make it run, which made the glow appear but disappear just as quickly. I also tried to reload the page, but it didn't do anything. Does anyone know how to fix this glitch/bug?
Sometimes I will go to other people's projects and check them out. One thing, though is that it isn't working properly. But the owner can't find the glitch and thinks everything is normal.
So, I click “See inside” to see what was wrong. You know how if a script running and is in progress it glows? Well, I saw a script with a forever loop that didn't glow. Now according to logic, forever goes forever, and it will never stop running. So I wonder, why isn't it glowing? How is the forever loop finished?
This means that the forever loop turned into a
(x being undefined, not knowing how many times it repeated)
which defies the purpose of the forever loop. However, it occurs rarely, maybe once a week, and it has never happened on my own project. I have seen this happen twice.
Also, I tried to manually click on the forever loop to make it run, which made the glow appear but disappear just as quickly. I also tried to reload the page, but it didn't do anything. Does anyone know how to fix this glitch/bug?
- stickfiregames
-
1000+ posts
Forever loop only repeats once
Which project are you talking about?
- Invisible_Factory
-
500+ posts
Forever loop only repeats once
how? I know for a fact putting a “if then” statement that is false inside the forever loop will stop it from functioning, but that was not the case in either of the projects. But Forever loops can be stopped.
still should glow because the statement can be made true anytime.
So how can you stop forever loops, without clicking on the stop button or manually stopping it after clicking see inside?
- Invisible_Factory
-
500+ posts
Forever loop only repeats once
I actually don't remember either of their names or links, but the next time I see one I will put it in the OP. Which project are you talking about?
- drmcw
-
1000+ posts
Forever loop only repeats once
It's what the stop blocks dohow? I know for a fact putting a “if then” statement that is false inside the forever loop will stop it from functioning, but that was not the case in either of the projects. But Forever loops can be stopped.still should glow because the statement can be made true anytime.
So how can you stop forever loops, without clicking on the stop button or manually stopping it after clicking see inside?
There are also other ways dependent upon the hat block that starts the script, the forever block is in.
Last edited by drmcw (Dec. 11, 2016 15:34:52)
- Invisible_Factory
-
500+ posts
Forever loop only repeats once
oh. Well, if I find it again I will check.It's what the stop blocks dohow? I know for a fact putting a “if then” statement that is false inside the forever loop will stop it from functioning, but that was not the case in either of the projects. But Forever loops can be stopped.still should glow because the statement can be made true anytime.
So how can you stop forever loops, without clicking on the stop button or manually stopping it after clicking see inside?
There are also other ways dependent upon the hat block that starts the script, the forever block is in.
- midknightking
-
1 post
Forever loop only repeats once
I have the same problem. I can't get my sprite to go on forever.#in python you use for i in range
- Morimop
-
1000+ posts
Forever loop only repeats once
Don't necropost please. I have the same problem. I can't get my sprite to go on forever.#in python you use for i in range
- Peashooter10000
-
12 posts
Forever loop only repeats once
I have a similar problem in my project, where the if-then-else block always reads false if it reads false once. My code is:
Last edited by Peashooter10000 (Oct. 16, 2023 16:57:21)
- Peashooter10000
-
12 posts
Forever loop only repeats once
Turns out my code had a forever block in one of the custom blocks. Oops.
- CaptainTrooper
-
100+ posts
Forever loop only repeats once
Turns out my code had a forever block in one of the custom blocks. Oops.
I have a similar problem in my project, where the if-then-else block always reads false if it reads false once. My code is:This forum post was in 2016. Please check the dates next time so you dont necropost by accident.
Also, make a topic separate from others if you have a glitch with scratch and its different from other glitches.
Last edited by CaptainTrooper (Oct. 17, 2023 00:14:11)
- Discussion Forums
- » Bugs and Glitches
-
» Forever loop only repeats once