I have created a Pygame Replit, and it functions perfectly when I run it. However, if anyone else attempts to run it, it doesn’t work. The game only works for people with a Replit account who have been invited to collaborate on the project. I think it’s a Replit problem rather than an issue with my code. Is there any way to resolve this? If this is a replit issue, does anyone know if they’re working on it? And if not, is there a better website I can use to host my pygame game?
Hi @NateDhaliwal, thank you for your help. I tried the forked version, but I’m still having the same issue. The program won’t work unless I’m logged in. It starts to run, but then it just stops. However, when I’m logged in, it works fine.
I’m not sure I understand your first question. Is “Secrets” a programming term? If so, I’m unfamiliar with it. To answer your second question, yes, the game runs from the main.py file.
Secrets are Replit’s environment variables.
Hmm… I guess you are not using it…
In this case, @ShaneAtReplit could you take a look at this? (Sorry to ping you)
You have a Hacker plan, which gives you quadruple the memory (RAM) of Free plan.
With only 0.5 GiB memory, it appears the repl runs out of memory when loading the Animations around line 736 before even starting the game loop.
So you’ll need to find a way to not have all the animations in memory at once.
Hey @NuclearPasta0 ! Thank you for the response. I just downgraded to the hacker plan 2 days ago. I had the pro plan up until two days ago and I was still having the same issues then. So are you saying even at the pro plan I didn’t have enough memory? Also I don’t understand how it would let me run the game if it’s a memory issue?(the game works 100% for me when logged in)
Basically what Nuclear is saying is that you have the Hacker plan so you had plenty of memory. But people running your game probably don’t have the Hacker plan, so they don’t have enough memory to run your game.
Are you sure this is the way it works? Would someone need to pay for a plan to run my game? For further context, I invited someone to collaborate on the project, and they could run the game without purchasing a plan
When you run a (non-website) Repl you don’t have edit permissions to from the cover page, Replit will automatically fork the Repl (this is known as a ghost fork). Person running your program owns that fork. When you own a Repl, obviously you need to have enough memory for it to run.
Thank you for all the help. If you know of any way to get around these issues please let me know! (I’ve tried to find better websites to host my game but haven’t had much luck.)