Sign in to follow this  

Triangular/square/hexagonal Minesweeper (updated GUI)

This topic is 2800 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi all! Minesweeper is a remake of the well known Windows minesweeper with triangle/hexagonal/square grid. Please give it a try: https://sourceforge.net/projects/minesweepergame/ version without the custom window (and hopefully with the GUI bug-fix): http://sourceforge.net/projects/minesweepergame/minesweeper_old.zip/download Some screen-shots: triangle grid square grid hexagonal grid It is not complete yet (I'm not sure if it ever will be), but has some useful features:
  • openGL renderer
  • field size up to 200x200
  • zoom and pan field (middle button)
  • save game at exit
  • load game at startup
  • custom windowed GUI
  • all the controls on the field are the same as in the Windows version (left button up - reveal, right click - place flag/question mark, left+right click - auto reveal neighbors) An important feature it doesn't have: the rendering is not optimized (immediate mode, so the game can slow down slightly, if zoomed out ). Please make suggestions of new features, critique the whole game (be harsh!), if you find a bug, please report it! Test the GUI to its limits please, because I think I will reuse it in other projects too. Thanks for your time! [Edited by - szecs on April 24, 2010 2:37:24 AM]

    Share this post


    Link to post
    Share on other sites
    Looks very interesting from the screenshots, I'd love to try it. However, I'm trying it now on an old WinXP machine, and at startup it says "The application failed to initialize properly (0xc0000135).".

    Does it require a certain DLL or so? Or is this PC just too old (Geforce3 card)?

    Also, is a Linux version possible? Then I can try it tonight on my Linux box :)

    Nice looking GUI btw!

    Share this post


    Link to post
    Share on other sites
    I don't know what could be the problem. (I didn't add error checks, I know that's noob).
    It has one glWindowPos3i maybe that could be the problem?
    Otherwise no framebuffers, no vertex buffers.

    linux version: I'm not a programmer, I don't think I can make it cross platform, maybe with glut.

    Anyone else has this problem?

    Share this post


    Link to post
    Share on other sites
    What was the program developed with?

    Maybe your programming environment (e.g. Visual Studio) adds some dependencies on certain DLLs that I don't have and that's why it doesn't run for me?

    Quote:
    Original post by szecs
    I'm not a programmer


    What do you mean by that? If you program a minesweeper game, you're a programmer imho :)

    Share this post


    Link to post
    Share on other sites
    Quote:
    Original post by Lode
    What was the program developed with?
    ...
    What do you mean by that? If you program a minesweeper game, you're a programmer imho :)
    I don't even know how the check DLL dependencies. (Are they related to libs in some way?)
    Visual Studio 2008 BTW.
    + I'm just tinkering, I don't know nothing about architectures, engineering, language, so I couldn't apply for a programmer job. So I guess that means I'm programming, but I'm not a programmer.

    Share this post


    Link to post
    Share on other sites
    I've opened your program in "Dependency Walker", which checks for DLL dependencies. It said that "MSCOREE.DLL" was missing on my computer, so I downloaded that. Now if I run the program, it says an error about the .NET Framework.

    So now I now why the program doesn't work for me: I don't have the .NET framework installed!

    Totally unrelated: you asked if such a built in GUI was elegant. IMHO: for a game, yes, it most certainly is!

    Share this post


    Link to post
    Share on other sites
    I've found the options now, in "new game". Took me a while. [looksaround] Perhaps you could move the new game settings to "options" and make "new game" just start a game without bringing up a dialogue box? It might be a bit more intuitive. And is there any way to scroll the screen?

    I like the hexagonal grid mode, by the way. :)

    Share this post


    Link to post
    Share on other sites
    Quote:
    Original post by Lode
    I've opened your program in "Dependency Walker", which checks for DLL dependencies. It said that "MSCOREE.DLL" was missing on my computer, so I downloaded that. Now if I run the program, it says an error about the .NET Framework.

    So now I now why the program doesn't work for me: I don't have the .NET framework installed!

    Totally unrelated: you asked if such a built in GUI was elegant. IMHO: for a game, yes, it most certainly is!
    Sorry, I didn't notice this post at all!
    Can I make the game .NET independent somehow?

    Share this post


    Link to post
    Share on other sites
    Quote:
    Original post by szecs
    Quote:
    Original post by Lode
    I've opened your program in "Dependency Walker", which checks for DLL dependencies. It said that "MSCOREE.DLL" was missing on my computer, so I downloaded that. Now if I run the program, it says an error about the .NET Framework.

    So now I now why the program doesn't work for me: I don't have the .NET framework installed!

    Totally unrelated: you asked if such a built in GUI was elegant. IMHO: for a game, yes, it most certainly is!
    Sorry, I didn't notice this post at all!
    Can I make the game .NET independent somehow?


    I guess that depends on the language you're writing the game in.

    If you're using C#, then not.

    If you're using C++, then it's possible, I mean, if all you're doing is OpenGL calls, and no .NET specific functionality, it should be possible to use any other way to load OpenGL (SDL, glut, ...). But it'll of course be some more work to study these libraries and get it all to work.

    If you're using Visual Basic, then I don't know, to be honest.

    Anyway, tonight I'll check if your game runs in my Linux if I run it in Wine, with Mono installed (the open source attempt at running .NET applications)!

    EDIT: Sorry I accidently deleted my post! I post it again here. I had added an extra question, which I wanted to move to a new reply. Here it is:

    How do you handle the GUI? Is it handled every frame, or only when events happen? Is the GUI based on events or not?

    Quote:
    Original post by szecs
    Thanks for that, I'm using C++, so I'll try to look into the problem!


    Who says it's a problem? Many applications use .NET. Please don't quote me saying .NET is a problem! I simply don't have it installed on this 8 year old WinXP computer, so I can't run .NET apps, that's all.

    I must say I'm surprised by the combination of OpenGL and .NET though. Microsoft tries pushing .NET, but they also try pushing Direct3D instead of OpenGL, so I don't think having OpenGL in a .NET application would happen automatically :)

    Share this post


    Link to post
    Share on other sites
    The GUI is event based. But I don't know how it is usually done, I didn't read articles (I am a pervert, who wants do do everything by himself).
    It can easily be modified to a "game-loop" version, it doesn't really matter.

    Okay, I won't bother with the .NET stuff, but it's just a minesweeper, it should run on win98 too...
    Quote:
    so I don't think having OpenGL in a .NET application would happen automatically
    I don't even know how to setup a project properly. I made it from existing file, so the whole stuff is a bloody mess. I found a "targeted framework" option, but only .NET can be set (2.0 ... 3.5).

    Doesn't matter, I should ask it in the technical forums.

    Share this post


    Link to post
    Share on other sites
    Added dialogs at saving or deleting existing files, fixed positioning of GUI windows, when resizing the main window.

    Please make suggestions on new features, critique the whole game and the graphical use interface (be harsh!), if you find a bug, please report it!

    Thanks for your time!

    Share this post


    Link to post
    Share on other sites
    If you are using VS 2008, right click on the project and go to properties. Then click on Configuration properties and under Project defaults there is something about Common Language Runtime support. Make sure it says no common language runtime support.

    Share this post


    Link to post
    Share on other sites
    Quote:
    Original post by landagen
    If you are using VS 2008, right click on the project and go to properties. Then click on Configuration properties and under Project defaults there is something about Common Language Runtime support. Make sure it says no common language runtime support.
    Thanks for the tip. I did that and compiled, reloaded, I hope it works now without .NET

    Share this post


    Link to post
    Share on other sites
    Update:
  • A little more optimized field rendering
  • GUI windows fade in when invoked
  • Replaced default Windows titlebar and border with custom GUI elements

    I would appreciate some feedback about the GUI usability, features, stability, bugs, especially the main window functions (resize/move/maximize-restore-minimize). If I miss a feature, or some features behaves differently than the default features, please let me know! Test it to its limits! (there may be test cases I don't even know about.)

    The window is not layered window yet, so it has sharp corners.

    Thanks!

    Share this post


    Link to post
    Share on other sites
    Awesome! I like this new minesweeper, I posted it on my site :)
    ( I think you should pick a better name though, like Minesweeper XL or something)

    It seems that I can no longer access the menu in the new version?

    Nick

    Share this post


    Link to post
    Share on other sites
    Quote:
    Original post by Beather
    Awesome! I like this new minesweeper, I posted it on my site :)
    ( I think you should pick a better name though, like Minesweeper XL or something)

    It seems that I can no longer access the menu in the new version?

    Nick
    Thanks!

    And thanks for adding it to your site!

    What do you mean by no access?
    The load game menu only pops up, if there is at least one saves game to load. The zip containing the new version (with the custom skin) doesn't contain saved games.

    EDIT: the new version contains saved games too, so I don't know what you mean by no access.

    And since the new version has some major issues, I suggest you to use the old version instead.

    Share this post


    Link to post
    Share on other sites
    And I don't understand one thing: why are the numbers all gray in the screenshots?

    BTW I made the custom GUI, because it's a learning project (a very small one), and it was also easier, that learning the win32 way.

    Share this post


    Link to post
    Share on other sites
    Sign in to follow this