AMP's Block Collection (Looking for Feedback)

$brush-3 $AMP\'s-5\ $Block-3 $Collection-3\ $\(probably\)-0.8 $the $best $blocks $of $all $time!::motion ring
This is a collection of useful blocks such as:

(keys being pressed::#1600FF)

set cursor to [default V]::#1600FF

<JavaScript enabled?::#1600FF>

Some of them are not made by me (most of them are tho, and a lot of them previously used code by me that was modified by someone else), see their help dialog to see who made them.

You can download these blocks by exporting them from the project here.

I liked them. Nice! :grin:

You can add more useful blocks in the future and improve the blocks so things get better.

thanks :slight_smile: i've defenitely improved my skills on snap since i started out

what is the infinity sign on the on every tick::#0000ff hat and how did you get it?

it represents a hat that constantly checks and executes instead of just once. right-click the hat block definition then check "conditional"

interesting, so the sb for it is on every tick::#0000ff condition hat

i'm looking for feedback on this.
btw the link was updated to another file host so trolls can't take it down and it takes longer to expire (downloading it resets expiry).

You don’t need a file host thing though… why do you have it?

the file host contains an xml with just the blocks, the project also contains examples

alright, after re-reading my reply I realized I was way too harsh on the criticism. please dont take it personally!

is in
AMPs Block Collection script pic has a one block workaround

comment // already exists
also Brian’s rant about comments in code

AMPs Block Collection script pic unnecessary js, just


should be changed to

is
and AMPs Block Collection script pic can be

AMPs Block Collection script pic

so does the script pics

Yeah, in general we're not happy about links to code hosted elsewhere, especially not code with Javascript in it. I'm sure this particular one is benign, but it just makes life a little harder for moderators.

this doesn't seem to work for me. if i use it, it stops all scripts followed by it if javascript is disabled.

I cannot replicate that.

try running the set cursor to [default V]::#1600FF block. it detects JS to choose whether your workaround should be used or mine (yours requires a library that causes the block to take a bit longer to load), but your workaround doesn't run even though i have the entire code in the block.

i closely copied from your JS detection script by hand (simply exporting it and getting the code just gave me the old code).

yeah, I just realized. just replace the js enabled block with

(and yes the script pic will work this time)

ok so the thing is, the set cursor block only takes slightly longer on the first try, then is literally the same speed for everything other time. the amount of time it takes to detect if JS is enabled adds up, and it means that it is actually faster to always use the not js method, since it means you dont always have to check for js.

fixed. thanks for the script.

on a side note i removed the option to set the cursor to "none" because people can end up forgetting where their cursor is. i'll probably add a failsafe to stop people from doing set cursor to (join [none] @delInput @addInput)::#1600FF.

I mean, you could just add a help screen. your cursor will come back the moment your mouse exits the snap editor.

i don't know how to add help dialogues to custom blocks if that's what you're talking about.

hint: right click on the set cursor block when it is in the editor or palette and select help
I am against adding a failsafe because one thing snap does that I really like is preventing you from doing things they dont want, but still letting you do them if you really want to.

yep!

oh it was the comment I attached all along.