# 【跳过开屏Logo动画】
Unity编辑器里的屏蔽开屏Logo动画是需要付费才能使用的,但是同时官方也提供了代码可以屏蔽的方式。
Assets/Plugins/StopVray.cs
using System.Threading.Tasks;
using UnityEngine;
using UnityEngine.Rendering;
using UnityEngine.Scripting;
[Preserve]
public class StopVray
{
#if UNITY_WEBGL
private static void Application_focusChanged(bool obj)
{
Application.focusChanged -= Application_focusChanged;
SplashScreen.Stop(SplashScreen.StopBehavior.StopImmediate);
}
#endif
[RuntimeInitializeOnLoadMethod(RuntimeInitializeLoadType.BeforeSplashScreen)]
private static void BeforeSplashScreen()
{
#if UNITY_WEBGL
Application.focusChanged += Application_focusChanged;
#else
Task.Run(()=>{
SplashScreen.Stop(SplashScreen.StopBehavior.StopImmediate);
});
#endif
}
}