Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cocos2d-js-v3.13.js:57555 Uncaught TypeError: ccs.dataReaderHelper.addDataFromBinaryCache is not a function #3575

Open
mblackcat opened this issue Jan 25, 2021 · 0 comments

Comments

@mblackcat
Copy link

When I use ccs.dataReaderHelper.addDataFromFile to read .csb file like below:

ccs.dataReaderHelper.addDataFromFile('res/myui.csb');

I get error:

cocos2d-js-v3.13.js:57555 Uncaught TypeError: ccs.dataReaderHelper.addDataFromBinaryCache is not a function
    at Object.addDataFromFile (cocos2d-js-v3.13.js:57555)
    at Object.cc.game.onStart (test.html?_ijt=hhnmd6tfcppjnmr010d3db9eub:31)
    at Array.<anonymous> (cocos2d-js-v3.13.js:1259)
    at cocos2d-js-v3.13.js:350
    at cc.AsyncPool.self.flow (cocos2d-js-v3.13.js:146)
    at Object.map (cocos2d-js-v3.13.js:197)
    at Object.loadJs (cocos2d-js-v3.13.js:337)
    at Object.loadJsWithImg (cocos2d-js-v3.13.js:347)
    at Object.prepare (cocos2d-js-v3.13.js:1256)
    at cocos2d-js-v3.13.js:1268

I can not find any implementation about the function addDataFromBinaryCache, some one can help me?

else if(str === ".csb")
            ccs.dataReaderHelper.addDataFromBinaryCache(filePath, dataInfo);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant