How to use the planck-js.Circle function in planck-js

To help you get started, we’ve selected a few planck-js examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github grtlr / bubble-treemaps / src / implementation / algorithm / layoutplanck.js View on Github external
layerCluster.nodes.forEach(function(circle) {
        let centerGlobal = planck.Vec2(circle.x, circle.y);
        let centerLocal = centerGlobal.sub(bodyCentroid);
        let fixture = body.createFixture(planck.Circle(centerLocal, circle.r + circle.planckPadding), circleFD);


2D JavaScript physics engine for cross-platform HTML5 game development

Latest version published 3 years ago

Package Health Score

64 / 100
Full package analysis