Commit 75d586d1 authored by 李维's avatar 李维

Test on platform

parent ee36d426
This diff is collapsed.
...@@ -6,6 +6,12 @@ ...@@ -6,6 +6,12 @@
// - https://docs.cocos.com/creator/manual/en/scripting/life-cycle-callbacks.html // - https://docs.cocos.com/creator/manual/en/scripting/life-cycle-callbacks.html
import GameLogic from "./GameLogic" import GameLogic from "./GameLogic"
// cc.game.onStart = function(){
// cc.director.runScene(new MyScene());
// console.log("Test")
// cc.game.run();
// };
// cc.game.run();
cc.Class({ cc.Class({
extends: cc.Component, extends: cc.Component,
...@@ -14,10 +20,18 @@ cc.Class({ ...@@ -14,10 +20,18 @@ cc.Class({
}, },
onStart() {
},
// 生命周期 onLoad // 生命周期 onLoad
onLoad() { onLoad() {
this.initSceneData(); this.initSceneData();
this.initSize(); this.initSize();
cc.macro.ENABLE_TRANSPARENT_CANVAS = true;
cc.director.setClearColor(new cc.Color(255 ,255 ,255 , 0));
}, },
_imageResList: null, _imageResList: null,
......
...@@ -67,6 +67,8 @@ ...@@ -67,6 +67,8 @@
loadScript(debug ? 'physics.js' : 'physics-min.js', window.boot); loadScript(debug ? 'physics.js' : 'physics-min.js', window.boot);
} }
else { else {
cc.macro.ENABLE_TRANSPARENT_CANVAS = true;
cc.director.setClearColor(new cc.Color(255 ,255 ,255 , 0));
window.boot(); window.boot();
} }
}); });
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment