summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrey Nazarov <skuller@skuller.net>2013-03-19 03:38:31 +0400
committerAndrey Nazarov <skuller@skuller.net>2013-03-20 22:04:53 +0400
commit72166e9cddee2b882b423b6b6299f164e45f3ae5 (patch)
tree9ce1c0d4f2f5b5ea2c433b1c67dd070af0c0553c /src
parent99699c674b84290530995c6852b2add9b97d6d2d (diff)
Fix weapon shell scale in software mode.
Diffstat (limited to 'src')
-rw-r--r--src/refresh/sw/alias.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/refresh/sw/alias.c b/src/refresh/sw/alias.c
index 5d1f730..5d2c2e0 100644
--- a/src/refresh/sw/alias.c
+++ b/src/refresh/sw/alias.c
@@ -232,9 +232,14 @@ static void R_AliasTransformFinalVerts(int numpoints, finalvert_t *fv, maliasver
plightnormal = bytedirs[newv->lightnormalindex];
if (currententity->flags & RF_SHELL_MASK) {
- lerped_vert[0] += plightnormal[0] * POWERSUIT_SCALE;
- lerped_vert[1] += plightnormal[1] * POWERSUIT_SCALE;
- lerped_vert[2] += plightnormal[2] * POWERSUIT_SCALE;
+ float scale;
+
+ scale = (currententity->flags & RF_WEAPONMODEL) ?
+ WEAPONSHELL_SCALE : POWERSUIT_SCALE;
+
+ lerped_vert[0] += plightnormal[0] * scale;
+ lerped_vert[1] += plightnormal[1] * scale;
+ lerped_vert[2] += plightnormal[2] * scale;
}
fv->xyz[0] = DotProduct(lerped_vert, aliastransform[0]) + aliastransform[0][3];