Scaling Issue with the "Apply Owner Scale to Attributes" Module in Niagara Using Death Event

During the process of solving the overall scaling issue of Niagara System, I encountered this problem and wanted to document it.

Solution for the overall VFX scaling issue: [解决方法]Niagara特效整体缩放问题

Problem Description

When scaling a Niagara System, the particle size does not scale along with it, which leads to the effect being distorted after scaling. The official solution is to use the “Apply Owner Scale to Attributes” module, which usually works fine.

However, the Niagara System I used for testing employs a Death Event, where the death of a particle from one emitter triggers another emitter. I added the “Apply Owner Scale to Attributes” module to both emitters, but the scaling for particles in one of the emitters resulted in excessive scaling. For example, when the overall effect was scaled by 2x, these particles would scale by 4x.

After investigating, I found that the second emitter inherits the scaling from the first emitter, and then the “Apply Owner Scale to Attributes” module applies the scaling again, meaning the triggered particles are scaled by the square of the overall effect’s scale.

Solution

I manually added a square root node to the “Apply Owner Scale to Attributes” module.

  1. Double-click the “Apply Owner Scale to Attributes” module to enter the node editing interface, and add a new version in the version control panel (do not modify the original version).

    Screenshot 2024-10-21 191858

  2. Find the part that controls the particle scaling. (The logic here is essentially multiplying the overall effect’s scale by the particle size, so we need to take the square root of the overall scale.)

  3. After the “Lerp” node, add a “Sqrt” node and connect it to the original node. Since normal emitters don’t need square root scaling, we will add a “Static Switch” node, connecting the original scaling factor and the square-rooted factor to the conditional node. Save the changes.

  4. Go back to the Niagara System interface, switch the “Apply Owner Scale to Attributes” module in the triggered emitter to the version we created, and check the square root option.

    Screenshot 2024-10-21 192715

  5. Test it in the level. The expected outcome is that both particle emitters should scale uniformly with the overall effect.