【add】主入口初始化
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
namespace EPOOutline
|
||||
{
|
||||
[ExecuteAlways]
|
||||
public class OnPreRenderEventTransferer : MonoBehaviour
|
||||
{
|
||||
private Camera attachedCamera;
|
||||
|
||||
public Action<Camera> OnPreRenderEvent;
|
||||
|
||||
private void Awake()
|
||||
{
|
||||
attachedCamera = GetComponent<Camera>();
|
||||
}
|
||||
|
||||
private void OnPreRender()
|
||||
{
|
||||
if (OnPreRenderEvent != null)
|
||||
OnPreRenderEvent(attachedCamera);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user