using UnityEngine; using UnityEngine.SceneManagement; using UnityAtoms.BaseAtoms; namespace UnityAtoms.SceneMgmt { /// /// Action to change scene. /// [EditorIcon("atom-icon-purple")] [CreateAssetMenu(menuName = "Unity Atoms/Actions/Scene Management/Change Scene")] public sealed class ChangeScene : AtomAction { /// /// Scene to change to. /// [SerializeField] private StringReference _sceneName = null; /// /// Change the scene. /// public override void Do() { SceneManager.LoadScene(_sceneName.Value); } } }