If it helps, I just made a glow affect; I'm working on a sort of cloud thing.. which is hard to describe, but at the moment it's a ball of random glowing balls so might be similar to what you're after.
This is an object that glows:
class CloudParticleGlow extends Object3D {
private static final long serialVersionUID = 1L;
private static Object3D glow = null;
private static float offset = 1.8f;
private static float zoffset = 0.4f;
CloudParticleGlow(String texture) {
super(glow);
glow = new Object3D(2);
glow.addTriangle( new SimpleVector( -offset, -offset, -zoffset ), 0, 0,
new SimpleVector( -offset, offset, -zoffset ), 0, 1,
new SimpleVector( offset, offset, -zoffset ), 1, 1,
TextureManager.getInstance().getTextureID( texture ) );
glow.addTriangle( new SimpleVector( offset, offset, -zoffset ), 1, 1,
new SimpleVector( offset, -offset, -zoffset ), 1, 0,
new SimpleVector( -offset, -offset, -zoffset ), 0, 0,
TextureManager.getInstance().getTextureID( texture ) );
glow.setBillboarding(Object3D.BILLBOARDING_ENABLED);
glow.setTransparency(5);
glow.setLighting(Object3D.LIGHTING_NO_LIGHTS);
glow.setAdditionalColor(new RGBColor(255, 255, 255));
glow.build();
}
}
This is an invisible "container" that I made the parent of my glow object:
class CloudParticle extends Object3D {
private static final long serialVersionUID = 1L;
private static Object3D particle = null;
static {
particle = Primitives.getCone(0.3f);
particle.setTransparencyMode(Object3D.TRANSPARENCY_MODE_ADD);
particle.setTransparency(0);
}
CloudParticle() {
super(particle);
}
}
I created an array of each, with both arrays the same size; I make each Particle the parent to the equivalent Glow, and I make every first item in the particle array the parent of all other particles:
particles = new CloudParticle[particleCount];
glow = new CloudParticleGlow[particleCount];
for (int i = 0; i < particleCount; i++) {
String texture = "glowgreen";
switch (rand.nextInt(3)) {
case(0):
texture = "glowred";
break;
case(1):
texture = "glowblue";
break;
case(2):
texture = "gloworange";
break;
}
particles[i] = new CloudParticle();
glow[i] = new CloudParticleGlow(texture);
particles[i].addChild(glow[i]);
world.addObject(particles[i]);
world.addObject(glow[i]);
if (i > 0) {
particles[0].addChild(particles[i]);
}
I can then rotate or move an individual particle or all to move individual glows, or I can move the central particle to move everything.
This is in progress but I think with the right texture and movement could be expanded for fire / explosion.
[attachment deleted by admin]