Ver Fonte

CacheFile : Skip duplicate runtime shader instead of throw

TothBenoit há 1 semana atrás
pai
commit
dfb0738683
1 ficheiros alterados com 4 adições e 1 exclusões
  1. 4 1
      hxsl/CacheFile.hx

+ 4 - 1
hxsl/CacheFile.hx

@@ -332,7 +332,10 @@ class CacheFile extends Cache {
 					throw "assert";
 				}
 				var rt2 = rttMap.get(r.specSign);
-				if( rt2 != null ) throw "assert";
+				if( rt2 != null ) {
+					log("Duplicate runtime shader found");
+					continue;
+				}
 				runtimeShaders.push(rt);
 				rttMap.set(r.specSign, { rt : rt, shaders : shaderList });
 			}