You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
374 B
23 lines
374 B
using JetBrains.Annotations; |
|
using UnityEngine; |
|
using UnityEngine.SceneManagement; |
|
|
|
namespace Utils |
|
{ |
|
public class SceneLoader : MonoBehaviour |
|
{ |
|
|
|
[SerializeField] private string _sceneName; |
|
|
|
[UsedImplicitly] |
|
public void LoadScene() |
|
{ |
|
SceneManager.LoadScene(_sceneName); |
|
} |
|
|
|
public void SetScene(string sceneName) |
|
{ |
|
_sceneName = sceneName; |
|
} |
|
} |
|
}
|
|
|