From 3acd6b2f3353d4a97e0bf0243aaca51451fb2cba Mon Sep 17 00:00:00 2001 From: Nehon Date: Thu, 12 Feb 2015 22:27:51 +0100 Subject: [PATCH] Fixed the error message when types/swizzles in a variable mapping do not match --- .../com/jme3/material/plugins/ShaderNodeLoaderDelegate.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jme3-core/src/plugins/java/com/jme3/material/plugins/ShaderNodeLoaderDelegate.java b/jme3-core/src/plugins/java/com/jme3/material/plugins/ShaderNodeLoaderDelegate.java index 5abe4d1ee..4437293f3 100644 --- a/jme3-core/src/plugins/java/com/jme3/material/plugins/ShaderNodeLoaderDelegate.java +++ b/jme3-core/src/plugins/java/com/jme3/material/plugins/ShaderNodeLoaderDelegate.java @@ -1058,12 +1058,12 @@ public class ShaderNodeLoaderDelegate { if (!ShaderUtils.typesMatch(mapping)) { String ls = mapping.getLeftSwizzling().length() == 0 ? "" : "." + mapping.getLeftSwizzling(); String rs = mapping.getRightSwizzling().length() == 0 ? "" : "." + mapping.getRightSwizzling(); - throw new MatParseException("Type mismatch, cannot convert" + mapping.getLeftVariable().getType() + ls + " to " + mapping.getRightVariable().getType() + rs, statement1); + throw new MatParseException("Type mismatch, cannot convert " + mapping.getRightVariable().getType() + rs + " to " + mapping.getLeftVariable().getType() + ls, statement1); } if (!ShaderUtils.multiplicityMatch(mapping)) { String type1 = mapping.getLeftVariable().getType() + "[" + mapping.getLeftVariable().getMultiplicity() + "]"; String type2 = mapping.getRightVariable().getType() + "[" + mapping.getRightVariable().getMultiplicity() + "]"; - throw new MatParseException("Type mismatch, cannot convert" + type1 + " to " + type2, statement1); + throw new MatParseException("Type mismatch, cannot convert " + type1 + " to " + type2, statement1); } }