
Mine3D: A Web 3D Minesweeper Game - nkjoep
http://egraether.com/mine3d/
======
msimpson
I would love this even more if a lined or dotted grid remained in the dead
space to differentiate the area of each clue.

In fact, a highlight of the 27 cells within the area of a clue on hover would
be great as well.

Otherwise, fantastic work.

GitHub Issues
([https://github.com/egraether/mine3D/issues](https://github.com/egraether/mine3D/issues))

Feature Requests
([https://mine3d.uservoice.com/forums/136434-general](https://mine3d.uservoice.com/forums/136434-general))

~~~
kakarot
Thanks for sharing the links to his github, that's very thoughtful.

Now I feel selfish for having the same thoughts as you about the grid and just
quitting the game instead of telling OP.

------
ronilan
Shameless plug time!

Someone says "minesweeper", I post my implementation. It's an established
ritual.

Here go:
[http://www.ronilan.com/bugsweeper/](http://www.ronilan.com/bugsweeper/)

Few notes:

1\. This is dated January 2014. It is a job interview homework.

2\. The HN community has detected a bug and indicated that it should be fixed.
That was done March 2017.

3\. There are currently no known bugs.

4\. The goal of the game is to find the unknowns.

5\. No puns intended.

6\. Code:
[http://www.ronilan.com/bugsweeper/js/bugsweeper.js](http://www.ronilan.com/bugsweeper/js/bugsweeper.js)

~~~
blueblimp
The best minesweeper implementation is Simon Tatham's, because it guarantees a
board that can be solved without guessing.

[http://www.chiark.greenend.org.uk/~sgtatham/puzzles/js/mines...](http://www.chiark.greenend.org.uk/~sgtatham/puzzles/js/mines.html)

That guarantee allows for playing with high mine counts, which would
ordinarily be impossible way too often. The high mine count boards sometimes
contain interesting deductions.

~~~
niuzeta
How does he guarentee it?

~~~
tim_hutton
The source code (mines.c) is here:

[https://git.tartarus.org/?p=simon/puzzles.git;a=blob;f=mines...](https://git.tartarus.org/?p=simon/puzzles.git;a=blob;f=mines.c;h=da4428c7eb400620cf3ea114e598935b4a82d4ab;hb=HEAD)

There is code for solving a grid using deductions in this section:

[https://git.tartarus.org/?p=simon/puzzles.git;a=blob;f=mines...](https://git.tartarus.org/?p=simon/puzzles.git;a=blob;f=mines.c;h=da4428c7eb400620cf3ea114e598935b4a82d4ab;hb=HEAD#l278)

And below that is the code that generates grids and checks that they are
solvable without taking risks.

A similar approach is used to analyse the difficulty of Sudoku games here:

[http://hodoku.sourceforge.net/en/index.php](http://hodoku.sourceforge.net/en/index.php)

with different names for the different types of deduction.

~~~
niuzeta
Thank you so much! This helps so much.

------
superfx
This is awesome! I was a pretty serious (classic) minesweeper player and was
even ranked pretty highly internationally. Curious: did other people have
their intuition translate "incorrectly" at first? I kept on blowing up cells
because I hadn't yet fully internalized the changes that occur in 3D (I know
the rules are the same, but the "pattern recognition rules" are not quite the
same.) It was really interesting having to step back and rework out the
implications of things in 3D. In some vague sense I feel like this is a bit
like how some mathematical theorems hold in certain number of dimensions but
not others (e.g. random walks). Cool game!

~~~
3131s
I consider myself like an advanced-intermediate player, though my clicking
dexterity is not what it once was. Care to share some of your record times? :)

~~~
superfx
It's been a while, but I think my best time on expert was 63s.

------
stared
For interesting variants of minesweeper, I like one one the hyperbolic plane
("minefield", one zones in HyperRogue:
[http://www.roguetemple.com/z/hyper/gallery.php](http://www.roguetemple.com/z/hyper/gallery.php)).

------
sprokolopolis
This is a cool concept. The one problem that I had, is that it is difficult to
tell which cubes the numbers are paired with. I think that it would be more
intuitive if the numbers were printed/etched into each face of the cubes (like
dice, but with normal numbers).

------
kyberias
Unplayable without the standard left+right-button combination:

[http://www.minesweeper.info/archive/MinesweeperStrategy/mine...](http://www.minesweeper.info/archive/MinesweeperStrategy/mine_general.html)

~~~
PhasmaFelis
The ability to mark cubes as "maybe mines" (I think double-right-click in the
original) would also be excellent.

------
kshitij_libra
Haha Awesome!

Reminds me of a 3D 2048 game I made some years back.

[https://kshitij-banerjee.github.io/Cubiks-2048/](https://kshitij-
banerjee.github.io/Cubiks-2048/)

Check the dismember view I provided (space bar). That open up the cube to give
a better spatial understanding of the board.

That is the problem with 3D games, I realized. Trying to visualize is a pain
to most people and deviates them from the game. This was my attempt at solving
that.

I think in your case, hovering over a cell and highlighting its adjacent
numbers might help create better visual understanding of the state.

~~~
logicallee
>Trying to visualize is a pain to most people and deviates them from the game.

But it's a built-in skill of everyone over the age of a few months old!

Isn't the real problem the inability of 3D interfaces to, ahem, interface,
with an innate skill 100% of sighted users have? In other words I think the
interfaces are wrong, not the users.

~~~
swsieber
I don't think that's the problem. I think the problem is that "3D" versions
have us effectively trying to manipulate the internal 3D state of a box -
that's something we're terrible at - we usually interact with 3D objects in a
sparse state.

~~~
logicallee
>we usually interact with 3D objects in a sparse state.

I don't know that I can agree with this. There's nothing hard about spearing a
meatball with your fork, and some spaghetti, even if it's dense 3D space... So
it's not about visualization, more about UX/interaction or interface...

------
Matthias247
That's cool. I had the same idea (3d minesweeper with semi-transparent blocks)
about 10 years ago, but never came around to actually realize it. Great to see
how the gameplay is like.

One possible improvement: Add some keyboard mappings for map rotation. E.g.
something like WSAD to rotate the cube and QE,RF to strafe vertically and
horizontally. I guess it would need some experimentation to figure out what
makes sense.

------
jackyinger
This is fun!

Assuming the developer is listening... I think I ran into a bug related to
resizing the window after starting the game. Clicking selected other blocks
than I desired.

Also, I'd like to +1 the request to have a grid remain at least on the
numbered cells. A partial transparency of numbered cells might be neat because
you could see depth better from overlap of cells.

~~~
david-given
I kept finding it wanted to clip the right hand edge of the puzzle off the
right hand side of the browser window. I tend to use square browsers --- am I
weird?

And left-dragging to pan wasn't an entirely happy experience; partly because
it kept selecting bits of the HTML on the left, and partly because I felt
there was something slightly strange about the way rotation worked. Is it
traditional arcball or something else?

...but in general I thought it worked really well. I played sweep mode, and
liked it a great deal (I did get an unfair puzzle, but guessed correctly and
won it. On, um, easy mode).

 _Update_ : has something just changed? I can't delete mines in sweep mode any
more --- they just blow up instead.

------
herpderp3dtwerp
Great job! Really enjoyed playing it. The controls are a bit tough... maybe
because i'm using a trackpad on a mac.

------
misotaur
What is the stack used?I`d love to read a blog about the making of.

~~~
egraether
It's hand written WebGL. You can find it on GitHub:
[https://github.com/egraether/mine3D](https://github.com/egraether/mine3D)

------
stevarino
This is surprisingly addictive. I'm loving the "bonus" links it sends when you
complete a puzzle (although I did get one with near transparent blocks that
was murder to attempt).

Example:
[http://egraether.com/mine3d/?grid=30,16,1,99](http://egraether.com/mine3d/?grid=30,16,1,99)

Currently only at a 20% win rate, which is frustrating.

------
rodorgas
Should it work on mobile? How do I rotate the cube? Awesome idea btw!

------
_feda_
Wow. Very nice job. Very intuitive. However, you should move the cube into the
center of the screen, since that is the center of the players focus.

------
HurrdurrHodor
This would probably be better if each cube had only 6 neighbors because the
way it is the areas are pretty large and it gets quite difficult.

------
stevage
I don't think "Space = new game" was a good keyboard control choice.
Accidentally lost my game halfway through :/

------
sogen
Note: Should have 2012 in the title

------
spyridonas
My eset security blocked this url.

------
tiredwired
cool but, I wish the entire cube scaled to fit inside the window instead of
being clipped.

------
eriknstr
Pretty good game, nice work.

------
oerpli
One of those things that are possible but still shouldn't be done.

~~~
3131s
As a game I agree that it ultimately doesn't work quite as well as the
original minesweeper, but I definitely am glad it was made. It's awesome!
Visually the cascading effect of boxes being revealed is done so well and it's
fun to see familiar patterns from the 2D version show up here -- I'm sure
there are many new patterns in this 3d version that I haven't found yet.

Without giving it any thought really, I wonder what modifications (if any)
needed to be made to the flood fill algorithm in this version.

[https://en.wikipedia.org/wiki/Flood_fill](https://en.wikipedia.org/wiki/Flood_fill)

------
nik1aa5
I love this!

------
martinko
Hm, eset smart security is blocking the site for me..

~~~
coldtea
Then don't use eset "smart" security?

~~~
martinko
Corporate policy for all work laptops...

------
tim_hacker
I think mine is better

~~~
tim_hacker
[https://github.com/tim-hub/TiminesSweeper-3D-](https://github.com/tim-
hub/TiminesSweeper-3D-)

------
tim_hacker
I think mine is better

[https://github.com/tim-hub/TiminesSweeper-3D-](https://github.com/tim-
hub/TiminesSweeper-3D-)

~~~
PhasmaFelis
Yours displays in a subwindow that's too small for it and has scrollbars. You
can click and drag to rotate the cube, but for some reason it doesn't start
rotating until after you release the button, which makes rotation very
difficult to judge. I spotted a mine, clicked on a "1" _next to_ the mine, and
it exploded. If you're not using standard Minesweeper controls, that needs to
be clearer. Also, Kongregate made me watch a 30-second ad first.

~~~
tim_hacker
Sorry for that.

There are many bugs and bad things in the game I did not fix, because I have
no time to do. I have to work and find work to make a living.

Maybe the word I say is not clearly, What I mean is I think my game's
mechanic/idea is better.

Certainly, [http://egraether.com/mine3d/](http://egraether.com/mine3d/) this
is more stable, more beautiful ui, and more light weight.

