From 1d2cc1b78041d3ab6a998071a87b1fed2978e183 Mon Sep 17 00:00:00 2001 From: Tyrann Date: Sun, 23 Sep 2007 21:04:23 +0930 Subject: [PATCH] [PATCH] qbsp: copy face sphere attributes in NewFaceFromFace Makes sure we maintain the sphere, e.g. in SplitFace. Signed-off-by: Tyrann --- qbsp/csg4.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/qbsp/csg4.c b/qbsp/csg4.c index e0b70415..7dc31368 100644 --- a/qbsp/csg4.c +++ b/qbsp/csg4.c @@ -60,6 +60,9 @@ NewFaceFromFace(face_t *in) newf->contents[0] = in->contents[0]; newf->contents[1] = in->contents[1]; + VectorCopy(in->origin, newf->origin); + newf->radius = in->radius; + return newf; } @@ -295,8 +298,6 @@ SaveOutside(bool mirror) newf->planeside = f->planeside ^ 1; // reverse side newf->contents[0] = f->contents[1]; newf->contents[1] = f->contents[0]; - VectorCopy(f->origin, newf->origin); - newf->radius = f->radius; for (i = 0; i < f->w.numpoints; i++) // add points backwards VectorCopy(f->w.points[f->w.numpoints - 1 - i], newf->w.points[i]);