Ver Fonte

Added short section on how to control effect from script.

Mikael Säker há 7 anos atrás
pai
commit
be11efb4e3
1 ficheiros alterados com 14 adições e 0 exclusões
  1. 14 0
      docs/en/manuals/particlefx.md

+ 14 - 0
docs/en/manuals/particlefx.md

@@ -204,3 +204,17 @@ Magnitude
 
 Max Distance
 : The maximum distance within which particles are affected at all by this modifier. Only used for Radial and Vortex.
+
+## Controlling a particle effect
+
+To start and stop a particle effect from a script:
+
+```lua
+-- start the effect component "particles" in the current game object
+particlefx.play("#particles")
+
+-- stop the effect component "particles" in the current game object
+particlefx.stop("#particles")
+```
+
+See the [Particle FX reference documentation](/ref/particlefx) for more information.