Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using UnityEngine;
- using System.Collections;
- [ExecuteInEditMode]
- public class SkyboxSetup : MonoBehaviour
- {
- public float RotationDegree;
- // Update is called once per frame
- void Update ()
- {
- Quaternion rotationDegree = Quaternion.AngleAxis(RotationDegree, Vector3.up);
- Matrix4x4 rotationShader = Matrix4x4.TRS(Vector3.zero, rotationDegree, Vector3.one);
- RenderSettings.skybox.SetMatrix("_Rotation", rotationShader);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement