Sprites

Vocabulary:

Property: Attributes that describe an object's characteristics

Sprite: A graphic character on the screen with properties that describe its location, movement, and various character attributes.

New Code

Today we are going to create Sprites. They will need to be drawn using code. Sprites can have many properties and as you get familiar with them, you can start to create dynamic and existing-looking sprites. Pay attention to this lesson, it's very important. Once you get the hang of creating a sprite and drawing the sprite, here is a video on how to animate your sprite. This will help you manage your animations.

When uploading your own images, searching for clip art is a good idea because they normally don't have a background. having no background is helpful so you don't have a block picture of a kite. Make sure when you use the set animation block, that the name is the name of the sprite. That way, the var kite = createSprite will match your code defining the appearance of the sprite.

When you set the scale of the sprite because it's too large or too small, you will use the sprite.scale block. Make sure you label the name of the sprite that is having its size changed before the sprite is drawn.

At the end, you will need to create your own scene with a sprite and text. Here is a sample.