/** Set the mass properties to override the mass properties of the fixtures. Note that this changes the center of mass position. * Note that creating or destroying fixtures can also alter the mass. This function has no effect if the body isn't dynamic. * @param data the mass properties. */ public void setMassData (MassData data) { massData2.center.set(data.center.x, data.center.y); massData2.I = data.I; massData2.mass = data.mass; body.setMassData(massData2); }
md.mass = massPerParticle; md.I = 1.0f; b.setMassData(md); b.setSleepingAllowed(false); liquid[i] = b;
md.mass = massPerParticle; md.I = 1.0f; b.setMassData(md); b.setSleepingAllowed(false); liquid[i] = b;