Discuss Scratch

SeanTank36
Scratcher
20 posts

We need new code blocks, like "Previous Costume", and "If I Receive [message1]".

Scratch Team!
We need some more code blocks to make creating certain projects easier!
Like, for example:

when green flag clicked
if <when I receive [ message1]> then
repeat (6)
next costume
end
wait until <when I receive [ message2]>
repeat (6)
previous costume
else
move (8) steps
end



Oh, and P.S.
Merry Christmas and Happy Holidays!
wWSunPandaWw
Scratcher
1000+ posts

We need new code blocks, like "Previous Costume", and "If I Receive [message1]".

No support.
They've said that they're not going to add a previous costume block, and that they're also not going to add a broadcast boolean. To create a previous costume block, you do this:

when [space] key pressed
switch costume to [ ((costume #) - (0))]

As for the broadcast boolean, why can't you just use the regular
when I receive [ v]  
script? If you really need a boolean, just use variables.

I have no idea why my codeblocks won't connect here.

Last edited by wWSunPandaWw (Dec. 8, 2017 17:09:03)

SeanTank36
Scratcher
20 posts

We need new code blocks, like "Previous Costume", and "If I Receive [message1]".

I don't know how to do that;
switch costume to [ ((costume # ) - (0))]
thing, and I already know about the
when I receive [ v]
thing!
But I'm talking about this:
A SENSOR BLOCK that makes it so that “if I recieve this message, I do this thing, if not, do the other thing” within a script, ya know?
if <When I receive [ message1]> then 
Do a thing


else
Do an different thing
end
wWSunPandaWw
Scratcher
1000+ posts

We need new code blocks, like "Previous Costume", and "If I Receive [message1]".

SeanTank36 wrote:

I don't know how to do that;
switch costume to [ ((costume # ) - (0))]
thing, and I already know about the
when I receive [ v]
thing!
But I'm talking about this:
A SENSOR BLOCK that makes it so that “if I recieve this message, I do this thing, if not, do the other thing” within a script, ya know?
if <When I receive [ message1]> then 
Do a thing


else
Do an different thing
end

Okay, for some reason, Scratch keeps doing that, so I'm going to give you an exploded view of the script.

switch costume to [ v]
(() - (1))

(costume #)

The
 
(costume #)
goes into the first slot of the
(() - (1))
block. You then put that into the “costume1” part of the
switch costume to [ v]
block.

For more information, look at a project I made for this purpose here.

Last edited by wWSunPandaWw (Dec. 8, 2017 19:06:41)

girlsruless
Scratcher
1000+ posts

We need new code blocks, like "Previous Costume", and "If I Receive [message1]".

Previous costume block? Yassssss
Cub56
Scratcher
1000+ posts

We need new code blocks, like "Previous Costume", and "If I Receive [message1]".

No support, for the previous costume block you can just use

switch costume to [((costume #) - (1)) v]

For the “if I receive” it's already been rejected - there's the “when I receive” block already.

Last edited by Cub56 (Dec. 8, 2017 19:30:46)

-ShadowOfTheFuture-
Scratcher
1000+ posts

We need new code blocks, like "Previous Costume", and "If I Receive [message1]".

I believe both of those blocks have been rejected.

Curse you, 60-second rule…

The stickied list of rejected suggestions wrote:

<broadcast received> boolean
There is way too much ambiguity to how this would work. Would it return true of the broadcast was fired at any point since the project was created, since the green flag was clicked, since something else was broadcasted, etc.? If you really want to do something like this, instead just make a variable and set it to 1 and use the equals block.

Last edited by -ShadowOfTheFuture- (Dec. 8, 2017 21:18:50)

Charles12310
Scratcher
1000+ posts

We need new code blocks, like "Previous Costume", and "If I Receive [message1]".

-ShadowOfTheFuture- wrote:

I believe both of those blocks have been rejected.

Curse you, 60-second rule…

The stickied list of rejected suggestions wrote:

<broadcast received> boolean
There is way too much ambiguity to how this would work. Would it return true of the broadcast was fired at any point since the project was created, since the green flag was clicked, since something else was broadcasted, etc.? If you really want to do something like this, instead just make a variable and set it to 1 and use the equals block.
As I said, the “previous costume” is not rejected. Where is its place in any of the topics that have a list of rejected suggestions?

It's just that users feel like it doesn't need to be needed because there is already a way to switch to a previous costume.
DaEpikDude
Scratcher
1000+ posts

We need new code blocks, like "Previous Costume", and "If I Receive [message1]".

I'd say 30% support for previous costume: it's not too hard of a workaround and you can make a custom block for it if need be.
No support for the broadcast boolean though: you can do something like this.
when I receive [broadcast v]
set [broadcast received? v] to [true]
Also, as has been pointed out, it's been rejected for being too ambiguous.
290Scratcher
Scratcher
1000+ posts

We need new code blocks, like "Previous Costume", and "If I Receive [message1]".

No support, there are workarounds for both.
when I receive [message1 v] :: events boolean
when I receive [message1 v]
set [something received? v] to [true]
...
set [something received? v] to [false]
then
if <(something received) = [true]> then
. . .
end
previous costume :: looks

switch costume to ((costume #) - (1))

Powered by DjangoBB