This week, the class and the TA will work through this assignment as a group to allow everyone to ask questions and get introduced to the Scratch programming environment.
There will be a lab attendance grade assigned for this assignment. Note that there is a separate line item in the syllabus for lab attendance. This attendance is the second of those three lab attendance grades. In order to receive full credit for the lab attendance, you need to attend at least one lab session during the weeks of October 11th or October 25th.
For this or future labs, you can always (and probably will need to) refer to the getting started guide.
Click the Scratch program to open it on your computer.
Click on the sprite on the lower right pane to select it. Right click and select delete to remove it from the stage.
Click on the Stage in the same lower right panel you just deleted the sprite from. In the center pane, you will now see a tab named "Backgrounds". Click on it and select to edit the current background (white when you start up). In the dialog that pops up, select "Import" and select a picture for your background from any of the available images in the folders.
From the "New Sprite" selection buttons, click on the one that is for "Choose new sprite from a file". You can figure out which button this is by hovering over it with your mouse and waiting for the "tip" to appear. Select a sprite from any of the available sprite images that you like.
Make sure that your sprite is selected in the lower right hand box and that the "Scripts" tab is selected in the center panel. Click on "motion" on the left upper panel, and drag the "move 10 steps" block into the center panel. Click on the move block in the center panel (once) to see the sprite move. Click on the "10" and change it to a larger number (30, 40, 50, etc.) by typing the number in and hitting "Enter". Now click on the move block again, and you will notice the sprite move a greater distance.
Drag the move block back to the left to remove it from your script. Or, right-click on the block and select "delete".
Put the block "turn 15 degrees" into the script panel and click on it to see what happens. Change the value of the turn so that it is more noticeable to you.
Click on the word "control" on the upper left pane. Select the "when green flag clicked" block and drag it into the script panel. Connect it to your "turn degrees" block. Now, if you click on the green flag above the sprite on the stage, the sprite will turn. Add a "move 10 steps" block before the turn. Change the value of the steps if you'd like and now watch the sprite move and turn every time the green flag is clicked.
Click on "motion" again to get the movement blocks. Choose "if on edge, bounce" and place it in your script before the move block. Click the green flag to see if your sprite bounces when it reaches an edge. If it isn't getting near an edge, use the mouse to move your sprite (click and drag) to and edge and then click the green flag. Lastly, add a "forever" block around your code for this sprite. This block is in the "control" set of blocks. Now, when you click the green flag, your sprite will move and turn and bounce off the edges until you stop the program.
Select another sprite to add to your stage. Click the green flag. Notice that your first sprite still does what you programmed it to do, but the second sprite doesn't do anything. Each sprite is programmed independently. You can remove you second sprite from the stage by deleting it.
If your name or nickname, has 5 or fewer letters, create a sprite for each letter of your name. If you have more than 5 letters in your name or nickname, use your initials or some other set of letters. You need to have at least three and don't want many more than 5. Note that there is a file folder for letters when you create a sprite.
Make each letter sprite perform a different action forever when the green flag is clicked upon. Try out your program many times to make sure it does what you want at this point.
**** Extra credit - make it so that each letter returns to its proper "position" every time the green flag is clicked, so that every time the program is started, the letters all start out looking correctly positioned and rotated correctly.
You will need to remove much of the program from your original sprite to do this. This sprite should now start almost off the edge of the stage. You can move the sprite with the mouse to find out where these coordinates are. When the green flag is pressed, the sprite should come up to the letters (explore the blocks "glide" or "go to" for more interesting effects) and say "Hi! My name is XXXX". Pick a name for your Sprite to fill in the XXXX's. Remember that speaking is under the "Looks" set of blocks. Each of the letters should respond with "I am the letter ?" (fill in the ? appropriately). You will need to work out the timing of the speech and waits to make this work appropriately. Remember that the "wait" block is under the "Control" set of blocks.
Your non-letter sprite should perform an action when clicked upon with the mouse. The action is up to you, but it must use one or more of the following blocks from the "Looks" set.
After a few seconds, the graphic should return to normal.
When you have finished your Lab 4 assignment, select to save it by selecting "Save As" from the File menu. Save the project as YourNameLab4 where you put your name in for "YourName" in the filename. Submit it to the digital drop box in UBLearns. In the digital dropbox, you can submit multiple times. We will only grade the last submission you make, so make sure that the last submission is the one you want graded.
NOTE: The assignment is not technically due until Sunday, November 28th at 11:55pm. However, you are welcome and encouraged to submit the assignment early. NO late assignments will be graded.
Go to http://www.scratch.mit.edu and download it to your own computer.
There are at least three letter sprites on the screen. The letters can appear after the green flag is clicked, or are there when the program is loaded. (2 pts each - 6 points total)
Letter 1 performs and action in a forever block that is different from Letter 2 & Letter 3 (7 points)
Letter 2 performs and action in a forever block that is different from Letter 1 & Letter 3 (7 points)
Letter 3 performs and action in a forever block that is different from Letter 1 & Letter 2 (7 points)
When the flag is clicked:
Sprite 1 (non-letter sprite) performs an action when clicked upon with the mouse (10 points). This action is one of the following:
Sprite 1 returns to normal after a few seconds of showing the effect. (10 points)
Extra credit (15 points): When the green flag is clicked, the letters return to their original positions. That is, if they were rotating or moving when the program is running and then the program is stopped, clicking the green flag again will cause them to go back to their original positions and orientations.