From 4708d07c4d112287be73a9e5567bc8854296cd5a Mon Sep 17 00:00:00 2001 From: hikerstk Date: Sun, 17 Feb 2008 12:29:14 +0000 Subject: [PATCH] Work around the physics problems for wilber and hexley kart by changing the size of the physical model to be the same as the tuxkart. git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/trunk/supertuxkart@1505 178a84e3-b1eb-0310-8ba1-8eac791a3b58 --- src/kart.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/kart.cpp b/src/kart.cpp index 6e0f260a6..2e0fcdb3e 100644 --- a/src/kart.cpp +++ b/src/kart.cpp @@ -175,6 +175,19 @@ void Kart::createPhysics(ssgEntity *obj) // ssgEntity *model = getModel(); float x_min, x_max, y_min, y_max, z_min, z_max; MinMax(obj, &x_min, &x_max, &y_min, &y_max, &z_min, &z_max); + if(getName()=="Hexley" || getName()=="Wilber") + { + // These kart models are too small, so we get problems with stability. + // Till we find either better (bigger) models or improve their physics + // parameters to become playable, we just adjust the size of their + // physical models to be the same as the tuxkart model + x_min=-0.473799; + x_max= 0.486361; + y_min=-0.772244; + y_max= 0.739075; + z_min= 0.002806; + z_max= 0.701095; + } float kart_width = x_max-x_min; m_kart_length = y_max-y_min; if(m_kart_length<1.2) m_kart_length=1.5f;