TOC:
1.0 Action Menu Based Edits
1.1 Change to Particle Effect X
1.2 Start/Stop Particle Effect X
1.3 Attach/Detach Particle Effects to/from
Squadmate
1.4 Reset to Defaults
2.0 Dialog Based Edits
2.1 Particle Circle Dialog
2.1.1 Radius
2.1.2 Velocity
0
2.1.3 Velocity
1
2.1.4 Velocity
2
2.2 Particle Params Dialog
2.2.1 ShapeName
0
2.2.2 ShapeName
1
2.2.3 ShapeName
2
2.2.4 ShapeName
3
2.2.5 Animation
Name
2.2.6 Type
2.2.7 Timer
Period
2.2.8 Life Time
2.2.9 Position
0
2.2.10 Position
1
2.2.11 Position
2
2.2.12 MoveVelocity
0
2.2.13 MoveVelocity
1
2.2.14 MoveVelocity
2
2.2.15 Rotation
Velocity
2.2.16 Weight
2.2.17 Volume
2.2.18 Rubbing
2.2.19 Size
2.2.20 Color
2.2.21 Animation
Phase
2.2.22 Random
Direction Period
2.2.23 Random
Direction Intensity
2.2.24 On Timer
2.2.25 Before
Destroy
2.2.26 Object
2.3 Particle Random Dialog
2.3.1 LifeTime
2.3.2 Position0
2.3.3 Position1
2.3.4 Position2
2.3.5 MoveVelocity0
2.3.6 MoveVelocity1
2.3.7 MoveVelocity2
2.3.8 RotationVelocity
2.3.9 Size
2.3.10 Color0
2.3.11 Color1
2.3.12 Color2
2.3.13 Color3
2.3.14 RandomDirectionPeriod
2.3.15 RandomDirectionIntensity
2.4 Drop Interval and Object Height Dialog
2.4.1 Drop Interval
2.4.2 Object
Height
2.5 Show Fully Formatted Commands Dialog
2.6 Import Dialog
3.0 Misc Tips
4.0 Foreign Languages
1.0 Action Menu Based Edits:
1.1 Change to Particle Effect X:
This utility
supports up to 5 particle effects running at a time.
This is to facilitate
creating more complex compound particle
effects.
All of the dialogs will only modify the currently selected
particle effect.
The only option that modifies all five effects at
the same time
is "Attach Particle Effects to Squadmate"/"Detach
Particle Effects
from Squadmate" (see below for details on that).
1.2 Start/Stop Particle Effect X:
Simply starts
or stops the current particle effect. When the utility
first loads,
particle effect 1 is the only effect actively running.
1.3 Attach/Detach Particle Effects to/from
Squadmate:
This command
attaches *all* the particle effects to your squadmate.
If your squadmate
is in a vehicle, it attaches them to the vehicle.
If your squadmate
is dead (itchy trigger finger huh? ;) ), they go
back to the
standard location.
1.4 Reset to Defaults:
Resets the current
particle effect to the initial values.
2.0 Dialog Based Edits:
2.1 Particle Circle Dialog:
2.1.1 Radius:
This Field's behavior is not what one might expect. One may
think, off hand, that this means that each particle will appear
somewhere within X meters of the center. However, what it
really does, is make each particle appear at the rim of an X
meter radius circle centered on the position/object. This is
also forces the particle effect to always start on the ground or
surface of the water. For a simple example of what exactly this
does: reset particle effect 1 to the default, set this parameter
to 5 and just view it from a few angles.
2.1.2 Velocity
0:
Adds spin to the Particle Circle Positive is clockwise (from top
down) and negative is counter clockwise. This parameter seems
to have no effect if the radius above is not set.
2.1.3 Velocity
1:
Modifies the direction of movement towards and away from the
center of the circle. Positive is away from the center, and
negative is towards the center This parameter seems to have no
effect if the radius above is not set.
2.1.4 Velocity
2:
Modifies the direction of movement vertically. Positive is up
and negative is down. This parameter seems to have no effect if
the radius above is not set.
2.2 Particle Params Dialog
2.2.1 ShapeName
0:
This is the resource to use. It is in convenient drop down menu
format, so you don't have to sit there and type an exactly
correct string into a box. The downside to this is that it
makes it more difficult to try and use something that wasn't
packaged with the game as a particle effect.
If you would like to add another resource to this drop down
menu, you have to edit the variable ValidShapeNamesArray in
init.sqf, line 29.
Change the following:
//Valid shapenames, straight from the wiki
ValidShapeNamesArray =
[
"\Ca\Data\ParticleEffects\Blood\Blood.p3d",
"\Ca\Data\Cl_basic.p3d",
"\Ca\Data\Cl_fire",
"\Ca\Data\Cl_fired",
"\Ca\Data\Cl_water",
"\Ca\Data\ParticleEffects\CloudletSand\CloudletSand.p3d",
"\Ca\Data\ParticleEffects\CloudletWater\CloudletWater.p3d",
"\Ca\Data\ParticleEffects\FireAndSmokeAnim\FireAnim.p3d",
"\Ca\Data\kouleSvetlo",
"\Ca\Data\krater_po_kulce",
"\Ca\Data\missileSmoke",
"\Ca\Data\ParticleEffects\Pstone\Pstone.p3d",
"\Ca\Data\RainDrop",
"\Ca\Data\ParticleEffects\RocketSmoke\RocketSmoke.p3d",
"\Ca\Data\ParticleEffects\FireAndSmokeAnim\SmokeAnim.p3d",
"\Ca\Data\ParticleEffects\SparksEffect\SparksEffect.p3d",
"\Ca\Data\ParticleEffects\Watereffects\WaterEffects.p3d"
];
to this:
ValidShapeNamesArray =
[
"\MyModelsPath\MyModel.p3d",
"\Ca\Data\ParticleEffects\Blood\Blood.p3d",
"\Ca\Data\Cl_basic.p3d",
"\Ca\Data\Cl_fire",
"\Ca\Data\Cl_fired",
"\Ca\Data\Cl_water",
"\Ca\Data\ParticleEffects\CloudletSand\CloudletSand.p3d",
"\Ca\Data\ParticleEffects\CloudletWater\CloudletWater.p3d",
"\Ca\Data\ParticleEffects\FireAndSmokeAnim\FireAnim.p3d",
"\Ca\Data\kouleSvetlo",
"\Ca\Data\krater_po_kulce",
"\Ca\Data\missileSmoke",
"\Ca\Data\ParticleEffects\Pstone\Pstone.p3d",
"\Ca\Data\RainDrop",
"\Ca\Data\ParticleEffects\RocketSmoke\RocketSmoke.p3d",
"\Ca\Data\ParticleEffects\FireAndSmokeAnim\SmokeAnim.p3d",
"\Ca\Data\ParticleEffects\SparksEffect\SparksEffect.p3d",
"\Ca\Data\ParticleEffects\Watereffects\WaterEffects.p3d"
];
2.2.2 ShapeName
1:
Setting this parameter to 0 is likely to make the game crash to
the desktop. I do not check for this in the dialog scripts. As
a rule, I feel the user should be free to experiment. I don't
know everything and who knows? There may be a use for setting
this number to zero somewhere. Even if there isn't now, there
may be later.
This number should always be an integer.
This is the anim divisor. It should be 1 for a 1x1 tile particle
effect, 8 for an 8x8 tile particle effect, etc. If this number
is incorrect, it will most likely be highly visible, and just
not look very good at all.
In the tips section below, there's a hint to get this number
where you want it.
2.2.3 ShapeName
2:
This parameter is Ordinal, not Cardinal. This means start at 0,
not 1.
This number should always be an integer.
This is the Anim Starting Row, it picks the row, from the top
down, to start animating from.
In the tips section below, there's a hint to get this number
where you want it.
2.2.4 ShapeName
3:
This parameter is Cardinal, not Ordinal. This means start at 1,
not 0.
This number should always be an integer.
This is the Number of Number of Frames to Play, and should, in
most cases, be the number of effects available to the animation.
If you go over this, (for example selecting 9 in an tile
particle effect), it will start playing the animation frames of
the next effect down. If there is nothing below to grab, it will
draw a blank for that frame. If 1 is used, it will only play the
first frame of the selected row.
In the tips section below, there's a hint to get this number
where you want it.
2.2.5 Animation
Name:
I know this is supposed to be a string, pointing to a class
name. Presumably for animated doors, or some such thing. It
is
beyond the scope of this tool, and therefore not editable.
2.2.6 Type:
The is either Billboard or SpaceObject. It is in a convenient
drop down menu, so you don't have to type an exactly correct
string into a box.
Billboard draws the particle as a 2d object that always faces
the direction of the person looking at it. It is intended to be
used for all but one "straight out of the box" particle effect.
SpaceObject draws the particle as a 3d object that can have any
side facing the person viewing the particle. The only "straight
out of the box" particle effect designed to use this is
"\Ca\Data\ParticleEffects\Pstone\Pstone.p3d".
2.2.7 Timer Period:
Setting this number to 0 will likely cause the game to lock up
in pretty much all cases. I do not check for this in the dialog
scripts. As a rule, I feel the user should be free to
experiment. I don't know everything and who knows? There may be
a use for setting this number to zero somewhere. Even if there
isn't now, there may be later.
This controls the how often the "On Timer" parameter below is
executed.
2.2.8 Life Time:
The amount of time each particle will stick around before being
removed, in seconds.
2.2.9 Position
0:
The East-West starting position offset of each particle.
2.2.10 Position
1:
The North-South starting position offset of each particle.
2.2.11 Position
2:
The Up-Down starting position offset of each particle.
2.2.12 MoveVelocity
0:
The East-West starting velocity of each particle.
2.2.13 MoveVelocity
1:
The North-South starting velocity of each particle.
2.2.14 MoveVelocity
2:
The Up-Down starting velocity of each particle.
2.2.15 Rotation
Velocity:
How fast the object is "spinning". No visible effect unless it's
a space object.
2.2.16 Weight:
Part 1 of the particle's "Density". If this is 1.275, and the
Volume is 1, the particle will not rise or sink.
2.2.17 Volume:
Part 2 of the particle's "Density". If this is 1, and the
Weight is 1.275, the particle will not rise or sink.
2.2.18 Rubbing:
Modifies the amount of impact the in-game "wind" has on the
particle. Higher is more, lower is less. Partially linked to
weight above.
2.2.19 Size:
The game supports an unlimited number of size parameters
(theoretically anyways, probably not really though), this dialog
utility only supports 10, due to the practical limitations of a
dialog.
The first size parameter you pass is the starting size of each
particle. The last size parameter *you set* is the ending size
of the parameter.
If you set 3 sizes, the first is the starting size, the second
is the middle size, and the last is the ending size.
To select which size you are editing, click the + and - buttons
next to the size label.
Due to the practical limitations of a dialog, 0 is considered to
be no value. If for some reason, you need 0 to be the last
value, try setting it to nearly 0 instead. For example, try
0.00001 instead of simply 0. You can then change it to 0 in the
script you actually use the effect in.
2.2.20 Color:
The game supports an unlimited number of color parameters
(theoretically anyways, probably not really though), this dialog
utility only supports 10, due to the practical limitations of a
dialog.
The first color parameter you pass is the starting color of each
particle. The last color parameter *you set* is the ending
color of the parameter.
If you set 3 colors, the first is the starting color, the second
is the middle color, and the last is the ending color.
To select which color you are editing, click the + and - buttons
next to the color label.
The colors are linked, if color 3 is selected, red 3, blue 3,
green 3, and alpha 3 are all selected.
The colors used in game should be a decimal between 0 and 1. To
convert from standard windows 0-255 to arma 0-1, multiply the
number by 0.00392, it will be close enough for all practical
purposes.
To easily figure out what values are associated with any color
you have in mind:
Open MS Paint (Start->All Programs->Accessories->Paint).
Double click on any color in the color bar.
Click define custom colors.
Figure out what color you want.
Convert the red, green, and blue values listed to their arma
equivalents by multiplying each number by 0.00392.
Due to the practical limitations of a dialog, 0 is considered to
be no value. If for some reason, you need 0 to be the last
value, try setting it to nearly 0 instead. For example, try
0.00001 instead of simply 0. You can then change it to 0 in the
script you actually use the effect in. Note that since all the
colors are linked, if any of the values for the current color
are non-zero, the color is counted. For example, solid black
(Red: 0, Blue: 0, Green: 0, Alpha: 1) is not ignored since the
Alpha is non-zero.
Alpha is transparency.
2.2.21 Animation Phase:
Controls the animation speed of the effect. If ShapeName 3
above is 1, it will have no visible effect. 1 seems to play all
the selected frames in over the period of a second. 2 seems to
play all the selected frames twice in one second. 0.5 seems to
play half the animation frames in one second.
The game supports an unlimited number of animation phase
parameters (theoretically anyways, probably not really though),
this dialog utility only supports 10, due to the practical
limitations of a dialog.
The first animation phase parameter you pass is the starting
animation phase of each particle. The last animation phase
parameter *you set* is the ending animation phase of the
parameter.
If you set 3 animation phases, the first is the starting
animation phase, the second is the middle animation phase, and
the last is the ending animation phase.
To select which animation phase you are editing, click the + and
- buttons next to the animation phase label.
Due to the practical limitations of a dialog, 0 is considered to
be no value. If for some reason, you need 0 to be the last
value, try setting it to nearly 0 instead. For example, try
0.00001 instead of simply 0. You can then change it to 0 in the
script you actually use the effect in.
2.2.22 Random
Direction Period:
Makes the particle move in a completely random direction at a
regular interval. The lower this number is, the faster it
happens.
0 is off.
2.2.23 Random
Direction Intensity:
Controls the speed that the particle will move when the random
direction above changes.
2.2.24 On Timer:
Executes a script or code every time the timer period above is
hit. This parameter is beyond the scope of this project, and
therefore not editable.
2.2.25 Before
Destroy:
Executes a script or code just before each particle is removed.
This parameter is beyond the scope of this project, and
therefore not editable.
2.2.26 Object:
Controls the object that the effect is attached to. The only
way to edit this within this project is via the action menu.
See Attach/Detach Particle Effects to/from Squadmate above.
2.3 Particle Random Dialog
The formula used
is something along the lines of:
NewNumber =
(CurrentNumber + (ran (Modifier*2)) - (Modifier))
(this is a very
loose hypothesis based on observation alone):
So, if you're
wanting a value that should be between 0 and 1, set the
relevant initial
value in the particle params dialog (see below) to
0.5 and the
value here to 0.5.
If it's an array,
say size for example, it modifies each member of
the array by
the same value. So, if your size array looks like
[1,2,3,4,5]
and it's randomized to be +3, the final product is
[4,5,6,7,8].
2.3.1 LifeTime:
Alters the length of time each particle will be drawn.
2.3.2 Position0:
Modifies the East-West starting position of each particle.
2.3.3 Position1:
Modifies the North-South starting position of each particle.
2.3.4 Position2:
Modifies the Up-Down starting position of each particle.
2.3.5 MoveVelocity0:
Modifies the East-West starting velocity of each particle.
2.3.6 MoveVelocity1:
Modifies the North-South starting velocity of each particle.
2.3.7 MoveVelocity2:
Modifies the Up-Down starting velocity of each particle.
2.3.8 RotationVelocity:
Modifies the rotation velocity of each particle. No effect if
the particle is not a "Space Object" type.
2.3.9 Size:
Modifies the size of each particle.
2.3.10 Color0:
Modifies the red value of each particle.
2.3.11 Color1:
Modifies the green value of each particle.
2.3.12 Color2:
Modifies the blue value of each particle.
2.3.13 Color3:
Modifies the Alpha (transparency) value of each particle.
2.3.14 RandomDirectionPeriod:
Modifies the Random Direction Period of each particle.
2.3.15 RandomDirectionIntensity:
Modifies the Random Direction Intensity of each particle.
2.4 Drop Interval and Object Height Dialog
2.4.1 Drop Interval:
This is the amount of time effect source will wait before
spawning another particle.
The lower this number is, the less time it will wait, and the
more particles will appear.
The game *does* have a limit to the number of particles it will
draw at once. It may or may not be determined by the graphics
settings of the user. If the engine is past these limits, it
will stop drawing the oldest *particle* first, although the
particle source will remain perfectly intact, and will keep
pumping out particles as long as it's told to.
2.4.2 Object
Height:
This modifies the height of the gameLogic used as the target
object by default. This does not modify the height of your
squadmate, or any vehicle he's in.
This height is in meters.
2.5 Show Fully Formatted Commands Dialog:
This dialog shows
the commands needed to reproduce the currently
selected particle
effect.
You can copy
the contents of each box by highlighting the whole
contents and
pressing control+c. You can then paste that info into
your favorite
text editor for later use.
2.6 Import Dialog:
In this dialog,
there are 4 boxes labeled setParticleCircle,
setParticleRandom,
setParticleParams, and setDropInterval
respectively.
Using this dialog
is simple enough in theory. All you have to do,
ideally, is
copy code from another source (such as the biki particle
effect templates
page at
http://community.bistudio.com/wiki/ParticleTemplates
or a script)
into their respective
boxes and hit apply.
There are a few
things to be aware of, however.
1: Do not use single quotes (') in a line of code. These *will*
cause the game to error. This problem is not fixable unless BIS
includes some string manipulation functions in a patch. As of
this writing, there are no such functions and the methods of
manipulating a string rely on a combination of exploiting the
format command's string length limit and brute force. The brute
force bit is why importing is so slow. The rest is nearly
instantaneous.
2: Code is not accepted, as there is no practical method of
accounting for it here, and should be converted to solid
numbers/strings. For example, convert {ran 1} to a number
between 0 and 1 (0.5 if you want the mean average), then do the
import.
3: setParticleCircle, setParticleRandom, and setDropInterval
count the number of brackets and commas to figure out the number
of parameters passed. It will abort the import if the count is
wrong. There are no such checks on setParticleParams since it
uses multidimensional arrays and I'm lazy.
4: Importing just one of the fields, but not the others, is
accomplished by just inserting code into the relevant field and
hitting apply. For example: if you wish to import a
setParticleParams command, paste the command into the
setParticleParams field, leave the others blank, and hit apply.
5: Be sure you are putting the code to import in the correct
boxes.
6: The render parameters (see 2.2.19 Size, 2.2.20 Color and
2.2.21 Animation Phase above) only handle 10 of each parameter.
Any parameters past 10 should be ignored. In the unlikely event
that your particle effect has more than 10 of one of these, I
suggest simplifying it to 10. In the case of colors, that's 10
complete colors (max 40 parameters in total for color alone).
3.0 Misc Tips:
When setting ShapeName 0-3, it is hard sometimes
to know what you're
likely to want beforehand. Even if you
have a general idea, you may not
know exactly what numbers to use for ShapeName
1-3. This may help you out
in this case:
1: Import this
as a jumping off place:
XXXPARTICLEEFFECTSOURCEXXX setParticleCircle [0, [0, 0, 0]];
XXXPARTICLEEFFECTSOURCEXXX setParticleRandom [0, [0, 0, 0], [0, 0, 0],
0, 0, [0, 0, 0, 0], 0, 0];
XXXPARTICLEEFFECTSOURCEXXX setParticleParams [["\Ca\Data\ParticleEffects\FireAndSmokeAnim\SmokeAnim.p3d",
1, 0, 1], "", "Billboard", 1, 3.0141, [0, 0, 3], [0, 0, 0], 1, 1.275, 1,
0, [6, 6], [[1, 1, 1, 1], [1, 1, 1, 1], [1, 1, 1, 1]], [1], 1, 0, "", "",
XXXOBJECTXXX];
XXXPARTICLEEFFECTSOURCEXXX setDropInterval 3;
This shows large versions of the whole particle effect tile.
2: Modify Shapename
0 until you've found the tile that has the
desired effect
on it.
3: If there's
just one effect on the desired tile, leave ShapeName
1-3 as 1, 0,
1. Otherwise, start adding one to shapename 1 until it
is displaying
a single effect perfectly. In the case of
"\Ca\Data\ParticleEffects\FireAndSmokeAnim\SmokeAnim.p3d",
this will
be 8, but other
tiles will have other numbers. Usually, the width of
the tile is
the perfect indicator for what this number will be.
4: Add/Subtract
1 from ShapeName 2 until you find the specific effect
you where wanting
to work with.
5: If you want
this effect to be animated, add 1 to ShapeName 2 until
you are happy
with the frames it is playing. This will often be the
width of the
tile again. Some tiles have rows with empty spots on
them, this will
result in the game drawing a blank for some animation
frames.
This will make the particle appear to flash on and off. To
prevent this,
just make this number a smaller until it goes away.
4.0 Foreign Languages:
Unfortunately, I only write in english. I can
get the gist of what's being
said when I read a few other languages, but attempting
to write in one of
these languages pretty much results in something
about the same quality as
babelfish or a similar tool.
If you feel willing and capable of translating this
manual into another
language, like if that your native language is something
other than
english, by all means, go for it. If you tell
me, I will gladly include it
in future releases of this package with full credit,
or link to it.