public RadialBlurBoot GetRadialBlurBootComp() { if (_CurLODLevel == EFxLODLevel.Invaild) { return(null); } if (_RadialBlurBootComp != null) { return(_RadialBlurBootComp); } var root = gameObject; var hangpoint = root.FindChildRecursively("HangPoint_Blur"); if (hangpoint != null) { _RadialBlurBootComp = hangpoint.GetComponent <RadialBlurBoot>(); if (null == _RadialBlurBootComp) { _RadialBlurBootComp = hangpoint.AddComponent <RadialBlurBoot>(); } } return(_RadialBlurBootComp); }
public void EnableRadialBlur() { if (_RealFxGameObject == null) { return; } if (RadialBlurBoot == null || !RadialBlurBoot.IsValid()) { return; } RadialBlurBoot radialBlurComp = null; if (_FxProxy != null) { radialBlurComp = _FxProxy.GetRadialBlurBootComp(); } if (radialBlurComp != null) { radialBlurComp.enabled = true; radialBlurComp.StartEffect(RadialBlurBoot.FadeIn, RadialBlurBoot.Duration, RadialBlurBoot.FadeOut, RadialBlurBoot.Intensity, RadialBlurBoot.Radius); } else { Common.HobaDebuger.LogWarningFormat("Can not find HangPoint_Blur at {0}", _RealFxGameObject.name); } RadialBlurBoot.Set(0, 0, 0, 0, 0); }