From: divverent Date: Mon, 6 Sep 2010 06:21:51 +0000 (+0000) Subject: fix CSQC being unable to use the "effects" field as its fieldoffset never got initialized X-Git-Tag: xonotic-v0.1.0preview~230^2~38 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=e46b145fb645c005413c7f34360d1d02498f8898;p=xonotic%2Fdarkplaces.git fix CSQC being unable to use the "effects" field as its fieldoffset never got initialized git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10446 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/csprogs.c b/csprogs.c index 92a88720..aa438a52 100644 --- a/csprogs.c +++ b/csprogs.c @@ -205,7 +205,7 @@ qboolean CSQC_AddRenderEdict(prvm_edict_t *ed, int edictnum) if((val = PRVM_EDICTFIELDVALUE(ed, prog->fieldoffsets.scale)) && val->_float) entrender->scale = scale = val->_float; if((val = PRVM_EDICTFIELDVALUE(ed, prog->fieldoffsets.colormod)) && VectorLength2(val->vector)) VectorCopy(val->vector, entrender->colormod); if((val = PRVM_EDICTFIELDVALUE(ed, prog->fieldoffsets.glowmod)) && VectorLength2(val->vector)) VectorCopy(val->vector, entrender->glowmod); - if((val = PRVM_EDICTFIELDVALUE(ed, prog->fieldoffsets.effects)) && val->_float) entrender->effects |= (int)val->_float; + if(ed->fields.client->effects) entrender->effects |= (int)ed->fields.client->effects; if((val = PRVM_EDICTFIELDVALUE(ed, prog->fieldoffsets.tag_entity)) && val->edict) { int tagentity; diff --git a/progsvm.h b/progsvm.h index 323ae71b..85610510 100644 --- a/progsvm.h +++ b/progsvm.h @@ -191,7 +191,6 @@ typedef struct prvm_prog_fieldoffsets_s int discardabledemo; // ssqc int dphitcontentsmask; // ssqc / csqc int drawonlytoclient; // ssqc - int effects; // ssqc / csqc int exteriormodeltoclient; // ssqc int fatness; // ssqc / csqc int forceshader; // csqc