Particles & Shapes
Introduction
When writing particle scripts you use shapes to describe the source or velocity of a particle system. These parameters aren't very straight forward and it can be quite confusing trying to figure them out as you go. Here's my attempt at clearing things up.
Shapes and Their Parameters
In Doom 3 the shapes available are lines, spheres, boxes, cylinders, cones, planes, gaussian blobs and points. Let's go over each shape and it's parameters. We will use the command initialVelocity in these examples.
Point

...
Definition: This shape defines a point in space using x, y and z coordinates.
...
Syntax:
Code:
initialVelocity ( shape, x, y, z)
...
Example:
Code:
initialVelocity ( point, 0, 0, 0)
Line
...
Definition: This shape defines two points in space using separate x, y and z coordinates. Both points form a line.
...
Syntax:
Code:
initialVelocity ( shape, x1, y1, z1, x2, y2, z2)
...
Example:
Code:
initialVelocity ( line, -10, -10, -10, 10, 10, 10)
Sphere (Does not work as intended)

...
Definition: This shape defines a point in space using x, y and z coordinates. Two radius are defined to form two spheres. Particles are spawned between these two spheres.
...
Syntax:
Code:
initialVelocity ( shape, x, y, z, r1, r2)
...
Example:
Code:
initialVelocity ( sphere, 0, 0, 0, 10, 20)
NOTE: For some reason, even in Id's particle effects, the sphere shape doesn't really draw a sphere at all. Instead it draws a diagonal line.
If you try using it yourself though you see that the parameters do work in the manner posted above, it just doesn't draw a sphere like it suggests. Perhaps it's a bug or the code is incomplete?
Box
...
Definition: This shape defines two points in space using x, y and z coordinates. The points represent two opposite corners that are used to form a box.
...
Syntax:
Code:
initialVelocity ( shape, x1, y1, z1, x2, y2, z2)
...
Example:
Code:
initialVelocity ( box, -10, -10, -10, 10, 10, 10)
Cylinder
...
Definition: This shape defines two points in space using x, y and z coordinates. Two radius are defined to form two cylinders. Particles are spawned between these two cylinders.
...
Syntax:
Code:
initialVelocity ( shape, x1, y1, z1, x2, y2, z2, r1, r2)
...
Example:
Code:
initialVelocity ( cylinder, 0, 0, -30, 0, 0, 30, 30, 60)
Cone
...
Definition: This shape defines two points in space using x, y and z coordinates. Two radius are defined to form two cones. Particles are spawned between these two cones.
...
Syntax:
Code:
initialVelocity ( shape, x1, y1, z1, x2, y2, z2, r1, r2)
...
Example:
Code:
initialVelocity ( cone, 0, 0, -30, 0, 0, 30, 30, 60)
Gaussian Blobs (Does not work as intended)

...
Definition: This shape defines two points in space using x, y and z coordinates. Two radius are defined to form two spheres. (At the moment, the game will only accept the parameters for a single point and radius.) These spheres are used to form a blob similar to a nurbs surface.
...
Syntax:
Code:
initialVelocity ( shape, x, y, z, r)
...
Example:
Code:
initialVelocity ( blob, 0, 0, 0, 20)
NOTE: This shape behaves nothing like the diagram above and the syntax, although correct, cannot possibly form the shape in the diagram.
As you can see from the syntax above, you can only define a single point and radius. This means that if blob was used in this manner it would create a sphere because there are no other points to influence the shape.
I've tried all sorts of things to input a second point and radius but to no avail. The game will reject any blob shape with more than 4 parameters.
This isn't all. Blob can't even draw a sphere correctly. Instead you get a shape like this from a single point.

Again, I'm guessing it's a bug or the code is incomplete.
Plane
...
Definition: This shape defines three points in space using x, y and z coordinates. The fourth point is calulated and a plane is formed.
...
Syntax:
Code:
initialVelocity ( shape, x1, y1, z1, x2, y2, z2, x3, y3, z3 )
...
Example:
Code:
initialVelocity ( plane, 0, 0, -10, 0, 50, -10, 50, 0, -10 )
NOTE: Each successive points' position is in relation to the last point. For instance if the absolute position of point 1 is 0,0,0; point 2 is 0,10,10; and point 3 is 0,10,20; then the parameters would be...
Code:
initialVelocity( plane, 0, 0, 0, 0, 10, 10, 0, 0, 10 )
Conclusion
Hopefully this is enough to familiarize you with the shape parameters and in conjunction with bullet's particle tutorials you should be well on your way to creating unique particle effects.
Comments and critiques are welcome.
I was thinking of doing one like this, but you did a much better job than I could have with your 3D representations. One thing though: you left out the Gaussian Blob. I have a bunch of notes on the thing laying around here that I could type up if anyone's interested in using it.
I've added the section on Gaussian Blobs even though it seems that it does not behave as intended.
I guess the reason the sphere and blob do not work correctly is because we are dealing with the alpha. Hopefully this gets ironed out before the retail release.
Added the section on planes. The parameters are damn confusing on that one. Why did they make all the coordinates relative on this shape yet absolute on the rest of the shapes? It would have been easier if they were all absolute.