Fixed an issue in material when having classic lights along with a LightProbe

This commit is contained in:
Rémy Bouquet 2015-11-06 09:19:33 +01:00
parent 7d07a63ebf
commit 45321fc7d5

View File

@ -787,12 +787,15 @@ public class Material implements CloneableSmartAsset, Cloneable, Savable {
}
ColorRGBA color = l.getColor();
//Color
lightData.setVector4InArray(color.getRed(),
color.getGreen(),
color.getBlue(),
l.getType().getId(),
lightDataIndex);
lightDataIndex++;
if(l.getType() != Light.Type.Probe){
lightData.setVector4InArray(color.getRed(),
color.getGreen(),
color.getBlue(),
l.getType().getId(),
lightDataIndex);
lightDataIndex++;
}
switch (l.getType()) {
case Directional: