- moveclip_t clip;
- vec3_t bigmins, bigmaxs;
- int i;
-
- memset ( &clip, 0, sizeof ( moveclip_t ) );
-
- VectorCopy(start, clip.start);
- VectorCopy(end, clip.end);
- VectorCopy(mins, clip.mins);
- VectorCopy(maxs, clip.maxs);
- clip.type = type;
- clip.passedict = passedict;
-
- Collision_RoundUpToHullSize(sv.worldmodel, clip.mins, clip.maxs, clip.hullmins, clip.hullmaxs);
-
- if (type == MOVE_MISSILE)
- {
- // LordHavoc: modified this, was = -15, now = clip.mins[i] - 15
- for (i=0 ; i<3 ; i++)
- {
- clip.mins2[i] = clip.mins[i] - 15;
- clip.maxs2[i] = clip.maxs[i] + 15;
- }
- }
- else
- {
- VectorCopy (clip.mins, clip.mins2);
- VectorCopy (clip.maxs, clip.maxs2);
- }
-
- bigmins[0] = min(clip.mins2[0], clip.hullmins[0]);
- bigmaxs[0] = max(clip.maxs2[0], clip.hullmaxs[0]);
- bigmins[1] = min(clip.mins2[1], clip.hullmins[1]);
- bigmaxs[1] = max(clip.maxs2[1], clip.hullmaxs[1]);
- bigmins[2] = min(clip.mins2[2], clip.hullmins[2]);
- bigmaxs[2] = max(clip.maxs2[2], clip.hullmaxs[2]);
-
- // clip to world
- clip.trace = SV_ClipMoveToEntity (sv.edicts, start, mins, maxs, end);
-
- // clip to entities
- // create the bounding box of the entire move
- SV_MoveBounds ( start, bigmins, bigmaxs, end, clip.boxmins, clip.boxmaxs );
-
- SV_ClipToAreaGrid(&clip);