Added a flag ShowShadow in WithVoxelBarrel, WithVoxelBody, WithVoxelTurret, WithVoxelUnloadBody and WithVoxelWalkerBody

This commit is contained in:
abc013
2016-09-20 13:34:05 +02:00
parent c9474a857a
commit b9d1f373fe
7 changed files with 33 additions and 14 deletions

View File

@@ -212,8 +212,9 @@ namespace OpenRA.Graphics
lightAmbientColor, lightDiffuseColor, color.TextureMidIndex, normals.TextureMidIndex);
// Disable shadow normals by forcing zero diffuse and identity ambient light
Render(rd, Util.MatrixMultiply(shadow, t), lightDirection,
ShadowAmbient, ShadowDiffuse, shadowPalette.TextureMidIndex, normals.TextureMidIndex);
if (v.ShowShadow)
Render(rd, Util.MatrixMultiply(shadow, t), lightDirection,
ShadowAmbient, ShadowDiffuse, shadowPalette.TextureMidIndex, normals.TextureMidIndex);
}
}
}));