Commit a9285ccd authored by wildfirecode's avatar wildfirecode

1

parent db507c6b
......@@ -39,7 +39,7 @@
<script src="libs/security.js"></script>
<script src="libs/physics.min.js"></script>
<!-- <script src="default.thm.js"></script> -->
<script src="output.js"></script>
<script src="libs/downloadApp.js"></script>
<script>
// localStorage.clear();
......@@ -92,28 +92,8 @@ var __bgUrl__ = 'resource/assets/startScene/bg.jpg';
return b;
}
</script>
<script>
// window['resPath'] = 'https://yun.duiba.com.cn/db_games/activity/fishaqy/1535713239/'
/**
* {
* "renderMode":, //Engine rendering mode, "canvas" or "webgl"
* "audioType": 0 //Use the audio type, 0: default, 2: web audio, 3: audio
* "antialias": //Whether the anti-aliasing is enabled in WebGL mode, true: on, false: off, defaults to false
* "calculateCanvasScaleFactor": //a function return canvas scale factor
* }
**/
egret.runEgret({
renderMode: "webgl", audioType: 0, calculateCanvasScaleFactor: function (context) {
var backingStore = context.backingStorePixelRatio ||
context.webkitBackingStorePixelRatio ||
context.mozBackingStorePixelRatio ||
context.msBackingStorePixelRatio ||
context.oBackingStorePixelRatio ||
context.backingStorePixelRatio || 1;
return (window.devicePixelRatio || 1) / backingStore;
}
});
</script>
<script src="output.js"></script>
</body>
</html>
\ No newline at end of file
......@@ -29,4 +29,16 @@ class Main extends MainBase {
}
}
window['Main'] = Main;
\ No newline at end of file
window['Main'] = Main;
egret.runEgret({
renderMode: "webgl", audioType: 0, calculateCanvasScaleFactor: function (context:any) {
var backingStore = context.backingStorePixelRatio ||
context.webkitBackingStorePixelRatio ||
context.mozBackingStorePixelRatio ||
context.msBackingStorePixelRatio ||
context.oBackingStorePixelRatio ||
context.backingStorePixelRatio || 1;
return (window.devicePixelRatio || 1) / backingStore;
}
});
\ No newline at end of file
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