Particle troubles placement wrong?
by Mike Rowley · in Torque Game Engine Advanced · 04/06/2008 (8:12 am) · 7 replies
I have some default particle emitters I'm using to simulate water vapor under a waterfall. My waterfall is nothing more than a box with an IFL attached. I placed the partcle emitters at the base of the fall, and just in front of it, but for some reason, in TGEA 1.7.0 they don't render properly. (may be a bug, but just in case it's me messing up again, I put this here) ((this works perfectly in tge 1.5.2))
The following images will show you what I'm talking about:
Players view from the front
Free flight from above
Free flight from the side
Editor view showing the placement of the nodes
I'm using the following sky block:
Note windEffectPrecip is turned off.
Here is the default chimney smoke I'm using:
and my .mis file info:
(1 of several)
I don't understand why this isn't working like it should. Any help in figureing this out would be greatly appreciated.
My system specs are:
[code]
Windows XP home sp2
AMD Athlon 64
1.0 gb ram
nVidia GeForce 6800 xt (latest drivers)
The following images will show you what I'm talking about:
Players view from the front
Free flight from above
Free flight from the side
Editor view showing the placement of the nodes
I'm using the following sky block:
new Sky(SkyObject) {
canSaveDynamicFields = "1";
Enabled = "1";
position = "336 136 0";
rotation = "1 0 0 0";
scale = "1 1 1";
materialList = "scriptsAndAssets/data/skies/sky_skybox.dml";
cloudHeightPer[0] = "0";
cloudHeightPer[1] = "0";
cloudHeightPer[2] = "0";
cloudSpeed1 = "0";
cloudSpeed2 = "0";
cloudSpeed3 = "0";
visibleDistance = "800";
fogDistance = "20";
fogColor = "0.8 0.8 0.9 1";
fogStorm1 = "0";
fogStorm2 = "0";
fogStorm3 = "0";
fogVolume1 = "0 0 0";
fogVolume2 = "0 0 0";
fogVolume3 = "1 1 1";
windVelocity = "0 0 0";
SkySolidColor = "0.6 0.6 0.6 1";
useSkyTextures = "1";
renderBottomTexture = "0";
noRenderBans = "0";
renderBanOffsetHeight = "50";
skyGlow = "0";
skyGlowColor = "0.557279 -0.635902 0.533987 -0.557212";
fogVolumeColor1 = "128 128 128 -2.22768e+038";
fogVolumeColor2 = "128 128 128 0";
fogVolumeColor3 = "128 128 128 -1.70699e+038";
windEffectPrecipitation = "0";
};Note windEffectPrecip is turned off.
Here is the default chimney smoke I'm using:
datablock ParticleData(ChimneySmoke)
{
textureName = "~/data/shapes/particles/smoke";
dragCoefficient = 0.0;
gravityCoefficient = -0.2; // rises slowly
inheritedVelFactor = 0.00;
lifetimeMS = 3000;
lifetimeVarianceMS = 250;
useInvAlpha = false;
spinRandomMin = -30.0;
spinRandomMax = 30.0;
colors[0] = "0.6 0.6 0.6 0.1";
colors[1] = "0.6 0.6 0.6 0.1";
colors[2] = "0.6 0.6 0.6 0.0";
sizes[0] = 0.5;
sizes[1] = 0.75;
sizes[2] = 1.5;
times[0] = 0.0;
times[1] = 0.5;
times[2] = 1.0;
};
datablock ParticleEmitterData(ChimneySmokeEmitter)
{
ejectionPeriodMS = 20;
periodVarianceMS = 5;
ejectionVelocity = 0.25;
velocityVariance = 0.10;
thetaMin = 0.0;
thetaMax = 90.0;
particles = ChimneySmoke;
};
datablock ParticleEmitterNodeData(ChimneySmokeEmitterNode)
{
timeMultiple = 1;
};and my .mis file info:
new ParticleEmitterNode(fallsSplash1) {
canSaveDynamicFields = "1";
Enabled = "1";
position = "-388.297 -379.112 213.455";
rotation = "0 0 1 209.13";
scale = "1 1 1";
dataBlock = "ChimneySmokeEmitterNode";
emitter = "ChimneySmokeEmitter";
velocity = "1";
};(1 of several)
I don't understand why this isn't working like it should. Any help in figureing this out would be greatly appreciated.
My system specs are:
[code]
Windows XP home sp2
AMD Athlon 64
1.0 gb ram
nVidia GeForce 6800 xt (latest drivers)
#2
Thanks Jeff. You've given me a direction to look. :-)
04/08/2008 (3:45 pm)
Ok, thanks. The water isn't transperant, but a few minutes woth of PSP will fix that. i'll also check the bounding box for the water and see if they are overlapping. It is possible as I've rotated the water block to fit the mountain. Thanks Jeff. You've given me a direction to look. :-)
#3
04/08/2008 (4:40 pm)
I didn't realize the waterfall was actual water blocks. I believe they have their own special-case render order, which I don't know a lot about. Particles sort pretty well with normal water. Perhaps the reorientation of the water throws off the ordering.
#4
3dcentral.net/myPic/Relto/waterfall_inspect.jpg
This shows the bounding box. Is there a way to fix that? The images (all 22) now are set at 70% transperant, (which looks much better) and the particles are looking better, but still show behind the falls.
Gahh...fixed the image to be a link as the image command isn't working.
04/08/2008 (5:21 pm)
No, the waterfall is an object with an ifl attached. 3dcentral.net/myPic/Relto/waterfall_inspect.jpg
This shows the bounding box. Is there a way to fix that? The images (all 22) now are set at 70% transperant, (which looks much better) and the particles are looking better, but still show behind the falls.
Gahh...fixed the image to be a link as the image command isn't working.
#5
04/09/2008 (5:20 am)
You need to make the bounding-box fit tightly around the waterfall, especially on the side where the emitters are. It might also help if you adjust the particle emitters to spray forward a little, out from the waterfall. This will extend their boxes out a bit.
#6
Thanks for you help. :-)
04/10/2008 (3:54 pm)
I have no clue how to resize the bounding box. This dts object was added to the world, rotated to fit the space, then saved. I resized the particles and solved my problem tho. Thanks for you help. :-)
#7
04/11/2008 (9:41 am)
You would do that in your modeling program where you created the box.
Associate Jeff Faust
Faust Logic, Inc.
In torque, transparent objects are sorted by the distance of the closest point on their axis-aligned-bounding-box and the camera. All particles in an emitter are sorted in a clump based on the emitter's bounding box.
With this info, you should observe how the bounding-boxes of the emitters relate to the bounding-boxes of your water. It might explain the sorting order you are observing.