Physics not working on Android?(CocoonJS)

0 favourites
From the Asset Store
2D fighting template based in the game that defined the fighting games genre.
  • I met some problem when using physics behavior and exported to Android devices via cocoonjs. Have you guys have the same issue?

    CAPX here:

    https://dl.dropboxusercontent.com/u/1396615/SharkGame/waterfloating.zip

  • If you're using r127, it's a known problem. It's a beta release and problems are to be expected.

  • Ah ok. Thanks Asheley. Which version should I roll back to?

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • r126, the last stable release.

  • the project wont open in the previous version though?

  • theames - no, which is why you should always back up regularly, and especially before installing a beta update.

  • Ashley ok no problem

    i just set up a simple test in 129, create a sprite, apply physics

    handle the touch, apply impulse to the sprite, run in cocoon, no impulse with error

    tag touchnstart, result of expression this.body.getlocalcenter [undefined] is not a function

  • Physic not work in r129, i made a simple test physic and export to cocoonjs to test a boc2d native, but it's has error and just black screen.

  • Yep I have just try the new r129 and the game is crashing on Android and Cocoonjs.

  • Ashley

    I'm running R139 now, and when I export the project to Cocoonjs 1.4 using the accelerated physics. I hit a black screen and nothing happens. The Memory Log gives me some error about the Box 2d Physics, so I assume it has to be the accelerated physics, because the Standard Web Based physics still work when the file is exported.

    Its pretty crucial for our game performance on mobile, as it's obviously the physics that slows our game down. Any Idea how to fix this without having to switch back to the Standard Web Based physics?

  • BAnyBudde

    I understand your frustration, but this has been an issue for a while now, and is out of Scirra's hands for the time being. CocoonJS was updated which appears to have caused some errors.

    I'm sure the team are working as hard as they can to make sure things are smooth. For now, you'll either have to switch to the older physics engine with Cocoon, or just wait a little longer.

    I've been waiting for this for approximately 3 months... but it's given me a lot of time to polish up my game.

    Sorry I couldn't be more help.

  • AnD4D

    Yeah, we have been waiting for 3 months too :)

    Unfortunately I am very impatient ha ha

    I am sure they must be working very hard, I was just under the impression that the Accelerated Physics were up and running, It seems like that was posted for the R138 update.

    Just trying to find out if I'm unaware of a certain issue regarding this problem.

    Anyhoo, Thanks for the reply

    Always much appreciated.

    And be sure to let us know what your game is called.

    Kind Regards

  • BAnyBudde

    I understand your frustration, but this has been an issue for a while now, and is out of Scirra's hands for the time being. CocoonJS was updated which appears to have caused some errors.

    I'm sure the team are working as hard as they can to make sure things are smooth. For now, you'll either have to switch to the older physics engine with Cocoon, or just wait a little longer.

    I've been waiting for this for approximately 3 months... but it's given me a lot of time to polish up my game.

    Sorry I couldn't be more help.

    How do you switch back to "OLDER PHYSICS ENGINE with cocoon"

    Would appreciate your input. Thanks

    <img src="smileys/smiley17.gif" border="0" align="middle" />

  • Just found the problem I was having. Seems like a referencing error in the code that is generated by Construct 2.

    I was getting the problem "TypeError: 'undefined' is not an object ('evaluating window.Box2D.Dynamics')

    unzipped my Cocoon export file.

    1. Unzipped my Cocoon export zip file
    2. Opened the c2runtime.js file
    3. Searched for "window.Box2D"
    4. Deleted the "window." portion. As the window object doesnt' tie to Box2D as far as I can tell from the rest of the code
    5. zipped everything back up. (make sure you zip all the files to the root of the zip, else the runtime will fail)
    6. Upload you app and test
    7. hopefully it's all working!

    <img src="smileys/smiley4.gif" border="0" align="middle" />

  • just noticed that there is a physics engine property on the cocoon object.....

    guess that's what you guys meant?

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)