====== Creating Basic Animation in Scratch ====== === Setting the Stage === First thing is we are going to set the stage backdrop from the standard and bland white to a nice image. Click on the Stage backdrop preview on the bottom right of the window to show the Backdrops tab. Within this tab, we want you to choose a new backdrop using the backdrop add button on the bottom right. {{ :digital_literacy:technology_resources:scratch:animation:choose-backdrop.gif?nolink |}} === Changing Costumes === Scratch the cat has 2 built-in costumes (Costume 1 and Costume 2) which you can see by clicking on the Scratch the cat sprite and then the //Costumes// tab. {{ :digital_literacy:technology_resources:scratch:animation:scatch-costumes-list.png?nolink |}} To change the costume of a sprite, we use the //Switch costume// to block from the //Looks// palette. {{ :digital_literacy:technology_resources:scratch:animation:switch-costume-to-block.png?nolink |}} For us to create an animation, we need to change between the costumes at a certain speed. Here we are going to switch between Costume 1 and Costume 2, adding a //Wait block// from the //Control// palette, and setting the wait time to half a second (0.5). {{ :digital_literacy:technology_resources:scratch:animation:animation-core.png?nolink |}} Now that we have the animation code done, we need to wrap it in a //Forever// block which can be found under the //Control// palette, this way it will repeat for the duration of our program. {{ :digital_literacy:technology_resources:scratch:animation:animation-forever.png?nolink |}} Finally we need to connect our code to an event. As we want this animation to begin as soon as the user presses the Green Flag, lets bring out the //When Green Flag Clicked// hat from the //Events// palette and connect our animation code underneath. {{ :digital_literacy:technology_resources:scratch:animation:animation-event.png?nolink |}} Our animation code is now done. We can test it out by pressing the Green Flag of our project! {{ :digital_literacy:technology_resources:scratch:animation:final-animation.gif?nolink |}} ~~NOTOC~~