Cleaned up whitespace

Fixed Directional Attenuation (assumed, data was light dir vector already, but it was not!)
This commit is contained in:
NanoByte011 2015-01-21 22:30:41 -07:00
parent f475e367f2
commit 0a9257ad37

View File

@ -61,7 +61,7 @@ static void GenerateLightShader(T& object, LightingUidData& uid_data, int index,
{
case LIGHTATTN_NONE:
case LIGHTATTN_DIR:
object.Write("ldir = normalize(" LIGHT_POS".xyz);\n", LIGHT_POS_PARAMS(index));
object.Write("ldir = normalize(" LIGHT_POS".xyz - pos.xyz);\n", LIGHT_POS_PARAMS(index));
object.Write("attn = 1.0f;\n");
break;
case LIGHTATTN_SPEC: