attempt to fix the dark models at centers of dlights

This commit is contained in:
Bill Currie 2002-08-12 15:36:52 +00:00
parent 8e97d6279a
commit 2abaf27cdc

View file

@ -543,10 +543,12 @@ R_DrawAliasModel (entity_t *e, qboolean cull)
for (lnum = 0; lnum < r_maxdlights; lnum++) { for (lnum = 0; lnum < r_maxdlights; lnum++) {
if (r_dlights[lnum].die >= r_realtime) { if (r_dlights[lnum].die >= r_realtime) {
float d;
VectorSubtract (e->origin, r_dlights[lnum].origin, dist); VectorSubtract (e->origin, r_dlights[lnum].origin, dist);
add = ((r_dlights[lnum].radius d = DotProduct (dist, dist);
* r_dlights[lnum].radius * 8) d = max (d, 1);
/ DotProduct (dist, dist)); // FIXME Deek add = r_dlights[lnum].radius * r_dlights[lnum].radius * 8 / d;
if (add > 0) { if (add > 0) {
VectorMA (ambientcolor, add, r_dlights[lnum].color, VectorMA (ambientcolor, add, r_dlights[lnum].color,