I got a problem with the ParticleMesh. I try to make a rocket tail - it looks fine but I get ParticleSpawn on (0,0,0) every time I launch a rocket - i really dont know how to explain that.
pMesh.setRenderState(VisualCtrl.getTexture("flare")); // set a TextureState
pMesh.setRenderState(as1); // set to a simple BlendingState
pMesh.setRenderState(zstateOFF); // set ZBuffer OFF
pMesh.setRenderState(VisualCtrl.getTexture("flare")); // set a TextureState
pMesh.setRenderState(as1); // set to a simple BlendingState
pMesh.setRenderState(zstateOFF); // set ZBuffer OFF
Usually when you're dealing with specific components (eg. particles) it's a good idea to try to reproduce the error in a SimpleGame test. There's a pretty good chance you'll fix it in the process, or if not it's much easier for someone else to look at the problem.
Here is a example which I think shows the problem you describe:
/**
* @param args
*/
public static void main(String[] args) {
ScratchSimple app = new ScratchSimple();
app.setConfigShowMode(ConfigShowMode.AlwaysShow);
app.start();
}
}
If you uncomment the updateGeometricState that should fix the problem. If this is the same problem maybe that will give you some ideas. Probably you have warmed it up and updated before setting its location and updating. This will spawn some particles at the origin.