Game
Development
By: Mr Farhan
What are frames?
Frames make up an animation. Here is a walk animation:
- This walk is made of 8 pictures. Each picture is called a frame. Press Next to look at them →
- Frame 0. We start counting at 0, not 1!
- Frame 1 is almost the same picture, but the legs have moved a tiny bit.
- Frame 2: a tiny bit more…
- Frame 3: …and more. It carries on like this up to frame 7.
- Now show the frames one after another, slowly…
- …and faster. Your eyes join the pictures together. That is an animation! 🎬
Objects
Everything you put in a game is an object. Here are three kinds:
Sprites
The things that move and act, like the player and the enemy.
🖼️
Background image
The picture behind everything else.
🗺️
Layout
The stage that holds all your objects.
Sprite
Sprite
Background image
Layout
Properties
Every object in a game has properties.
Properties
Size
Color
- Here are some examples of properties. Press Next to change them one at a time →
- Height is how tall the object is. Make it bigger and the sprite stretches upwards.
- Width is how wide it is. Now it looks squashed!
- Size is the width and the height together. This is exactly twice as big as we started.
- Color tints the whole object. White means "no tint".
- Angle spins the object. It is measured in degrees, and a full turn is 360.
- Your turn! Drag the sliders and pick a colour to see what each property does 🎚️
Event
An event is something that happens. In a game, event means the same thing.
Whena key is pressed
▶Domove the character
Whenyou hit an enemy
▶Dominus one life
Whensomething happens…
▶Do…do something!
Game over!
Hold A or D on the keyboard to play
- This game has no events yet. Hold D… nothing happens!
- Our first event. Now hold D or A and the character moves!
- A second event. Walk into the enemy… ouch! Every hit takes away a life.
- Every event looks like this: when something happens, do something.