Is there always a single possible solution ? (I did a bunch of small ones and always found a solution pretty quickly)
Show HN: Pipes puzzle (a.k.a. Net) on a hexagonal grid
11–20 of 164 posts
Re: Show HN: Pipes puzzle (a.k.a. Net) on a hexagonal grid
#12My first, a 5x5, in 3:08 It was fun, but on the edge of annoying, which seems appropriate.
Re: Show HN: Pipes puzzle (a.k.a. Net) on a hexagonal grid
#13(really fun game btw, I will have to return to this later. I'm looking forward to sharing this with my 8 year old who's fascinated with logic puzzles.)
Re: Show HN: Pipes puzzle (a.k.a. Net) on a hexagonal grid
#14Re: Show HN: Pipes puzzle (a.k.a. Net) on a hexagonal grid
#15Captivating! So, while generating the puzzle, you are essentially creating a random Spanning Tree for the given nodes (hexagon) arrangement? Then you randomize each pipe piece's direction within a hexagon? What algorithm are you using for it Spanning Tree? I have been working on Maze Generation[0] and found randomized Prim's, Kruskal's to be useful for Spanning Tree creation but the good old Depth First Search increa…
The generator basically does the same but every tile starts out with a full set of possible orientations - every rotation of every tile shape (there are 62 I think). I remove some orientations due to border conditions, then pick a random possible orientation for some tile and so on till the board is filled. There usually is some backtracking involved.
This isn't terribly efficient and can get stuck for quite long when generating large puzzles. I actually want to look into adapting maze generation algorithms for creating these puzzles, so thanks for the link, I'll check it out.
Re: Show HN: Pipes puzzle (a.k.a. Net) on a hexagonal grid
#16What are the green/red lines that appear when you click the junction between two hexes? (really fun game btw, I will have to return to this later. I'm looking forward to sharing this with my 8 year old who's fascinated with logic puzzles.)
Re: Show HN: Pipes puzzle (a.k.a. Net) on a hexagonal grid
#17Wow! What fun. You have to make this a phone/tablet app...
Glad you liked it! I actually play it often on my phone, it's workable when zoomed in. An app would be nicer surely but I don't know how to build those =).
Re: Show HN: Pipes puzzle (a.k.a. Net) on a hexagonal grid
#18Is there always a single possible solution ? (I did a bunch of small ones and always found a solution pretty quickly)
Re: Show HN: Pipes puzzle (a.k.a. Net) on a hexagonal grid
#19I first played the version of this with squares on a Palm Pilot and that was a long time ago. I was even looking for that version for my iPhone the other day but was drowning in other random games (and little network tools) until I gave up.
It shouldn’t take much effort to turn it into a PWA, so then people can use it just like an app. I already saved it to my Home Screen and would certainly play this as a daily puzzle, just like Wordle. Keep up the great work.
Re: Show HN: Pipes puzzle (a.k.a. Net) on a hexagonal grid
#20Captivating! So, while generating the puzzle, you are essentially creating a random Spanning Tree for the given nodes (hexagon) arrangement? Then you randomize each pipe piece's direction within a hexagon? What algorithm are you using for it Spanning Tree? I have been working on Maze Generation[0] and found randomized Prim's, Kruskal's to be useful for Spanning Tree creation but the good old Depth First Search increa…
Well the way I wrote my pipes solver was to keep a set of possible orientations of every tile and gradually remove impossible options by using border conditions and some heuristics like avoiding islands and loops. And when this doesn't turn up any new info I resort to depth-first search. The generator basically does the same but every tile starts out with a full set of possible orientations - every rotation of every…