diff --git a/libs/video/renderer/gl/gl_mod_sprite.c b/libs/video/renderer/gl/gl_mod_sprite.c index f6174c338..0190f03bd 100644 --- a/libs/video/renderer/gl/gl_mod_sprite.c +++ b/libs/video/renderer/gl/gl_mod_sprite.c @@ -83,10 +83,10 @@ R_GetSpriteFrame (entity_t *currententity) return pspriteframe; } -// FIXME: add modelalpha support? void R_DrawSpriteModel (entity_t *e) { + float color[4]; float *up, *right; msprite_t *psprite; mspriteframe_t *frame; @@ -110,11 +110,17 @@ R_DrawSpriteModel (entity_t *e) up = vup; right = vright; } + VectorScale (up, e->scale, up); + VectorScale (right, e->scale, right); qfglBindTexture (GL_TEXTURE_2D, frame->gl_texturenum); qfglBegin (GL_QUADS); + VectorCopy (e->colormod, color); + color[3] = e->alpha; + qfglColor4fv (color); + qfglTexCoord2f (0, 1); VectorMA (e->origin, frame->down, up, point); VectorMA (point, frame->left, right, point);