可以正常运行在play3中,但是在ide中就报错运行不起来
在MainScene中app:enterScene(“ButtonScene”)
然后在ButtonScene中
function ButtonScene:ctor()
local node = cc.uiloader:load(“test_ui_3.json”)
:addTo(self)
end
报错提示如下:
Get data from file(test_ui_3.json) failed, error code is 2
uiloader - load file fail:test_ui_3.json
LUA ERROR:
attempt to index a nil value