Sliding puzzle minigame

Game_2024-05-08_19-57-42.png


Synopsis
This plugin adds a tile sliding puzzle that you can use as a minigame in your game. Just give it an image, specify a grid size, and boom - instant minigame!

Features
  • You only need to use one image per puzzle - it will automatically be sliced into however many pieces are needed.
  • There are 3 different control schemes to choose from, plus mouse support.
  • You can optionally display a timer or a move counter (or both) - their results will be saved to variables of your choice when the player finishes (or gives up on) a puzzle, allowing you to assign rewards based on performance as you see fit.
  • Everything is customisable - size of the puzzle window, colour of the grid lines, scene background, text on the exit confirmation window, sounds - you name it.
  • All plugin parameters can also be changed with a plugin command during the game - so you can have different coloured grid lines for different puzzles, only show the timer on special challenges, and so on.
Terms
This plugin is available under the MIT Licence. You're free to use it in any games, commercial or not, or use the code in your own plugins. Credit is appreciated, but not required.
This is very cool! I have actually been thinking about this type of puzzle and how I would do it. I guarantee the way I would Event it would be much more difficult and inefficient than having a plugin.

I remember these games as a kid with little handheld puzzles. And they always frustrated me. It always seemed like I just kept moving things until the puzzle was finally done. Even if the moves didn't make any sense to me.

I am definitely going to try this and I think it is awesome that you can make plugins for stuff like this. I hope I will eventually get there as well, rather than Eventing everything.
I have actually been thinking about this type of puzzle and how I would do it.
There is actually a tutorial on doing this kind of puzzle with eventing that you might find interesting 🙂
great plugin thanks! I'm so bad at doing these type of puzzles lol.
oh, i thought this was the FF1 15 slide puzzle game
oh, i thought this was the FF1 15 slide puzzle game
Well, if you make an image with just numbers on it you could definitely make that 😉
great plugin, thanks a lot.
I have a question, once the game starts, the background will be darker and blur, how could I keep the background transparent in order to show the image below.
great plugin, thanks a lot.
I have a question, once the game starts, the background will be darker and blur, how could I keep the background transparent in order to show the image below.
That's not currently possible here unfortunately.

I'm currently away, and will be for a while, but an ability to use a custom background for the entire screen is a planned feature for all my minigame plugins.
Anyone else get a memory leak from this plugin? Adds to memory every time I move a tile and it never clears from RAM.
Anyone else get a memory leak from this plugin? Adds to memory every time I move a tile and it never clears from RAM.
Thanks for the report! I think I've found the problem - does this fix it for you?
Thanks for the report! I think I've found the problem - does this fix it for you?
Testing it now and I'll come back and let you know!

Nope, doesn't seem to have fixed it. I'm watching my RAM usage in the Task Manager and after I've made like 4 or 5 moves in the puzzle it starts to add about 0.1 RAM usage every subsequent time I move a tile. If I exit the puzzle, it doesn't clear the RAM. I've tried disabling and preloader plugins I'm using and it doesn't make a difference. I've also tried not using sound effects and it doesn't make a difference. I'm using a 3x3 puzzle on a 540x540px image.

I'll come back and edit this post if I find anything else that may be helpful.

EDIT 5/4/25
I think it was SRD Preloader and Game Upgrade being dumb...Seems to function normally now and I'm not using the edit provided by the quoted reply.
Does it work on MZ?
Hello. Do you know why it might not work in the browser version? It seems perfectly fine in PC client, but when imported and played via browser, it gets stuck on the "now loading" when trying to launch the puzzle.
Does it work on MZ?
I tried using FOSSIL to get this plugin to work on MZ, but it didn't work. We're waiting for either a port or an alternative.
I tried using FOSSIL to get this plugin to work on MZ, but it didn't work. We're waiting for either a port or an alternative.
UPDATE: The plugin can work on MZ, but there are issues with the puzzle image not displaying (the window is literally transparent), even though the event works very well.

I'm using a 540x540 puzzle image, 3x3 type, and the game screen is 1920x1080. I tried using the SRD tool to change the event window, and it helped, but I don't know if there's a way to use it without using a third-party plugin.
Version 1.1 is now available

Minor features
:
- You can now set a background for the entire scene

Bugfixes:
- Tiles are now rendered using Pixi Sprites instead of repeated block transfers. This should be more performant in general, but also work better in browsers.



While I don't have MZ to test it, there is a chance that this way of rendering tiles might actually work there too. I recommend giving it a try @aksnsjja2102.

@ElvenNeko - I don't know if you still need this, but this version might help you. At least it does work perfectly fine in a browser in an empty project.
Thanks, this is something I had been planning to use for my game for some time

Original thread: https://forums.rpgmakerweb.com/threads/sliding-puzzle-minigame.168482/