Discuss Scratch

Invisible_Factory
Scratcher
500+ posts

The end of "Double click the green flag"

I don't know if it should be stickied but it should be an ITopic. Nice tutorial!
JABrules
Scratcher
100+ posts

The end of "Double click the green flag"

Invisible_Factory wrote:

I don't know if it should be stickied but it should be an ITopic. Nice tutorial!
There's not really much point, as the whole “double-click the green flag” glitch is just a myth and actually the result of poor coding. It is helpful if the scratcher doesn't know how to fix their program, but it's better for them to find the problem and fix it as they should learn more about coding and bug-fixing.
awesome-llama
Scratcher
1000+ posts

The end of "Double click the green flag"

The way I fix that problem is have a broadcast hat replacing all gf clicked? blocks and only one remaining, which sets all variables, and broadcasts to everything else.
moss-shadow
Scratcher
500+ posts

The end of "Double click the green flag"

For my game, which is extremely packed and complex (which is probably why), you become a warrior once you are born. How I fixed this: for the cat who announces the ceremony, I added this script:
when green flag clicked
stop [other scripts in sprite v]
wait (1) secs
stop [other scripts in sprite v]
broadcast [Now we start v]

When he receives the broadcast, he doesn't announce the ceremony and does what he should be doing. It seems to work for me.
liam48D
Scratcher
1000+ posts

The end of "Double click the green flag"

This is a great tutorial.
Petertheb
New Scratcher
1 post

The end of "Double click the green flag"

I have a problem with this i am only starting scratch and i was wondering if you could help me with my green flag problem im not sure what it is
https://scratch-mit-edu.ezproxyberklee.flo.org/projects/99882624/
deck26
Scratcher
1000+ posts

The end of "Double click the green flag"

Petertheb wrote:

I have a problem with this i am only starting scratch and i was wondering if you could help me with my green flag problem im not sure what it is
https://scratch-mit-edu.ezproxyberklee.flo.org/projects/99882624/
You should start your own topic. The New Topic button is at the top of the forum page.
Gingerspot
Scratcher
3 posts

The end of "Double click the green flag"

I always thought that the double-click thing was weird.
smallperm
Scratcher
10 posts

The end of "Double click the green flag"

I tried fixing it like that but it won't work. I think it's got to do something with my intro

when green flag clicked
repeat (whatever)

next costume
end
forever

switch costume to [something v]
repeat (whatever)

next costume
end

end

which makes the intro go on forever but I have this script below to stop it (kinda)

when green flag clicked
wait (intro) secs
repeat (10)
change [ghost v] effect by (10)

end

I think it's because It's technically still going I have to double click the flag

@smallperm

Last edited by smallperm (April 6, 2016 05:17:25)

rosebud87
Scratcher
87 posts

The end of "Double click the green flag"

That is helpful!
when green flag clicked
forever

if <[Zparx] = [awesome ]> then
say [Yay!] for (2) secs

end

end
humantorch01
Scratcher
85 posts

The end of "Double click the green flag"

Another thing to take away having to click the green flag twice is to have ONE green flag clicked block
when green flag clicked
duckboycool
Scratcher
1000+ posts

The end of "Double click the green flag"

But that is much harder to program around rather than just putting in a few wait blocks.

Or with this example, wait until.

Last edited by duckboycool (Feb. 4, 2017 05:16:14)

cherrycake30
Scratcher
1 post

The end of "Double click the green flag"

I wish everyone who creates games where you have to click the green flag could see this. It helped a lot.

<[this v] = [amazing v
<set [Helped v] to [999999999999999999999999999999999999999999999999999999999999999999999999999999]>
(distance to [amazingness]=[0 v]>
retrocity5
New Scratcher
4 posts

The end of "Double click the green flag"

I have a title screen but, it works differently. It waits 7.5 secs to play a theme then goes into the game. How would I fix this “Double-click Flag” thing then?
Zparx
Scratcher
500+ posts

The end of "Double click the green flag"

retrocity5 wrote:

I have a title screen but, it works differently. It waits 7.5 secs to play a theme then goes into the game. How would I fix this “Double-click Flag” thing then?


I would have to see how your game is set up, but if you're experiencing this issue, I would recommend putting your “set variable to” block before the waiting period.

If you could leave a link to the project here, I could take a look at it for you and work out a better solution.
akon11
Scratcher
23 posts

The end of "Double click the green flag"

Thanks for this information! I needed it for my “Dodge the Watermelons” game. This was very useful!
tbrec0602
Scratcher
2 posts

The end of "Double click the green flag"

Thanks so much, you really helped my projects!
Mystic_Hacker_21
Scratcher
3 posts

The end of "Double click the green flag"

Thanks, Zparx! Personally, I don't have this problem, but it is extremely useful for scratchers that do it this way. I basically do it like this, if it were to be activated with the space bar:

Intro Sprite:


When green flag clicked
intro part here
broadcast [start]
hide

Title Screen Sprite:


When green flag clicked
hide
go to x: [0] y: [0]
When I receive [start]
show
wait until <key [space] pressed?>
title screen disappearance script
continue project

Last edited by Mystic_Hacker_21 (Dec. 1, 2017 09:56:25)

Charles12310
Scratcher
1000+ posts

The end of "Double click the green flag"

It's been months and this topic hasn't been stickied yet. What is going on?

I honestly think this would be a useful method to use. I would mostly prefer this:

when green flag clicked
set [start? v] to [0]
wait until <(start) = [1]>
...

when [space v] key pressed
set [start v] to [1]

I agree that this should be stickied, even though nothing has happened yet. This would be useful to a lot of users in the future.
deck26
Scratcher
1000+ posts

The end of "Double click the green flag"

Yes, but too many sticky topics just means the first page of the forum gets full of those rather than actual topics requiring help. Better to have something like this in the wiki.

Powered by DjangoBB