News for hackers. Stuff that matters.
Re:Show HN: I made a pretty relaxing puzzle game by mattw2121 on Wednesday November 23, 2022 @07:39AM (#33718438)
Thanks for creating and sharing. I really like it. I would like a Easy, Hard, and Insane mode with increasing # of tiles.
Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @04:02PM (#33724474)
That's a great idea! Will add to backlog.
Re:Show HN: I made a pretty relaxing puzzle game by bbx on Wednesday November 23, 2022 @07:35AM (#33718394)
I like the "Ideal number of clicks" criteria. Adds an additional challenge, and increases replayability.
Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @03:58PM (#33724441)
Thanks! That was some of the feedback from my friends when I initially sent it to them. They were like: "wow this is relaxing" but shortly after: "ok, how do we compete?" :D
Re:Show HN: I made a pretty relaxing puzzle game by bombcar on Wednesday November 23, 2022 @07:17AM (#33718237)
This is nice. I just liked clicking to see the cat.
Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @07:21AM (#33718275)
Thanks! Glad you liked it!
Re:Show HN: I made a pretty relaxing puzzle game by rwky on Wednesday November 23, 2022 @08:31AM (#33718866)
That is one chilled out cat
Re:Show HN: I made a pretty relaxing puzzle game by jamesbfb on Wednesday November 23, 2022 @07:38AM (#33718428)
That was…oddly satisfying. Really wish I could do another one!
Re:Show HN: I made a pretty relaxing puzzle game by mungoman2 on Wednesday November 23, 2022 @08:01AM (#33718632)
You can! "Play older games" at the bottom of the page.
Re:Show HN: I made a pretty relaxing puzzle game by HanClinto on Wednesday November 23, 2022 @08:39AM (#33718927)
Did you see the list at the bottom of the page? You can play all of the older puzzles!
Re:Show HN: I made a pretty relaxing puzzle game by tsm on Wednesday November 23, 2022 @07:26AM (#33718315)
Congratulations on the launch! It's a nice way to blow off some steam on a pomodoro break or while mulling over a bug
Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @07:28AM (#33718332)
Thanks! That's exactly how I use it too! Also goes well with a coffee break;)
Re:Show HN: I made a pretty relaxing puzzle game by badcppdev on Wednesday November 23, 2022 @07:37AM (#33718413)
Nice and relaxing but I want to do another one now.

You could do a hex tile version as well

Re:Show HN: I made a pretty relaxing puzzle game by bbx on Wednesday November 23, 2022 @07:38AM (#33718423)
There's a list of older games you can play at the bottom of the page.
Re:Show HN: I made a pretty relaxing puzzle game by badcppdev on Wednesday November 23, 2022 @09:03AM (#33719165)
Thanks. I couldn't see it because it disappears if you click on 'Play again' and reappears when the picture is solved
Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @04:04PM (#33724503)
Thanks for this feedback and that's now fixed - all older games and all played games have now the option to play older games at the bottom.
Re:Show HN: I made a pretty relaxing puzzle game by hnfong on Wednesday November 23, 2022 @07:28AM (#33718331)
Implement right click for the other direction?
Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @07:30AM (#33718348)
Nice suggestion! How should that behave on mobile? Any idea on how to best tackle it?
Re:Show HN: I made a pretty relaxing puzzle game by woogley on Wednesday November 23, 2022 @07:41AM (#33718452)
I think you should lean into this problem and just call the game "clockwise"

Consistent across platforms, consistent "ideal" count, clever-ish game name

Re:Show HN: I made a pretty relaxing puzzle game by dwringer on Wednesday November 23, 2022 @08:47AM (#33719006)
I would like to see either as you describe (which I think would be the most relaxing), or have the direction-changing buttons also count as a click each time they are pressed. I found it tempting to switch direction, turn a piece, then switch back, often using two clicks instead of the three it would take to turn it clockwise-only, but very inefficient since I switched back and forth many times. Making those count as clicks, though, does up the difficulty and would make hitting the target require you to use them only once, so perhaps removing them altogether is the solution.
Re:Show HN: I made a pretty relaxing puzzle game by sh1mmer on Wednesday November 23, 2022 @09:23AM (#33719433)
If you did it as clockwise by default instead of listing the ideal turn count you could list the minimum number of “counter” turns. Then have a button to do the next turn as a counter turn.
Re:Show HN: I made a pretty relaxing puzzle game by bbx on Wednesday November 23, 2022 @07:37AM (#33718415)
I would have suggested having 2 zones per tile: one to rotate left, one to rotate right. But the tap zone is quite small already, so it's prone to errors.

One slower but more UX-friendly option would be to allow long-press on a tile, it would zoom in, and you can pick left or right with each button.

Double tap is also an option but you need to remove the ability to select the content of the page.

Re:Show HN: I made a pretty relaxing puzzle game by didsomeonesay on Wednesday November 23, 2022 @07:38AM (#33718425)
Maybe you could try swipe left/right or rotating gestures that snap to 90 degree increments.

That is, rotating with one finger by holding and dragging either in circle or straight line.

Better not the two finger rotation known from map apps.

Re:Show HN: I made a pretty relaxing puzzle game by dncornholio on Wednesday November 23, 2022 @07:31AM (#33718358)
Double tap
Re:Show HN: I made a pretty relaxing puzzle game by zoidb on Wednesday November 23, 2022 @07:37AM (#33718419)
I think for mobile have two ideal click counts, one for a single direction and another with direction switches.
Re:Show HN: I made a pretty relaxing puzzle game by bambax on Wednesday November 23, 2022 @08:06AM (#33718669)
Or: pull down for rotate CCW, pull up for rotate CW. Just sum up event.movementY to calculate rotations.

Cons: A little slower than simply clicking, maybe, and makes it easier to overshoot. Need to count rotations instead of clicks.

Pros: Quite intuitive (that's how dials work in most DAWs for instance) and would work well on mobile, even if the tile size is small.

Re:Show HN: I made a pretty relaxing puzzle game by kiru_io on Wednesday November 23, 2022 @08:07AM (#33718678)
Not sure how easy it is to implement, but here is another idea: hold on the tile few seconds, then you have the choice to swipe left or right (has also some edge cases, when the elements are in the corner)
Re:Show HN: I made a pretty relaxing puzzle game by tcmb on Wednesday November 23, 2022 @08:12AM (#33718713)
Short tap for CW, hold for CCW
Re:Show HN: I made a pretty relaxing puzzle game by huhtenberg on Wednesday November 23, 2022 @09:39AM (#33719635)
Tap-and-hold a tile, move finger outside of it and then rotate by moving finger around tile's center (like using a handle that you just extended from the tile).
Re:Show HN: I made a pretty relaxing puzzle game by w-m on Wednesday November 23, 2022 @10:07AM (#33720032)
Click left half of square for ccw rotation, click right half of square for cw rotation.
Re:Show HN: I made a pretty relaxing puzzle game by dhc02 on Wednesday November 23, 2022 @11:51AM (#33721605)
Long press?
Re:Show HN: I made a pretty relaxing puzzle game by huhtenberg on Wednesday November 23, 2022 @09:36AM (#33719603)
It's not uncommon for right-clicks to be blocked at the browser level.

A better option would be Ctrl-left-click for the other direction.

Re:Show HN: I made a pretty relaxing puzzle game by RadiozRadioz on Wednesday November 23, 2022 @10:20AM (#33720240)
Who is blocking these? Paranoid corporates?
Re:Show HN: I made a pretty relaxing puzzle game by m4lvin on Wednesday November 23, 2022 @09:46AM (#33719734)
Or use scroll-up and scroll-down to rotate left/right?
Re:Show HN: I made a pretty relaxing puzzle game by l2silver on Wednesday November 23, 2022 @10:12AM (#33720115)
I might just get rid of rotate all together
Re:Show HN: I made a pretty relaxing puzzle game by vesinisa on Wednesday November 23, 2022 @09:47AM (#33719737)
Right click is often blocked, but Shift+Click is not.
Re:Show HN: I made a pretty relaxing puzzle game by sph on Wednesday November 23, 2022 @09:51AM (#33719801)
Blocked by whom?
Re:Show HN: I made a pretty relaxing puzzle game by abcd_f on Wednesday November 23, 2022 @01:00PM (#33722445)
By people who like browser's native context menus.
Re:Show HN: I made a pretty relaxing puzzle game by Someone on Wednesday November 23, 2022 @11:28AM (#33721240)
An alternative is to change the scoring system, and count consecutive clicks on the same tile as ‘one’

Alternatively, just count three consecutive clicks that are close in time as one.

Re:Show HN: I made a pretty relaxing puzzle game by thaumasiotes on Wednesday November 23, 2022 @07:29AM (#33718335)
To achieve the ideal click count you can switch the rotation direction at any time by clicking on [clockwise] or [counterclockwise]

This would be a lot less annoying, and involve fewer clicks, if you just had left click rotate one way and right click rotate the other way.

Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @07:34AM (#33718390)
Nice, looks like something that i really should look into. How about mobile?
Re:Show HN: I made a pretty relaxing puzzle game by badcppdev on Wednesday November 23, 2022 @07:36AM (#33718403)
Swipe sideways left or right to turn left or right
Re:Show HN: I made a pretty relaxing puzzle game by Gare on Wednesday November 23, 2022 @07:48AM (#33718517)
Maybe also "swipe up or down for a 180 turn"?
Re:Show HN: I made a pretty relaxing puzzle game by busymom0 on Wednesday November 23, 2022 @07:43AM (#33718464)
Long press can be right click!
Re:Show HN: I made a pretty relaxing puzzle game by thaumasiotes on Wednesday November 23, 2022 @12:10PM (#33721798)
I have a puzzles app on my phone[1] that does just what you describe. It's awful; I will always tap repeatedly instead of long-pressing. Long-pressing is a gigantic usability failure.

That app also implements the solution here, of having a toggle that swaps the effect of press and long-press. I use that... sometimes. Rarely. But more often than I attempt to long-press.

Cell phones have a bad UI paradigm and therefore using software on a cell phone is generally more painful and annoying than using software on a computer. But that's not a reason to force painful, annoying UI into the computer too.

[1] https://www.chiark.greenend.org.uk/~sgtatham/puzzles/ https://f-droid.org/en/packages/name.boyle.chris.sgtpuzzles/

Re:Show HN: I made a pretty relaxing puzzle game by amadeuspagel on Wednesday November 23, 2022 @07:45AM (#33718487)
Nice.

It looks like it's always the same picture? It would be nice if you could play this with a random picture.

Re:Show HN: I made a pretty relaxing puzzle game by justusthane on Wednesday November 23, 2022 @08:02AM (#33718638)
The picture changes every day (there’s a countdown timer until the next picture at the top after you finish), and you can play previous days if you scroll down.
Re:Show HN: I made a pretty relaxing puzzle game by boosteri on Wednesday November 23, 2022 @07:52AM (#33718562)
I only ever got 90° rotation. The page mentions it should be random .. am I just that lucky?

Enjoyed the game though, nice and simple. And no hug of death yet, well done!

Re:Show HN: I made a pretty relaxing puzzle game by mungoman2 on Wednesday November 23, 2022 @07:55AM (#33718590)
They mean on game start each tile has been rotated a random amount.
Re:Show HN: I made a pretty relaxing puzzle game by knicholes on Wednesday November 23, 2022 @07:54AM (#33718577)
That was surprisingly fun! Thank you.
Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @04:02PM (#33724479)
I'm glad you liked it!
Re:Show HN: I made a pretty relaxing puzzle game by Robin_Message on Wednesday November 23, 2022 @07:58AM (#33718612)
On a phone, I didn't like having to change rotation direction separately from rotating. And I don't always find rotation directions intuitive. So maybe a direct manipulation would be better?

Other than that, I enjoyed it.

Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @03:59PM (#33724448)
Thanks Robin! Yeah, it is not ideal game for phones, but I have few ideas in backlog on how to improve that.
Re:Show HN: I made a pretty relaxing puzzle game by rouxz on Wednesday November 23, 2022 @08:06AM (#33718675)
"Relaxing" and at the same time counting number of clicks right next to Ideal number of clicks doesn't work very well for me :(
Re:Show HN: I made a pretty relaxing puzzle game by JrProgrammer on Wednesday November 23, 2022 @08:28AM (#33718849)
I agree. I liked the idea but seeing an ideal number just puts pressure on something that shouldn't be.

Maybe create a casual/competitive toggle?

Anyways good job OP :)

Re:Show HN: I made a pretty relaxing puzzle game by indigodaddy on Wednesday November 23, 2022 @09:15AM (#33719342)
It could just reveal the # of click stats after completion
Re:Show HN: I made a pretty relaxing puzzle game by boringg on Wednesday November 23, 2022 @09:22AM (#33719430)
I'd agree get rid of any competitive features so that its relaxing but if you want to make it competitive toggle it on.
Re:Show HN: I made a pretty relaxing puzzle game by Markoff on Wednesday November 23, 2022 @09:45AM (#33719718)
Try Prune, the most relaxing game I played in years.

http://www.prunegame.com

And while you are at it follow it by watching Tales from the loop, most relaxing TV show I've seen in years.

Re:Show HN: I made a pretty relaxing puzzle game by TrueGeek on Friday December 02, 2022 @01:53PM (#33835016)
Thanks for recommending Tales From the Loop. What a beautiful show.
Re:Show HN: I made a pretty relaxing puzzle game by cheapliquor on Wednesday November 23, 2022 @10:02AM (#33719953)
Right - I only noticed the "ideal" number of clicks after I had finished the puzzle. That kinda diminished the "relaxing" aspect and made me want to go back and start speedrunning.

Otherwise, neat lil game. I got a nice picture of a kitty cat. :)

Re:Show HN: I made a pretty relaxing puzzle game by larsonnn on Wednesday November 23, 2022 @12:45PM (#33722262)
So you are the one which needed to go back.
Re:Show HN: I made a pretty relaxing puzzle game by blurrybird on Thursday November 24, 2022 @06:52AM (#33730281)
Agreed, I needed to de-stress so I clicked through.

When I finished the back of my neck tension that I didn’t realise I had disappeared.

Most stressful thing I’ve done all week. Got 33/33 though so that’s neat.

Re:Show HN: I made a pretty relaxing puzzle game by throwaway_75369 on Wednesday November 23, 2022 @08:14AM (#33718737)
This was nice - I woke up in the middle of the night with some anxiety and insomnia and this was just what I needed; a dark background theme would have helped with the bright rectangle in my hand :)
Re:Show HN: I made a pretty relaxing puzzle game by bmacho on Wednesday November 23, 2022 @08:29AM (#33718856)
Darkreader extension works on it.
Re:Show HN: I made a pretty relaxing puzzle game by s0teri0s on Wednesday November 23, 2022 @08:16AM (#33718756)
This is nice. If possible, I would change it so that a left rotation happened on a left click and a right rotation happened on a right click; make scoring optional if you want it to be more relaxing.
Re:Show HN: I made a pretty relaxing puzzle game by mfbx9da4 on Wednesday November 23, 2022 @08:20AM (#33718788)
Yeah I find it relaxing to fill out CAPTCHAs as well (not)
Re:Show HN: I made a pretty relaxing puzzle game by homero on Wednesday November 23, 2022 @08:22AM (#33718798)
Sometimes the preview sticks sometimes it doesn't. I wasted all my clicks on that lol
Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @05:32PM (#33725367)
Thanks for the bug report - that's fixed now to only allow it for 3 seconds.
Re:Show HN: I made a pretty relaxing puzzle game by s3p on Wednesday November 23, 2022 @08:28AM (#33718847)
Found this very relaxing, thanks OP :)
Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @04:03PM (#33724488)
I'm happy it worked for you!
Re:Show HN: I made a pretty relaxing puzzle game by drivers99 on Wednesday November 23, 2022 @08:36AM (#33718907)
Some of the squares are basically a solid color (not so much the cat picture but the previous ones I checked). I like to do jigsaw puzzles and one good thing about them is even in fairly solid color areas, you get a good confirmation by pieces fitting together well. Something to think about when selecting photos.
Re:Show HN: I made a pretty relaxing puzzle game by prismatix on Wednesday November 23, 2022 @11:23AM (#33721172)
Agreed. In Tabletop simulator Jigsaw Join the pieces fuse together when they're in the correct place. Maybe the white border could disappear between pieces in the correct place - although that might make it too easy if there's only one left.
Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @03:54PM (#33724393)
Yeah, apologies for that. There is no.4 that's extremely difficult, especially on phones with not such great colours and there's one more that has 2 tricky squares. I'm trying to pick pictures that do not have solid squares for future.
Re:Show HN: I made a pretty relaxing puzzle game by phtrivier on Wednesday November 23, 2022 @08:37AM (#33718911)
Great marketing move of using a cat.
Re:Show HN: I made a pretty relaxing puzzle game by dbojan on Wednesday November 23, 2022 @08:41AM (#33718949)
implement random pic loading from ... somewehere
Re:Show HN: I made a pretty relaxing puzzle game by dbojan on Wednesday November 23, 2022 @08:41AM (#33718953)
implement random picture loading from ... somewhere ? (with proper size)
Re:Show HN: I made a pretty relaxing puzzle game by halftheopposite on Wednesday November 23, 2022 @08:46AM (#33719001)
Really like the concept, and played it longer than I initially expected!

Shameless plug for a multiplayer puzzle game I created a year ago https://flipcards.online of which your game reminded me. Although mine has nothing relaxing as it favours competition. But rotating tiles of images is clearly checked.

Re:Show HN: I made a pretty relaxing puzzle game by adigau31 on Wednesday November 23, 2022 @08:54AM (#33719090)
I like that game! It's way less relaxing for sure lol Have you considered showing the progress of others in real-time to add some spice, go more into details?

I really like what Chris has done with Liveblocks.io on his multiplayer Wordle: https://github.com/CTNicholas/wordle-wars

Re:Show HN: I made a pretty relaxing puzzle game by halftheopposite on Wednesday November 23, 2022 @08:57AM (#33719119)
That's actually a great idea! Will work on it in the next fews days. Also planning on putting a quick tutorial to explain the concept. PS: Thanks for the link, looking at it right now.
Re:Show HN: I made a pretty relaxing puzzle game by zaphodias on Wednesday November 23, 2022 @09:05AM (#33719202)
I had a computer game similar to this one like 15 years ago!

I can't remember the name but I think it came as a CD with some encyclopedia for kids or something like this. You unlocked a memory of me solving the puzzle of a picture of a shark :D

Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @03:54PM (#33724399)
Hahaha, I love that I could bring this memory back!
Re:Show HN: I made a pretty relaxing puzzle game by somberi on Wednesday November 23, 2022 @09:07AM (#33719229)
I loved this game and thanks for making it. It had a prayer-beads quality to it, and extending that metaphor, may I suggest you remove stats, but keep counter clock moves, where the mind gets trapped, and moves on to the next block, thereby helping the user focus on the task at hand.
Re:Show HN: I made a pretty relaxing puzzle game by 6LLvveMx2koXfwn on Wednesday November 23, 2022 @09:12AM (#33719287)
I did it in 27 clicks, page says minimum is 29.
Re:Show HN: I made a pretty relaxing puzzle game by 6LLvveMx2koXfwn on Wednesday November 23, 2022 @10:02AM (#33719950)
er, no I didn't 29, missed one in the mountains to the right. Now confetti.
Re:Show HN: I made a pretty relaxing puzzle game by WesleyJohnson on Wednesday November 23, 2022 @02:30PM (#33723506)
Far right, row 2? That one got me as well.
Re:Show HN: I made a pretty relaxing puzzle game by nuclearnice1 on Wednesday November 23, 2022 @09:17AM (#33719369)
This is a nice game. What technology stack did you use to implement?
Re:Show HN: I made a pretty relaxing puzzle game by jmclnx on Wednesday November 23, 2022 @09:17AM (#33719374)
I think it is nice :) Thanks
Re:Show HN: I made a pretty relaxing puzzle game by boringg on Wednesday November 23, 2022 @09:23AM (#33719446)
I was surprised that I did find this relaxing - thanks OP. To other commenters point toggle on/off competitive features would be great otherwise it produces tiny amounts of competitive anxiety.
Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @04:03PM (#33724486)
Thanks! And this is idea is noted in backlog. Like opt out button from competition.
Re:Show HN: I made a pretty relaxing puzzle game by nemo44x on Wednesday November 23, 2022 @09:25AM (#33719461)
Excellent game, well done! Love that there’s a new image daily so I can choose to spend a small amount of time each day but I won’t get sucked into a non-stop treadmill.
Re:Show HN: I made a pretty relaxing puzzle game by ldoughty on Wednesday November 23, 2022 @09:28AM (#33719503)
I like it, but I will say I found 28 very frustrating... There's not enough detail in the picture to get the top row -- the entire row is basically 3 very similar colors, and there's no good hints... You basically have to determine the positioning by looking at the artifacting of the background.

The cat one was enjoyable though!

Re:Show HN: I made a pretty relaxing puzzle game by flapjaxy on Wednesday November 23, 2022 @09:29AM (#33719518)
Am I missing how you reshuffle to play another round?
Re:Show HN: I made a pretty relaxing puzzle game by tommica on Wednesday November 23, 2022 @09:37AM (#33719612)
Please add more images!
Re:Show HN: I made a pretty relaxing puzzle game by ranting-moth on Wednesday November 23, 2022 @09:39AM (#33719646)
Wow, this is nice. Love it!

Perhaps an option to hide the ideal clicks. If I was upset and using this to calm down (which I totally will!) it would just infuriate my messed up brain. But that's just me.

Well done!

Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @03:52PM (#33724380)
Thanks, would hiding the counter during the game and revealing the counter once finished work? Or you'd prefer to get rid of it completely?
Re:Show HN: I made a pretty relaxing puzzle game by ranting-moth on Wednesday November 23, 2022 @04:26PM (#33724756)
Personally if I've opted to hide it I wouldn't want to see it unless I've specifically asked for it.
Re:Show HN: I made a pretty relaxing puzzle game by lleb97a on Wednesday November 23, 2022 @09:43AM (#33719695)
Great job! I found it the right balance of relaxing and challenging.
Re:Show HN: I made a pretty relaxing puzzle game by vesinisa on Wednesday November 23, 2022 @09:46AM (#33719726)
It's nice but could you make it so that the rotation direction can additionally be toggled by holding down shift while clicking? I find it very irritating to always move the mouse to the bottom right corner to select the rotation direction - especially since "every click counts".

Other than that, I first thought that some of the tiles should start with correct orientation but soon realized that would make this puzzle just really easy, because our brains are just excellent at seeing the correct image from just a few correctly oriented tiles I think.

Re:Show HN: I made a pretty relaxing puzzle game by MikeTheGreat on Wednesday November 23, 2022 @11:43AM (#33721476)
Shift-click is a great idea.

I also like the idea of right-clicking to rotate the other way (so click always rotates one way, right-click the opposite)

I ignored the ideal clicks thing and really enjoyed slowly revealing today's picture of the lounging cat. Very relaxing indeed!

Re:Show HN: I made a pretty relaxing puzzle game by mistermegabyte on Wednesday November 23, 2022 @12:24PM (#33721991)
Awesome game. I agree that left click to rotate left and right click to rotate right would be so much more convenient.
Re:Show HN: I made a pretty relaxing puzzle game by Aardwolf on Wednesday November 23, 2022 @07:23PM (#33726311)
Shift click wouldn't work on mobile. Imho, just make 3 rotations in a row count as 1
Re:Show HN: I made a pretty relaxing puzzle game by dietketchup on Thursday November 24, 2022 @08:02AM (#33730834)
This would break the game. You can always guess for free.
Re:Show HN: I made a pretty relaxing puzzle game by Aardwolf on Thursday November 24, 2022 @02:02PM (#33735052)
Not really? It's not free, it costs 1 to do 3 or 1 rotation, and it costs 2 to do 2 rotations. There is still a challenge because it's still the combination of multiple tiles that makes the full image, you don't necessarily gain information from doing 1 vs 3 rotations if the neighboring pieces aren't already correct
Re:Show HN: I made a pretty relaxing puzzle game by geros on Thursday November 24, 2022 @06:07AM (#33729976)
Change cursor to match rotation icon.
Re:Show HN: I made a pretty relaxing puzzle game by the_cat_kittles on Wednesday November 23, 2022 @02:00PM (#33723203)
another option be to have clicking the left side of the tile turn it counter clockwise and right side clockwise
Re:Show HN: I made a pretty relaxing puzzle game by quickthrower2 on Sunday November 27, 2022 @12:59AM (#33760780)
Another option: clockwise only rotation. Then adjust the ideal number of clicks accordingly
Re:Show HN: I made a pretty relaxing puzzle game by searchableguy on Wednesday November 23, 2022 @09:51AM (#33719802)
Sorry OP but this triggers my captcha hell trauma on the internet using a VPN for privacy.
Re:Show HN: I made a pretty relaxing puzzle game by bambax on Wednesday November 23, 2022 @10:10AM (#33720082)
Solver in 0 clicks:

    [...document.querySelectorAll("#game > div > div")].forEach(e => e.style.transform="rotate(0deg)")
It doesn't win the game, but can at least save the "preview" clicks.
Re:Show HN: I made a pretty relaxing puzzle game by kidsil on Wednesday November 23, 2022 @10:25AM (#33720315)
Just wondering - why are you spreading the result to an array?

  document.querySelectorAll("#game > div > div").forEach(e => e.style.transform="rotate(0deg)")
Works too.
Re:Show HN: I made a pretty relaxing puzzle game by bambax on Wednesday November 23, 2022 @10:34AM (#33720443)
You're right!

(But since querySelectorAll returns a NodeList and not a regular array, some methods are unavailable, so I just have this habit of making it an array. But for iteration that's indeed not needed.)

Re:Show HN: I made a pretty relaxing puzzle game by bambax on Wednesday November 23, 2022 @11:04AM (#33720917)
Actual solver that does win the game:

    document.querySelectorAll("#game > div > div").forEach(e => {
        const rotation = e.style.transform.match(/(\d+)/)[0];
        const clicks = 4-(rotation/90)%4;
        [...Array(clicks)].forEach(i=>e.click());
    });
It could be optimized to change the rotation direction depending on whether the current rotation is smaller or larger than 180deg, but that's not really necessary since running the script only counts as one click, and generates negative "overspin" numbers ;-)
Re:Show HN: I made a pretty relaxing puzzle game by prox on Wednesday November 23, 2022 @01:09PM (#33722540)
What does […Array mean in this context? Does it create an array?
Re:Show HN: I made a pretty relaxing puzzle game by bambax on Wednesday November 23, 2022 @01:28PM (#33722798)
Yes it creates an array of length 'clicks'; so for example [...Array(2)] creates the array [undefined, undefined]. It's just a way to do a loop without writing a for loop and use forEach instead.
Re:Show HN: I made a pretty relaxing puzzle game by monkpit on Wednesday November 23, 2022 @01:30PM (#33722838)
Probably a shortcut for Array(n).fill()
Re:Show HN: I made a pretty relaxing puzzle game by manbash on Wednesday November 23, 2022 @02:30PM (#33723516)
The "..." is called a spread operator in javascript.

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...

(In python there is the "*" operator which should be equivalent: [1, 2, *arr].

Array(clicks) instantiate an array of length 'clicks', with its elements undefined.

Then "[...Array(clicks)]" takes the above array instance and spreads it as content in another array.

Seems redundant and they could've just used Array(clicks).

Re:Show HN: I made a pretty relaxing puzzle game by tuukkah on Wednesday November 23, 2022 @03:26PM (#33724090)
> Array(clicks) instantiate an array of length 'clicks', with its elements undefined.

Not undefined elements but no elements, or "empty" elements.

> they could've just used Array(clicks).

No, because the following forEach call does nothing for such an array. You need to fill the array first with Array(clicks).fill() or shorter, [...Array(clicks)]

Re:Show HN: I made a pretty relaxing puzzle game by tuukkah on Wednesday November 23, 2022 @03:02PM (#33723835)
... is the spread syntax, which is a neat way to use the entries of an existing array or object in an argument list or within an array or object literal.

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...

Array(length) creates an array that has a length but no elements (or weird, "empty" elements). The square brackets create a new array [...Array(length)] which will have undefined elements instead, as trying to access an "empty" element returns undefined.

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guid...

Re:Show HN: I made a pretty relaxing puzzle game by prox on Wednesday November 23, 2022 @05:36PM (#33725408)
That is neat! Thanks!
Re:Show HN: I made a pretty relaxing puzzle game by mahathu on Wednesday November 23, 2022 @07:39PM (#33726445)
Instead of the array spread syntax, why not:

    for(let i=0; i<clicks; i++){ e.click() };
Re:Show HN: I made a pretty relaxing puzzle game by bambax on Wednesday November 23, 2022 @07:51PM (#33726537)
Sure, it's the same. For some reason I don't like the 'for' syntax much, or having curly brackets on the same line. But to each their own.
Re:Show HN: I made a pretty relaxing puzzle game by eutectic on Wednesday November 23, 2022 @12:17PM (#33721883)
An actual solver in Python:

    import numpy as np
    from mip import Model, xsum, minimize, BINARY

    def solve(tiles):
        rotations = [[[] for _ in row] for row in tiles]
        rot_vars = [[[] for _ in row] for row in tiles]
        model = Model("rotaboxes")
        for i, row in enumerate(tiles):
            for j, tile in enumerate(row):
                for _ in range(3):
                    tile = tile.transpose((1, 0, 2))[::-1]
                    rotations[i][j].append(tile)
                    rot_vars[i][j].append(model.add_var(var_type=BINARY))
                model += (xsum(rot_vars[i][j]) == 1)
        costs = []
        for i, row in enumerate(tiles):
            for j, tile in enumerate(row):
                for (di, dj) in [(0, 1), (1, 0)]:
                    if (i + di >= len(tiles)) or (j + dj >= len(tiles[0])):
                        continue
                    for r0, t0 in enumerate(rotations[i][j]):
                        for r1, t1 in enumerate(rotations[i + di][j + dj]):
                            if di:
                                a, b = t0[-1], t1[0]
                            else:
                                a, b = t0[:,-1], t1[:,0]
                            n = np.square(a - b).mean()
                            d = np.square(a[1:] - a[:1]).mean() + np.square(b[1:] - b[:1]).mean()
                            e = 2. * n / (d + 0.01)
                            v = model.add_var(var_type=BINARY)
                            model += (v >= rot_vars[i][j][r0] + rot_vars[i + di][j + dj][r1] - 1)
                            costs.append(e * v)
        model.objective = minimize(xsum(costs))
        model.optimize()
        for row in rot_vars:
            for r in row:
                print([v.x for v in r])
        solution = [[[r for v, r in zip(vs, rs) if v.x >= 0.99][0] for vs, rs in zip(row0, row1)] for row0, row1 in zip(rot_vars, rotations)]
        return solution
Re:Show HN: I made a pretty relaxing puzzle game by ComodoHacker on Wednesday November 23, 2022 @12:49PM (#33722303)
Now you should count keystrokes for your type of solution.
Re:Show HN: I made a pretty relaxing puzzle game by miiiiiike on Wednesday November 23, 2022 @10:17AM (#33720196)
cute.
Re:Show HN: I made a pretty relaxing puzzle game by uptownfunk on Wednesday November 23, 2022 @10:21AM (#33720246)
Wow, really nice, relaxing. Don’t bloat it, sometimes simple and sweet is a winner. Mobile app version would be helpful.
Re:Show HN: I made a pretty relaxing puzzle game by kriro on Wednesday November 23, 2022 @10:22AM (#33720267)
Nicely done. Really enjoyed it.

Would be interesting if you combined it with DALLE-2. Either with a prompt at the top that generates the picture on the fly or just by curating some DALLE-2 pictures and using them for the puzzles (and maybe the prompt to generate it could be revealed as a reward).

Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @03:55PM (#33724402)
That's actually a really cool idea.
Re:Show HN: I made a pretty relaxing puzzle game by xivzgrev on Wednesday November 23, 2022 @10:28AM (#33720349)
Agree on removing ideal click count.

Some pictures were hard to distinguish they still needed to be turned (like 95% mountain and a sliver of something else).

I’d consider making the background already in place - i find rotating the cat the most enjoyable. Lining up a cloud or shoreline starts to feel tedious to me.

Re:Show HN: I made a pretty relaxing puzzle game by Sujeto on Wednesday November 23, 2022 @10:28AM (#33720358)
Nice!
Re:Show HN: I made a pretty relaxing puzzle game by gmiller123456 on Wednesday November 23, 2022 @10:30AM (#33720396)
It could probably benefit from an indicator that there's still work to be done. I thought I was done, but noticed a comment from someone else that they got confetti.
Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @03:57PM (#33724432)
Yeah, that's actually a great idea. Do you have any idea on how the indicator could look like? Something like counter how many tiles are still not in position?

Tiles still in wrong position ............ 24?

Re:Show HN: I made a pretty relaxing puzzle game by gmiller123456 on Wednesday November 23, 2022 @04:20PM (#33724685)
I was thinking something like that, "x tiles to go". Or a "Check" button that tells you how many are left, but it still automatically shows the confetti when you're done.
Re:Show HN: I made a pretty relaxing puzzle game by radres on Wednesday November 23, 2022 @10:37AM (#33720487)
I like the ideal number of clicks. But somewhat agree on sky etc. should come in order.
Re:Show HN: I made a pretty relaxing puzzle game by blinding-streak on Wednesday November 23, 2022 @10:39AM (#33720515)
This is great! Shared with my family. Thanks for making it.
Re:Show HN: I made a pretty relaxing puzzle game by bobo_legos on Wednesday November 23, 2022 @11:10AM (#33720990)
So I use Imagus in Firefox. When playing older games hovering over some of the tiles ends up loading the full image. Doesn't do it on today's cat image.

Otherwise fun little game.

Re:Show HN: I made a pretty relaxing puzzle game by kelnos on Thursday November 24, 2022 @12:45AM (#33728128)
Ran into this too and was really bummed to ruin the surprise!
Re:Show HN: I made a pretty relaxing puzzle game by xwdv on Wednesday November 23, 2022 @12:37PM (#33722161)
How about if instead of a photo it would be an interesting video?
Re:Show HN: I made a pretty relaxing puzzle game by larsonnn on Wednesday November 23, 2022 @12:44PM (#33722251)
It’s nice. But I would love it more without competitive features. Maybe you can choos if you want the relax or competitive mode.
Re:Show HN: I made a pretty relaxing puzzle game by yonrg on Wednesday November 23, 2022 @12:58PM (#33722422)
Absolutely, this was relaxing and fun

23 Nov 22 31/29 clicks rotabox.es/29

Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @04:04PM (#33724515)
Thank you!
Re:Show HN: I made a pretty relaxing puzzle game by nickstinemates on Wednesday November 23, 2022 @01:14PM (#33722626)
Cool project, I had fun. Could be like Wordle but more interesting.
Re:Show HN: I made a pretty relaxing puzzle game by CobrastanJorji on Wednesday November 23, 2022 @01:34PM (#33722893)
I like how well this specific picture works for this puzzle. The coastline lines up perfectly with a square border. The cat's face is sideways. The two steps are the same color, so the rotation could be in one of two possible positions. It makes it just tricky enough to make the right answer not immediately obvious, but it's not so hard that there's any chance for being frustrated. Plus, it's a kitty.
Re:Show HN: I made a pretty relaxing puzzle game by spikenilan on Wednesday November 23, 2022 @02:27PM (#33723469)
Very cool. I made something kinda similar a while back but never got around to publishing it. I think mine is overly complicated and I never got around to writing a tutorial but you can check it out here:

blurdle.cc

Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Wednesday November 23, 2022 @03:56PM (#33724414)
The link doesn't work :(
Re:Show HN: I made a pretty relaxing puzzle game by sbf501 on Wednesday November 23, 2022 @03:05PM (#33723865)
No. I do NOT want to "Stop Confetti" thank you very much.
Re:Show HN: I made a pretty relaxing puzzle game by johndhi on Wednesday November 23, 2022 @04:13PM (#33724607)
Bravo
Re:Show HN: I made a pretty relaxing puzzle game by iandanforth on Wednesday November 23, 2022 @04:16PM (#33724640)
Perfect on first try. I will now never play again to maintain my overspin rating of 0.
Re:Show HN: I made a pretty relaxing puzzle game by NotMyBestWork on Wednesday November 23, 2022 @04:58PM (#33725047)
I really enjoyed this, it was indeed relaxing. Do you grab any statistics on how well people do? I was hugely over, but only because a few of the 'difficult' squares were wrong.
Re:Show HN: I made a pretty relaxing puzzle game by Blammar on Wednesday November 23, 2022 @05:14PM (#33725206)
Am I missing something? I completed a picture with two rotations left, and nothing happened. I was optimal in the number of rotations (always 1 or 2 rotations.) I checked I was right by clicking the eye. The cute cat just sits there...
Re:Show HN: I made a pretty relaxing puzzle game by jbmny on Wednesday November 23, 2022 @05:38PM (#33725422)
"Tiles left to rotate" tells you how many still need to be rotated to solve the puzzle. Sounds like you're still two away from the goal. Some of the differences in this picture between right/wrong are very subtle.
Re:Show HN: I made a pretty relaxing puzzle game by hkon on Wednesday November 23, 2022 @05:35PM (#33725395)
Very nice, can you make it so that another puzzle shows up after 10 seconds after completing one?
Re:Show HN: I made a pretty relaxing puzzle game by permo-w on Wednesday November 23, 2022 @05:39PM (#33725432)
it's really nice. one suggestion I would have would be to make the gap between the squares variable. it would be easier if it was thinner or not there
Re:Show HN: I made a pretty relaxing puzzle game by permo-w on Wednesday November 23, 2022 @07:38PM (#33726435)
presumably you could hook this up to stable diffusion and have infinite levels
Re:Show HN: I made a pretty relaxing puzzle game by mpetrovich on Wednesday November 23, 2022 @08:14PM (#33726713)
Really fun! This inspired me to create my own version of the sliding-tile puzzle game that I used to play as a kid: https://tileslide.com/
Re:Show HN: I made a pretty relaxing puzzle game by CmdrKrool on Wednesday November 23, 2022 @08:24PM (#33726779)
Never assume the orientation of a cat :P
Re:Show HN: I made a pretty relaxing puzzle game by qroolen on Wednesday November 23, 2022 @08:28PM (#33726821)
really interesting the effect on short-term memory when you click to reveal the completed image (principally when you have a good chunk set already)! i loved it

also, as everyone probably, right-click to rotate counterclockwise came intuitively real quick in thoughts...

Re:Show HN: I made a pretty relaxing puzzle game by arrty88 on Wednesday November 23, 2022 @08:51PM (#33727010)
24 Nov 22 57/33 clicks rotabox.es/30
Re:Show HN: I made a pretty relaxing puzzle game by pengaru on Thursday November 24, 2022 @12:10AM (#33727986)
The amount of bikeshedding over obvious rotation modifiers on display in this thread is asinine.
Re:Show HN: I made a pretty relaxing puzzle game by jefozabuss on Thursday November 24, 2022 @02:56AM (#33728808)
Epilepsy warning: if you finish it you might have a page refresh bug where it constantly keeps refreshing (with flashing content) the page - for me it was solved by clearing localStorage (or just close the page I guess), I think this bug needs to be fixed ASAP.
Re:Show HN: I made a pretty relaxing puzzle game by ranguna on Thursday November 24, 2022 @03:23AM (#33728943)
That didn't happen for me, either it was fixed in 20 mins or I don't know.
Re:Show HN: I made a pretty relaxing puzzle game by amarant on Thursday November 24, 2022 @03:37AM (#33729013)
Happened to me, chrome on Android. Likely there is some precondition required to trigger the bug other than winning the game, since it doesn't seem to happen to everyone
Re:Show HN: I made a pretty relaxing puzzle game by boudra on Thursday November 24, 2022 @03:32AM (#33728992)
Same here, on Firefox.
Re:Show HN: I made a pretty relaxing puzzle game by trizoza on Thursday November 24, 2022 @03:51AM (#33729084)
Apologies for that. It was a bug I introduced that happens only in different timezones. Should be fixed now.
Re:Show HN: I made a pretty relaxing puzzle game by CleanCoder on Thursday November 24, 2022 @12:59PM (#33734285)
Can you elaborate on what you mean by "happens only in different timezones?" It sounds like an interesting bug to identify.
Re:Show HN: I made a pretty relaxing puzzle game by bratak on Thursday November 24, 2022 @02:34PM (#33735343)
Awesome, thanks for that §8-)
Re:Show HN: I made a pretty relaxing puzzle game by ashishb4u on Saturday November 26, 2022 @01:59AM (#33750581)
Love the concept, well done.

I was slightly annoyed at the dog puzzle, while i tried to rotate the boxes which contained just grass and a lot of bokeh. I guess picking the right pictures is really important.