From 58f7e36c3bfab689ef093c1647591c04e279ff09 Mon Sep 17 00:00:00 2001 From: YouWei Zhao Date: Thu, 28 Dec 2017 11:50:25 +0800 Subject: [PATCH] Update main.js MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 可以选择不监听事件,给GUI调用提供可能性 --- index.html | 1 + main.js | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/index.html b/index.html index 44c759a0..fa25ac90 100644 --- a/index.html +++ b/index.html @@ -113,5 +113,6 @@ 此浏览器不支持HTML5 + \ No newline at end of file diff --git a/main.js b/main.js index fe644e79..b9891a99 100644 --- a/main.js +++ b/main.js @@ -195,8 +195,9 @@ main.prototype.setMainTipsText = function (text) { main.dom.mainTips.innerHTML = text; } -var main = new main(); -main.init(); + + +main.prototype.listen = function () { window.onresize = function () { try { @@ -366,3 +367,7 @@ main.dom.normalLevel.onclick = function () { main.dom.hardLevel.onclick = function () { core.events.startGame('Hard'); } + +}//listen end + +var main = new main(); \ No newline at end of file