using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.Events; [CreateAssetMenu(menuName ="Event/SceneLoadEventSO")] public class SceneLoadEventSO : ScriptableObject { public UnityAction LoadRequestEvent; //把上面的事件启动 /// /// 场景加载请求 /// /// 场景 /// 坐标 /// 是否淡入淡出 public void RaiseLoadRequesEvent(GameSceneSO locationToLoad, Vector3 posToGo, bool fadeScreen) { LoadRequestEvent?.Invoke(locationToLoad, posToGo, fadeScreen); } }