Skip to main content

All Questions

Tagged with
2 votes
2 answers
133 views

"Element Fusion" game where 2048 meets Chemistry

I've developed "Element Fusion," a PyGame-based game inspired by 2048 but using chemical elements. I'm seeking feedback on: Gameplay mechanics Code structure and efficiency PyGame ...
Amirhossein Rezaei's user avatar
12 votes
2 answers
1k views

Space shooter game using pygame

I have made a space shooter game in pygame with over 800 lines of code (including blank lines). The aim of the game is to kill all of the ships in the game. You start with a small spaceship and one ...
coder's user avatar
  • 121
6 votes
1 answer
146 views

Code for a basic dodging game in Python

Can someone review the code for this dodging game I made a while back? I want to see if there are any improvements or optimizations I can make as I am more or less a Python beginner. ...
Baba20's user avatar
  • 97
0 votes
0 answers
53 views

Snake game player movement pygame

I've begun my journey with game development a little while ago, thought recreating snake would be cool, except I plan on adding other cool mechanics and stuff to it later. The player controller script ...
Trevn Jones's user avatar
4 votes
1 answer
354 views

2D Minecraft - infinite chunk system

I am making a 2d minecraft clone for a hobby. Here is my code: 2D_MC.py: ...
coder's user avatar
  • 179
2 votes
1 answer
99 views

Game of life(random generation, pygame)

I recently created game about life in python. First version of code was console, but recently I rewrote this game in pygame. I decied upgrade game and was added age of cells. But now I can see that my ...
Максим's user avatar
2 votes
1 answer
61 views

Conversion of ZX81 BASIC Game to Pygame

I got the idea for this code from an article on converting ZX81 BASIC to Pygame. Although some code was provided in the article, I implemented this myself. I'm pretty dubious about the approach of ...
Robin Andrews's user avatar
2 votes
1 answer
186 views

Go chess (weiqi) in Python using Pygame

Preface This question is a re-implementation of my other question here. The Game Go or weiqi is an amazingly simple yet complex board game. This game is typically played on a 19x19 grid, and pieces ...
cold10's user avatar
  • 469
3 votes
1 answer
156 views

Asteroid-avoidance arcade game in pygame

Out of boredom one day I decided to make a game in pygame. I think it turned out fine, but am absolutely sure that it can be improved. How so? ...
CodeWizard777's user avatar
1 vote
1 answer
44 views

When I try to re set up my code after failing in the game I cant get it to run the function without its own file being undefined [closed]

I know my code is ugly and unreadable. I originally had the game working without class functions but when I had to implement class function it all went downhill. TennisMaster.py ...
RobbieAwesome's user avatar
4 votes
1 answer
205 views

class that handles the rpg game map

I created a class to handle maps in my RPG game, before it became a class this was a collection of functions I created, but I thought it could be used as a class. although this code is working but i ...
syafiqfadillah's user avatar
4 votes
2 answers
289 views

Revised Top-Down Dungeon RPG

Introduction: So far, the game works well, and my only major concerns, are a bullet system (including a function where you click the mouse to shoot the bullets), and a collision system between the ...
Zelda's user avatar
  • 123
5 votes
2 answers
145 views

Language skill tester using Pygame

I made this little game that tests our language skills. It uses one external module, pinyin, which can be installed via the command prompt command ...
Chocolate's user avatar
  • 948
1 vote
0 answers
183 views

A little board game framework with MCTS AI

There are two main classes: Game and MCTSPlayer. The first one is just an abstract class with a couple of methods and some hints ...
Rennorb's user avatar
  • 121
5 votes
1 answer
242 views

A Python snake game (using Pygame)

So this is a fun little project I am working on. This is my current progress with the game: ...
Sriv's user avatar
  • 2,750
2 votes
0 answers
1k views

Python code for UNO Game

It's my first time here, so please accept my apologies in advance if something is wrong with my approach to asking. I've been learning Python for a couple of months and I decided to have a go at a ...
Fernando Manzanares Preciado's user avatar
3 votes
1 answer
112 views

An emotion recognition test I designed using Pygame

for my dissertation (in psychology) I created an emotion recognition test that displays an image of a face displaying a certain emotion for a set time, then allows participants to press a button ...
Theamazingone1's user avatar
5 votes
2 answers
427 views

Pygame Minesweeper Clone

I'm still a relative beginner to coding and I would like some feedback on my Minesweeper clone written in Python using Pygame for the graphics. I'm wondering if it would be beneficial to use classes ...
hmukhe's user avatar
  • 53
7 votes
2 answers
3k views

Simple PyGame Connect 4

I've made a simple connect 4 game using PyGame. I'm new to python and haven't completely perfected this. I know it's inefficient but I can't tell exactly HOW to fix it? Could someone help me out? ...
Moleman's user avatar
  • 71
2 votes
1 answer
1k views

2048 game in Python 3

I wrote this 2048 game using Python 3 and pygame a few weeks ago. Since I'm getting into CS this summer, I would like to get some review on how I can improve my code in generel. Any tips and ...
Oliver Bak's user avatar
1 vote
0 answers
4k views

Card Game using pygame module

I implemented a card game using pygame, the game is a game of war and using png files that I made in Microsoft paint. I tried to keep the object classes as separated from the pygame module as possible....
CE3601's user avatar
  • 139
1 vote
1 answer
545 views

Implementation of the Snake game in Pygame, with GUI

I wrote a simple Snake game in Pygame, with GUI. It`s my first Pygame game and one of my first projects in Python. My goal with this implementation is to make it bug-free with fluid UI and as fast/...
voaneves's user avatar
4 votes
1 answer
816 views

Movement function for a Sokoban game using Python [closed]

I've been working on the functions that handle when a player's sprite interacts with either a wall (0) or say the crate to push (£) I'm just wondering how this looks and if there alternative methods, ...
James D's user avatar
  • 41
5 votes
0 answers
1k views

Game involving catching falling items

This is my first game. Everything in the game was created by me during this week - from assets, music and, of course, code. As I am new to Python I have wondered if the design template for this game ...
tvaz's user avatar
  • 59
4 votes
1 answer
667 views

Mars Lander pygame

Here is my code about our final project in uni called 'Mars Lander'. The thing is that my code seems to be all over the place (more specifically in the 'main' function at the end of the code...) ...
Close Enough's user avatar
14 votes
2 answers
442 views

Counting people inside the house game

This program animates people going inside and outside of a house, the user has to keep a running sum in their head and must give the answer at the end. The speed of people, the number of maximum ...
Caridorc's user avatar
  • 27.5k
2 votes
1 answer
232 views

2D Basic 'evade the enemy' type game

I'm trying to learn how to become a good programmer. I think this means making my code more readable for others. I would really appreciate any feedback whatsoever. I'm not quite sure what specifically ...
Nathan's user avatar
  • 410
1 vote
1 answer
101 views

A small to medium sized pygame game

Github Link To Code Pastebin Link I am well aware of how terrible the SettingsMenu class is, it's still a work in progress and is the way it is so it can actually work. Can't paste it directly in ...
Ari Madian's user avatar
4 votes
1 answer
865 views

Creates a maze from file and enable user to go trough it with graphic display

I'm following the learnpythonthehardway.org book for learning Python. I recently made a one week projet and as I'm fairly new to coding program with POO and multiple files, I'd like to have someone ...
Onimanta's user avatar
4 votes
1 answer
1k views

Pong in Python and Pygame

I'm new to programming. This is my first project where I tried to use object-oriented programming. I'm looking for all kinds of comments. ...
magdalena_b's user avatar
12 votes
2 answers
347 views

Using the mouse to avoid asteroids and black holes

I have finished my first project for Python. I would be very grateful if you could check it and give me some feedback. Just simple game with possibility of replay. There are probably lots of mistakes ...
Maciejjy's user avatar
  • 123
4 votes
1 answer
11k views

Memory game using Python and PyGame

I am a beginner in Python and PyGame and wrote a memory game. I think there are lot of things I could have done better. I am looking for some advice on how I can improve the design and refactoring of ...
Boopesh's user avatar
  • 91
14 votes
1 answer
11k views

Space Shooter made using Pygame

This is my first game made using Pygame of about 550 lines of code. Advice and suggestions are more than welcome. ...
Tasdik Rahman's user avatar
9 votes
1 answer
2k views

Pygame version of my 3D Tic Tac Toe/Connect 4

I posted a question a while back asking for some feedback on the code of a game I made (it was limited to typing the input and drawing the output in ASCII). Now I've got it linked up with pygamef. ...
Peter's user avatar
  • 1,125
11 votes
3 answers
1k views

Bunny and Badgers: A tower defense game

I made a tower-defense game in Python with Pygame called "Bunny and Badgers". You're a bunny and must kill the badgers before they come into the castles. You can use W, A, S, D and the arrow ...
wb9688's user avatar
  • 251
7 votes
1 answer
3k views

Builder - A 2D Minecraft clone

I was poking around on my Raspberry Pi that I hadn't turned on or used in a while, and I stumbled upon this Python script that I wrote ~1.5 years ago, and I was intrigued. Essentially, it's a 2D ...
Ethan Bierlein's user avatar
6 votes
1 answer
135 views

Input processing/state machine function

I'm making a Mario clone in pygame and I have just wrote a function proccesses inputs and acts as a state machine for Mario. Everything is working just as I want it, but I was wondering if you can ...
Robbie's user avatar
  • 253
7 votes
1 answer
441 views

Game loop decorator for Pygame

I've built a simple decorator that wraps a function in a general Pygame game loop. It also allows for the programmer to set the tick rate. ...
Ethan Bierlein's user avatar
12 votes
1 answer
3k views

Pong game in Pygame

This is my first time trying OOP and I definitely made many stylistic mistakes. Please tell me how I should improve. Controls: w and s for player 1 ↑ and ↓ for player 2 The player with higher score ...
kittah's user avatar
  • 121
7 votes
1 answer
17k views

Snake game made in Python

I made a snake game with /some/ code from thenewboston's tutorials when I had just started Python. I think it wasn't a good idea to start game development right away since I didn't even know if what I ...
Vicente Bermúdez's user avatar
9 votes
1 answer
443 views

Block_breaker clone in pygame with simple edge detection

I tried to make this clone of brick_breaker on my own in one day. The source code and assets . However I have some concerns about the code so far: It uses simple edge detection code (as if ball goes ...
piyush_dev's user avatar
8 votes
1 answer
2k views

Tetris clone written in Python/Pygame

Tetromino class: ...
A_User's user avatar
  • 231
4 votes
3 answers
2k views

SimCity clone with PyGame

I am doing my best to keep this code clean and fast, but as I add more to the game, it seems to get harder to maintain a frame-rate higher than 200! I believe that the culprit is a somewhat large <...
Sam Tubb's user avatar
  • 539
11 votes
2 answers
601 views

SimCity clone performance

I am working on a SimCity clone, and I am noticing a drop in frame rate as I add more objects to my map, now this is expected, but, when I fill the whole screen, the game maintains about 300 FPS. ...
Sam Tubb's user avatar
  • 539
4 votes
1 answer
10k views

Basic Pong game in Pygame

I have just wrote this Pong game in Pygame: ...
LazySloth13's user avatar
  • 1,301
9 votes
1 answer
4k views

Pong with Pygame

Just looking for some pointers on how I could improve the code. This is my first game ever and python is my first language so it's bit messy but I'll be happy to explain stuff if needed. I'm kinda ...
bzrr's user avatar
  • 209
13 votes
1 answer
6k views

Self-playing Tetris game

I have an extremely simple self-playing Tetris game which I coded up and I am looking to see how it could be improved. It would also be a learning curve for me to see how those much better than I am ...
cobie's user avatar
  • 447
3 votes
2 answers
270 views

A game called "Twerk"

This my first Python program and game. Can you please point how I can improve and what code should be changed? ...
ErHunt's user avatar
  • 33