Setting up the Ping Pong game elements

We have made the preparations, and now it's time to set up the Ping Pong game. The following graph shows how we place the game elements. The game element contains our playground and later the scoreboard. Inside the playground, we place two decorative elements, namely paddle hand, which acts as the handle of the soccer machine. Then, we have two paddle elements—one on the left and one on the right.

Setting up the Ping Pong game elements

Get HTML5 Game Development by Example : Beginner's Guide - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.