欢迎来到程序小院
玩法:消除游戏,消除不同种类的矿石,上下左右一排矿石可以移动,相同颜色的三个以上连成一条线即可消除,快去消除矿石吧^^。
<div?id="viewporter">
<header?id="header"?class="EaselJS"></header>
<canvas?id="canvas"?width="640"?height="960"></canvas>
</div>
canvas{
position:absolute;
left:0;
top:0;
width:640;
height:960;
-ms-interpolation-mode:nearest-neighbor;
-webkit-transform:scale3d(1,1,1);
z-index:1;
}
function?a(e,?t)?{
??e?=?e?||?{},
??this.IS_MASTER?=?e.isMaster,
??this.IS_STANDALONE?=?e.isStandalone,
??this.messenger?=?e.messenger,
??this.eventTracking?=?e.eventTracking,
??this.moduleReady?=?t???t:?!1,
??this.isAvailable?=?!1,
??this.locale?=?""
}
function?r(e,?t)?{
??e?=?e?||?{},
??this.IS_MASTER?=?e.isMaster,
??this.IS_STANDALONE?=?e.isStandalone,
??this.messenger?=?e.messenger,
??this.eventTracking?=?e.eventTracking,
??this.moduleReady?=?t???t:?!1,
??this.isAvailable?=?!1
}
function?s(e,?t)?{
??e?=?e?||?{},
??this.IS_MASTER?=?e.isMaster,
??this.IS_SLAVE?=?!this.IS_MASTER,
??this.moduleReady?=?t???t:?!1,
??this.messenger?=?e.messenger,
??this.data?=?e.data?||?null,
??this.eventTracking?=?e.eventTracking,
??this.initialHeight?=?e.initialHeight,
??this._setupMasterEvent()
}
function?o(e,?t)?{
??e?=?e?||?{},
??this.IS_MASTER?=?e.isMaster,
??this.IS_SLAVE?=?!this.IS_MASTER,
??this.moduleReady?=?t???t:?!1,
??this.messenger?=?e.messenger,
??this.data?=?e.data?||?null,
??this.eventTracking?=?e.eventTracking,
??this.initialHeight?=?e.initialHeight,
??this._setupMasterEvent()
}
function?l(e,?t)?{
??e?=?e?||?{},
??this.isMaster?=?e.isMaster,
??this.isStandalone?=?e.isStandalone,
??this.messenger?=?e.messenger,
??this.moduleReady?=?t???t:?!1,
??this.timeoutAfter?=?500,
??this.timeout?=?!1,
??this._callbacks?=?{
??????pause:?!1,
??????resume:?!1
??}
}
function?u(e,?t)?{
??e?=?e?||?{},
??this.IS_MASTER?=?e.isMaster,
??this.isStandalone?=?e.isStandalone,
??this.messenger?=?e.messenger,
??this.eventTracking?=?e.eventTracking,
??this.moduleReady?=?t???t:?!1,
??this.events?=?{
??????GAME_START:?"GAME_START",
??????GAME_END:?"GAME_END",
??????GAME_PAUSE:?"GAME_PAUSE",
??????GAME_CONTINUE:?"GAME_CONTINUE",
??????GAME_MUTE:?"GAME_MUTE",
??????LEVEL_FAIL:?"LEVEL_FAIL",
??????LEVEL_COMPLETE:?"LEVEL_COMPLETE"
??},
??this._setupEvents()
}
function?c(e,?t)?{
??e?=?e?||?{},
??this.IS_MASTER?=?e.isMaster,
??this.IS_SLAVE?=?!this.IS_MASTER,
??this.IS_STANDALONE?=?e.isStandalone,
??this.data?=?e.data,
??this.messenger?=?e.messenger,
??this.moduleReady?=?t???t:?!1,
??this.gamePlayTracking?=?{
??????started:?!1,
??????appid:?null,
??????host:?null,
??????timestamp:?null
??},
??this.timeInGameTracking?=?{
??????started:?!1,
??????appid:?null,
??????timestamp:?null
??}
}
function?d(e,?t)?{
??e?=?e?||?{},
??this.IS_MASTER?=?e.isMaster,
??this.IS_SLAVE?=?!this.IS_MASTER,
??this.IS_STANDALONE?=?e.isStandalone,
??this.moduleReady?=?t???t:?!1,
??this.messenger?=?e.messenger,
??this.components?=?e.components,
??this.data?=?e.data?||?null
}
function?p(e)?{
??var?t?=?"string"?==?typeof?e???h(e)?:?e;
??t?&&?(this.type?=?t.type,?this.callbackId?=?t.callbackId,?this.data?=?t.data)
}
function?h(e)?{
??var?t,?n,?i,?a?=?!1,
??r?=?[];
??if?("string"?==?typeof?e?&&?(r?=?e.split("|"),?"gameapi"?===?r[0]))?{
??????r.shift(),
??????t?=?r.shift(),
??????i?=?parseInt(r.shift(),?10),
??????n?=?r.join("|");
??????try?{
??????????a?=?{
??????????????type:?t,
??????????????callbackId:?i,
??????????????data:?""?!==?n???JSON.parse(n)?:?""
??????????}
??????}?catch(s)?{}
??}
??return?a
}
function?g(e)?{
??e?=?e?||?{},
??this.IS_MASTER?=?"boolean"?==?typeof?e.isMaster???e.isMaster:?!1,
??this.IS_SLAVE?=?!this.IS_MASTER,
??this.api?=?e.api???e.api:?{},
??this._target?=?e.target???e.target:?{},
??this._callbacks?=?[],
??this._channels?=?[],
??this.IS_MASTER?&&?e.dataStore?&&?(this.dataStore?=?e.dataStore),
??this._setupEventListener()
}
function?f(e,?n,?l,?c,?d)?{
??window.outerHeight?-?window.innerHeight,
??this.version?=?"0.17.1",
??this.isReady?=?!1,
??this._setRole(),
??this.__?=?{},
??this.__.dataStore?=?this.IS_MASTER???new?e({
??????isMaster:?!0
??})?:?null,
??this.__.messenger?=?new?n({
??????isMaster:?this.IS_MASTER,
??????api:?this,
??????target:?this._getTarget(),
??????dataStore:?this.__.dataStore
??}),
??this.__.components?=?new?t,
??this.Branding?=?new?l({
??????isMaster:?this.IS_MASTER,
??????isStandalone:?this.IS_STANDALONE,
??????messenger:?this.__.messenger,
??????components:?this.__.components
??},
??!1),
??this.__.EventTracking?=?new?c({
??????isMaster:?this.IS_MASTER,
??????isStandalone:?this.IS_STANDALONE,
??????data:?null,
??????messenger:?this.__.messenger
??},
??!1),
??this.GameBreak?=?new?d({
??????isMaster:?this.IS_MASTER,
??????isStandalone:?this.IS_STANDALONE,
??????messenger:?this.__.messenger
??},
??!1),
??this.Game?=?new?i({
??????isMaster:?this.IS_MASTER,
??????messenger:?this.__.messenger
??},
??!1),
??this.Score?=?new?s({
??????isMaster:?this.IS_MASTER,
??????isStandalone:?this.IS_STANDALONE,
??????messenger:?this.__.messenger,
??????eventTracking:?this.__.EventTracking,
??????initialHeight:?window.outerHeight?-?window.innerHeight
??},
??!1),
??this.Award?=?new?o({
??????isMaster:?this.IS_MASTER,
??????isStandalone:?this.IS_STANDALONE,
??????messenger:?this.__.messenger,
??????eventTracking:?this.__.EventTracking,
??????initialHeight:?window.outerHeight?-?window.innerHeight
??},
??!1),
??this.User?=?new?a({
??????isMaster:?this.IS_MASTER,
??????messenger:?this.__.messenger,
??????eventTracking:?this.__.EventTracking
??},
??!1),
??this.Friends?=?new?r({
??????isMaster:?this.IS_MASTER,
??????messenger:?this.__.messenger,
??????eventTracking:?this.__.EventTracking
??},
??!1),
??this.GameEvent?=?new?u({
??????isMaster:?this.IS_MASTER,
??????messenger:?this.__.messenger,
??????eventTracking:?this.__.EventTracking
??},
??!1)
}
var?m;?(function(e)?{
??if?("function"?==?typeof?bootstrap)?bootstrap("promise",?e);
??else?if?("object"?==?typeof?exports)?module.exports?=?e();
??else?if?("function"?==?typeof?define?&&?define.amd)?define(e);
??else?if?("undefined"?!=?typeof?ses)?{
??????if?(!ses.ok())?return;
??????ses.makeQ?=?e
??}?else?m?=?e()
})(function()?{
??function?e(e)?{
??????return?function()?{
??????????return?X.apply(e,?arguments)
??????}
??}
??function?t(e)?{
??????return?e?===?Object(e)
??}
??function?n(e)?{
??????return?"[object?StopIteration]"?===?tt(e)?||?e?instanceof?q
??}
??function?i(e,?t)?{
??????if?(H?&&?t.stack?&&?"object"?==?typeof?e?&&?null?!==?e?&&?e.stack?&&?-1?===?
??????e.stack.indexOf(nt))?{
??????????for?(var?n?=?[],?i?=?t;?i;?i?=?i.source)?i.stack?&&?n.unshift(i.stack);
??????????n.unshift(e.stack);
??????????var?r?=?n.join("\n"?+?nt?+?"\n");
??????????e.stack?=?a(r)
??????}
??}
??function?a(e)?{
??????for?(var?t?=?e.split("\n"),?n?=?[],?i?=?0;?t.length?>?i;?++i)?{
??????????var?a?=?t[i];
??????????o(a)?||?r(a)?||?!a?||?n.push(a)
??????}
??????return?n.join("\n")
??}
??function?r(e)?{
??????return?-?1?!==?e.indexOf("(module.js:")?||?-1?!==?e.indexOf("(node.js:")
??}
??function?s(e)?{
??????var?t?=?/at?.+?\((.+):(\d+):(?:\d+)\)$/.exec(e);
??????if?(t)?return?[t[1],?Number(t[2])];
??????var?n?=?/at?([^?]+):(\d+):(?:\d+)$/.exec(e);
??????if?(n)?return?[n[1],?Number(n[2])];
??????var?i?=?/.*@(.+):(\d+)$/.exec(e);
??????return?i???[i[1],?Number(i[2])]?:?void?0
??}
??function?o(e)?{
??????var?t?=?s(e);
??????if?(!t)?return?!?1;
??????var?n?=?t[0],
??????i?=?t[1];
??????return?n?===?F?&&?i?>=?J?&&?st?>=?i
??}
??function?l()?{
??????if?(H)?try?{
??????????throw?Error()
??????}?catch(e)?{
??????????var?t?=?e.stack.split("\n"),
??????????n?=?t[0].indexOf("@")?>?0???t[1]?:?t[2],
??????????i?=?s(n);
??????????if?(!i)?return;
??????????return?F?=?i[0],
??????????i[1]
??????}
??}
??function?u(e,?t,?n)?{
??????return?function()?{
??????????return?"undefined"?!=?typeof?console?&&?"function"?==?typeof?console.warn?
??????????&&?console.warn(t?+?"?is?deprecated,?use?"?+?n?+?"?instead.",?Error("").
??????????stack),e.apply(e,?arguments)
??????}
??}
??function?c(e)?{
??????return?y(e)???e:?v(e)???k(e)?:?T(e)
??}
??function?d()?{
??????function?e(e)?{
??????????t?=?e,
??????????r.source?=?e,
??????????Q(n,
??????????function(t,?n)?{
??????????????W(function()?{
??????????????????e.promiseDispatch.apply(e,?n)
??????????????})
??????????},
??????????void?0),
??????????n?=?void?0,
??????????i?=?void?0
??????}
??????var?t,?n?=?[],
??????i?=?[],
??????a?=?z(d.prototype),
??????r?=?z(g.prototype);
??????if?(r.promiseDispatch?=?function(e,?a,?r)?{
??????????var?s?=?K(arguments);
??????????n???(n.push(s),?"when"?===?a?&&?r[1]?&&?i.push(r[1]))?:?W(function()?{
??????????????t.promiseDispatch.apply(t,?s)
??????????})
??????},
??????r.valueOf?=?function()?{
??????????if?(n)?return?r;
??????????var?e?=?m(t);
??????????return?y(e)?&&?(t?=?e),
??????????e
??????},
??????r.inspect?=?function()?{
??????????return?t???t.inspect()?:?{
??????????????state:?"pending"
??????????}
??????},
??????c.longStackSupport?&&?H)?try?{
??????????throw?Error()
??????}?catch(s)?{
??????????r.stack?=?s.stack.substring(s.stack.indexOf("\n")?+?1)
??????}
??????return?a.promise?=?r,
??????a.resolve?=?function(n)?{
??????????t?||?e(c(n))
??????},
??????a.fulfill?=?function(n)?{
??????????t?||?e(T(n))
??????},
??????a.reject?=?function(n)?{
??????????t?||?e(I(n))
??????},
??????a.notify?=?function(e)?{
??????????t?||?Q(i,
??????????function(t,?n)?{
??????????????W(function()?{
??????????????????n(e)
??????????????})
??????????},
??????????void?0)
??????},
??????a
??}
??function?p(e)?{
??????if?("function"?!=?typeof?e)?throw?new?TypeError("resolver?must?be?a?function.");
??????var?t?=?d();
??????try?{
??????????e(t.resolve,?t.reject,?t.notify)
??????}?catch(n)?{
??????????t.reject(n)
??????}
??????return?t.promise
??}
??function?h(e)?{
??????return?p(function(t,?n)?{
??????????for?(var?i?=?0,
??????????a?=?e.length;?a?>?i;?i++)?c(e[i]).then(t,?n)
??????})
??}
??function?g(e,?t,?n)?{
??????void?0?===?t?&&?(t?=?function(e)?{
??????????return?I(Error("Promise?does?not?support?operation:?"?+?e))
??????}),
??????void?0?===?n?&&?(n?=?function()?{
??????????return?{
??????????????state:?"unknown"
??????????}
??????});
??????var?i?=?z(g.prototype);
??????if?(i.promiseDispatch?=?function(n,?a,?r)?{
??????????var?s;
??????????try?{
??????????????s?=?e[a]???e[a].apply(i,?r)?:?t.call(i,?a,?r)
??????????}?catch(o)?{
??????????????s?=?I(o)
??????????}
??????????n?&&?n(s)
??????},
??????i.inspect?=?n,?n)?{
??????????var?a?=?n();
??????????"rejected"?===?a.state?&&?(i.exception?=?a.reason),
??????????i.valueOf?=?function()?{
??????????????var?e?=?n();
??????????????return?"pending"?===?e.state?||?"rejected"?===?e.state???i:?e.value
??????????}
??????}
??????return?i
??}
??function?f(e,?t,?n,?i)?{
??????return?c(e).then(t,?n,?i)
??}
??function?m(e)?{
??????if?(y(e))?{
??????????var?t?=?e.inspect();
??????????if?("fulfilled"?===?t.state)?return?t.value
??????}
??????return?e
??}
??function?y(e)?{
??????return?t(e)?&&?"function"?==?typeof?e.promiseDispatch?&&?"function"?==?typeof
??????e.inspect
??}
??function?v(e)?{
??????return?t(e)?&&?"function"?==?typeof?e.then
??}
??function?S(e)?{
??????return?y(e)?&&?"pending"?===?e.inspect().state
??}
??function?_(e)?{
??????return?!?y(e)?||?"fulfilled"?===?e.inspect().state
??}
??function?w(e)?{
??????return?y(e)?&&?"rejected"?===?e.inspect().state
??}
??function?b()?{
??????it.length?=?0,
??????at.length?=?0,
??????rt?||?(rt?=?!0)
??}
??function?A(e,?t)?{
??????rt?&&?(at.push(e),?t?&&?t.stack?!==?void?0???it.push(t.stack)?:?it.push("(no?stack)
??????"?+?t))
??}
??function?E(e)?{
??????if?(rt)?{
??????????var?t?=?Y(at,?e);?-?1?!==?t?&&?(at.splice(t,?1),?it.splice(t,?1))
??????}
??}
??function?I(e)?{
??????var?t?=?g({
??????????when:?function(t)?{
??????????????return?t?&&?E(this),
??????????????t???t(e)?:?this
??????????}
??????},
??????function()?{
??????????return?this
??????},
??????function()?{
??????????return?{
??????????????state:?"rejected",
??????????????reason:?e
??????????}
??????});
??????return?A(t,?e),
??????t
??}
??function?T(e)?{
??????return?g({
??????????when:?function()?{
??????????????return?e
??????????},
??????????get:?function(t)?{
??????????????return?e[t]
??????????},
??????????set:?function(t,?n)?{
??????????????e[t]?=?n
??????????},
??????????"delete":?function(t)?{
??????????????delete?e[t]
??????????},
??????????post:?function(t,?n)?{
??????????????return?null?===?t?||?void?0?===?t???e.apply(void?0,?n)?:?e[t].apply(e,?n)
??????????},
??????????apply:?function(t,?n)?{
??????????????return?e.apply(t,?n)
??????????},
??????????keys:?function()?{
??????????????return?et(e)
??????????}
??????},
??????void?0,
??????function()?{
??????????return?{
??????????????state:?"fulfilled",
??????????????value:?e
??????????}
??????})
??}
??function?k(e)?{
??????var?t?=?d();
??????return?W(function()?{
??????????try?{
??????????????e.then(t.resolve,?t.reject,?t.notify)
??????????}?catch(n)?{
??????????????t.reject(n)
??????????}
??????}),
??????t.promise
??}
??function?R(e)?{
??????return?g({
??????????isDef:?function()?{}
??????},
??????function(t,?n)?{
??????????return?O(e,?t,?n)
??????},
??????function()?{
??????????return?c(e).inspect()
??????})
??}
??function?M(e,?t,?n)?{
??????return?c(e).spread(t,?n)
??}
??function?L(e)?{
??????return?function()?{
??????????function?t(e,?t)?{
??????????????var?s;
??????????????if?("undefined"?==?typeof?StopIteration)?{
??????????????????try?{
??????????????????????s?=?i[e](t)
??????????????????}?catch(o)?{
??????????????????????return?I(o)
??????????????????}
??????????????????return?s.done???s.value:?f(s.value,?a,?r)
??????????????}
??????????????try?{
??????????????????s?=?i[e](t)
??????????????}?catch(o)?{
??????????????????return?n(o)???o.value:?I(o)
??????????????}
??????????????return?f(s,?a,?r)
??????????}
??????????var?i?=?e.apply(this,?arguments),
??????????a?=?t.bind(t,?"next"),
??????????r?=?t.bind(t,?"throw");
??????????return?a()
??????}
??}
??function?N(e)?{
??????c.done(c.async(e)())
??}
??function?P(e)?{
??????throw?new?q(e)
??}
??function?G(e)?{
??????return?function()?{
??????????return?M([this,?C(arguments)],
??????????function(t,?n)?{
??????????????return?e.apply(t,?n)
??????????})
??????}
??}
??function?O(e,?t,?n)?{
??????return?c(e).dispatch(t,?n)
??}
需要源码请关注添加好友哦^ ^
转载:欢迎来到本站,转载请注明文章出处
https://ormcc.com/