Skip to content

cwlowder/MineSweeper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 
 
 
 
 

Repository files navigation

MineSweeper
    by Curtis Lowder

How to run:
    To run the code, run the main command in the Main class.
    Note: the default configuration will run the AI players only.
        if you want to run the code in a mode that will allow a human to play,
            Answer no to the prompt of should run
        Running the code under AI control will run two major parts to the code:
            the probabilistic and random AI.
        Playing as a human is only meant for testing purposes
    The probabilisticPlayer is the main focus of this program.
    The randomPlayer is only meant as a control to compare performance.


Algorithm for probabilityPlayer:
    The algorithm in this code simply assigns a probability to each of the neighbors of an uncovered and numbered cell.
    Dividing the number of mined cells / number of covered cells, calculates the probability of each of a cells
    neighbors being a mine. After all the uncovered and numbered cells have their neighbor's probabilities calculated,
    the algorithm uncovers the lowest probability cell. If no probabilities are known for any of
    the cells, the algorithm picks a random covered cell, and uncovers it. This algorithm repeats until either the board
    is solved, or a mine has been hit.


Contact information:
    [email protected]

Some interesting information considered in this code:
    http://www.techuser.net/mineclick.html
        basically, the technique the original MineSweeper used to make sure your first click was never a bomb

    https://en.wikipedia.org/wiki/Microsoft_Minesweeper
        rules for the game

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published