From: res Date: Wed, 2 Jan 2008 01:08:11 +0000 (+0000) Subject: Made CSQC_AddRenderEdict compute the tag matrix if a tag is set. X-Git-Tag: xonotic-v0.1.0preview~2603 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=706ba4402b7f21c59c9894bd8d5ade30f1b9860e;p=xonotic%2Fdarkplaces.git Made CSQC_AddRenderEdict compute the tag matrix if a tag is set. git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@7892 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/clvm_cmds.h b/clvm_cmds.h new file mode 100644 index 00000000..58928c2f --- /dev/null +++ b/clvm_cmds.h @@ -0,0 +1,6 @@ +#ifndef __CLVM_CMDS_H__ +#define __CLVM_CMDS_H__ + +int CL_GetTagMatrix (matrix4x4_t *out, prvm_edict_t *ent, int tagindex); + +#endif /* __CLVM_CMDS_H__ */ diff --git a/csprogs.c b/csprogs.c index facc2308..9211626e 100644 --- a/csprogs.c +++ b/csprogs.c @@ -4,6 +4,7 @@ #include "csprogs.h" #include "cl_collision.h" #include "snd_main.h" +#include "clvm_cmds.h" //============================================================================ // Client prog handling @@ -157,8 +158,7 @@ qboolean CSQC_AddRenderEdict(prvm_edict_t *ed) tagentity = val->edict; if((val = PRVM_EDICTFIELDVALUE(ed, prog->fieldoffsets.tag_index)) && val->_float) tagindex = (int)val->_float; - // FIXME: calculate tag matrix - Matrix4x4_CreateIdentity(&tagmatrix); + CL_GetTagMatrix (&tagmatrix, PRVM_PROG_TO_EDICT(tagentity), tagindex); } else Matrix4x4_CreateIdentity(&tagmatrix);