Making a spinning effect with the new width and height blocks



How to make a spinning effect using the new set width and height blocks.
The outcome:

First, make sure you have the new update. This has the winter charaters and the set width and height blocks.
Then, go into the code.
Use a repeat forever block to make this last forever.
First, set a repeat block for 100.
Make sure to have made a variable, make it increase by one in this.
Then, make put the new set width and height block.
Make it so the width is set to the variable. The height is set to 100.
This code is in the repeat block
Then put a repeat block under it. Make it repeat times 200
Put the code just like above in it
Below it, put another reapeat block set for 100. Again, the code is the same.

If you want it bigger, just tweak these set and width blocks, so it adds the amount you want with the variable under width, and increase the height to match the desired shape.

Now you have made a text, shape or character spin!
Wait, the spinning effect works for one charater, unless you made other variables for it.

Should we add a remix tab to Hopscotch? -Yusamac's GT :man_technologist:t5:
๐•„๐•–๐•จ๐•ฅ๐•จ๐• โ„‚๐•ฃ๐•–๐•’๐•ฅ๐• ๐•ฃ'๐•ค ๐”พ๐•–๐•Ÿ๐•–๐•ฃ๐•’๐• ๐•‹๐• ๐•ก๐•š๐•”! (โœฟโ—•แ—œโ—•)โ”โ™ซ.*๏ฝฅ๏ฝก๏พŸ(ใฃโ—”โ—กโ—”)ใฃ(How's Your day? Hope its good :D) (Everyone's Awesome!) Mewtwo is amazing!-CoM

Just found reason why they stretched
I forgot to make seperate variables for them


I did something similar to this. Itโ€™s really cool! Btw, there are now object variables width and height.


I know, but you canโ€™t change those


You did yours different thatโ€™s why
Just checked the code for yours to see if they were different


What about
Repeat times (n)
Set width ((Self) Width) - 1) height ((Self) Height) + 1)
There is a (Self) Height plus 1 because for some reason, when you stretch the width, the height goes down so it compensates.




I didnโ€™t think of that honestly




I saw your yeti one and itโ€™s really cool!


That is a really good and pretty simple use case for the new blocks! I definitely see several use cases for this.


Great topic! For those who havenโ€™t already figured this out, this will be very useful! Keep it up! :+1:


Hey @MewtwoCreator, you can do this easier with sine, check!


Just a note:
Topic Tutorials belong in Open Source Code (like this topic)

Coding Schools, which have multiple tutorials, belong in Hopscotch Academy (unlike this topic)


It would make more sense as x130 instead of x200 because it ends up kinda stretched.


Yeah but you should always have the double amount of the size in the multiplier so it actually turns