In other languages

Help the wiki!

The Scratch Wiki is made by and for Scratchers. Do you want to contribute?

Learn more about joining as an editor!

See discussions in the Community Portal

Costume

A costume is one out of possibly many "frames" or alternate appearances of a sprite. Sprites can change their look to any of its costumes. They can be named, edited, created, and deleted, but every sprite must have at least one costume.

Contents

Backdrops

Main article: Backdrops

While sprites contain costumes, the Stage contains backdrops. They can be used in the same way, while mistaking a background block (only accessible from the Stage, but can be dragged into a sprite) for a costume block can cause a red border (a script error notice) to appear around the active script, and vice versa.

Creation

Taking a picture with a webcam.

There are four main ways of getting a costume or background for a sprite or stage.

  1. Drawing one yourself using the inbuilt Scratch Paint Editor, by clicking on the costume or background tab, and clicking the "paint" button
  2. Getting an image or multiple images that exist as files on the computer, either by clicking the "import" button under the costumes tab, or dragging in an image or images from an open folder. Dragging an animated .gif file from a folder into Scratch will split the gif into many costumes so the gif can be played using the Next costume block.
  3. Taking an image from a webcam, by clicking the "camera" button (added in 1.4)
  4. Right clicking on a sprite and selecting "grab screen region for new costume" which enables you to define an area of the Scratch client to become a new costume (this can't be done for the stage, as this will create a new sprite instead)

Deletion

Clicking the "X" button towards the lower right of each costume will delete it, provided that it isn't the only costume of the sprite.

Blocks

There are four blocks that relate to costumes, which are as follows:

The first three blocks can be located in the Looks block section, while the fourth can be found in the Sensing block area.

Uses

  • The first block is used for the sprite to transfer its look between any of its costumes. The drop-down box shows all of the sprite's costumes, with more than one page if the count exceeds 33.
  • The second block is mainly used in animation. A block that does the opposite has been suggested, but it can simply be done with the following code:
switch to costume ((costume #) - (1))
  • The third block contains the number of the current costume being used. It can be read through other blocks, and specific actions can be taken.
  • The fourth block contains two drop-down boxes. The first allows you to read a sprite's X Position, Y Position, direction, costume number, size, and volume; while it can also read the Stage's background number and volume.

This block can be read from the Stage and all sprites.

Example of the next costume/switch to costume()

  1. Scratch Cat.png
  2. Scratch Cat Costume 2.png

Costumes Tab

The costumes tab

To see the costumes of a sprite, click on the Costumes Tab. This will display a list of the costumes in the sprite, as well as open the paint editor.

See Also

  • This page was last modified on 11 February 2014, at 04:55.