Puzzle help

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
User avatar
xNick1
Party member
Posts: 265
Joined: Wed Jun 15, 2016 8:27 am
Location: Rome, Italy

Puzzle help

Post by xNick1 » Wed Jun 15, 2016 9:14 am

Hi guys!

This is my first post here.
Nice to meet you all!
I tried to make some stuff about a year ago but I didn't succeed.

I recently tried to follow some tutorials, and I've made a pong clone and a space invaders clone so far!

I'm now trying to make a puzzle.

If you recompose the entire image with the pieces put in random order by the game, you win.

Image

I'd like it to be kind of this puzzle, but with a picture.

I tried to write something, here's the link to the love file: https://www.sendspace.com/file/ivo3n4
I'm a little unsure about how to handle the pieces to move.
I generally have a character and I move it with the wasd keys, but with the puzzle I'd have to select a piece to move first!
What's the best way to handle that?

Any suggestions in general about how to make a puzzle?

Thank you for your patience :D

Edit: I'm sorry, I attached the file
Puzzle.love
(1.5 MiB) Downloaded 41 times
Last edited by xNick1 on Wed Jun 15, 2016 4:46 pm, edited 2 times in total.
Currently working on a lucid dreaming adventure called Aarstider: http://bit.ly/2mXmgPI

User avatar
pgimeno
Party member
Posts: 1990
Joined: Sun Oct 18, 2015 2:58 pm

Re: Puzzle help

Post by pgimeno » Wed Jun 15, 2016 3:21 pm

No need to select a piece to move first. There's always at most 4 possible moves. Think of it as moving the hole.

Edit: If you still prefer the player to select a piece, there's only at most 4 pieces that can be moved, and each of them can move in just one direction, so there's nothing else the player needs to do after selecting a piece. That can be done with a square moving around the puzzle. However I'm used to puzzles that require me to move the hole, or to move the piece, like this one: http://www.chiark.greenend.org.uk/~sgta ... fteen.html

Edit2: Please attach the .love file to the post next time. Having to solve a captcha to get the file is annoying.

User avatar
4aiman
Party member
Posts: 248
Joined: Sat Jan 16, 2016 10:30 am

Re: Puzzle help

Post by 4aiman » Thu Jun 16, 2016 6:50 pm

pgimeno wrote:Having to solve a captcha to get the file is annoying.
It's off-topic, but... what captcha? Didn't see anything that can't be ignored :)

User avatar
zorg
Party member
Posts: 2778
Joined: Thu Dec 13, 2012 2:55 pm
Location: Absurdistan, Hungary
Contact:

Re: Puzzle help

Post by zorg » Thu Jun 16, 2016 7:23 pm

4aiman wrote:
pgimeno wrote:Having to solve a captcha to get the file is annoying.
It's off-topic, but... what captcha? Didn't see anything that can't be ignored :)
Maybe it only gives you a captcha sometimes; It's still jumping through hoops with sendspace and other "shit tier" hosters; even mediafire is starting to get worse; mega's tolerable, but if the forums allow attachments, then one should do that istead, as how the op fixed it.
Me and my stuff :3True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.

User avatar
4aiman
Party member
Posts: 248
Joined: Sat Jan 16, 2016 10:30 am

Re: Puzzle help

Post by 4aiman » Thu Jun 16, 2016 8:40 pm

I agree, that attachments should be used for the purpose of adding a file.

But what I'm trying to say is "getting rid of anything irrelevant is not that difficult".
RequestPolicy+NoScript+RefControl and you'll be able to easily tell apart what you have to see and fill in and what is shown to you only to make you believe you need a *pro* account and doesn't really mean anything ;)

Here's how it looks like for me:
test.png
test.png (116.97 KiB) Viewed 1965 times
All I have to do is to click on the "Download" button and to save my file:
Снимок экрана_2016-06-16_23-33-19.png
Снимок экрана_2016-06-16_23-33-19.png (15.38 KiB) Viewed 1965 times
No captcha, no ads no irrelevant info. :awesome:

I'd say it's the responsibility of the one who downloads stuff to keep things he/she doesn't want to see away ;)

User avatar
zorg
Party member
Posts: 2778
Joined: Thu Dec 13, 2012 2:55 pm
Location: Absurdistan, Hungary
Contact:

Re: Puzzle help

Post by zorg » Thu Jun 16, 2016 8:47 pm

In a perfect world, there would be no need for these kinds of things, but alas.
(AdBlockPlus and uMatrix here)
Image
Me and my stuff :3True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.

User avatar
pgimeno
Party member
Posts: 1990
Joined: Sun Oct 18, 2015 2:58 pm

Re: Puzzle help

Post by pgimeno » Fri Jun 17, 2016 3:12 am

I'm a TOR user, and it's likely that some TOR exit node was used for multiple downloads, which were confused with bot activity because they were all done from the same IP, so I was asked to confirm I was not a bot.

Anyway, to the OP: do you have an idea now on how to move the pieces?

User avatar
xNick1
Party member
Posts: 265
Joined: Wed Jun 15, 2016 8:27 am
Location: Rome, Italy

Re: Puzzle help

Post by xNick1 » Sat Jun 18, 2016 9:55 am

Hey guys,
I made some progress.
Could you check it?

I'm not sure about how to move the pieces.
When I try to move the pieces, everything goes in a wrong direction xD

Thank you :D
Attachments
Puzzle.love
(1.5 MiB) Downloaded 42 times
Currently working on a lucid dreaming adventure called Aarstider: http://bit.ly/2mXmgPI

Xugro
Citizen
Posts: 63
Joined: Wed Sep 29, 2010 8:14 pm

Re: Puzzle help

Post by Xugro » Sat Jun 18, 2016 9:22 pm

You could take a look at my code. Just click on the piece you want to move. If you manage to get every piece into position it shows you the complete picture.

The idea is that you look at which piece a player clicks. If the empty space is next to it, then you switch the places of the clicked piece and the empty space.
Attachments
moving_puzzle.love
(97.26 KiB) Downloaded 40 times

User avatar
xNick1
Party member
Posts: 265
Joined: Wed Jun 15, 2016 8:27 am
Location: Rome, Italy

Re: Puzzle help

Post by xNick1 » Sun Jun 19, 2016 9:09 am

Xugro wrote:You could take a look at my code. Just click on the piece you want to move. If you manage to get every piece into position it shows you the complete picture.

The idea is that you look at which piece a player clicks. If the empty space is next to it, then you switch the places of the clicked piece and the empty space.
Thank you! =)
Currently working on a lucid dreaming adventure called Aarstider: http://bit.ly/2mXmgPI

Post Reply

Who is online

Users browsing this forum: No registered users and 8 guests