Compare commits
3 Commits
Author | SHA1 | Date |
---|---|---|
Max Bradbury | c02801e0d5 | |
Max Bradbury | cb4d8bd53e | |
Max Bradbury | 636fa2beb4 |
|
@ -20,6 +20,4 @@ the player can cheat under certain conditions; if there is only one tile left on
|
|||
|
||||
need a fallback for browsers that don't support CSS3 viewport sizing
|
||||
|
||||
In IE8, blank tiles do not cascade after clicking, nor do mine counts update properly. I think this is a problem with callbacks on jquery animations. I don't plan to support IE8 but this could be indicative of problems in other browsers.
|
||||
|
||||
colours used are not safe for red-green colourblindness. however, there is at least a visual distinction with the mines now
|
||||
|
|
54
index.html
54
index.html
|
@ -29,7 +29,7 @@
|
|||
width: 100vw;
|
||||
overflow: hidden;
|
||||
-moz-user-select: none;
|
||||
-webkit-user-select: none;
|
||||
-webkit-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
@ -229,7 +229,7 @@
|
|||
margin-top: 0;
|
||||
}
|
||||
|
||||
#setup h2,
|
||||
#setup h2,
|
||||
#setup label {
|
||||
margin: 0.4em 0.35em; /* fallback */
|
||||
margin: 4vmin 3.5vmin;
|
||||
|
@ -302,7 +302,7 @@
|
|||
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffefa7', endColorstr='#feae27',GradientType=0 );
|
||||
}
|
||||
|
||||
button.twitter {
|
||||
button.mastodon {
|
||||
background: #51aaea;
|
||||
background: -moz-linear-gradient(top, #51aaea 0%, #3375a6 100%);
|
||||
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#51aaea), color-stop(100%,#3375a6));
|
||||
|
@ -483,7 +483,7 @@
|
|||
$('#tutorial .gameBoard').html("");
|
||||
|
||||
gameBoardWidth = 10;
|
||||
|
||||
|
||||
//determine aspect ratio so as to fit the screen
|
||||
gameBoardHeight = determineGameBoardHeight();
|
||||
|
||||
|
@ -659,12 +659,12 @@
|
|||
function refreshMineCounts() {
|
||||
$('ul:not(.removing) li.revealed:not(.mine, .removing)').each(function() {
|
||||
var mineCount = $(this).countMinesText();
|
||||
|
||||
|
||||
$(this).text(mineCount);
|
||||
|
||||
//remove "mines1" etc
|
||||
$(this).attr(
|
||||
'class',
|
||||
'class',
|
||||
$(this).attr('class').replace(
|
||||
/mines[0-9]/, "mines" + mineCount
|
||||
)
|
||||
|
@ -688,7 +688,7 @@
|
|||
function checkGameOver() {
|
||||
if (isGameOver()) {
|
||||
$('#gameOver').show();
|
||||
|
||||
|
||||
var currentHiScore = 0;
|
||||
|
||||
if ($.isNumeric(localStorage.getItem("hiscore"))) {
|
||||
|
@ -755,7 +755,7 @@
|
|||
function updateMinesLeft() {
|
||||
//unflagged mines - revealed mines - flagged not-mines
|
||||
$('#mines').text(
|
||||
"Mines left: "
|
||||
"Mines left: "
|
||||
+ ($('.mine:not(.flagged)').length
|
||||
- $('.mine.revealed').length
|
||||
- $('li:not(.mine).flagged').length)
|
||||
|
@ -995,7 +995,7 @@
|
|||
$(this).addClass("revealed");
|
||||
} else if (!automated && parseInt($(this).text()) === $(this).getAdjacentTiles().filter('.flagged, .revealed.mine').length) {
|
||||
//already clicked; use middle click reveal functionality
|
||||
|
||||
|
||||
//number of flags matches number of adjacent mines
|
||||
$(this).getAdjacentTiles().filter(':not(.flagged, .revealed)').mouseup();
|
||||
} else {
|
||||
|
@ -1107,15 +1107,6 @@
|
|||
$('#cracktro').cracktro();
|
||||
});
|
||||
</script>
|
||||
<script>
|
||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||
|
||||
ga('create', 'UA-60523398-1', 'auto');
|
||||
ga('send', 'pageview');
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="stats">
|
||||
|
@ -1146,12 +1137,12 @@
|
|||
......................................................................
|
||||
inspired by minesweeper, tetris and 2048
|
||||
......................................................................
|
||||
gratz 'n' greetz go out to mum and dad, guy, titas, dan, nick, enrico,
|
||||
ahona, robin, arielle, isy, thom, tom, olu, lovely dave, jen, ed,
|
||||
david, andy, rachel, isaac, rory, 'partay' pat, al, ant, zoe, john,
|
||||
gratz 'n' greetz go out to mum and dad, guy, titas, dan, nick, enrico,
|
||||
ahona, robin, arielle, isy, thom, tom, olu, lovely dave, jen, ed,
|
||||
david, andy, rachel, isaac, rory, 'partay' pat, al, ant, zoe, john,
|
||||
charlie, wilkie, george
|
||||
......................................................................
|
||||
HELLO's fly out to some cool game devs: porpentine, merritt kopas,
|
||||
HELLO's fly out to some cool game devs: porpentine, merritt kopas,
|
||||
zoe quinn, aniwey, orteil
|
||||
......................................................................
|
||||
i listened to a lot of keygenjukebox while coding this
|
||||
|
@ -1160,21 +1151,14 @@
|
|||
......................................................................
|
||||
......................................................................
|
||||
......................................................................
|
||||
this story is dedicated to all those cyberpunks who fight against
|
||||
this story is dedicated to all those cyberpunks who fight against
|
||||
injustice and corruption every day of their lives
|
||||
......................................................................
|
||||
</div>
|
||||
|
||||
<div class="centre">
|
||||
<form name="_xclick" action="https://www.paypal.com/uk/cgi-bin/webscr" method="post" target="_blank">
|
||||
<input type="hidden" name="cmd" value="_xclick">
|
||||
<input type="hidden" name="business" value="mutantsluggenghiskhan@yahoo.co.uk">
|
||||
<input type="hidden" name="item_name" value="Donation to Ruin">
|
||||
<input type="hidden" name="currency_code" value="GBP">
|
||||
<button class="donate">donate</button>
|
||||
</form>
|
||||
<form action="https://twitter.com/synth_ruiner" target="_blank">
|
||||
<button class="twitter">say hi</button>
|
||||
<form action="https://timetheft.social/@tinybird" method="post" target="_blank">
|
||||
<button class="mastodon">say hi</button>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
|
@ -1186,7 +1170,7 @@
|
|||
<h1>endless mines</h1>
|
||||
|
||||
<p class="subtitle">ruin 2015</p>
|
||||
|
||||
|
||||
<p>
|
||||
<strong>left click</strong> or <strong>tap</strong> to clear a tile. <br>
|
||||
<strong>right click</strong> or <strong>hold</strong> to flag a mine. <br>
|
||||
|
@ -1200,7 +1184,7 @@
|
|||
<button class="start normal">normal</button>
|
||||
<button class="start hard">hard</button>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="centre">
|
||||
<button class="tutorial">tutorial</button>
|
||||
<button class="cancel">cancel</button>
|
||||
|
@ -1506,4 +1490,4 @@
|
|||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
|
Loading…
Reference in New Issue