]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - cl_collision.c
got rid of Mod_CheckLoaded, changed how model system restart works to make this work...
[xonotic/darkplaces.git] / cl_collision.c
index c97f0a3f4dbff6efc60ee914815f812d35606bc3..8f38186079b12b8b94d74a75af540f36ee64e723 100644 (file)
@@ -48,7 +48,6 @@ trace_t CL_TraceBox(const vec3_t start, const vec3_t mins, const vec3_t maxs, co
        cliptrace.fraction = 1;
        cliptrace.realfraction = 1;
 
-       Mod_CheckLoaded(cl.worldmodel);
        if (cl.worldmodel && cl.worldmodel->TraceBox)
                cl.worldmodel->TraceBox(cl.worldmodel, 0, &cliptrace, startmins, startmaxs, endmins, endmaxs, hitsupercontentsmask);
 
@@ -196,7 +195,6 @@ float CL_SelectTraceLine(const vec3_t start, const vec3_t end, vec3_t impact, ve
 
        if (hitent)
                *hitent = 0;
-       Mod_CheckLoaded(cl.worldmodel);
        if (cl.worldmodel && cl.worldmodel->TraceBox)
                cl.worldmodel->TraceBox(cl.worldmodel, 0, &trace, start, start, end, end, SUPERCONTENTS_SOLID);
 
@@ -223,6 +221,8 @@ float CL_SelectTraceLine(const vec3_t start, const vec3_t end, vec3_t impact, ve
                        continue;
                if (!ent->model || !ent->model->TraceBox)
                        continue;
+               if ((ent->flags & RENDER_EXTERIORMODEL) && !chase_active.integer)
+                       continue;
                // if transparent and not selectable, skip entity
                if (!(cl_entities[n].state_current.effects & EF_SELECTABLE) && (ent->alpha < 1 || (ent->effects & (EF_ADDITIVE | EF_NODEPTHTEST))))
                        continue;