SDK : Material editor fixed an npe in MaterialProperty when a param value was null

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@10438 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
This commit is contained in:
rem..om 2013-02-26 19:54:17 +00:00
parent 6a86bf034e
commit ce86297979

View File

@ -28,9 +28,11 @@ public class MaterialProperty {
public MaterialProperty(MatParam param) {
this.type = param.getVarType().name();
this.name = param.getName();
try {
this.value = param.getValueAsString();
} catch (UnsupportedOperationException e) {
if (param.getValue() != null) {
try {
this.value = param.getValueAsString();
} catch (UnsupportedOperationException e) {
}
}
}