chore: update internal

This commit is contained in:
mob-sakai
2026-06-23 19:04:02 +09:00
parent 1ac1b347af
commit c0a8e322b1
4 changed files with 91 additions and 13 deletions

View File

@@ -1,2 +1,11 @@
fileFormatVersion: 2
guid: 4f9f22bb079324476b1473030ad9fec3
guid: 4f9f22bb079324476b1473030ad9fec3
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -13,6 +13,8 @@ namespace Coffee.UIParticleInternal
public static int count => s_Repository.count;
public static Func<string, Shader> onShaderFind = Shader.Find;
#if UNITY_EDITOR
[RuntimeInitializeOnLoadMethod(RuntimeInitializeLoadType.SubsystemRegistration)]
public static void Clear()
@@ -48,7 +50,7 @@ namespace Coffee.UIParticleInternal
public static void Get(Hash128 hash, ref Material material, string shaderName)
{
Profiler.BeginSample("(COF)[MaterialRepository] Get");
s_Repository.Get(hash, ref material, x => new Material(Shader.Find(x))
s_Repository.Get(hash, ref material, x => new Material(onShaderFind(x))
{
hideFlags = HideFlags.DontSave | HideFlags.NotEditable
}, shaderName);
@@ -61,7 +63,7 @@ namespace Coffee.UIParticleInternal
public static void Get(Hash128 hash, ref Material material, string shaderName, string[] keywords)
{
Profiler.BeginSample("(COF)[MaterialRepository] Get");
s_Repository.Get(hash, ref material, x => new Material(Shader.Find(x.shaderName))
s_Repository.Get(hash, ref material, x => new Material(onShaderFind(x.shaderName))
{
hideFlags = HideFlags.DontSave | HideFlags.NotEditable,
shaderKeywords = x.keywords