* Fixed crash in MaterialLoader when handling materials exported from Blender 2.57

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@7446 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
3.0
sha..rd 14 years ago
parent 0726ad61bf
commit d7995b4a6a
  1. 8
      engine/src/ogre/com/jme3/scene/plugins/ogre/MaterialLoader.java

@ -224,7 +224,13 @@ public class MaterialLoader implements AssetLoader {
diffuse = readColor();
}
}else if(keyword.equals("ambient")) {
ambient = readColor();
if (scan.hasNext("vertexcolour")){
// use vertex colors
ambient = ColorRGBA.White;
scan.next(); // skip it
}else{
ambient = readColor();
}
}else if (keyword.equals("specular")){
specular = new ColorRGBA();
specular.r = scan.nextFloat();

Loading…
Cancel
Save