粒子系统操作器
公有操作器
一般而言,所有的粒子系统都会有movement_basic(基本移动)和lifespan_decay(寿命衰减)这两个操作器。movement_basic用来控制粒子的移动。lifespan_decay用来定义粒子的生存时间,一旦生存时间结束,系统就可以删除该粒子并回收相应的资源(alpha_fade 操作器本身内部包含 lifespace_decay,所以使用alpha_fade操作器时不需要再用额外的lifespan_decay 操作器了)。
一般操作
Fade In(淡入)/Fade Out(淡出)/Fade Oscillate(震荡闪变) 这三个是标准操作器,能作用于其他所有操作器。根据操作器的不同,淡化组件可能有效,也可能无效而是一个二进制效果。
Fade In(淡入)、Fade Out(淡出)的时间点是相对于emitter(发射器)的生存期而言的,我们说一个操作器在3秒后淡入指的是发射器发射结束(而不是粒子生存期结束)的3秒后。
如果设定了Fade Oscillate的振荡周期,那么fade in和fade out的时间就要被设定为震荡周期的小数倍。下面举个例子:如我们使用了Fade Oscillate操作器,并且把震荡周期设定为4秒、淡入系数设定为0.25、淡出系数设定为0.75,那么得到如下效果: 4秒为一个周期,每个4秒分为3个阶段,第一阶段为1秒(4秒的0.25倍),该阶段没有任何效果,第二阶段出现视觉效果且持续2秒(4秒的0.75-0.25=0.5倍),最后一阶段1秒,该阶段效果为淡出;然后如是循环反复。
粒子期限计时器(Lifespan Decay)
用于在粒子的生存期超限之后,将粒子删除。该操作没有参数传入。如果既没有使用lifespan_decay也没有使用alpha_fade,那么相关的粒子将永远不会因过期而被删除。
需要注意的是,如果没有使用相应的decay操作(或者,由于不合适的EndCap(截止)设定,decay操作没能被激活),创建的粒子将会永远存在于系统中,即便粒子本身已经完全淡出、半径缩小为0且生存期超限,这会导致严重的后果--已占用的系统资源(内存、处理器)不能正常释放--系统的可用资源将越来越少。我们可以通过粒子编辑器提供的预览窗口来快捷的确定自己粒子系统是否设计正确,确保粒子效果能正常结束并完成资源的清理和回收。如果预览窗体中显示的是不断的循环效果,那么你的设计是正确的。如果显示效果停止,并且永不重现,那么必定是因为它或者它的一个子系统缺少应有的decay操作器。为了继续设计(或者对于那些使用了EndCap的效果),在粒子编辑器中按下Stop(停止)按钮,就可以让它执行EndCap并重新启动。
Alpha衰减和计时(Alpha Fade and Decay)
用于指定在一段特定时间内将粒子的alpha值衰减到一个特定值,然后删除该粒子。
- start_alpha
- 指定粒子淡入过程的alpha值(亮度)的起点。淡入过程中,粒子亮度从start_alpha渐变至该粒子亮度的初始设定值。
- end_alpha
- 淡出过程中,粒子亮度将渐变至end_alpha设定的值。
- start_fade_in_time
- 设定淡入过程的起始时间点(规定为lifespan(粒子生存期)的小数倍)。
- end_fade_in_time
- 设定淡入过程的终止时间点(规定为lifespan(粒子生存期)的小数倍)。
- start_fade_out_time
- 设定粒子淡出过程的起始时间点(规定为lifespan(粒子生存期)的小数倍)。
- end_fade_out_time
- 设定粒子淡出过程的终止时间点(规定为lifespan(粒子生存期)的小数倍)。
随机Alpha淡入(Alpha Fade In Random)
设定粒子从零alpha值开始淡入,淡入过程持续时间是在一个指定的绝对或者相对时间范围内的一个随机值。
- fade in time min
- 时间范围的下限(最短时间)。
- fade in time max
- 时间范围的上限(最长时间)。
- fade in time exponent
- 随机时间范围的偏差值。
- proportional 0/1
- 设定随机时间范围为粒子生存期的相对值(小数倍)(1)或者绝对值(0)。
随机Alpha淡出(Alpha Fade Out Random)
设定粒子从其alpha初始设定值开始淡出并渐变为零alpha值,淡出过程持续时间是在一个指定的绝对或者相对时间范围内的一个随机值。不论是相对还是绝对时间,都是从粒子的生存期末尾计算(即对已粒子生存期的最后阶段)。举例来说,0.25的相对时间设定值表示粒子淡出过程位于粒子生存期的最后四分之一时段;而2的绝对时间设定值表示淡出过程对应于粒子生存期的最后2秒。(--alpha_fade_out操作本身不包含lifespan_deca操作--)
- fade out time min
- 时间范围的下限(最短时间)。
- fade out time max
- 时间范围的上限(最长时间)。
- fade out time exponent
- 随机时间范围的偏差值。
- proportional 0/1
- 设定随机时间范围为粒子生存期的相对值(小数倍)(1)或者绝对值(0)。
颜色渐变(Color Fade)
经过指定的时间,将粒子的颜色改变为目标颜色.
- color_fade
- 要渐变为的颜色。
- color_fade_time
- 渐变时间 (秒)。
- fade_start_time
- 当粒子生命周期到达这个点前,粒子系统完全是其初始颜色。如果这个值大于"fade_end_time"粒子系统将持续保持其初始颜色。
- fade_end_time
- 当粒子生命周期到达这个点,粒子系统完全变为 "color_fade"指定的颜色。如果这个值大于"fade_start_time"随后粒子系统将保持"color_fade"的颜色.
提示: "fade_end_time"和"fade_start_time"可以设置为负值,来在粒子系统创建前开始渐变。
基本移动(Movement Basic)
允许粒子基本的空间上的移动
- gravity
- 应用到粒子的重力。
- drag
- 粒子运动速度所承受的阻力。
翻滚(Roll)自旋转动(Rotation Spin Roll)
为粒子添加自旋转动,包括旋转减速和最小旋转。
- spin_rate_degrees
- 转向速率(度)。
- spin_stop_time
- 到达最小速率的时间(秒)。
- spin_rate_min
- 最小旋转速率(度)。
偏航(Yaw)自旋转动(Rotation Spin Yaw)
为粒子添加偏航角自旋转动,包括旋转减速和最小旋转,和上面一样。
- spin_rate_degrees
- 转向速率(度)。
- spin_stop_time
- 到达最小速率的时间(秒)。
- spin_rate_min
- 最小旋转速率(度)。
半径缩放(Radius Scale)
随着时间缩放半径。
- start_time
- 开始缩放的时间(秒)。
- end_time
- 结束缩放的时间(秒)。
- radius_start_scale
- 开始的缩放值。
- radius_end_scale
- 结束的缩放值。
- ease_in_and_out
- 样条缩放曲线(Spline scaling curve)。
- scale_bias
- 曲线对两端(0..1)的偏移率(Bias)。
Movement Rotate Particle Around Axis
Similar to Rotation Spin Yaw and Rotation Spin Roll, but rotates all active particles around a given axis (or axes).
- Rotation Axis
- Vector. Spin about X Y and/or Z axis. Can rotate around multiple axes at once, which can produce interesting patterns (especially when particles are given some speed on initialization).
- Rotation Rate
- Speed at which to spin, in degrees.
锁定控制点移动Movement Lock to Controlpoint
强制粒子定位到发射器(emitter)上的某些控制点。
- start_fadeout_min
- Bottom range of time to start fading out the lock (leave the particle behind).
- start_fadeout_max
- Top range of time to start fading out the lock (leave the particle behind).
- end_fadeout_min
- Bottom range of time to end fading out the lock. Particle will be fully disengaged from the control points movement at this point.
- end_fadeout_max
- Top range of time to end fading out the lock. Particle will be fully disengaged from the control points movement at this point.
- start/end exponents
- Bias on the selection within the range.
- control point number
- Which control point to lock to
- fade distance
- Particles will detach as they approach this distance
- lock rotation
- This will update a particle relative to a Control Point's rotation as well as position.
Movement Lock to Bone
Lock to Bone works like the Position Lock to Control Point operator, but is used in combination with the random position on model initializer. Given a particle is emitted from a particular bone, it will update its position based on the specific movement of that bone. Excellent for player auras or burning players.
- control_point_number
- The control point that references the model in question.
- lifetime start fade
- The time at which to start fading the lock - relative to particle lifespan (0-1).
- lifetime end fade
- The time at which to end (fully detach) the lock - relative to particle lifespan (0-1).
Oscillate Scalar
Oscillates a scalar output value at a certain rate and frequency. This can be used to creating flashing, glowing, pulsing particles or more subtle effects. The start and end timings are useful for creating an effect which occurs only once other operators have reached a desired effect, etc. Multiple oscillators of the same type can be applied to create multiple levels of effects (such as a particle which slowly pulses between small and large, but is also constantly minorly jittering in size as it does so).
- proportional
- This bool sets whether to oscillate at the specified frequency over the lifespan of the particle (1) or per second (0)
- oscillation frequency max
- Top range of frequency of oscillation. Depending on whether proportional is set, this frequency will map to the lifespan of the particle or per second. A high frequency will cause the particle to strobe, while anything lower than .25 can be used to apply a more constant direction of the rate rather than an oscillating effect.
- oscillation frequency min
- Bottom range of frequency of oscillation. Depending on whether proportional is set, this frequency will map to the lifespan of the particle or per second. A high frequency will cause the particle to strobe, while anything lower than .25 can be used to apply a more constant direction of the rate rather than an oscillating effect.
- oscillation rate max
- Top range of rate of change applied. This defines how much the particular output field changes per frame. Some fields (such as alpha) will be automatically clamped from 0.0 to 1.0, while others, such as radius, are not capped.
- oscillation rate min
- Bottom range of rate of change applied. This defines how much the particular output field changes per frame. Some fields (such as alpha) will be automatically clamped from 0.0 to 1.0, while others, such as radius, are not capped.
- oscillation field
- What parameter is oscillated. This can be alpha, radius, roll, etc.
- start time min/max
- A range defining when to start applying the oscillation. Start/End proportional flag defines whether this is relative to the lifespan of the particle or a strict time in seconds.
- end time min/max
- A range defining when to stop applying the oscillation. Start/End proportional flag defines whether this is relative to the lifespan of the particle or a strict time in seconds.
- oscillation multiplier
- This is a simple multiplier for the oscillation rate min/maxes.
- oscillation start phase
- This is where on the sin curve oscillation begins.
Oscillate Vector
Oscillates a vector output value at a certain rate and frequency. This can be used to create weaving, squiggling particles and so forth. The start and end timings are useful for creating an effect which occurs only once other operators have reached a desired effect. Multiple oscillators of the same type can be applied to create multiple levels of effects (such as a bug particle which slowly weaves about on a large scale at random and squiggles constantly as it moves).
- proportional
- This bool sets whether to oscillate at the specified frequency over the lifespan of the particle (1) or per second (0)
- oscillation frequency max
- Top range of frequency of oscillation. Depending on whether proportional is set, this frequency will map to the lifespan of the particle or per second. A high frequency will cause the particle to quickly move back and forth, while anything lower than .25 can be used to apply a more constant direction of the rate rather than an oscillating effect.
- oscillation frequency min
- Bottom range of frequency of oscillation. Depending on whether proportional is set, this frequency will map to the lifespan of the particle or per second. A high frequency will cause the particle to quickly move back and forth, while anything lower than .25 can be used to apply a more constant direction of the rate rather than an oscillating effect.
- oscillation rate max
- Top range of rate of change applied. This defines how much the particular output field changes per frame. Color will be automatically clamped from 0 to 255, while position is not capped.
- oscillation rate min
- Bottom range of rate of change applied. This defines how much the particular output field changes per frame. Color will be automatically clamped from 0 to 255, while position is not capped.
- oscillation field
- What parameter is oscillated. This can be color or position.
- start time min/max
- A range defining when to start applying the oscillation. Start/End proportional flag defines whether this is relative to the lifespan of the particle or a strict time in seconds.
- end time min/max
- A range defining when to stop applying the oscillation. Start/End proportional flag defines whether this is relative to the lifespan of the particle or a strict time in seconds.
- oscillation multiplier
- This is a simple multiplier for the oscillation rate min/maxes.
- oscillation start phase
- This is where on the sin curve oscillation begins.
相对控制点移动阻塞(Movement Dampen Relative to Control Point)
这个操作器抑制粒子接近指定的控制点,这个可和锁定控制点移动(以及其距离渐变选项一同使用),使得控制点“捕捉”附近的粒子并将其拉向自身。也可以用来锁定粒子线的终点而允许其中截面自由移动。
- control_point_number
- 阻塞相关控制点。
- falloff range
- 阻塞衰减的距离。
- dampen scale
- 移动阻塞强度。
设置控制点位置(Set Control Point Positions)
允许粒子设置自身的控制点(Control Point)。
- <nth> Control Point Number
- 受到影响的控制点 待完善: 设置成 -1安全吗?
- <nth> Control Point Parent
- 指定另外一个控制点作为移动的parent 。保留0值则意味使用系统的原点(origin )。
- <nth> Control Point Location
- Vector 控制点坐标
- Set positions in world space
- 当设置为true, 控制点是相对于world 定位的,否则则是相对于本系统的原点定位。
- Control Point to offset positions from
- 控制点的位置从这个控制点位置位移。 待完善: 是随着时间更新还是一次性生效?
控制点置中(Set Control Point to Particles' Center)
将控制点锁定到该系统粒子云的中心
- Control Point Number to Set
- Center Offset
- 要设置的控制点,以及可选的worldspace位移.