1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253 |
- var manifest = JSON.parse(egret_native.readFileSync("manifest.json"));
- var game_file_list = manifest.initial.concat(manifest.game);
- var window = this;
- egret_native.setSearchPaths([""]);
- egret_native.requireFiles = function () {
- for (var key in game_file_list) {
- var src = game_file_list[key];
- require(src);
- }
- };
- egret_native.egretInit = function () {
- if(egret_native.featureEnable) {
- //控制一些优化方案是否开启
- //Control whether some optimization options are open
- var result = egret_native.featureEnable({
-
- });
- }
- egret_native.requireFiles();
- egret.dom = {};
- egret.dom.drawAsCanvas = function () {
- };
- };
- egret_native.egretStart = function () {
- var option = {
- //以下为自动修改,请勿修改
- //The following is automatically modified, please do not modify
- //----auto option start----
- entryClassName: "Main",
- frameRate: 60,
- scaleMode: "showAll",
- contentWidth: 988,
- contentHeight: 718,
- showPaintRect: false,
- showFPS: true,
- fpsStyles: "x:0,y:0,size:12,textColor:0xffffff,bgAlpha:0.9",
- showLog: false,
- logFilter: "",
- maxTouches: 2,
- textureScaleFactor: 1
- //----auto option end----
- };
- egret.native.NativePlayer.option = option;
- egret.runEgret();
- egret_native.Label.createLabel("/system/fonts/DroidSansFallback.ttf", 20, "", 0);
- egret_native.EGTView.preSetOffScreenBufferEnable(true);
- };
|