pinwheel
block so that you can use it to draw a variety of shapes.Recall how you first generalized your original pinwheel script: you added an input variable called branches that controlled the turning angle of the sprite. By adding more input variables, you can generalize other aspects of your program...
move
block inside your pinwheel
block as shown below.pinwheel
block, then click the "+" sign at the end to add an input label (choose "Title text"). Type backup:
as shown below, and click "OK".pinwheel
code, and press "OK" or "Apply."pinwheel
block behaves like the changes in your experimentation above.pinwheel
script so that it will accept a positive value (between 0 and 100) for backup.
A great way to avoid having bugs in your program in the first place is to keep your code organized by deleting any unused blocks to avoid clutter. Here are examples of messy code and neatly organized code with comments. If you came back to your project after a few days, which code do you think would be easier to debug?
You can use the clean up option by right-clicking in the Scripts area to organize and arrange your blocks vertically. You can remove a block or script either by dragging it out of the scripting area and back to the palettes on the left or by choosing "delete" option from the drop-down menu as shown below. Note that this is different from the "delete block definition" option which will permanently delete a custom block and all its instances from your entire project.
move
block.pinwheel
program...wait
blocks inside the pinwheel
script so you don't have to wait so long between trials.pinwheel
that make the result look like a circle.(Save your project first; you'll need the pinwheel
block you already have later.)
It doesn't have to look exactly like the photo. But each arm of a pinwheel is essentially two triangles. You may find the block helpful.