ShaderNodeDefinition path is now set while loading the definition.

fix-456
Nehon 8 years ago
parent 26ccaaea88
commit 2f06c9b37b
  1. 2
      jme3-core/src/plugins/java/com/jme3/material/plugins/ShaderNodeLoaderDelegate.java

@ -193,6 +193,7 @@ public class ShaderNodeLoaderDelegate {
shaderNodeDefinition = new ShaderNodeDefinition(); shaderNodeDefinition = new ShaderNodeDefinition();
getNodeDefinitions().put(name, shaderNodeDefinition); getNodeDefinitions().put(name, shaderNodeDefinition);
shaderNodeDefinition.setName(name); shaderNodeDefinition.setName(name);
shaderNodeDefinition.setPath(key.getName());
readShaderNodeDefinition(statement.getContents(), key); readShaderNodeDefinition(statement.getContents(), key);
} }
@ -942,7 +943,6 @@ public class ShaderNodeLoaderDelegate {
} }
for (ShaderNodeDefinition definition : defs) { for (ShaderNodeDefinition definition : defs) {
definition.setPath(defLine[2].trim());
if (defName.equals(definition.getName())) { if (defName.equals(definition.getName())) {
def = definition; def = definition;
} }

Loading…
Cancel
Save