Discuss Scratch

Crow_Boy08
Scratcher
1000+ posts

making wait for second blocks have options!

Here's what i mean: the second block is just a second block so here is an example:
  
wait () [minutes v]:: control

wait () [hours v]:: control
So there needs to be more options with second blocks
because this would be great for getting achievements in games or having something unexpected in a project
thanks for uhhhhhhhhhhhhhhhhhhhhhhhh
reading this

2.5 people support this topic. one person semi supported so thats why its 2.5

Last edited by Crow_Boy08 (Feb. 23, 2022 22:11:21)

RL1123
Scratcher
1000+ posts

making wait for second blocks have options!

You can still use the wait seconds block with some basic maths to wait for a set number of minutes or hours.
wait ((minutes) * (60)) secs
wait ((hours) * (3600)) secs
However, I really doubt that someone would be dedicated enough to play a game for an hour straight, most people's attention spans aren't that long.

Last edited by RL1123 (Feb. 20, 2022 22:22:18)

lolecksdeehaha
Scratcher
1000+ posts

making wait for second blocks have options!

Sorry, no support. The workaround is extremely easy:
define wait (amount) (hours/minutes)
if <(hours/minutes)=(hours)> then
wait (((amount)*(60))*(60)) secs
else
wait ((amount)*(60)) secs
end
Crow_Boy08
Scratcher
1000+ posts

making wait for second blocks have options!

lolecksdeehaha wrote:

Sorry, no support. The workaround is extremely easy:
define wait (amount) (hours/minutes)
if <(hours/minutes)=(hours)> then
wait (((amount)*(60))*(60)) secs
else
wait ((amount)*(60)) secs
end
yeah but what if new scratchers don't know it and they don't know how to use custommblocks
RL1123
Scratcher
1000+ posts

making wait for second blocks have options!

Crow_Boy08 wrote:

yeah but what if new scratchers don't know it and they don't know how to use custommblocks
Then they can use the workarounds in post #2.
lolecksdeehaha
Scratcher
1000+ posts

making wait for second blocks have options!

Crow_Boy08 wrote:

lolecksdeehaha wrote:

~snip~
yeah but what if new scratchers don't know it and they don't know how to use custommblocks
Then they can take the basic knowledge that 1 minute = 60 seconds and the basic knowledge that 1 hour = 60 minutes.
wait (60) secs // if you (somehow) didn't know, this is waiting for a minute
Myst--
Scratcher
100+ posts

making wait for second blocks have options!

No support. Just make a variable!
Crow_Boy08
Scratcher
1000+ posts

making wait for second blocks have options!

Myst-- wrote:

No support. Just make a variable!
yeah i was going to say yeah you can do it with variables but i scrapped the text
Crow_Boy08
Scratcher
1000+ posts

making wait for second blocks have options!

ok guys thanks for your workarounds!
k0d3rrr
Scratcher
1000+ posts

making wait for second blocks have options!

The workarounds (mostly) don't work because of the 1/200 second delay that scripts have on Scratch, so, support!
Also, here's what the blocks should look like.
wait (3) [seconds v]:: control // Results in three seconds.
wait (5) [minutes v]:: control // Results in five minutes.
wait (0.25) [hours v]:: control // Results in fifteen minutes.
VedanshS933
Scratcher
1000+ posts

making wait for second blocks have options!

k0d3rrr wrote:

The workarounds (mostly) don't work because of the 1/200 second delay that scripts have on Scratch, so, support!
Also, here's what the blocks should look like.
wait (3) [seconds v]:: control // Results in three seconds.
wait (5) [minutes v]:: control // Results in five minutes.
wait (0.25) [hours v]:: control // Results in fifteen minutes.

The easiest workaround

wait (60) secs // for minutes

Do basic maths and type the answer. That's simple. Isnt it that the Scratch Editor works on Second and not Minutes and Hours? And who the heck would need to put 2 hours? Semi Support.

Scratch On!

Last edited by VedanshS933 (Feb. 21, 2022 11:45:29)

DinoMaster20
Scratcher
1000+ posts

making wait for second blocks have options!

Crow_Boy08 wrote:

(#4)

lolecksdeehaha wrote:

Sorry, no support. The workaround is extremely easy:
define wait (amount) (hours/minutes)
if <(hours/minutes)=(hours)> then
wait (((amount)*(60))*(60)) secs
else
wait ((amount)*(60)) secs
end
yeah but what if new scratchers don't know it and they don't know how to use custommblocks
Scratch isn't about going the easiest way, it about learning. You could also just use
wait (60) secs
or
wait (3600) secs
Though, I'm sure we don't need to wait for this long anyway. Why would you possibly need to do something for that long?
lolecksdeehaha
Scratcher
1000+ posts

making wait for second blocks have options!

k0d3rrr wrote:

The workarounds (mostly) don't work because of the 1/200 second delay that scripts have on Scratch, so, support!
Also, here's what the blocks should look like.
wait (3) [seconds v]:: control // Results in three seconds.
wait (5) [minutes v]:: control // Results in five minutes.
wait (0.25) [hours v]:: control // Results in fifteen minutes.
But… with longer blocks, wouldn't it be the same delay? This is literally how scripts on Scratch work, regardless of the hacky implementation (by the ST) of the blocks.
RL1123
Scratcher
1000+ posts

making wait for second blocks have options!

k0d3rrr wrote:

The workarounds (mostly) don't work because of the 1/200 second delay that scripts have on Scratch, so, support!
Source for the amount of delay?
lolecksdeehaha
Scratcher
1000+ posts

making wait for second blocks have options!

rayli1123 wrote:

k0d3rrr wrote:

The workarounds (mostly) don't work because of the 1/200 second delay that scripts have on Scratch, so, support!
Source for the amount of delay?
Scratch's crappy interpreting system.
Also, I don't get why they're mentioning that. It'll be the same for the wait for minute/hour blocks.
ideapad-320
Scratcher
1000+ posts

making wait for second blocks have options!

Support!

lolecksdeehaha wrote:

Sorry, no support. The workaround is extremely easy:
define wait (amount) (hours/minutes)
if <(hours/minutes)=(hours)> then
wait (((amount)*(60))*(60)) secs
else
wait ((amount)*(60)) secs
end
“SIMPLE” workaround:
define wait (number) (period)
if <<(period) = [milliseconds]> or <(period) = [millisec]>> then
wait ((number)/(1000)) secs
else
if <(period) = [frames]> then
wait ((number)/(30)) secs
else
if <(period) = [10th-seconds]> then
wait ((number)/(10)) secs
else
if <<(period) = [min]> or <(period) = [minutes]>> then
wait ((number)*(60)) secs
else
if <<(period) = [hour]> or <(period) = [hr]>> then
wait ((number)*(3600)) secs
else
wait (number) secs
end
end
end
end
end
also 1/200 sec delay:

k0d3rrr wrote:

The workarounds (mostly) don't work because of the 1/200 second delay that scripts have on Scratch, so, support!
Also, here's what the blocks should look like.
wait (3) [seconds v]:: control // Results in three seconds.
wait (5) [minutes v]:: control // Results in five minutes.
wait (0.25) [hours v]:: control // Results in fifteen minutes.
And i would like to ask you HOW?

Myst-- wrote:

No support. Just make a variable!
Its like saying “Use blocks”
Crow_Boy08
Scratcher
1000+ posts

making wait for second blocks have options!

bump
Crow_Boy08
Scratcher
1000+ posts

making wait for second blocks have options!

ugh bump
Crow_Boy08
Scratcher
1000+ posts

making wait for second blocks have options!

bomp
lolecksdeehaha
Scratcher
1000+ posts

making wait for second blocks have options!

ideapad-320 wrote:

Support!

lolecksdeehaha wrote:

Sorry, no support. The workaround is extremely easy:
define wait (amount) (hours/minutes)
if <(hours/minutes)=(hours)> then
wait (((amount)*(60))*(60)) secs
else
wait ((amount)*(60)) secs
end
“SIMPLE” workaround:
~snip~
also 1/200 sec delay:

k0d3rrr wrote:

The workarounds (mostly) don't work because of the 1/200 second delay that scripts have on Scratch, so, support!
Also, here's what the blocks should look like.
wait (3) [seconds v]:: control // Results in three seconds.
wait (5) [minutes v]:: control // Results in five minutes.
wait (0.25) [hours v]:: control // Results in fifteen minutes.
And i would like to ask you HOW?

Myst-- wrote:

No support. Just make a variable!
Its like saying “Use blocks”
But, it's are you literally going to use those all at the same time? Also, Scratch wait blocks are really bad at milliseconds.
on a side note, do you know about decimal points?

Powered by DjangoBB