Discuss Scratch

Alberknyis
Scratcher
1000+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

@Zekrom01

I see what you're trying to say, but if you want to compare two things *fairly* you can't just pick two completely different cases for them, right?

So this:
if(boolean_expression)
{
	statement
}
else if(boolean_expression)
{
	stetement
}
else if(boolean_expression)
{
	stotement
}
else
{
	stoshment
}

Would look like this:
if <> then
else
if <> then
else
if <> then
else
end
end
end

And that's pretty easy to read, right?
Charmind
Scratcher
500+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

maybe this can be new block named switch, not if <> then?
Support
switch(variable) default::control cstart
(1)::control celse
(2)::control celse
(3)::control cend

it works that:
if (variable) = (1):: cstart control
...::grey
else if (variable) = (2)::celse
...::grey
else if (variable) = (3)::celse
...::grey
else::clese
default::grey
::cend
scratchisthebest
Scratcher
1000+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

Yeah but I think this should be added to the if/else block, not the if. It's closer to modern programming languages:

if (a) {
  
} else if (b) {
  
} else if (c) {
  
}
Zekrom01
Scratcher
1000+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

scratchisthebest wrote:

Yeah but I think this should be added to the if/else block, not the if. It's closer to modern programming languages:

if (a) {
  
} else if (b) {
  
} else if (c) {
  
}
Sure.
Zekrom01
Scratcher
1000+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

when <true ::operators Boolean> ::sensing hat
repeat until <this suggestion accepted? ::extension> ::grey cstart
bump ::custom
bump it again ::motion
bump it {{a lot of ::variables stack}::looks ring} times ::pen
goto {bump ::custom stack} ::control cap
end ::cend

Sorry, I was bored.
Tessaract2
Scratcher
28 posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

That's a good suggestion, support! :: pen
But how do you do that? :: motion
Zekrom01
Scratcher
1000+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

Tessaract2 wrote:

That's a good suggestion, support! :: pen
But how do you do that? :: motion
Do what?

Oh, and thank you for the support!
SkyShine
Scratcher
100+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

This would be useful, support!
Tessaract2
Scratcher
28 posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

How do you make the C block have like 12 thingies, and not one like this? :: motion
forever

end
DaSpudLord
Scratcher
1000+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

Tessaract2 wrote:

How do you make the C block have like 12 thingies, and not one like this? :: motion
forever

end
this is the beginning of a loop :: cstart

this is the middle :: celse

this is another part of the middle :: celse

this is the end :: cend
this is the beginning of a loop :: cstart

this is the middle :: celse

this is another part of the middle :: celse

this is the end :: cend
Dy155
Scratcher
98 posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

Support. It's like this:
when I receive [game started v]
if <...>
custom block :: custom
else if <...> :: celse
...
else
...
Zekrom01
Scratcher
1000+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

bump
pvz_pro
Scratcher
500+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

Zekrom01 wrote:

Zekrom01 wrote:

bump
Why quote yourself to bump?
anyway, I support.

Last edited by pvz_pro (Jan. 22, 2016 14:54:26)

Zekrom01
Scratcher
1000+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

pvz_pro wrote:

Zekrom01 wrote:

Zekrom01 wrote:

bump
Why quote yourself to bump?
I get bored and decide to do it. you're allowed to do that
Zekrom01
Scratcher
1000+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

bump
The_Kitty_Eevee
Scratcher
100+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

DaSpudLord wrote:

ChocolatePi wrote:

DaSpudLord wrote:

Semi-support, this could be confusing to inexperienced scratchers.
How would it be confusing?

I support! It's much better than calling it “elif”. I'm not sure about the wording on the item in the right-click menu though. How about “insert condition” or something?

User1 wrote:

Why r der soooooo mannneeee c thingies on da block??????!!!!!!!!!???????:
if <> then::control cstart

else if <> then::celse

else if <> then::celse

else if <> then::celse

else if <> then::celse

else if <> then::celse

else if <> then::celse

else if <> then::celse

else::celse

end
^^^^^^^
Zekrom01
Scratcher
1000+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

bump
Tessaract2
Scratcher
28 posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

bump :: motion
MathlyCat
Scratcher
1000+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

Support!!
Studio04040807
Scratcher
100+ posts

Suggestion for the if <> then block (25+ support, 3 semi, 1 no)

Support, but the block should always have an else block at the end:
if <> then :: cstart control
... :: grey
else if <> then :: celse
... :: grey
else :: celse
... :: grey

end

Powered by DjangoBB