Error 5000 when switching scene, FB instant

Hi all, When I deploy game to FB instant. When switching scene using cc.director.loadScene, sometime the game crash. When I check log It print error 5000 endlessly and non-stop. I am using cocos creator 2.4.6. Thanks for reading my post!

1 Like

I can ask engineering


You can check your code where destory a object twice or more.

I don’t manually destroy object, just switching scene like this

  cc.assetManager.getBundle('main').loadScene(sceneName, (err, scene) => {
    cc.director.loadScene(sceneName, () => {
      // some code

The crash happen not so frequently, I am not sure how to reproduce it, and for now I can only see the crash occur on FB Instant build. I will investigate more on this problem, maybe I coded wrong or something.

You load scene twice in this code,

you may run scene after load in bundle, like this:

Sorry for the late reply. The problem still pesist after I change my code to use runScene. It still happen sometime while testing. I hope I will find the root cause soon.

You have to be a little patient to find the time to report this error.

I have found some article about this
I selected all module in module config and the problem is gone.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.