Problem with Box2D

Welcome to our brand new Clickteam Community Hub! We hope you will enjoy using the new features, which we will be further expanding in the coming months.

A few features including Passport are unavailable initially whilst we monitor stability of the new platform, we hope to bring these online very soon. Small issues will crop up following the import from our old system, including some message formatting, translation accuracy and other things.

Thank you for your patience whilst we've worked on this and we look forward to more exciting community developments soon!

Clickteam.
  • I have just started working with Box2d and came upon a problem i dont know how to solve. I have boxes that fall from the sky and build up at the bottom.

    Then i have another event to create bombs at the main caracter and when the bomb explodes it creates a cirkle zone that destroyes any shapes in its zones.

    It works great as long as this zone is inside the frame area.

    If the zone is a bit outside the frame area and i guess the "world body" the game bugs though. For some reason it seems to destroy all shapes in the frame and all collisions of all physics objects stop to work and they just continue to fall through the frame.

    Why is this and how can i solve it?

    Steam games: Please login to see this link.

  • Hard to tell without seeing your code. Are you perhaps removing the ground body? Do you have any event controlling what bodies are destroyed or are you removing any body that happens to be within the zone? It could also be an object picking issue if you are using the object interface.

    //Jonas
    Please login to see this link.

  • Quote from Werbad

    Hard to tell without seeing your code. Are you perhaps removing the ground body? Do you have any event controlling what bodies are destroyed or are you removing any body that happens to be within the zone? It could also be an object picking issue if you are using the object interface.


    Its the same event happening when the remove zone is within the world body and then it works. The problem happens when a part of that zone is outside the world body.

    The event destroyed any bodies within the zone.

    Steam games: Please login to see this link.

  • The only cause I can think of is that you might be removing the world body if the destruction zone touches one of the boundary line segments. The easiest way for me to find the cause would be if you could upload an application showing the problem for me to look at.

    //Jonas
    Please login to see this link.

  • Quote from Werbad

    The only cause I can think of is that you might be removing the world body if the destruction zone touches one of the boundary line segments. The easiest way for me to find the cause would be if you could upload an application showing the problem for me to look at.


    I would be gratefull if you could look at it Werbad, just sent you a pm! :) Ha det bra så länge ;)

    Steam games: Please login to see this link.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!