Mobile defense/firefox pixelation

This commit is contained in:
MaxRobinsonTheGreat
2020-07-23 15:52:02 -06:00
parent b0af739747
commit cafb444417
4 changed files with 310 additions and 7 deletions

View File

@@ -3,6 +3,13 @@
import Engine from './Engine';
$('document').ready(function(){
let isMobile = window.matchMedia("only screen and (max-width: 760px)").matches;
console.log(isMobile)
if (isMobile) {
alert("Though the simulation still works on mobile, most features are disabled. Try it on desktop for the full experience!");
$('.control-panel').css('display', 'none');
}
var engine = new Engine();
engine.start(60);
});