User Tools

Site Tools


world_setup:game_features:particleeffects

3D Particle Effects

You can add 3d particle effects to your world using the effect commands:
*addeffect [PLAYER_NAME],[EFFECT_NUM],[worldX],[worldY],[worldz](,[SCALE],[PARAM])
*addeffectall [num],[worldX],[worldY],[worldz],[scale],[param]
*addspreadeffect [PLAYER_NAME],[spread_type],[spread_range],[spread_amount],[effectnum],[worldX],[worldY],[worldz],[scale],[param]
*addspreadeffectall [spread_type],[spread_range],[spread_amount],[effectnum],[worldX],[worldY],[worldz],[scale],[param]

e.g Example of the command used from script:

Event( "&command", "Particles" )
{
    $effectNum = 10
    $scale = 100
    $param = 0
    *addeffect %PLAYER%,$effectNum,$gPlayerWorldX,$gPlayerWorldY,0,$scale,$param
}

Note if the WorldZ is set to 0, the particle effect appears on the landscape. The [SCALE] and [PARAM] parameters are optional and ignored by many of the effects.

Currently supported values for the 'EFFECT_NUM' parameter are:

  • 0 - A circle of 'sparks' cast up, then out and up from the position given
  • 1 - A circle of larger 'sparks' cast out and up from the position given.
  • 2 - A column of sparks around the location
  • 3 - A sphere of sparks around the location given
  • 4 - A spark fountain appears at the specified location
  • 5 - Spark fountain with different behaviour
  • 6 - A burst of spark particles is cast out in a circle centered on the effect location
  • 7 - Reverse of effect 6, particles travel in to meet at the effect location
  • 8 - Sets off a series of bursts of smoke
  • 9 - Sets off a series of bursts of smoke, as though a cigar was being smoked at the effect location.
  • 10 - Starts a fire attached to the player specified
  • 11 - [Not currently used]
  • 12 - A circle explosion cast out from the effect location
  • 13 - A circle explosion cast out from the effect location with a small flame explosion at the centre
  • 14 - Triggers a rocket launch sequence on the specified player
  • 15 - Triggers a rocket launch sequence on the nearest building to the player
  • 16 - Small sized flame explosion
  • 17 - Medium sized flame explosion
  • 18 - Large flame explosion
  • 19 - Makes the player perform animation 'Action 1' (if the player model has such an animation)
  • 20 - [Not currently used]
  • 21 - [Not currently used]
  • 22 - [Not currently used]
  • 23 - [Not currently used]
  • 24 - [Not currently used]
  • 25 - [Not currently used]
  • 26 - [Not currently used]
  • 27 - Player gets a jetpack for a period of time. (90 seconds by default, if a param value is used that determines the number of seconds the jetpack is active for)
  • 28 - Cancel the bonus jetpack from effect 27
  • 29 - Adds a firework generator at the specified location. The firework generator will launch fireworks at regular intervals for 10 seconds.
  • 30 - Special effect for attaching armour to a tractor. Limited use cases :)

Spread Effects

Using the *addspreadeffect or *addspreadeffectall commands is effectively the same as triggering *addeffect or *addeffectall multiple times, with the location of each effect instance controlled by the spread type and range. Currently the spread type can be:
0 - Effects are distributed randomnly in a circular radius around the location given
1 - Effects are distributed evenly in a circular radius around the location given

world_setup/game_features/particleeffects.txt · Last modified: 2023/07/12 16:35 by mit

Except where otherwise noted, content on this wiki is licensed under the following license: Public Domain
Public Domain Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki