Discuss Scratch
- Discussion Forums
- » Suggestions
- » Scratch Workaround Guide VII
- medians
-
1000+ posts
Scratch Workaround Guide VII
This block since for some reason they had a backdrop equivalent but no costume ver:

Workaround:

If you can't see it:



Workaround:

If you can't see it:


Last edited by medians (Jan. 21, 2023 03:22:10)
- hill_walker123
-
100+ posts
Scratch Workaround Guide VII
yes, it's fine with me! But I didn't actually change any of the idea which makes it work (imagining a circle around the pivot and using cos and sin blocks to rotate around that), so I made sure to still include full credits to you. Is it alright if I add the version I did to the workaround guide, with credits for the original code and idea to you?
- hill_walker123
-
100+ posts
Scratch Workaround Guide VII
you can use scratchblocks This block since for some reason they had a backdrop equivalent but no costume ver:
Workaround:
If you can't see it:
switch costume to [random costume v]that's visible to everyone
switch costume to ((0) + (0))
set [# of costumes v] to (costume [number v] :: looks)
switch costume to (pick random (1) to (# of costumes))
Last edited by hill_walker123 (Jan. 23, 2023 16:30:49)
- medians
-
1000+ posts
Scratch Workaround Guide VII
The blocks in method 1 of delete last item of list are messed up. They should be:

Or in scratchblocks:
Repeat until message:

Repeat until message ended can be done by changing = 1 to 0, and if you want to wait until the message starts in the first place, you can add:

You can also add this before the repeat until loop in repeat until message but with 0 for a similar thing.

Or in scratchblocks:
set [popped value v] to (item (length of [list v] :: list) of [list v] :: list)
delete (length of [list v]) of [list v]
Yeah I know.you can use scratchblocksswitch costume to [random costume v]that's visible to everyone
switch costume to ((0) + (0))
set [# of costumes v] to (costume [number v] :: looks)
switch costume to (pick random (1) to (# of costumes))
Repeat until message:

Repeat until message ended can be done by changing = 1 to 0, and if you want to wait until the message starts in the first place, you can add:

You can also add this before the repeat until loop in repeat until message but with 0 for a similar thing.
- MSE666
-
26 posts
Scratch Workaround Guide VII
DON'T CREATE CODE BLOCK ON TO LOW FGS
when I start as a cloneOR
create clone of [ v]
delete this clone
when green flag clicked
forever
add (HELP ME:: list) to [HELP ME v]
end
- INSERT-USER_NAME
-
1000+ posts
Scratch Workaround Guide VII
those don't work and i'm on a school chromebook DON'T CREATE CODE BLOCK ON TO LOW FGSwhen I start as a cloneOR
create clone of [ v]
delete this clonewhen green flag clicked
forever
add (HELP ME:: list) to [HELP ME v]
end
- medians
-
1000+ posts
Scratch Workaround Guide VII
Okay but blocks that do this cannot be shared because they crash Scratch. DON'T CREATE CODE BLOCK ON TO LOW FGSwhen I start as a cloneOR
create clone of [ v]
delete this clonewhen green flag clicked
forever
add (HELP ME:: list) to [HELP ME v]
end
- medians
-
1000+ posts
Scratch Workaround Guide VII
Method 2: trigonometric “point towards”This can be shortened to:
This method uses the trigonometry function “atan” to calculate the direction between your current position and the target with math.define point towards x: (target x) y: (target y)
point in direction ([atan v] of (((target x) - (x position)) / ((target y) - (y position)))
if <(target y) < (y position)> then
turn cw (180) degrees
end
define point towards x: (target x) y: (target y)
point in direction (([atan v] of (((target x) - (x position)) / ((target y) - (y position)))) + ((180) * <(target y) < (y position)>))

- _nix
-
1000+ posts
Scratch Workaround Guide VII
Please stop asking. I will make a post clearly stating that I'm looking to have someone else maintain the thread or create their own workaround guide. I haven't decided when yet, so you'd be better off not expecting it any time soon. It'll probably be when I'm less active on the site in general or am too busy with other work to make suitable updates. when can i have the sticky
In my opinion, besides adding newly shared workarounds every now and then (which I am still doing!), the guide doesn't currently need that much maintenance or expanding, which is why I am not handing it off to anyone else right now.
- medians
-
1000+ posts
Scratch Workaround Guide VII
And that's how you not get the sticky. She is still maintaining it. when can i have the sticky
- _nix
-
1000+ posts
Scratch Workaround Guide VII
Thanks! But I won't be using this one — see, my goal is to have readable code that is easy to understand and learn from, not code that is absolutely as compact as it can possibly be. The main advantage of compact code is that it takes less space if you have to use it a bunch of times, but most people will just reuse the custom block. And, if a person's project is lagging a lot, this probably won't make much of a performance difference compared to bigger changes in code design. I think the benefits of readable code outweighs the benefits of compact code in this case.This can be shortened to:define point towards x: (target x) y: (target y)
point in direction ([atan v] of (((target x) - (x position)) / ((target y) - (y position)))
if <(target y) < (y position)> then
turn cw (180) degrees
end
- xz-Blaze
-
1000+ posts
Scratch Workaround Guide VII
not right now. she is still maintaining this sticky. when can i have the sticky
- medians
-
1000+ posts
Scratch Workaround Guide VII
The blocks in method 1 of delete last item of list are messed up. They should be:
Or in scratchblocks:set [popped value v] to (item (length of [list v] :: list) of [list v] :: list)
delete (length of [list v]) of [list v]
- _nix
-
1000+ posts
Scratch Workaround Guide VII
Got it, thanks! I'll have a lookie over other recent feedback later today.The blocks in method 1 of delete last item of list are messed up. They should be:
Or in scratchblocks:set [popped value v] to (item (length of [list v] :: list) of [list v] :: list)
delete (length of [list v]) of [list v]
edit: lmao sorry I screwed up an SSD with the OS install for my secondary comp / local file server and spent the afternoon getting that fixed. If nothing goes terribly awry I'll make halfway good on that promise tomorrow!
Last edited by _nix (Feb. 14, 2023 01:53:05)
- inom5962dojo
-
100+ posts
Scratch Workaround Guide VII
The reason new people want new Blocks is so it’s easier to do things, people who are inexperienced at coding are not going to think of these, and only like 1% of Scratchers use the fourms(not sure if that’s right, I think I saw it somewhere) These long scripts could be simplified into just one block, that’s the point of new blocks.
- _nix
-
1000+ posts
Scratch Workaround Guide VII
You're kind of right, but that's sort of the beauty of learning — as you code more and look at how other people do things (with “see inside”, through the forums, or by checking out tutorial projects!), you start to get better at coming up with solutions to code problems which The reason new people want new Blocks is so it’s easier to do things, people who are inexperienced at coding are not going to think of these, and only like 1% of Scratchers use the fourms(not sure if that’s right, I think I saw it somewhere) These long scripts could be simplified into just one block, that’s the point of new blocks.could use a single block, but are actually solvable with all the code already available! So, it does end up being a little harder for beginning Scratchers, but I think it's a healthy amount of challenge: there isn't much reason to learn the finer nuances of programming if every essential block is already available to you.
That's something I keep in mind with this workaround guide: Some Scratchers just really need a code block available to them, and aren't interested in figuring out exactly how to get it to work themselves. For those people, it's nice to have workarounds available. But the big goal with this guide, which makes it different from the ones before it, is that I want to gently teach people how the workarounds work, so that they have some coding ideas to think about whenever they use that workaround. I want to help introduce people who are less experienced with Scratch to concepts they might not have experimented with much before.
That's why workarounds are great — there's a great variety of frequently suggested blocks, and workarounds for them use many different kinds of blocks and ideas! By sharing those workarounds and going into a little detail about how they work, I can help show many different concepts in bite-sized pieces. I try not to go into a ton of detail, so I don't overwhelm most people and make them think they could never learn the ideas. It's just a small example in each workaround, but I hope it goes some way to help people warm up to ideas and start thinking about and using them more.
- inom5962dojo
-
100+ posts
Scratch Workaround Guide VII
You're kind of right, but that's sort of the beauty of learning — as you code more and look at how other people do things (with “see inside”, through the forums, or by checking out tutorial projects!), you start to get better at coming up with solutions to code problems which The reason new people want new Blocks is so it’s easier to do things, people who are inexperienced at coding are not going to think of these, and only like 1% of Scratchers use the fourms(not sure if that’s right, I think I saw it somewhere) These long scripts could be simplified into just one block, that’s the point of new blocks.could use a single block, but are actually solvable with all the code already available! So, it does end up being a little harder for beginning Scratchers, but I think it's a healthy amount of challenge: there isn't much reason to learn the finer nuances of programming if every essential block is already available to you.
That's something I keep in mind with this workaround guide: Some Scratchers just really need a code block available to them, and aren't interested in figuring out exactly how to get it to work themselves. For those people, it's nice to have workarounds available. But the big goal with this guide, which makes it different from the ones before it, is that I want to gently teach people how the workarounds work, so that they have some coding ideas to think about whenever they use that workaround. I want to help introduce people who are less experienced with Scratch to concepts they might not have experimented with much before.
That's why workarounds are great — there's a great variety of frequently suggested blocks, and workarounds for them use many different kinds of blocks and ideas! By sharing those workarounds and going into a little detail about how they work, I can help show many different concepts in bite-sized pieces. I try not to go into a ton of detail, so I don't overwhelm most people and make them think they could never learn the ideas. It's just a small example in each workaround, but I hope it goes some way to help people warm up to ideas and start thinking about and using them more.
Wow, thanks for responding so in depth! That’s a good point!
- _nix
-
1000+ posts
Scratch Workaround Guide VII
Thanks, I've gotten around to adding this now! Have a look near the top of the Motion, Looks & Sound section.yes, it's fine with me! But I didn't actually change any of the idea which makes it work (imagining a circle around the pivot and using cos and sin blocks to rotate around that), so I made sure to still include full credits to you. Is it alright if I add the version I did to the workaround guide, with credits for the original code and idea to you?
update:
Thanks! I've got this added too. Check out the bottom of This block since for some reason they had a backdrop equivalent but no costume ver:Motion, Looks & Sound — it's placed after the related “# of costumes” workaround.
Workaround:
I've also updated the Looks section to mention that none of those “switch costume” workarounds are needed for backdrops, since those already have options right in the block dropdown menu. Thanks for pointing that out for “random costume”!
Last edited by _nix (Feb. 14, 2023 14:12:55)
- INSERT-USER_NAME
-
1000+ posts
Scratch Workaround Guide VII
I found a workaround that can be very dangerous if misused, and as such, I'm not too sure if I should post it here.