]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/lib/csqcmodel/cl_model.qc
Merge branch 'sev/lumaIcons' into 'master'
[xonotic/xonotic-data.pk3dir.git] / qcsrc / lib / csqcmodel / cl_model.qc
index 6b86092967e67dd5b9638bafce9585ebfbec16fb..05aba388c4b7c27a49d13cdb160a75afc559a43b 100644 (file)
 #include "cl_player.qh"
 #include "common.qh"
 #include "interpolate.qh"
-#include <client/defs.qh>
-#include <common/animdecide.qh>
 #include <common/csqcmodel_settings.qh>
-#include <common/util.qh>
 
 float autocvar_cl_lerpanim_maxdelta_framegroups = 0.1;
 float autocvar_cl_nolerp = 0;
@@ -194,6 +191,14 @@ void CSQCModel_Draw(entity this)
 
        CSQCModel_Hook_PreDraw(this, isplayer);
 
+       if(isplayer)
+       {
+               if(this.entnum == player_localentnum)
+                       this.renderflags |= RF_EXTERNALMODEL;
+               else
+                       this.renderflags &= ~RF_EXTERNALMODEL;
+       }
+
        // inherit draw flags easily
        entity root = this;
        while(root.tag_entity)
@@ -267,6 +272,9 @@ NET_HANDLE(ENT_CLIENT_MODEL, bool isnew)
                this.csqcmodel_teleported = 1;
        }
 
+       if(sf & BIT(14))
+               viewloc_SetTags(this);
+
        CSQCModel_InterpolateAnimation_Note(this, sf);
        InterpolateOrigin_Note(this);
        CSQCPlayer_PostUpdate(this);