Questions tagged [jbox2d]

JBox2D is a Java physics engine often used in games an other physics simulations and is a port/extension of the C++ physics engine, Box2D.

JBox2D is a physics engine for Java often used in games and other physics simulations, and is a port/extension of the C++ physics engine, Box2D.

Questions

Questions with the jbox2d tag should be specifically about JBox2D and its implementation. Questions about the physics engine in general should be tagged with box2d as well.

Brief Definitions

  • World contains the physics environment for a simulation
  • Body is a physics entity with any number of child fixtures. These fixtures are treated as all part of the same physics object, and will interact accordingly (they won't break up). Bodies also provide support for user-applied forces and torque.
  • Fixture contains a single shape and information about it (for example, friction and restitution).
  • Shape contains information about the basic physical properties of the physics object. (for example, the vertices of the polygon shape)
  • Joint is basically a way of adding constraints to different bodies. There are a variety of joints, including revolute, distance, and prismatic joints.

Links

JBox2D

Box2D

183 questions
-1
votes
1 answer

java jbox2D PolygonShape set position

I develop jbox2d (java) and I have a problem when I create a polygon shape. I can not choose the position of my polygon, there is a field "m_centroid" I defined as the center of my window. The polygon remains in the left corner. public class Player…
jeyGey
  • 67
  • 3
-1
votes
1 answer

JBOX2d: restart a game

can anyone show the correct code to reset a game when using physics engine (JBOX2D)? I am working on a game using Processing and I am unable to reset the game so that the user can play another round. Thanks in advance
1 2 3
…
12
13