原微信小程序项目打包成小米快游戏需要注意些什么呢?

打包成微信小程序可以运行,直接在浏览器也可以运行。打包成小米快游戏就报错了。
报错信息:
runtime.js:1 ### game runtime ### 禁止写全局变量 window
set @ runtime.js:1
runtime.js:1 [Deprecation] Synchronous XMLHttpRequest on the main thread is deprecated because of its detrimental effects to the end user’s experience. For more help, check https://xhr.spec.whatwg.org/.
(anonymous) @ runtime.js:1
./main.js:6230 Read json failed: path: internal://files/gamecaches/cacheList.json message: Unexpected token o in JSON at position 1
readJsonSync @ ./main.js:6230
./main.js:18948 k-cocos v0.1
runtime.js:1 Failed to load resource: net::ERR_FILE_NOT_FOUND
(anonymous) @ runtime.js:1
runtime.js:1 ### game runtime ### xhr buffer.js加载失败
(anonymous) @ runtime.js:1
./main.js:7861 Uncaught TypeError: Cannot read property ‘Buffer’ of null
at Object…/…/…/assets/main/index.js.window.__require.Base64.buffer (./main.js:7861)
at s (./main.js:6495)
at e (./main.js:6503)
at Object…/…/…/assets/main/index.js (./main.js:6505)
at webpack_require (./main.js:22)
at assets/main/index.js (./main.js:18882)
at …/…/…/ccRequire.js.window.cocos_require (./main.js:18891)
at downloadBundle (./main.js:632)
at invoke (cocos2d-js.js:10244)
at process (cocos2d-js.js:10254)

已解决,太坑爹了!!!!!!!导致问题出现的原因是因为我打包的时候把调试勾选上了。

请问, 你的项目中,有使用window.来挂载全局变量吗?我也遇到了这个 禁止写全局变量window 的警告。我项目中有用到 window.aaa 这种形式的全局变量,我没有勾选调试,也还是不行