From: Mircea Kitsune Date: Sun, 6 Nov 2011 22:49:13 +0000 (+0200) Subject: Fix a bug which would cause the bounding box to get an incorrect size if scaling... X-Git-Tag: xonotic-v0.6.0~35^2~18^2~5 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=bfa4a6299d75630d344f9d835541fb95e9f3a047;p=xonotic%2Fxonotic-data.pk3dir.git Fix a bug which would cause the bounding box to get an incorrect size if scaling a model back and forth --- diff --git a/qcsrc/server/mutators/sandbox.qc b/qcsrc/server/mutators/sandbox.qc index 264aa83a7..bb6b3e647 100644 --- a/qcsrc/server/mutators/sandbox.qc +++ b/qcsrc/server/mutators/sandbox.qc @@ -84,6 +84,7 @@ void sandbox_ObjectEdit_Scale(entity e, float f) if(e.scale) { e.scale = bound(autocvar_g_sandbox_object_scale_min, e.scale, autocvar_g_sandbox_object_scale_max); + setmodel(e, e.model); // reset mins and maxs based on mesh setsize(e, e.mins * e.scale, e.maxs * e.scale); // adapt bounding box size to model size } }