Live data from Hacker News

Show HN: Stop playing my matchstick puzzles, start building your own in seconds

mathstick.github.io

11–20 of 36 posts

Re: Show HN: Stop playing my matchstick puzzles, start building your own in seconds

#11
post #10

Would you be willing to add a manifest so this can be "installed" as an app on Android?

sure i'll consider converting it to PWA if people prefer playing the main game than creating and sharing puzzles with the Puzzle Maker.

Re: Show HN: Stop playing my matchstick puzzles, start building your own in seconds

#12
Highly recommend y'all try playing with the Puzzle Maker first! It’s a great way to get a feel for the shape of numbers and the different moves you can make.

I personally found this 'learn-by-doing' approach really helps me understand the patterns before I tackle the harder levels.

Re: Show HN: Stop playing my matchstick puzzles, start building your own in seconds

#13
post #10

Would you be willing to add a manifest so this can be "installed" as an app on Android?

sure i'll consider converting it to PWA if people prefer playing the main game than creating and sharing puzzles with the Puzzle Maker.

I think you can just pretend to be a PWA, no need for code changes.

You may need an unused service worker, or not, I don't remember.

This just means your site looks like an Android app (but still needs net, etc).

Re: Show HN: Stop playing my matchstick puzzles, start building your own in seconds

#14
post #13

Earlier quoted context omitted.

sure i'll consider converting it to PWA if people prefer playing the main game than creating and sharing puzzles with the Puzzle Maker.

I think you can just pretend to be a PWA, no need for code changes. You may need an unused service worker, or not, I don't remember. This just means your site looks like an Android app (but still needs net, etc).

Thanks, I used to do something like that when I made a tabletop like card maker using three.js + angular 8, but it has been a long time ago, I need to catch up with the details how to implement it with angular v21 since it is almost a completely new framework compared to the old versions

Re: Show HN: Stop playing my matchstick puzzles, start building your own in seconds

#17
post #2

Mathstick 2 is now ready! Same as my first version, you can earn sticks to unlock the next level and the challenges get harder as you progress. With the newly added Puzzled Maker, you can now create your own matchstick puzzles and generate a shareable link to stump your friends :) For example, check out this custom challenge I just created: https://mathstick.github.io/play?q=ktoylsjcnmylbetuinmylielj... Feel free to…

The answer to all of these should be moving a stick over the equality sign to change it to an inequality sign.

Re: Show HN: Stop playing my matchstick puzzles, start building your own in seconds

#18
post #2

Mathstick 2 is now ready! Same as my first version, you can earn sticks to unlock the next level and the challenges get harder as you progress. With the newly added Puzzled Maker, you can now create your own matchstick puzzles and generate a shareable link to stump your friends :) For example, check out this custom challenge I just created: https://mathstick.github.io/play?q=ktoylsjcnmylbetuinmylielj... Feel free to…

The answer to all of these should be moving a stick over the equality sign to change it to an inequality sign.

This is too tricky to be allowed. Let's play a fair game :D

Re: Show HN: Stop playing my matchstick puzzles, start building your own in seconds

#20

nice game! may i know what amount of js/css knowledge should i possess to be able to write sth like this? Eloquent JavaScript + any generic CSS book enough? thanks for making my evening.

thank you and glad you love it, those books are more than enough.

As for the css part, I would suggest you start by building the layout for the desktop first. Once the desktop version looks good, use media queries to adjust the design for mobile and tablet sizes.

As for js and html part, think in Components: Instead of one giant file, break your code into "modules" or "components". In my matchstick game, I built the "Puzzle Display" as a standalone component. This allowed me to reuse the exact same code for the main game, the puzzle creator, and the shareable play pages.

For specific effects or tricky logic, Google and LLMs (like ChatGPT) are great resources. Avoid "copy-pasting" code you don't understand. Always try to deconstruct how a solution works before adding it to your project. Use these tools as teachers, not just shortcuts.

Most importantly, enjoy what you are doing. Let me know if you need more info, I'm more than happy to help. Good luck to your coding journey.

Post reply on HN