Tidy up the corpse related code in SV_Push.

This commit is contained in:
Bill Currie 2011-12-22 11:18:27 +09:00
parent 4ade879674
commit d1be716031
2 changed files with 5 additions and 9 deletions

View file

@ -512,13 +512,12 @@ SV_Push (edict_t *pusher, const vec3_t tmove, const vec3_t amove)
// if it is still inside the pusher, block
c_mins = SVvector (check, mins);
c_maxs = SVvector (check, maxs);
if (c_mins[0] == c_maxs[0]) {
continue;
}
c_solid = SVfloat (check, solid);
if (c_solid == SOLID_NOT || c_solid == SOLID_TRIGGER) { // corpse
if (c_mins[0] == c_maxs[0]
|| c_solid == SOLID_NOT || c_solid == SOLID_TRIGGER) { // corpse
c_mins[0] = c_mins[1] = 0;
VectorCopy (c_mins, c_maxs);
SV_LinkEdict (check, false);
continue;
}

View file

@ -514,12 +514,9 @@ SV_Push (edict_t *pusher, const vec3_t tmove, const vec3_t amove)
// if it is still inside the pusher, block
c_mins = SVvector (check, mins);
c_maxs = SVvector (check, maxs);
if (c_mins[0] == c_maxs[0]) {
SV_LinkEdict (check, false);
continue;
}
c_solid = SVfloat (check, solid);
if (c_solid == SOLID_NOT || c_solid == SOLID_TRIGGER) { // corpse
if (c_mins[0] == c_maxs[0]
|| c_solid == SOLID_NOT || c_solid == SOLID_TRIGGER) { // corpse
c_mins[0] = c_mins[1] = 0;
VectorCopy (c_mins, c_maxs);
SV_LinkEdict (check, false);