From 2f310aa9f3f1cb1d51e8f62a6d5e3dda4821b82b Mon Sep 17 00:00:00 2001 From: chai Date: Wed, 22 Sep 2021 19:25:56 +0800 Subject: *effect --- Assets/Scripts/Unit/Components/UnitLensEffect.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Assets/Scripts/Unit/Components') diff --git a/Assets/Scripts/Unit/Components/UnitLensEffect.cs b/Assets/Scripts/Unit/Components/UnitLensEffect.cs index a61955f7..394a0b92 100644 --- a/Assets/Scripts/Unit/Components/UnitLensEffect.cs +++ b/Assets/Scripts/Unit/Components/UnitLensEffect.cs @@ -57,7 +57,8 @@ public class UnitLensEffect : UnitComponent MainCamera.Instance.customRenderingPipeline.onPostRender += OnRenderUnit; ///// - m_Effects.Add(new LensEffect_MotionBlur()); + //m_Effects.Add(new LensEffect_MotionBlur()); + m_Effects.Add(new LensEffect_BlurRim()); } public override void Release() @@ -90,6 +91,7 @@ public class UnitLensEffect : UnitComponent MethodInfo method = eff.GetType().GetMethod(re.ToString(), BindingFlags.Instance | BindingFlags.Public, null, new Type[] { typeof(LensEffectBase.EStage), typeof(CommandBuffer) }, null); if (method == null) continue; + eff.owner = owner; method.Invoke(eff, new object[] { LensEffectBase.EStage.Before, cb.Value }); for (int j = 0; j < body.renderers.Length; ++j) { -- cgit v1.1-26-g67d0