2
votes
1answer
96 views

Separation algorithm in flock simulation?

I'm using box2d (the c++ one). I found a method for an arriving behavior (on http://www.red3d.com/cwr/steer/gdc99/ ), which works well, problem is, the bodies are bumping into each other and it ...
2
votes
1answer
98 views

Efficiently storing game states history for physics?

I would like to store the history of a box2d simulation. Currently I can't find any built-in mechanism for that. I need to store the states of all non static objects in the last second, mainly for ...
5
votes
3answers
125 views

What could cause a sudden stop in Box2D?

I'm using Box2d for a game, and I have a bug that's driving me nuts. I've simplified the situation down to a square player sliding back and forth frictionlessly on top of a floor composed of a series ...
0
votes
1answer
80 views

How to get the Exact Collision Point and ignore the collision (from 2 “ghost bodies”)

I have a very basic problem with Box2D. For a arenatype game where you can throw scriptable "missiles" at other players I decided to use Box2D for the collision detection between the players and the ...
1
vote
1answer
385 views

Check for bodies within a specific circle in Box2D

I'm trying to find positions to insert new bodies into my world. For that, I'd like to have a "free" spot where this body wouldn't overlap with anything else. So my plan was to sample "random" ...
1
vote
1answer
316 views

How to fake flipping a skeleton in Box2D?

Imagine I have a skeleton — that is a set of bodies held together through various constraints and joints — and I want to flip it. Bodies cannot be flipped in Box2D, so how can I fake that? ...
0
votes
0answers
217 views

Box2D high-level c++ wrapper

Is there a high level wrapper around Box2D out there? I know that the library isn't exactly very low level as-is, but in my opinion some things in the library could be made more intuitive at the cost ...
5
votes
1answer
206 views

Rectangles render with gaps in between them (Box2D)

Right now I create my boxes where 1 meter is 85 pixels. Gravity is 10. And fixtureDef.restitution = 0.1f; fixtureDef.friction = 0.5f; ...
2
votes
1answer
460 views

Setting the Box2D gravity for a pixel coordinate game?

I'm making a game with Box2D with a top left coordinate system. I multiply positions by an M_TO_PX_RATIO of 10.0f to convert from meters to pixels. I noticed that when I set gravity to 9.8, the ...
2
votes
2answers
496 views

2D AI Engines/ Resources?

i'm wondering if there's any 2D AI source code or engines out there. I'm inspired by the Euphoria engine, and want to use whatever is already out there to make something like it in 2D, where the ...
7
votes
6answers
360 views

Determining player.isFalling() through change of y?

I'm currently using Box2D and my character is a bunch of fixtures in Box2D. I was wondering if, to determine if a player is falling, detecting a change in Y position would be appropriate? Are there ...
5
votes
2answers
2k views

Is it worth it to use Bullet for 2D physics instead of Box2D for the sake of learning Bullet?

There isn't much more to the question. I'm not concerned about overhead, as I'm sure they are both fine for my purposes. Basically, I am familiar with Box2D concepts because of the Farseer Physics ...
7
votes
1answer
376 views

How can I copy or back-calculate definitions for an entire b2World?

I'm working on a platformer where I'd like to be able to move or copy bodies between multiple Box2D b2Worlds. The desire has cropped up three times now - moving objects between documents in my editor, ...