Relative Content

Tag Archive for pythonpygamepygbag

Unable to write to text file in python/pygame program compiled with pygbag

I have a python/pygame program that reads data from a settings file at the start of the program and writes out (changed) settings at the end of the program. This settings file is in the same (app.folder) directory as the main.py program. Everything works fine when running the program in a Python environment but when I compile it using Pygbag the file is read quite happily but I cannot write back to it at the end of the program.

Weird error with using pygbag to export pygame game to web

Recently I have been working on a game and I am using pygbag to convert it to HTML so that it can be played on a web browser. When I build the python files and run them, the game works as expected. However, when I used the pygbag command inside the command line, and then went to localhost:8000 (the development port in which the game would be temporarily posted), the audio worked, but I encountered a black screen. I went to localhost:8000#debug, which would show me what error was occuring, and it gave this error: https://imgur.com/a/y1sH9h0

Pygbag Page Unresponsive

I built a Connect 4 game with Pygame and am trying to get it to run in a browser using pygbag, but I keep getting a page unresponsive error. When I try to run it in a browser there is a start button, and when I click that I get to see the connect 4 board, but then I get the page unresponsive error. Let me know if you know what could be causing this error. Here is my code for the main game loop: