]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
fix steelstorm animated shader timing (shadertime was not declared in
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Mon, 23 May 2011 11:08:46 +0000 (11:08 +0000)
committerRudolf Polzer <divVerent@xonotic.org>
Mon, 23 May 2011 11:33:13 +0000 (13:33 +0200)
this csprogs.dat and the old code checked for that, no longer possible)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@11162 d7cf8633-e32d-0410-b094-e92efae38249
::stable-branch::merge=9ae45aa38830d74344ac5d7a959788a2d89b5a6f

csprogs.c

index 58290c5b88f001ab9e7af72d061f7a503a34a633..1a71803937636a7735ebc82f9bee6092e0fcb27f 100644 (file)
--- a/csprogs.c
+++ b/csprogs.c
@@ -360,7 +360,8 @@ qboolean CSQC_AddRenderEdict(prvm_edict_t *ed, int edictnum)
        VM_GenerateFrameGroupBlend(ed->priv.server->framegroupblend, ed);
        VM_FrameBlendFromFrameGroupBlend(ed->priv.server->frameblend, ed->priv.server->framegroupblend, model);
        VM_UpdateEdictSkeleton(ed, model, ed->priv.server->frameblend);
-       entrender->shadertime = PRVM_clientedictfloat(ed, shadertime);
+       if (PRVM_clientedictfloat(ed, shadertime)) // hack for csprogs.dat files that do not set shadertime, leaves the value at entity spawn time
+               entrender->shadertime = PRVM_clientedictfloat(ed, shadertime);
 
        // transparent offset
        if (renderflags & RF_USETRANSPARENTOFFSET)