Rasagar/Packages/com.occasoftware.super-simple-skybox/Runtime/SkyObjects/MoonStatic.cs

15 lines
357 B
C#
Raw Normal View History

2024-09-01 13:42:24 -07:00
using UnityEngine;
namespace OccaSoftware.SuperSimpleSkybox.Runtime
{
[ExecuteAlways]
[AddComponentMenu("OccaSoftware/Super Simple Skybox/Moon (Static)")]
public class MoonStatic : MonoBehaviour
{
private void Update()
{
Shader.SetGlobalVector(ShaderParams._MoonDirection, -transform.forward);
}
}
}