Discuss Scratch

Scratcher1002
Scratcher
1000+ posts

Custom everything (Supporters 14:15:8:15:10.5)

edward789121 wrote:

joefarebrother wrote:

I support custom C blocks, in a way. I think in all custom blocks there should be an “Add C input” option, which will create a block in a C input which could be dragged into a script, like in this badly-made mockup:


that's a copy of my post
No, because his has a mockup in picture.
Jonathan50
Scratcher
1000+ posts

Custom everything (Supporters 14:15:8:15:10.5)

Scratcher1002 wrote:

DaSpudLord wrote:

No support for custom hat, how would you define when it starts?

Support for the rest.
Same way as the c-block…?
Wat. No. A c-block can go under a hat, and that's when it's run. Hat blocks *start* a script and don't go under any hat.
Scratcher1002
Scratcher
1000+ posts

Custom everything (Supporters 14:15:8:15:10.5)

Jonathan50 wrote:

Scratcher1002 wrote:

DaSpudLord wrote:

No support for custom hat, how would you define when it starts?

Support for the rest.
Same way as the c-block…?
Wat. No. A c-block can go under a hat, and that's when it's run. Hat blocks *start* a script and don't go under any hat.
Oh.. Oops. You would put something like:
define when <this> (script)
repeat until <(timer) > (0.1)>

end
forever
if <this:: custom-arg> then
script :: custom-arg
end

when <> :: custom hat
MathlyCat
Scratcher
1000+ posts

Custom everything (Supporters 14:15:8:15:10.5)

Support. It clearly solves the millions of issues with suggestions.
Scratcher1002
Scratcher
1000+ posts

Custom everything (Supporters 14:15:8:15:10.5)

MathlyCat wrote:

Support. It clearly solves the millions of issues with suggestions.
And then the “Workarounds for highly suggested blocks” topic would be needed a lot for people to code those workarounds.
MathlyCat
Scratcher
1000+ posts

Custom everything (Supporters 14:15:8:15:10.5)

Scratcher1002 wrote:

MathlyCat wrote:

Support. It clearly solves the millions of issues with suggestions.
And then the “Workarounds for highly suggested blocks” topic would be needed a lot for people to code those workarounds.
Oh no…

NO SUPPORT
NO SUPPORT
NO SUPPORT!!!!!!


(Just kidding )
Jonathan50
Scratcher
1000+ posts

Custom everything (Supporters 14:15:8:15:10.5)

Scratcher1002 wrote:

Oh.. Oops. You would put something like:
define when <this> (script)
repeat until <(timer) > (0.1)>

end
forever
if <this:: custom-arg> then
script :: custom-arg
end

when <> :: custom hat
There's a problem; ‘this’ will never change because it's a boolean input. If you had a
when <(timer) > [50]> :: custom hat
block, it would never fire, because when the boolean is evaluated it'll be zero.
You can try this:
define custom block <boolean input>
wait until (boolean input)
say [Hello, world] for (2) secs

when gf clicked
reset timer
custom block <(timer) > [50]>
Since when the boolean is evaluated it's false, and false is passed to the custom block, it'll just hang there forever.
The primitive WAIT UNTIL and REPEAT UNTIL (and in Scratch 1.4, FOREVER IF) blocks get around this by evaluating the boolean every cycle, so it's not really a normal block.
Sheep_maker
Scratcher
1000+ posts

Custom everything (Supporters 14:15:8:15:10.5)

For custom hats, we can just have custom booleans and
when<>::events hat
though I think there was a problem with that block that led to no-supports on its suggestion(s). Could someone remind me what it was, if there was any?
Scratcher1002
Scratcher
1000+ posts

Custom everything (Supporters 14:15:8:15:10.5)

Sheep_maker wrote:

For custom hats, we can just have custom booleans and
when<>::events hat
though I think there was a problem with that block that led to no-supports on its suggestion(s). Could someone remind me what it was, if there was any?
The reason was that it was too ambiguous, would it stop after the boolean was true? Or would it keep going? I believe it was also buggy in the latter sense.
Jonathan50
Scratcher
1000+ posts

Custom everything (Supporters 14:15:8:15:10.5)

Scratcher1002 wrote:

Custom cap:

No idea what this would be used for…. But whateves.
It could be useful:
define{breakpoint :: custom cap} :: custom hat
say [BREAKPOINT REACHED] for (2) secs
stop [all v]

Last edited by Jonathan50 (April 27, 2016 01:31:13)

joefarebrother
Scratcher
500+ posts

Custom everything (Supporters 14:15:8:15:10.5)

Jonathan50 wrote:

You can try this:
define custom block <boolean input>
wait until (boolean input)
say [Hello, world] for (2) secs

when gf clicked
reset timer
custom block <(timer) > [50]>
Since when the boolean is evaluated it's false, and false is passed to the custom block, it'll just hang there forever.
The primitive WAIT UNTIL and REPEAT UNTIL (and in Scratch 1.4, FOREVER IF) blocks get around this by evaluating the boolean every cycle, so it's not really a normal block.

I thought about that problem after making my previous post here. The way snap! handles it, with first class procedures, would be confusing for new scratchers, especially from an input which doesn't look like it should be one, and might still be confusing even if scratch had added lambdas a long time ago.

My idea to solve this is to have an option when creating an input, one option being “check once before this block starts” and the other being “check every time this input is used”
joefarebrother
Scratcher
500+ posts

Custom everything (Supporters 14:15:8:15:10.5)

Scratcher1002 wrote:

Sheep_maker wrote:

For custom hats, we can just have custom booleans and
when<>::events hat
though I think there was a problem with that block that led to no-supports on its suggestion(s). Could someone remind me what it was, if there was any?
The reason was that it was too ambiguous, would it stop after the boolean was true? Or would it keep going? I believe it was also buggy in the latter sense.
I noticed Snap! has this block. How does it handle it?

(I'm on mobile and can't test it now)
cs377310
Scratcher
100+ posts

Custom everything (Supporters 14:15:8:15:10.5)

support for reporters, booleans, c and cap blocks. no support the rest.

mock up for reports/booleans/c/cap blocks:

Last edited by cs377310 (June 25, 2016 01:35:13)

cs377310
Scratcher
100+ posts

Custom everything (Supporters 14:15:8:15:10.5)

Bump!
meowflash
Scratcher
500+ posts

Custom everything (Supporters 14:15:8:15:10.5)

Good idea!

when stop sign clicked :: custom hat
wait until <green flag clicked? :: custom>
for (2) in (x :: variables) :: custom cstart
say ((50)^(10) :: custom) for (2) secs
end
stop all and click green flag :: custom cap
24691357
Scratcher
100+ posts

Custom everything (Supporters 14:15:8:15:10.5)

LATIN CAPITAL LETTER A, LATIN CAPITAL LETTER L, LATIN CAPITAL LETTER L support
SparkyGaming101
Scratcher
23 posts

Custom everything (Supporters 14:15:8:15:10.5)

Sorry for necroposting.
Support. For. All.
Custom Hats
They would work like:
define while <boolean> (start script :: custom stack) (current block running?) (end script :: custom cap) :: hat 
do script :: grey
start script :: custom stack
...
end script :: custom cap
Instead of:
define while <boolean> :: hat 
do script :: grey
BUT both appear as:
while <> :: custom hat
Custom Booleans
define <boolean> <true?> <false> (report <> :: cap)
...
Appears as:
<boolean> :: custom
Custom C's
define (report [true v] :: custom stack)   if < > then else if < >  else
do script :: custom cap // Automatically added.
Appears as:
if <> then{
...
}else if <>{
...
}else{
...
} :: custom
Custom Reporters
define (join (s1 :: custom) (s2 :: custom) (s3 :: custom) (s4 :: custom) (s5 :: custom))  (set reporter to [] :: custom stack)
set reporter to (join (join (join (join (s1:: custom) (s2 :: custom)) (s3:: custom)) (s4:: custom )) (s5:: custom)) :: custom stack
report reporter :: custom cap //Auto Added.
Summary:
I support all.
Tommy0924
Scratcher
100+ posts

Custom everything (Supporters 14:15:8:15:10.5)

SparkyGaming101 wrote:

Sorry for necroposting.
Support. For. All.
Custom Hats
They would work like:
define while <boolean> (start script :: custom stack) (current block running?) (end script :: custom cap) :: hat 
do script :: grey
start script :: custom stack
...
end script :: custom cap
Instead of:
define while <boolean> :: hat 
do script :: grey
BUT both appear as:
while <> :: custom hat
Custom Booleans
define <boolean> <true?> <false> (report <> :: cap)
...
Appears as:
<boolean> :: custom
Custom C's
define (report [true v] :: custom stack)   if < > then else if < >  else
do script :: custom cap // Automatically added.
Appears as:
if <> then{
...
}else if <>{
...
}else{
...
} :: custom
Custom Reporters
define (join (s1 :: custom) (s2 :: custom) (s3 :: custom) (s4 :: custom) (s5 :: custom))  (set reporter to [] :: custom stack)
set reporter to (join (join (join (join (s1:: custom) (s2 :: custom)) (s3:: custom)) (s4:: custom )) (s5:: custom)) :: custom stack
report reporter :: custom cap //Auto Added.
Summary:
I support all.
Meant to be on this account.
SparkyGaming101
Scratcher
23 posts

Custom everything (Supporters 14:15:8:15:10.5)

SparkyGaming101 wrote:

Sorry for necroposting.
Support. For. All.
Custom Hats
They would work like:
define while <boolean> (start script :: custom stack) (current block running?) (end script :: custom cap) :: hat 
do script :: grey
start script :: custom stack
...
end script :: custom cap
Instead of:
define while <boolean> :: hat 
do script :: grey
BUT both appear as:
while <> :: custom hat
Custom Booleans
define <boolean> <true?> <false> (report <> :: cap)
...
Appears as:
<boolean> :: custom
Custom C's
define (report [true v] :: custom stack)   if < > then else if < >  else
do script :: custom cap // Automatically added.
Appears as:
if <> then{
...
}else if <>{
...
}else{
...
} :: custom
Custom Reporters
define (join (s1 :: custom) (s2 :: custom) (s3 :: custom) (s4 :: custom) (s5 :: custom))  (set reporter to [] :: custom stack)
set reporter to (join (join (join (join (s1:: custom) (s2 :: custom)) (s3:: custom)) (s4:: custom )) (s5:: custom)) :: custom stack
report reporter :: custom cap //Auto Added.
Summary:
I support all.
And the custom reporter looks like:
(join [s] [s] [s] [s] [s] :: custom 

Last edited by SparkyGaming101 (July 6, 2018 01:37:53)

julianandwill
Scratcher
500+ posts

Custom everything (Supporters 14:15:8:15:10.5)

Support for all, they could really make anything possible.

Last edited by julianandwill (July 6, 2018 02:08:12)

Powered by DjangoBB