Advertisement

Latest Box2D Activity

Advertisement
8Observer8
April 05, 2024 10:42 AM
How to set up Box2D-WASM with importmap and Rollup for JavaScript

​Playground: https://plnkr.co/edit/BGNYcIJRiJXpd9N4?preview

GitHub: https://github.com/8Observer8/how-to-set-up-box2dwasm-with-importmap-rollup-js

glMatrix is just a bonus:

index.html

<!DOCTYPE html>

<html lang="en">

<head>
    <meta charset="utf-8">
    <meta name="viewpor…
44,484 views
8Observer8
July 21, 2023 01:36 PM
The debug drawer of Box2D-WASM colliders using Melon.js and JavaScript

I added debug drawing of the circle collider using the Melon.js game engine and Box2D-WASM.

Live demo: https://8observer8.github.io/webgl10-js/debug-drawer-box2dwasm-melonjs-js/
GitHub repository: https://https://github.com/8Observer8/debug-drawer-box2dwasm-melonjs-js

Playgrounds/Sandboxes:

3,854 views

its_artem said:
Actually, I tried disabling the b2Bodies and setting their locations to the positions they would have fallen to, and they're still jittering.

Well, figuring out it's not because of physics is progress.

Just stating the obvious, but now you need to figure out what's the difference betwe…

5,224 views

Never used box2d, but as nobody else seems to have time, let's try.

I copy/pasted the code above and reformatted it to something readable. Compiling it fails with:

$ g++ something.cpp
something.cpp: In function ‘void AddBox(b2World&, int, int)’:
something.cpp:132:20: error: invalid conversion fro…
5,619 views

AntonioR said:
@SuperVGA Thanks. If you look at the textures you will actually find Abuse checkpoint texture there, but I did not implement checkpoints, because I did not finish the level. Back in 2012 I made a different Quake 2D game and everybody was also comparing it to Abuse, but I have not play…

5,645 views
8Observer8
January 29, 2021 11:48 PM
Usage of Planck.js with TypeScript (Planck.js is a port of Box2D Physics Engine)

My example shows how to use Ammo.js with TypeScript in Debug and Release modes: hello-planckjs-webgl10-ts

You should install these modules globally:

  • npm i typescript -g
  • npm i browserify -g
  • npm i uglify-js -g

Install all packages from `package.json` using the command: `npm i`

Comment/Uncomment Debug/Relea…

7,485 views
5 hours ago, Dirk Gregorius said:

Box2D does not use incremental manifolds, but builds full manifolds each frame. The contact and friction impulses are matched between frames using contact IDs. 

Erin has given a bunch of talks over the year which cover certain aspects o…

5,131 views

I think this is not correct if you mean general triangle meshes. Both SAT and GJK only work for collision/distance between *convex* polyhedra. Also, you use SAT for nearly all boolean overlap tests I am aware of. At least in a specialized form. It is the basic idea for these kind of tests. For di…

5,915 views
desdemian
April 14, 2018 07:54 PM
Working on the AI, a coreographic fight.

This week was full work on the AI, which was lacking a bit, to say the least. It is a simple state machine that changes based on the distance to the character (far? jump, close? punch/kick) and its own physical state (falling? stucked? idling? close to edge?).

Eventually I managed to make se…

3,060 views
Understanding Constraint Resolution in Physics Engine

Original Post: Limitless Curiosity

Out of various phases of the physics engine. Constraint Resolution was the hardest for me to understand personally. I need to read a lot of different papers and articles to fully understand how constraint resolution works. So I decided to write this article t…

31,287 views
Advertisement
Advertisement