Arrays

Color

Format

[r, g, b, a]

Description

r is the intensity of red, g is the intensity of green, b is the intensity of blue.

a is alpha (0 = transparent, 1 = opaque).

All values should be in the range 0 to 1.


ParticleArray

Format

["ShapeName", "AnimationName", "Type", TimerPeriod, LifeTime, [Position], [MoveVelocity], RotationVelocity, Weight, Volume, Rubbing, [Size], [Color], [AnimationPhase], RandomDirectionPeriod, RandomDirectionIntensity, "OnTimer", "BeforeDestroy", "Object"]

Description

Global parameters

  • ShapeName
    Name of the shape associated with the particle.
    This is just the name of the model used for the shape, for example "cl_fire".

    For Arma this can become an array with 4 elements, which has the path to the model as the first element. The second element is the Animation divisor, 1 for 1X1 or 8 for 8X8 and so on. The third element is the Animation start row. Rows are numbered, starting at the top, from 0 through to 7. The fourth and final element is the number of frames to play, the speed of which is controlled by the animation phase which is described further below.

    Here is an example picture of the FireSmokeAnim texture. This picture uses 8X8 frames. This of course will mean you need to use 8 as the second array element otherwise too much or too little of the image will be drawn by the game. As can be seen from the image the first two rows, 0 and 1, are smoke effects as is row 3. Row 2 is a fire effect. You can choose which row to start with using these numbers (0 - 7).

    The number of frames to play would in most cases be the number of frames available in the image.
  • AnimationName
    Name of the animation of the shape. For OFP this was normally left as an empty string "". For ArmA an empty string is used, basically it just means this option is obsolete, although I think the empty string must be used in order to 'fill' the slot.
  • Type
    Type of particle (either "Billboard" or "SpaceObject").
  • TimerPeriod
    The period of calling the "OnTimer" event (in sec).
  • LifeTime
    Life time of the particle (in sec).

Physical parameters

  • Position
    Either 3D coordinate (x, y, z) or name of the selection - in this case the Object property must be set.
  • MoveVelocity
    3D vector (x, y, z) which describes the velocity vector of the particle direction andspeed in m/s.
  • RotationVelocity
    Float number which determines number of rotations in one second.
  • Weight
    Weight of the particle (kg).
  • Volume
    Volume of the particle (m^3).
  • Rubbing
    Float number without dimension which determines the impact of the density of the environment on this particle. 0 = no impact (vacuum).

Render parameters

Note that all these values are set as arrays to show their development in time. If you set the Size array as [1, 2], then at the beginning the size of the particle will be 1 and at the end of the lifetime of the particle it's size will be 2. The rest of the values during the lifetime will be linearly interpolated.

  • Size
    Size of the particle in time to render (in metres).
  • Color
    Colour of the particle in time to render (rgba - see description of colour array above).
  • AnimationPhase
    Phase of the animation in time. Basically the play speed of the fourth element of the Shapename array from above. The larger the number the faster the frames play.

Random parameters

  • RandomDirectionPeriod
    Period of change of the velocity vector (s).
  • RandomDirectionIntensity
    Each MoveVelocity component will be changed with random value from interval <0, RandomDirectionIntensity>.
  • OnTimer
    Name of the script to run every period determined by TimerPeriod property. The position of the particle is stored in "this" variable.
  • BeforeDestroy
    Name of the script to run right before destroying the particle. The position of the particle is stored in "this" variable.
  • Object
    Object to bind this particle to.

Examples

ArmA and OFP

drop ["cl_basic", "", "Billboard", 1, 1, [-3.5*(sin(direction xural)), -3.5*(cos(direction xural)), 0], [random 0.1, random 0.1, random 0.5], 1, 0.005, 0.0042, 0.7, [0.3,3], [[0.5,0.5,0.5,0],[0.7,0.7,0.7,0.5],[0.9,0.9,0.9,0]], [0,1,0,1,0,1], 0.2, 0.2, "", "", xural]

ArmA Only

drop [["\ca\data\ParticleEffects\FireAndSmokeAnim\SmokeAnim.p3d", 8, 1, 8], "", "Billboard", 1, 1, [-3.5*(sin(direction xural)), -3.5*(cos(direction xural)), 0], [random 0.1, random 0.1, random 0.5], 1, 0.005, 0.0042, 0.7, [0.3,3], [[0.5,0.5,0.5,0],[0.7,0.7,0.7,0.5],[0.9,0.9,0.9,0]], [0,1,0,1,0,1], 0.2, 0.2, "", "", xural]

Arma2 Only

drop [["\Ca\Data\ParticleEffects\Universal\Universal", 16, 0, 64, 1], "", "Billboard", 1, 1, [-3.5*(sin(direction xural)), -3.5*(cos(direction xural)), 0], [random 0.1, random 0.1, random 0.5], 1, 0.005, 0.0042, 0.7, [0.3,3], [[0.5,0.5,0.5,0],[0.7,0.7,0.7,0.5],[0.9,0.9,0.9,0]], [0,1,0,1,0,1], 0.2, 0.2, "", "", xural]


Position

Format

[x, z] or [x, z, y]

Description

x coordinates are east to west
z coordinates are south to north
y is height above ground.
Default y is 0.


Position2D

Format

[x, z]

Description

x coordinates are east to west
z coordinates are south to north.


PositionASL

Format

[x, z, y]

Description

x coordinates are east to west
z coordinates are south to north

y is the height above sea level.


Waypoint

Format

[group, index]

Description

Group is of type Group, index selects waypoint.

Index 0 selects first waypoint which is always created on group starting position.

snYpir

Note that [groupname, 0] is automatically created at a unit's starting position. Therefore:

  • [groupname, 1] would be the first in-editor waypoint
  • [groupname, 2] would be the second

And so on...


Search OFPEC COMREF