Building a game of pong with sprites. #docs#lessons#pong
### ~avatar avatar
### @video td/videos/pong-0
Welcome! This tutorial will teach you how to build a simple pong game using sprites.
### ~
The game works as follow: the user moves a paddle on the left of the screen and a ball bounces on the other side. Let's start by creating the 2 sprites.
```
let paddle = game.createSprite(0, 2)
let ball = game.createSprite(4, 2)
```
Let's make the ball start with an angle.
```
ball.setDirection(-45)
```
The user will control the paddle by pressing ``A`` to go up and ``B`` to go down. Let's add ``on button pressed`` event handlers to do that.