Pygame is daunting to look at understand initially. Especially to those uninitiated to programming or just initiated to block based languages like Scratch. As a part of my work for a summer camp at Curiositygym, Mumbai, I dived into it and here is my walkthrough for all levels from super easy to hard. Game We shall… Continue reading Pygame Tutorial, learn a lot and have loads of fun!
You can see the pink walls here? They are actually multiple smaller rectangles drawn close together. How do we decide what is the pattern for the walls for adding multiple levels in the game?
Now for some music! Feel it! No pictures here and in the free version no pictures allowed.
How do you store scores of the game for deciding who is the winner post all the levels have been won against many players? You can use text files to store the scores on the hard disk.
After all the cannons have disappeared, need to display a game over screen. How do we switch to a different screen when the game is over? Very simple! We draw a black/pink screen and draw text on it?
Since in Part 14, the rectangles around the circle sprites drawn was too big and the collision happened even though the rockets is far away and did not work, we shall change the circle sprites to football image or change the circle sprite to a normal circle object.
This is the next challenge, we shall use these cannons as something the rockets cannot collide against. We already had a moving rocket turning 90 degrees on mouse clicks in Part 12, now we shall build on it and create cannons (circles).