Sprite Shape Renderer Set Shader User Value#
Miscellaneous / Sprite Shape Renderer / Sprite Shape Renderer Set Shader User Value
Description#
Executes the Set Shader User Value method on the Sprite Shape Renderer component
Parameters#
| Name | Description |
|---|---|
| V |
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;
using UnityEngine.U2D;
namespace VisualScript.Runtime
{
[Title("Sprite Shape Renderer Set Shader User Value")]
[Category("Miscellaneous/Sprite Shape Renderer/Set Shader User Value")]
[Description("Executes the Set Shader User Value method on the Sprite Shape Renderer component")]
[Image(typeof(IconSprite), ColorTheme.Type.Purple, typeof(BadgeEye))]
[Parameter("V")]
[Serializable]
public class GenInstructionSpriteShapeRenderer_SetShaderUserValue_1 : Instruction
{
[SerializeField] private GetGameObject m_SpriteShapeRenderer = new GetGameObject(
new GenTypeGameObject_SpriteShapeRenderer()
);
[SerializeField] private GetInteger m_V = new GetInteger();
protected override string GetTitle(GameObject source)
{
string method = TextUtils.ThemeAsKeyword("Set Shader User Value");
return $"{this.m_SpriteShapeRenderer} {method} ({this.m_V})";
}
protected override Awaitable Run(Args args)
{
SpriteShapeRenderer component = this.m_SpriteShapeRenderer.Get<SpriteShapeRenderer>(args);
if (component == null) return Done;
component.SetShaderUserValue(
(uint) this.m_V.Get(args)
);
return Done;
}
}
}