Correctly restore the saved start point.

This fixes the point test failures.
This commit is contained in:
Bill Currie 2011-12-04 21:12:12 +09:00
parent 7da6df9dfb
commit b4a497baab
2 changed files with 8 additions and 4 deletions

View file

@ -115,8 +115,14 @@ test_t tests[] = {
{ -8, 0, 8}, {-12, 0, 12}, { 1, 0, 0, 1, 0, 9}},
{"Point, Covered Step touch backside", &point, &hull_covered_step,
{ 0, 0, 8}, {-12, 0, 12}, { 1, 0, 1, 1, 0, 9}},
{"Point, Covered Step start solid", &point, &hull_covered_step,
{ 0, 0, -4}, {-16, 0, 12}, { 1, 0, 1, 1, 0, 9}},
{"Point, Covered Step start solid", &point, &hull_covered_step,
{ 4, 0, -4}, {-12, 0, 12}, { 1, 1, 1, 0, 0, 9}},
{"Box, Covered Step start solid", &box, &hull_covered_step,
{ -4, 0, 4}, {-12, 0, 12}, { 1, 0, 1, 1, 0, 9}},
{ -4, 0, 4}, {-12, 0, 12}, { 1, 1, 1, 0, 0, 9}},
{"Box, Covered Step start solid", &box, &hull_covered_step,
{ -17, 0, 4}, {-17, 0, 12}, { 1, 0, 1, 1, 0, 9}},
{"Box, Covered Step start solid", &box, &hull_covered_step,
{ -4, 0, 4}, {-16, 0, 36}, { 0.875, 0, 1, 1, 0, 9}},
{"Box, Covered Step start solid", &box, &hull_covered_step,

View file

@ -747,10 +747,8 @@ MOD_TraceLine (hull_t *hull, int num,
}
} while (tstack->start_frac > trace->fraction);
// set the hit point for this plane
VectorCopy (end, tstack->start);
// go down the back side
VectorCopy (tstack->start, start);
VectorCopy (tstack->end, end);
side = tstack->side;
trace_state.split_plane = tstack->plane;