I'm using LiquidFun to simulate water, it's a physics engine based on box2d that uses particles. My problem is when rendering the particles with a specific color.
what is the purpose of setting the particle color on it's particle definition? when you also have to set the color on which the particle is to be rendered on the ParticleDebugRenderer.
public void createWater(float x, float y){
ParticleDef def = new ParticleDef();
def.color.set(Color.Red); //set particle color
def.flags.add(ParticleDef.ParticleType.b2_tensileParticle);
def.flags.add(ParticleDef.ParticleType.b2_colorMixingParticle);
def.position.set(x, y);
int index = system.createParticle(def);
}
ParticleDebugRenderer:
pdr = new ParticleDebugRenderer(Color.BLUE, maxParticles); //set as BLUE
if I set the particle to be RED it would still be rendered in blue because the ParticleDebugRenderer is set to BLUE.