Browse Source

Shader live reload: remove trace

Tom Spira 8 months ago
parent
commit
6e8f318834
1 changed files with 3 additions and 4 deletions
  1. 3 4
      hxsl/SharedShader.hx

+ 3 - 4
hxsl/SharedShader.hx

@@ -268,14 +268,13 @@ class SharedShader {
 	function initLiveReload() {
 	function initLiveReload() {
 		if( module == null )
 		if( module == null )
 			return;
 			return;
-		if( hxd.fs.SourceLoader.isActive() )
-			SHADER_RESOLVE.set(data.name, this);
+		if( !hxd.fs.SourceLoader.isActive() )
+			return;
+		SHADER_RESOLVE.set(data.name, this);
 		var path = module.split(".").join("/")+".hx";
 		var path = module.split(".").join("/")+".hx";
 		file = hxd.fs.SourceLoader.resolve(path);
 		file = hxd.fs.SourceLoader.resolve(path);
 		if( file != null )
 		if( file != null )
 			file.watch(onFileReload);
 			file.watch(onFileReload);
-		else
-			trace("Could not live reload shader "+data.name);
 	}
 	}
 
 
 	function onFileReload() {
 	function onFileReload() {