diff --git a/jme3-core/src/main/java/com/jme3/material/Material.java b/jme3-core/src/main/java/com/jme3/material/Material.java index 3299f3624..4a6d04275 100644 --- a/jme3-core/src/main/java/com/jme3/material/Material.java +++ b/jme3-core/src/main/java/com/jme3/material/Material.java @@ -1325,9 +1325,9 @@ public class Material implements CloneableSmartAsset, Cloneable, Savable { param.setName(param.getName().substring(2)); } - if (def.getMaterialParam(name) == null) { - logger.log(Level.WARNING, "The material parameter is not defined: " + - name + ". Ignoring.."); + if (def.getMaterialParam(param.getName()) == null) { + logger.log(Level.WARNING, "The material parameter is not defined: {0}. Ignoring..", + param.getName()); } else { checkSetParam(param.getVarType(), param.getName()); paramValues.put(param.getName(), param);