Giter VIP home page Giter VIP logo

Comments (3)

Birch-san avatar Birch-san commented on August 22, 2024

yeah, I think you're right.

JSContactListenerWithoutSolveCallbacks was a quick, untested attempt of mine to satisfy this TODO from box2d.js:
https://github.com/kripken/box2d.js/blob/1e6e9da36a3160a9f40cda4cddcb4f83abb4d82c/Box2D_v2.3.1.idl#L33-L35

hmm, I also see that their [JSImplementation="b2ContactListener"]s clash.

I think the best solution is to just delete JSContactListenerWithoutSolveCallbacks — the performance problem it was designed to solve (eliminating WASM->JS calls) is not a problem nowadays.

if you construct a b2ContactListener, I'm not sure (because of the clash) whether you'll end up with a JSContactListener or a JSContactListenerWithoutSolveCallbacks. if it's the former (i.e. solve callbacks are included), then I think this isn't very consequential (because you can implement the solve callbacks as a no-op if you want to ignore them). but if it's calling the latter, then solve callbacks won't be called, which is a bigger problem.

are you trying to use solve callbacks, and are they not working?

from box2d-wasm.

BlueNebulaDev avatar BlueNebulaDev commented on August 22, 2024

I've been using JSContactListener and PreSolve and PostSolve are called, so everything works correctly with that class.

from box2d-wasm.

Birch-san avatar Birch-san commented on August 22, 2024

v7.0.0 deletes JSContactListenerWithoutSolveCallbacks.

from box2d-wasm.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.