Version: 2023.1
Limit Velocity over Lifetime module
Lifetime by Emitter Speed module

Inherit Velocity 模块

Use this module on subemitters. Each particle in the parent system can spawn particles in the subemitter. This module reads the velocity from the parent particle and controls how the speed of the subemitter particles reacts to that velocity over time.

Using the Inherit Velocity module

This module is part of the Particle System component. When you create a new Particle System GameObject, or add a Particle System component to an exiting GameObject, Unity adds the Inherit Velocity module to the Particle System. By default, Unity disables this module. To create a new Particle System and enable this module:

  1. Click GameObject > Effects > Particle System.
  2. In the Inspector, find the Particle System component.
  3. In the Particle System component, find the Inherit Velocity module fold-out.
  4. To the left of the fold-out header, enable the checkbox.

API

Since this module is part of the Particle System component, you access it through the ParticleSystem class. For information on how to access it and change values at runtime, see the Inherit Velocity module API documentation.

属性

For some properties in this section, you can use different modes to set their value. For information on the modes you can use, see Varying properties over time.

属性 功能
Mode 指定如何将发射器速度应用于粒子
    Current 发射器的当前速度将应用于每一帧上的所有粒子。例如,如果发射器减速,所有粒子也将减速。
    Initial 每个粒子出生时将施加一次发射器的速度。粒子出生后对发射器速度的任何改变都不会影响该粒子。
Multiplier 粒子应该继承的发射器速度的比例。

详细信息

这种效果对于从移动对象发射粒子非常有用,例如汽车产生的尘云、火箭产生的烟雾、蒸汽火车烟囱产生的蒸汽,或者粒子最初应以所在对象的速度百分比移动的任何情况。仅当 Simulation Space主模块中设置为 World 时,此模块才对粒子有影响。

此外也可以使用曲线来影响随时间变化的效果。例如,可对新创建的粒子施加强烈的吸力,使吸力随时间推移而减少。这对于蒸汽火车烟雾可能有用,因为蒸汽火车烟雾会随着时间的推移而缓慢漂移并在发出后停止跟随火车。

Unity calculates the emitter’s velocity in one of two ways: * Based on the velocity of an attached Rigidbody component * Based on how far the Particle System’s Transform component travelled during the current frame

To specify the method Unity uses, see the Main module’s Emitter Velocity property:

Limit Velocity over Lifetime module
Lifetime by Emitter Speed module
Copyright © 2023 Unity Technologies
优美缔软件(上海)有限公司 版权所有
"Unity"、Unity 徽标及其他 Unity 商标是 Unity Technologies 或其附属机构在美国及其他地区的商标或注册商标。其他名称或品牌是其各自所有者的商标。
公安部备案号:
31010902002961