Coder Social home page Coder Social logo

alexaegis / minesweeper Goto Github PK

View Code? Open in Web Editor NEW
59.0 3.0 4.0 5.02 MB

A minesweeper clone for the web using TinySlice! My state manager libary.

Home Page: https://alexaegis.github.io/minesweeper/

License: MIT License

HTML 0.14% JavaScript 1.70% TypeScript 45.44% Svelte 37.07% SCSS 15.61% Shell 0.03%
svelte typescript minesweeper rxjs sveltejs tinyslice

minesweeper's Introduction

ci codacy code style: prettier svelte vercel

The classic Win98 Minesweeper game recreated for the web using reactive technologies such as Svelte and RxJS. With some additional features of a Windows 2000 desktop interface like window management, and a taskbar together with a start menu.

Preview

Click on the image to try it out on github pages!

Also available @ Vercel

Comparison

Here's a screencapture from a Windows NT 2000 Virtual Machine:

Preview

Differences

I either can't fix these, or they would make no sense to fix. There are of course many more differences, these are the ones I noticed and thought worth mentioning.

  • Font used does not contain actual bold versions of Tahoma at 8px
  • The edges of the tiles and panels within Minesweeper have some 3D Object colored pixels where the edges meet. This cannot be replicated with the box-shadow trick, and regular inset/outset css borders have a sharp edge.
  • The numbers are not pixelated. I've spent a lot of time making those numbers with clip-path's so they will stay. And I think I managed to capture the shape of the original pretty well.
  • Some pixel are not exactly pixel shaped, that's thanks to browser rendering, can't do anything about that.
  • The timer for Minesweeper in the original starts at 1, immediately as you start the game. I believe this is not correct so my timer switches to 1 only after a second after starting the game.

    My initial implementation actually did make the same mistake, and started from 1 immediately!

  • The maximum size of a playfield in the original is 30 by 24, not much larger than the Expert preset. I raised this to 50 by 50.
  • Pressing Cancel in the custom game window resets the game board in the original. I'm not going to do that.

Features

  • Taskbar
    • Start button, animated Start Menu
    • Buttons for open programs
    • A clock
  • Window Management
    • Movable
    • Minimizable (Animated!)
    • Resizable
    • Modals
    • Dropdowns
  • Minesweeper Game
    • Original presets
    • Custom games
    • Highscores
    • Cheating (Recorded to the highscore!)
    • Unlocking the scheme (The original used W98 colors regardless of your scheme)

Known bugs

  • Shortcuts do not work.

Planned features

  • Cheese Terminator
  • Basic scheme editor
  • A tetris game would be cool

Styles

98.css with some tweaks.

Other art

Pixelart was done by me using Pixilart referencing imagery from Windows Virtual Machines.

minesweeper's People

Contributors

alexaegis avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

minesweeper's Issues

[feature] seeds

have a seed for the random field generation, reflect it in the url so the game is share-able.

Consider making the entire gamestate importable exportable

[bug] Game is finished with one mine left.

Capture d’écran 2020-10-09 163903

You can finish the game by having all tiles uncovered (as in the picture), but with the counter still showing bombs to be discovered.

To Reproduce
Steps to reproduce the behavior:

  1. Finish the game while letting 1 or two bombs not detected.

Expected behavior
I think it would be a lot clearer at the end to either

  • let the user finish manually.
    or
  • automatically uncover all bombs and clear the mine counter set to Zero.

[feature] Settings kills state

Going to settings shouldn't kill state of ongoing game. If you choose to start a new game then by all means, but just clicking settings and exiting shouldn't wipe game state.

Nice minesweeper BTW 👍

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.