Penjee.com 's Blog

How to animate an image in Pygame

One of the thing you want to do often, when making a game, is animate an object. We are going to learn how to move a red square image across the pygame window. Here’s an animation of the finished product:   The full code is at the below. Download Source Code Scroll down for a … Continue reading How to animate an image in Pygame →

Pygame Add Image to Surface

So, you know how to make a simply pygame window, and now you want to do something a bit more interesting, aye? How do you  add an image to your pygame surface ? In this quick tutorial, we’ll show you exactly that. So that your finished product will look like is the following picture :     … Continue reading Pygame Add Image to Surface →

Super Simple Pygame Window

If you’ve already installed pygame, let’s create a super simple Pygame window, that, for now, does nothing! We explain the code in detail below. What you’ll see: Code [crayon-676783e99e672691464445/] This simply creates a window and that’s it. And otherwise just initialize pygame (line 3) , creates the simple window (line 8) and uses the classic pygame … Continue reading Super Simple Pygame Window →