Firstborn/Library/PackageCache/com.unity.render-pipelines..../Runtime/2D/Shadows/ShadowCasterGroup2D.cs
Schaken-Mods 9092858a58 updated to the latest editor
I updated everything to the latest Unity Editor. Also realized I had the wrong shaders on my hairs, those are fixed and the hairs look MUCH better!
2023-05-07 17:43:11 -05:00

38 lines
1.1 KiB
C#

using System.Collections.Generic;
using UnityEngine.Scripting.APIUpdating;
namespace UnityEngine.Rendering.Universal
{
[MovedFrom("UnityEngine.Experimental.Rendering.Universal")]
public abstract class ShadowCasterGroup2D : MonoBehaviour
{
[SerializeField] internal int m_ShadowGroup = 0;
List<ShadowCaster2D> m_ShadowCasters;
internal virtual void CacheValues()
{
for (int i = 0; i < m_ShadowCasters.Count; i++)
m_ShadowCasters[i].CacheValues();
}
public List<ShadowCaster2D> GetShadowCasters() { return m_ShadowCasters; }
public int GetShadowGroup() { return m_ShadowGroup; }
public void RegisterShadowCaster2D(ShadowCaster2D shadowCaster2D)
{
if (m_ShadowCasters == null)
m_ShadowCasters = new List<ShadowCaster2D>();
m_ShadowCasters.Add(shadowCaster2D);
}
public void UnregisterShadowCaster2D(ShadowCaster2D shadowCaster2D)
{
if (m_ShadowCasters != null)
m_ShadowCasters.Remove(shadowCaster2D);
}
}
}