Added support for --material-debug command line option, which prints
the texture the kart is on and its slowdown related parameters. This should help debugging incorrect slowdowns. git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@6341 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
parent
3e4e4e00f1
commit
87f849184d
@ -831,6 +831,15 @@ void Kart::update(float dt)
|
||||
MaxSpeed::setSlowdown(MaxSpeed::MS_DECREASE_TERRAIN,
|
||||
material->getMaxSpeedFraction(),
|
||||
material->getSlowDownTime() );
|
||||
#ifdef DEBUG
|
||||
if(UserConfigParams::m_material_debug)
|
||||
{
|
||||
printf("%s\tfraction %f\ttime %f.\n",
|
||||
material->getTexFname().c_str(),
|
||||
material->getMaxSpeedFraction(),
|
||||
material->getSlowDownTime() );
|
||||
}
|
||||
#endif
|
||||
}
|
||||
} // if there is material
|
||||
|
||||
|
@ -257,6 +257,10 @@ int handleCmdLine(int argc, char **argv)
|
||||
{
|
||||
UserConfigParams::m_track_debug=1;
|
||||
}
|
||||
else if(!strcmp(argv[i], "--material-debug"))
|
||||
{
|
||||
UserConfigParams::m_material_debug = true;
|
||||
}
|
||||
else if(!strcmp(argv[i], "--camera-debug"))
|
||||
{
|
||||
UserConfigParams::m_camera_debug=1;
|
||||
|
Loading…
Reference in New Issue
Block a user