Discuss Scratch

_nix
Scratcher
1000+ posts

Scratch Workaround Guide VII

INSERT-USER_NAME wrote:

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.
Is it a workaround for “when mouse over love/fave”, which is also a workaround for “when mouse over report”? In that case, yes, I'm aware, and yes, that's half the reason it's not in this guide

(The other half is that people probably shouldn't be trying to detect loves/faves from inside the project anyway. That's a “connecting to the outside world” feature which was left out of Scratch for a reason.)

Last edited by _nix (Feb. 19, 2023 22:57:37)


══ trans autistic lesbian enbydoggirls // 16 17 18 19 20 21, she/they
sparrows one word to the paragraph // <3 // ~(quasar) nebula
INSERT-USER_NAME
Scratcher
1000+ posts

Scratch Workaround Guide VII

_nix wrote:

INSERT-USER_NAME wrote:

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.
Is it a workaround for “when mouse over love/fave”, which is also a workaround for “when mouse over report”? In that case, yes, I'm aware, and yes, that's half the reason it's not in this guide
Nah, it's basically an “always” block, and it continuously runs all the blocks under it like a forever loop no matter what, the only way to stop it is the pause button that only can be found in TurboWarp or the nono word.

consider posting here maybe?
hey guys
qwerty_wasd_gone
Scratcher
1000+ posts

Scratch Workaround Guide VII

INSERT-USER_NAME wrote:

_nix wrote:

INSERT-USER_NAME wrote:

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.
Is it a workaround for “when mouse over love/fave”, which is also a workaround for “when mouse over report”? In that case, yes, I'm aware, and yes, that's half the reason it's not in this guide
Nah, it's basically an “always” block, and it continuously runs all the blocks under it like a forever loop no matter what, the only way to stop it is the pause button that only can be found in TurboWarp or the nono word.
the when <> is true workaround?

shift+ctrl+down arrow to scroll
I may sometimes make mistakes, change my mind, etc., and edit my posts
When (::red) clicked :: events hat
repeat until <key [all v] pressed?>{
destroy this sprite::control cap
when @greenFlag misclicked::events hat
become idiot::custom}::control
(╯°□° ╯︵ ┻━┻::red)::#000000 reporter//this is brad, he creates cursed scripts like the one you saw above
(ㆆ_ㆆ)//this is max, he stares at you with that expression if you say you don't support my suggestion


You found me
INSERT-USER_NAME
Scratcher
1000+ posts

Scratch Workaround Guide VII

qwerty_wasd_gone wrote:

INSERT-USER_NAME wrote:

_nix wrote:

INSERT-USER_NAME wrote:

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.
Is it a workaround for “when mouse over love/fave”, which is also a workaround for “when mouse over report”? In that case, yes, I'm aware, and yes, that's half the reason it's not in this guide
Nah, it's basically an “always” block, and it continuously runs all the blocks under it like a forever loop no matter what, the only way to stop it is the pause button that only can be found in TurboWarp or the nono word.
the when <> is true workaround?
No, it's

consider posting here maybe?
hey guys
qwerty_wasd_gone
Scratcher
1000+ posts

Scratch Workaround Guide VII

INSERT-USER_NAME wrote:

qwerty_wasd_gone wrote:

INSERT-USER_NAME wrote:

_nix wrote:

INSERT-USER_NAME wrote:

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.
Is it a workaround for “when mouse over love/fave”, which is also a workaround for “when mouse over report”? In that case, yes, I'm aware, and yes, that's half the reason it's not in this guide
Nah, it's basically an “always” block, and it continuously runs all the blocks under it like a forever loop no matter what, the only way to stop it is the pause button that only can be found in TurboWarp or the nono word.
the when <> is true workaround?
No, it's
when [timer v] > (0.001)
reset timer
...
not dangerous

shift+ctrl+down arrow to scroll
I may sometimes make mistakes, change my mind, etc., and edit my posts
When (::red) clicked :: events hat
repeat until <key [all v] pressed?>{
destroy this sprite::control cap
when @greenFlag misclicked::events hat
become idiot::custom}::control
(╯°□° ╯︵ ┻━┻::red)::#000000 reporter//this is brad, he creates cursed scripts like the one you saw above
(ㆆ_ㆆ)//this is max, he stares at you with that expression if you say you don't support my suggestion


You found me
INSERT-USER_NAME
Scratcher
1000+ posts

Scratch Workaround Guide VII

qwerty_wasd_gone wrote:

INSERT-USER_NAME wrote:

qwerty_wasd_gone wrote:

INSERT-USER_NAME wrote:

Nah, it's basically an “always” block, and it continuously runs all the blocks under it like a forever loop no matter what, the only way to stop it is the pause button that only can be found in TurboWarp or the nono word.
the when <> is true workaround?
No, it's
when [timer v] > (0.001)
reset timer
...
not dangerous
I said dangerous if misused, as there's almost no way to stop the script as it will forever keep on running.

Still, I'm not sure if it could go here.

consider posting here maybe?
hey guys
qwerty_wasd_gone
Scratcher
1000+ posts

Scratch Workaround Guide VII

INSERT-USER_NAME wrote:

qwerty_wasd_gone wrote:

INSERT-USER_NAME wrote:

qwerty_wasd_gone wrote:

INSERT-USER_NAME wrote:

Nah, it's basically an “always” block, and it continuously runs all the blocks under it like a forever loop no matter what, the only way to stop it is the pause button that only can be found in TurboWarp or the nono word.
the when <> is true workaround?
No, it's
when [timer v] > (0.001)
reset timer
...
not dangerous
I said dangerous if misused, as there's almost no way to stop the script as it will forever keep on running.

Still, I'm not sure if it could go here.
just press see inside then remove the script from the project, problem solved

shift+ctrl+down arrow to scroll
I may sometimes make mistakes, change my mind, etc., and edit my posts
When (::red) clicked :: events hat
repeat until <key [all v] pressed?>{
destroy this sprite::control cap
when @greenFlag misclicked::events hat
become idiot::custom}::control
(╯°□° ╯︵ ┻━┻::red)::#000000 reporter//this is brad, he creates cursed scripts like the one you saw above
(ㆆ_ㆆ)//this is max, he stares at you with that expression if you say you don't support my suggestion


You found me
medians
Scratcher
1000+ posts

Scratch Workaround Guide VII

qwerty_wasd_gone wrote:

just press see inside then remove the script from the project, problem solved
Cloud projects? Large projects?

Medians bamboozled by 3.0 (version 3.0): https://scratch-mit-edu.ezproxy.canberra.edu.au/projects/979822351/
hi875230163394: You're similar to valve in that you both hate a certain number…
Scratch 0.x, 1.x, 2.x, 3.x and LogoBlocks Archives
Bamboozlement: https://scratch-mit-edu.ezproxy.canberra.edu.au/studios/33739789
Describe favorite topics: https://scratch-mit-edu.ezproxy.canberra.edu.au/studios/35764610/
SP community won against Fandom :P
Years on internet: 16 (very close to 16)
medians: Oh god not this utc - 12 thing again..
Fun_Cupcake_i81: What, were you expecting not to see the utc - 12 thing again? THE UTC - 12 THIGN ALWAYS RETURNS. ALWAYS.
medians: I knew it would happen. I was the one who started it last year.
Fun_Cupcake_i81: Well then if you didn't want it back maybe you need to time travel to last year and fix that

Oh wait if you could time travel I think we all know exactly when you would go-
user1: That picture is from 2.0. Now he’s at my house and is my pet.
user2: But this is medians we're talking about, so “from 2.0” can mean the same thing as “from five seconds ago”.

Detect Scratch version here
My other accounts: @selfexplanatory @modesties @chaircard @fireflyhero @dividendyield @colloids @radians @skeuamorphism @dihectogon @anglebisector @aau- @EditBlockColors @AdamantOrb @MoongeistBeam @festively @Ampharos_ @straightforwardness @interchangeably
i trolled redcat LOL






if you see this
{what method did you use::control hat
answer on profile ::motion
} ::operators

;
qwerty_wasd_gone
Scratcher
1000+ posts

Scratch Workaround Guide VII

medians wrote:

qwerty_wasd_gone wrote:

just press see inside then remove the script from the project, problem solved
Cloud projects? Large projects?
leave the project, there

shift+ctrl+down arrow to scroll
I may sometimes make mistakes, change my mind, etc., and edit my posts
When (::red) clicked :: events hat
repeat until <key [all v] pressed?>{
destroy this sprite::control cap
when @greenFlag misclicked::events hat
become idiot::custom}::control
(╯°□° ╯︵ ┻━┻::red)::#000000 reporter//this is brad, he creates cursed scripts like the one you saw above
(ㆆ_ㆆ)//this is max, he stares at you with that expression if you say you don't support my suggestion


You found me
medians
Scratcher
1000+ posts

Scratch Workaround Guide VII

qwerty_wasd_gone wrote:

medians wrote:

qwerty_wasd_gone wrote:

just press see inside then remove the script from the project, problem solved
Cloud projects? Large projects?
leave the project, there
Rip the people who want to play the project but without the script lol. And remixing projects to forget they remixed them.

Last edited by medians (Feb. 20, 2023 17:18:16)


Medians bamboozled by 3.0 (version 3.0): https://scratch-mit-edu.ezproxy.canberra.edu.au/projects/979822351/
hi875230163394: You're similar to valve in that you both hate a certain number…
Scratch 0.x, 1.x, 2.x, 3.x and LogoBlocks Archives
Bamboozlement: https://scratch-mit-edu.ezproxy.canberra.edu.au/studios/33739789
Describe favorite topics: https://scratch-mit-edu.ezproxy.canberra.edu.au/studios/35764610/
SP community won against Fandom :P
Years on internet: 16 (very close to 16)
medians: Oh god not this utc - 12 thing again..
Fun_Cupcake_i81: What, were you expecting not to see the utc - 12 thing again? THE UTC - 12 THIGN ALWAYS RETURNS. ALWAYS.
medians: I knew it would happen. I was the one who started it last year.
Fun_Cupcake_i81: Well then if you didn't want it back maybe you need to time travel to last year and fix that

Oh wait if you could time travel I think we all know exactly when you would go-
user1: That picture is from 2.0. Now he’s at my house and is my pet.
user2: But this is medians we're talking about, so “from 2.0” can mean the same thing as “from five seconds ago”.

Detect Scratch version here
My other accounts: @selfexplanatory @modesties @chaircard @fireflyhero @dividendyield @colloids @radians @skeuamorphism @dihectogon @anglebisector @aau- @EditBlockColors @AdamantOrb @MoongeistBeam @festively @Ampharos_ @straightforwardness @interchangeably
i trolled redcat LOL






if you see this
{what method did you use::control hat
answer on profile ::motion
} ::operators

;
MSE666
Scratcher
26 posts

Scratch Workaround Guide VII

medians wrote:

MSE666 wrote:

DON'T CREATE CODE BLOCK ON TO LOW FGS
when I start as a clone
create clone of [ v]
delete this clone
OR
when green flag clicked
forever
add (HELP ME:: list) to [HELP ME v]
end
Okay but blocks that do this cannot be shared because they crash Scratch.
yse
Dolgoipa
New Scratcher
5 posts

Scratch Workaround Guide VII

Great
MSE666
Scratcher
26 posts

Scratch Workaround Guide VII

Gys i'm fround to This!
Here click me is Gandi IDE

Last edited by MSE666 (March 4, 2023 08:43:06)

1080GBA
Scratcher
500+ posts

Scratch Workaround Guide VII

_nix wrote:

1080GBA wrote:

when can i have the sticky
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.

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.
bruh

Follow 1080GBA forever::#1080ba hat

Made by 1080GBA. All copyrights reserved.
————————————————————————————————————————————————————————————————————

self made custom cat block
————————————————————————————————————————————————————————————————————
3000th post in topic

500th post of myself
————————————————————————————————————————————————————————————————————
(((((((((((KING::#ff0000 ring)::#ff8800 ring)::#ffff00 ring)::#88ff00 ring)::#00ff88 ring)::#00ffff ring)::#0088ff ring)::#0000ff ring)::#8800ff ring)::#ff00ff ring)::#ff0088 ring)
————————————————————————————————————————————————————————————————————
<<<<<<<<1080GBA::#000>::#222>::#444>::#666>::#888>::#aaa>::#ccc>::#eee>
————————————————————————————————————————————————————————————————————
CrSb0001
Scratcher
10 posts

Scratch Workaround Guide VII

Here is another method for exponentiation:
define pow(base)(power)
set [result v] to [1]
set [base v] to (base)
set [power v] to (round (power))
set [done v] to [0]
if <(power) < [0]> then
set [base v] to [((1) / (base))]
set [power v] to [-1(() *(round (power))]
end
repeat until <[done v] = [1]>
if <(([power v]) mod (2)) = [0]> then
set [result v] to (([result v]) * ([base v]))
change [power v] by (-1)
end
if <(([power v]) mod (2)) > [0]> then
set [done v] to [1]
end
if <<not <<[done v] = [1]>>>
set [base v] to (([base v]) * ([base v]))
set [power v] to (([power v]) / (2))
end
end

Hopefully I wrote this correctly, if I didn't, here's the link to my cookie clicker script that I use the code in: https://scratch-mit-edu.ezproxy.canberra.edu.au/projects/814368636/editor/ (in the Cookie sprite)

Edit: eh, it worked well enough. I had a hard time typing most of the code by hand tbh

Last edited by CrSb0001 (April 11, 2023 14:32:23)


while <(boing)>
end
Stack Overflow: CrSb0001
Youtube: CrSb0001
Instagram: CrSb0001
when @stopSign clicked :: hat :: events
5_g
Scratcher
1000+ posts

Scratch Workaround Guide VII

CrSb0001 wrote:

Here is another method for exponentiation:
define pow(base)(power)
set [result v] to [1]
set [base v] to (base)
set [power v] to (round (power))
set [done v] to [0]
if <(power) < [0]> then
set [base v] to [((1) / (base))]
set [power v] to [-1(() *(round (power))]
end
repeat until <[done v] = [1]>
if <(([power v]) mod (2)) = [0]> then
set [result v] to (([result v]) * ([base v]))
change [power v] by (-1)
end
if <(([power v]) mod (2)) > [0]> then
set [done v] to [1]
end
if <<not <<[done v] = [1]>>>
set [base v] to (([base v]) * ([base v]))
set [power v] to (([power v]) / (2))
end
end

Hopefully I wrote this correctly, if I didn't, here's the link to my cookie clicker script that I use the code in: https://scratch-mit-edu.ezproxy.canberra.edu.au/projects/814368636/editor/ (in the Cookie sprite)

Edit: eh, it worked well enough. I had a hard time typing most of the code by hand tbh
that is so complicated for something so simple in other programming languages, no wonder most projects on scratch run horribly

Pro forumer, Scratch Empires I OG


IMPORTANT INFO ON SO2 FOR ANYONE WHO MISSED IT
MyScratchedAccount
Scratcher
1000+ posts

Scratch Workaround Guide VII

Can you add the custom charcters workaround
<key [(join [NOT ON THE LIST CHARACTER HERE] []) pressed?>

FOR THE HAT BLOCK, you need to hack JSON

Links:

Give An Internet - - My Profile - My Best Project Of The Week - Am I Online? - on wiki, go to my talk

Scratched//Boy/Him/He////Likes Apples//Coder //
—-
Go to Codin[co
medians
Scratcher
1000+ posts

Scratch Workaround Guide VII

MyScratchedAccount wrote:

Can you add the custom charcters workaround
<key [(join [NOT ON THE LIST CHARACTER HERE] []) pressed?>

FOR THE HAT BLOCK, you need to hack JSON
I was about to be like wait, but don’t you need to hack json both times?


You can’t put reporters in that block in 2.0 or earlier without hacking.

Anyway, that method doesn’t work with certain keys, so if this was added, maybe that could be mentioned.

Also the code should be like this:
<key (join [not on character list] []) pressed?>

Medians bamboozled by 3.0 (version 3.0): https://scratch-mit-edu.ezproxy.canberra.edu.au/projects/979822351/
hi875230163394: You're similar to valve in that you both hate a certain number…
Scratch 0.x, 1.x, 2.x, 3.x and LogoBlocks Archives
Bamboozlement: https://scratch-mit-edu.ezproxy.canberra.edu.au/studios/33739789
Describe favorite topics: https://scratch-mit-edu.ezproxy.canberra.edu.au/studios/35764610/
SP community won against Fandom :P
Years on internet: 16 (very close to 16)
medians: Oh god not this utc - 12 thing again..
Fun_Cupcake_i81: What, were you expecting not to see the utc - 12 thing again? THE UTC - 12 THIGN ALWAYS RETURNS. ALWAYS.
medians: I knew it would happen. I was the one who started it last year.
Fun_Cupcake_i81: Well then if you didn't want it back maybe you need to time travel to last year and fix that

Oh wait if you could time travel I think we all know exactly when you would go-
user1: That picture is from 2.0. Now he’s at my house and is my pet.
user2: But this is medians we're talking about, so “from 2.0” can mean the same thing as “from five seconds ago”.

Detect Scratch version here
My other accounts: @selfexplanatory @modesties @chaircard @fireflyhero @dividendyield @colloids @radians @skeuamorphism @dihectogon @anglebisector @aau- @EditBlockColors @AdamantOrb @MoongeistBeam @festively @Ampharos_ @straightforwardness @interchangeably
i trolled redcat LOL






if you see this
{what method did you use::control hat
answer on profile ::motion
} ::operators

;
CrSb0001
Scratcher
10 posts

Scratch Workaround Guide VII

5_g wrote:

CrSb0001 wrote:

Here is another method for exponentiation:
define pow(base)(power)
set [result v] to [1]
set [base v] to (base)
set [power v] to (round (power))
set [done v] to [0]
if <(power) < [0]> then
set [base v] to [((1) / (base))]
set [power v] to [-1(() *(round (power))]
end
repeat until <[done v] = [1]>
if <(([power v]) mod (2)) = [0]> then
set [result v] to (([result v]) * ([base v]))
change [power v] by (-1)
end
if <(([power v]) mod (2)) > [0]> then
set [done v] to [1]
end
if <<not <<[done v] = [1]>>>
set [base v] to (([base v]) * ([base v]))
set [power v] to (([power v]) / (2))
end
end

Hopefully I wrote this correctly, if I didn't, here's the link to my cookie clicker script that I use the code in: https://scratch-mit-edu.ezproxy.canberra.edu.au/projects/814368636/editor/ (in the Cookie sprite)

Edit: eh, it worked well enough. I had a hard time typing most of the code by hand tbh
that is so complicated for something so simple in other programming languages, no wonder most projects on scratch run horribly

Sorry about it being so long, I got this from Stack Overflow. The person who gave me the code wasn't really good with Scratch, I'll try to see if I can simplify it somehow :\
Edit: the exponentiation script was derived for a script with the same function in C, that's why it's so difficult to understand tbh.
Edit 2: It's based off of a C script for exponentiation by squaring

Last edited by CrSb0001 (March 13, 2023 14:36:03)


while <(boing)>
end
Stack Overflow: CrSb0001
Youtube: CrSb0001
Instagram: CrSb0001
when @stopSign clicked :: hat :: events
10data10
Scratcher
100+ posts

Scratch Workaround Guide VII

This may cross the line of being too complex for your guide but people are frequently asking about how to do this so it might help to have workarounds (or a few workarounds) included.


Clones don’t have names and therefore they can’t be used in these blocks the way Sprites can.

go to [ v]


point towards [ v]
<touching [ v] ?>
(distance to [ v])
([ v] of [Clone v])

Basically the workaround is to have local clone ID variables with constantly running forever loops in each clone that store its X position, its Y position, its direction, its costume, size, local variables and other information into sets of lists and that other sprites and clones can access and use and if necessary use the Pythagorean equation and trig. See, simple.

There are a number of examples but, as far as I can tell, are not collected anywhere.

I like this one by legendary34678 showing how sprites can be bonded together

https://scratch-mit-edu.ezproxy.canberra.edu.au/projects/719996268/

And this one from WildTraces showing how clones can detect distance to other clones and move away.

https://scratch-mit-edu.ezproxy.canberra.edu.au/projects/384145242

And many others that are probably better but in a search they end up being buried by Star Wars projects.


TL;DR
Because clones don’t have names they cannot be used in certain Scratch Blocks. The workaround is to move to the SNAP website and do your programming there.

Powered by DjangoBB