Inspiration
I've always loved collaborative games. I remember playing Minecraft with my cousin building all sorts of cool things in creative mode, and wanted to bring that same energy to Reddit. That's why I built The Daily Machine so strangers all over the world could experience the same joy I felt as a kid and come up with the most creative solutions possible to get a marble into a goal.
What it does
This is a game for Reddit where the whole subreddit builds one Rube Goldberg machine together. Each player gets to place one part per day. The parts provided are a ramp, a wall, a trampoline, a conveyer, and a fan. At midnight UTC the machine runs once and posts the results as a comment. When the marble finally reaches the goal, the level is solved and a new board starts.
How we built it
This was built solo in 8 days using the official Devvit Web Phaser template, Phaser on the client, Hono on the server, Redis for state, and TypeScript. All the art and sound are generated in code. I used Claude Code throughout development and reviewed everything it wrote, with regression tests for any bug that came back twice.
Challenges we ran into
The physics engine implemented for the game would give different results on different devices since different browsers round the math slightly differently, and physics can turn these slight rounding changes into a completely different run. To fix this I made it where the official run gets simulated once on the server and stored, and everyone else just sees the recording of the official run.
Another terrible bug I faced was buttons only registered clicks in one specific spot. The actual cause was every button's tap zone was shifted up and to the left of the button you could see by half the buttons size. I only found this out after building a overlay to show the clickable areas of the button.
Lastly I cut out half of the game's features midway through since I wanted to focus on polishing the 5 parts first and it would make debugging 2 times quicker since there are less parts in the game.
Accomplishments that we're proud of
I'm proud of multi user collaboration in the game, this was the first time I built a multiplayer game so the learning experience was really fun and valuable. I'm also proud of the automatic scheduler I built which sends out messages for which person's part killed the run, and which person's part moved the marble the farthest.
What we learned
I learnt a lot about git and making sure to commit my code frequently, I didn't commit for days and lost a week's worth of work after a bug happened while having no way to revert back to the original version. I also learnt a lot about debugging because even though I used an AI to help with development, it still made mistakes throughout the project so I had to come up with ways to debug invisible issues like clicks not registering, physics working differently, etc.
What's next for The Daily Machine
I plan to add more features like maybe inverted gravity blocks, portals, and also obstacles like kill blocks which spawn in random locations so the users have to think creatively of how to get the marble around these obstacles.
Built With
- claude
- devvit
- hono
- matter.js
- node.js
- phaser.js
- redis
- typescript
- vite
- web-audio
Log in or sign up for Devpost to join the conversation.