Home

Awesome

15 Puzzle

Implementation of the classic 15 Puzzle game for Neovim.

📺 Showcase

https://github.com/NStefan002/15puzzle.nvim/assets/100767853/d613555a-b603-490f-b24a-cb8ef89246a3

🖼️ Gallery

<details> <summary> Preview themes </summary>

15P_theme1

15P_theme2

15P_theme3

15P_theme4

15P_theme5

</details>

🗞️ News

📋 Installation

lazy:

{
    "NStefan002/15puzzle.nvim",
    cmd = "Play15puzzle",
    config = true,
}

packer:

use({
    "NStefan002/15puzzle.nvim",
    config = function()
        require("15puzzle").setup()
    end,
})

rocks.nvim

:Rocks install 15puzzle.nvim

❓ How to Play

  1. :Play15puzzle
  2. Use the h, j, k, l to slide the squares in the desired direction.
  3. Place each square in its correct place.
  4. Try to solve the puzzle in the fewest moves and as fast as possible.

🎮 Controls

NOTE:

<details> <summary>You can change the default mappings and some additional settings.</summary>
require("15puzzle").setup({
    keys = {
        up = "k",
        down = "j",
        left = "h",
        right = "l",
        new_game = "n",
        confirm = "<CR>",
        cancel = "<Esc>",
        next_theme = "<c-l>",
        prev_theme = "<c-h>",
        solve = "s",
    },
    -- additional settings

    solver_time_limit = 7000,
})
</details>