Particle System Pause#
Effects / Particle System / Particle System Pause WithChildren
Description#
Executes the Pause method on the Particle System component
Parameters#
| Name | Description |
|---|---|
| With Children |
Code#
// <auto-generated>
// This script was automatically generated using the Visual Script Transpiler.
// Do not modify. Changes to this file will be lost when updating the package.
// </auto-generated>
using System;
using UnityEngine;
using VisualScript.Icons;
namespace VisualScript.Runtime
{
[Title("Particle System Pause")]
[Category("Effects/Particle System/Pause", "WithChildren")]
[Description("Executes the Pause method on the Particle System component")]
[Image(typeof(IconParticleSystem), ColorTheme.Type.Blue)]
[Keywords("Effect")]
[Parameter("With Children")]
[Serializable]
public class GenInstructionParticleSystem_Pause_1_BoolWithChildren : Instruction
{
[SerializeField] private GetGameObject m_ParticleSystem = new GetGameObject(
new GenTypeGameObject_ParticleSystem()
);
[SerializeField] private GetBool m_WithChildren = new GetBool();
protected override string GetTitle(GameObject source)
{
string method = TextUtils.ThemeAsKeyword("Pause");
return $"{this.m_ParticleSystem} {method} ({this.m_WithChildren})";
}
protected override Awaitable Run(Args args)
{
ParticleSystem component = this.m_ParticleSystem.Get<ParticleSystem>(args);
if (component == null) return Done;
component.Pause(
(bool) this.m_WithChildren.Get(args)
);
return Done;
}
}
}