In this add-on, you’ll program an “obstacle” that slowly grows using the “change size” block. To start, click on the “obstacle” sprite.
From looks, drag out a “change size by” block.
Click this block a few times to make the obstacle sprite larger.
Use a “forever” block to make the obstacle keep growing.
Test your code by clicking the block stack. That obstacle is really big! To keep it from growing too large for your project, add a “set size to” block at the beginning of this block stack. That way, the obstacle will start at its original size each time the stack is run. Click the stack to test. The obstacle grows way too fast. The player will never make it past that.
Change the value in the “change size” block to something smaller, like 1.
That’s slower, but it’s still too fast. Try changing the value to something smaller, like 0.3.
That’s it! That's a much better speed. Add a “when flag clicked” block to the top of the block stack to make your obstacle grow when the game begins.
Now it’s your turn!
Make the obstacle grow and shrink using “change size by,” “set size to,” “when flag clicked,” and “forever” blocks.