Skip to content

ParticleEd

Alex Miyamoto edited this page Oct 21, 2019 · 5 revisions

The original particle editor was the first tool created for Usagi; something was needed quickly and in time for a demo (the editor and original particle system were knocked up in only two weeks by one developer). The quickest way to get it up and running was determined to be IMGUI.

The executable is available at Tools/bin/ParticleEditor.exe, but it is probably wisest to build it as required. It is currently in a fairly buggy state, but an updated version is coming in v0.3. This document assumes you are using that version.
Most of the parameters should be self explanatory but the new version includes tooltips.

A replacement tool using the ATF libraries was in an almost complete state, however as Sony seems to have abandoned those tools we are instead improving the original tool (we are moving away from ATF where possible).

You can change your preview angle and distance by putting your mouse over a preview window and holding down Alt and using the mouse (mouse wheel to zoom, right mouse to pan, left mouse to rotate).

You can test ribbon trails by moving the emitter with the gamepad sticks.

Preview windows allow you to select models to draw so get a sense of scale.

Effects

All of the effect parameters are on the left hand side

  • Preload: The number of instances to keep in memory so allocations aren't done per instance
  • Add Emitter: Adds a previously saved emitter
  • Add Trail: Adds a ribbon trail (these can currently only be added to effects, not emitters).

For each emitter if you expand their parameters you can set their:

  • Position
  • Scale
  • Rotation
  • Particle Scale (a multiplier to the scales calculated by the effect)
  • Start Time (to delay the emitter being spawned)

Emitters

All of the emitter parameters are on the right.

File

Load or save an emitter

Shape settings

Here you can specify a shape for an emitter, The settings you have available depend on the type of shape you want to spawn in. For shapes other than point you can set the hollowness value so that particles are not spawned from the center. A hollowness value of 1 will cause particles to only be spawned from the surface of the shape.

The velocity and gravity settings for the shape allow you to move it over time. For instance if you wanted an emitter that was launched upwards but pulled down to the ground by velocity, constantly giving off sparks over time you would set an upward velocity (Y is up in Usagi) and a downward gravity vector.

Setting particle escape velocity means that particles launched by this shape will be spawned with a velocity away from the center of the shape.

Emission

Emission controls the rate at which particles are spawned

  • Mode
    • Timed: The emitter exists for a set time
    • One shot: On spawning the emitter emits the maximum number of particles immediately and once only.
    • Infinite: Use with care The effect will continue until stopped in code
  • Max particles: In one shot the number of particles to emit, in other modes the maximum number of living particles to allow (regardless of other spawn options)
  • Interval: The time between turning on and off.
  • Release Random: A random value applied to the length of time the emission is disabled
  • Effect Duration: The length of time before the emitter is destroyed automatically in Timed mode
  • Emission Rate: The number of particles emitted per second (the left value is the lifetime, the right is the rate of emission, you can add more keys to adjust the emission rate over lifetime)

Blend

Controls the blending mode used by the particles. The last value, Softness range controls fade out of soft particles.

Sorting

Controls the layer and the priority. Lower priority emitters in the same layer are drawn first. Depth offset

Texture

By using repeat x, y in the texture parameter section you can use textures with multiple frames. The timing of which is specified with the Anim timing drop down.

Color, alpha and scaling

Color alpha and scale are updated on the GPU and so are controlled by passing in 3 values for each along with timings indicating at what fraction of a particles life to begin transitioning from one to the next.

The starting scale of particles is controlled by the Base scale value and randomise