[LayaAirIDE 2.0]使用Laya2.0做微信开放数据域是出错。

Laya2.0发布为微信开放数据域项目是报错:
WAGameSubContext.js:1 Uncaught TypeError: Cannot read property 'USER_DATA_PATH' of undefined
at Function.MiniFileMgr.setNativeFileDir (laya.wxmini.js:673)
at Function.MiniAdpter.init (laya.wxmini.js:91)
at Function.MiniAdpter.enable (laya.wxmini.js:77)
at Function.Browser.__init__ (laya.core.js:4125)
at Object.Laya.init (laya.core.js:252)
at new Main (Main.ts:6)
at Object.2../GameConfig (Main.ts:35)
at o (_prelude.js:11)
at r (_prelude.js:11)
at _prelude.js:11
MiniFileMgr.setNativeFileDir @ laya.wxmini.js:673
MiniAdpter.init @ laya.wxmini.js:91
MiniAdpter.enable @ laya.wxmini.js:77
Browser.__init__ @ laya.core.js:4125
Laya.init @ laya.core.js:252
Main @ Main.ts:6
2../GameConfig @ Main.ts:35
o @ _prelude.js:11
r @ _prelude.js:11
(anonymous) @ _prelude.js:11
require @ WAGameSubContext.js:1
(anonymous) @ WAGameSubContext.js:1
(anonymous) @ index.js:19
require @ WAGameSubContext.js:1
(anonymous) @ subcontext.html:10
laya.webgl.js:2358 gridInfo:slotW=32,gridw=16,gridNum=256,textureW=512

该怎么解决?
已邀请:

何吓吓

赞同来自:

开放域工程里,一定要使用Laya2.0.0beta4或者更高的引擎版本。需要在main里加一句:
Laya.isWXOpenDataContext = true;
否则默认初始化会出错。

要回复问题请先

商务合作
商务合作