TimelineImprovements

This commit is contained in:
ThomasCharester committed 2026-11-20 14:28:56 +03:00
1 parent e312131725
commit f927552adc
2211 files changed
+115416 -540944

No files matched your search

@@ -102,6 +102,7 @@ namespace MK.Toon.Editor
/////////////////
// Advanced //
/////////////////
protected MaterialProperty _transparentReceiveFog;
protected MaterialProperty _screenSpaceReflections;
protected MaterialProperty _screenSpaceReflectionsContributeTransparent;
protected MaterialProperty _renderPriority;
@@ -189,6 +190,7 @@ namespace MK.Toon.Editor
_dissolveBorderSize = FindProperty(Properties.dissolveBorderSize.uniform.name, props);
_dissolveBorderColor = FindProperty(Properties.dissolveBorderColor.uniform.name, props);
_transparentReceiveFog = FindProperty(Properties.transparentReceiveFog.uniform.name, props, false);
_screenSpaceReflectionsContributeTransparent = FindProperty(Properties.screenSpaceReflectionsContributeTransparent.uniform.name, props, false);
_renderPriority = FindProperty(Properties.renderPriority.uniform.name, props);
_alembicMotionVectors = FindProperty(Properties.alembicMotionVectors.uniform.name, props, false);
@@ -688,8 +690,12 @@ namespace MK.Toon.Editor
protected void DrawScreenSpaceReflections(MaterialEditor materialEditor, Material material)
{
#if URP_SCREEN_SPACE_REFLECTION
bool isTransparent = material.renderQueue >= (int) UnityEngine.Rendering.RenderQueue.Transparent;
#if MK_URP && UNITY_6000_6_OR_NEWER
bool isTransparent = Properties.surface.GetValue(material) == Surface.Transparent;
#if UNITY_6000_7_OR_NEWER
if(_transparentReceiveFog != null && isTransparent)
materialEditor.ShaderProperty(_transparentReceiveFog, "Receive Fog");
#endif
if(_screenSpaceReflections != null)
materialEditor.ShaderProperty(_screenSpaceReflections, UI.screenSpaceReflections);
if(_screenSpaceReflectionsContributeTransparent != null && isTransparent)
@@ -824,12 +830,12 @@ namespace MK.Toon.Editor
private void ManageKeywordsScreenSpaceReflections(Material material)
{
#if URP_SCREEN_SPACE_REFLECTION
bool isTransparent = material.renderQueue >= (int) UnityEngine.Rendering.RenderQueue.Transparent;
#if MK_URP && UNITY_6000_6_OR_NEWER
bool isTransparent = Properties.surface.GetValue(material) == Surface.Transparent;
if(_screenSpaceReflections != null)
EditorHelper.SetKeyword(Properties.screenSpaceReflections.GetValue(material) == false, "_SCREENSPACEREFLECTIONS_OFF", material);
if(_screenSpaceReflectionsContributeTransparent != null && isTransparent)
EditorHelper.SetKeyword(Properties.screenSpaceReflectionsContributeTransparent.GetValue(material) == false && material.renderQueue >= (int) UnityEngine.Rendering.RenderQueue.Transparent, "_SCREENSPACEREFLECTIONSCONTRIBUTETRANSPARENT_OFF", material);
if(_screenSpaceReflectionsContributeTransparent != null)
EditorHelper.SetKeyword(Properties.screenSpaceReflectionsContributeTransparent.GetValue(material) == false && isTransparent, "_SCREENSPACEREFLECTIONSCONTRIBUTETRANSPARENT_OFF", material);
#endif
}