PcoWSkbVqDnWTu_dm2ix

Using Particles for Actions

Using Particles for Actions

With arrows finished, first-time players can follow the path to their goal, making their initial introduction clearer and less likely that they get lost and quit. To further enhance the user experience, let players know they’ve successfully completed their task with an appealing particle effect.

In the example below, a celebratory burst of ticket-shaped particles emits whenever players interact with the booths.

The more ways in which players receive feedback for their actions, the more alive a world becomes.

Giving multiple forms of feedback is also another way of improving a player’s user experience. A player with the sound down or one who is hearing impaired may rely more on visual cues. Other players may be low vision and paying more attention to sound.


Creating Particles

When creating a particle, it needs to be inserted into a part or attachment. In this example, you’ll place particles in the TestPlayer object used earlier.

  1. In TestPlayer, create a ParticleEmitter named Burst. Default particles will start emitting from the TestPlayer object. You’ll customize the emitter to create a burst effect.
  1. In the Burst particle’s properties, find Texture. Copy and paste one of the texture IDs supplied below, or use your own, into the texture field and press Enter.
6772766862
6772766551
5857851618
6803084085
6772783963
6703369286
6749057157
6772766413

Custom textures can be any image that you have. Learn to upload them in the Game Assets article.


If using the ticket texture, it will look like below.
  1. In the properties of TestPlayer, find and change the Color and Size properties to something appropriate for your experience.

Create a Burst Effect

Different properties can be changed so that the particles look more like a quick burst rather than a gentle stream. After designing the particle, you’ll disable the emitter so that it only plays when activated by a script.

Make Particles Spread

The ParticleEmitter sends out particles along two planes controlled by the property, SpreadAngle.

  1. To make the particles fly out in all directions like the example, set the SpreadAngle X and Y to 360.

Different Burst Properties

After adding the recommended values under the video, the particles will look like they are quickly bursting from the player like a firework.

  1. To get a burst motion, set the following properties to these values to make the particles explode and then quickly fade out.

Property

Value

Rationale

LightEmission

0.4

Adds a faint glow. Note the maximum is 1.

Drag

8

More drag causes the particles to quickly lose speed. 

Lifetime

0.6, 1

Makes particles exist for between .6 and 1 seconds. 

Rate

50

How many particles are emitted per second. 

Speed

40

How fast the particles are going when first emitted. 

Randomized properties make particles feel less repetitive. Some properties, such as Lifetime and Rotation add randomization by allowing for a minimum and a maximum value.


  1. Lastly, the particle should only play when the script (which you’ll see in the next lesson) tells it to. Find the Enabled property and toggle it off.

Particles can be tested without being enabled with the help of a plugin. For more installation and instructions, see the Using Using Particles for Explosions article.


For more information, see the Particle Emitters reference article. One option for improving is to use sequences which create effects like changing colors, or increasing size over time.



Previous Connect the Beam Next Adding Scripts