Fix kart selection confirmation + fix ModelViewWidget::setRotateTo() that was not using the rotation speed
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/branches/christmas@12438 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
parent
c83678801e
commit
5ec7bd3a2d
@ -133,11 +133,11 @@ void ModelViewWidget::update(float delta)
|
||||
|
||||
if (distance_with_positive_rotation < distance_with_negative_rotation)
|
||||
{
|
||||
angle += delta*(3.0f + std::min(distance_with_positive_rotation, distance_with_negative_rotation)*2.0f);
|
||||
angle += m_rotation_speed * delta*(3.0f + std::min(distance_with_positive_rotation, distance_with_negative_rotation)*2.0f);
|
||||
}
|
||||
else
|
||||
{
|
||||
angle -= delta*(3.0f + std::min(distance_with_positive_rotation, distance_with_negative_rotation)*2.0f);
|
||||
angle -= m_rotation_speed * delta*(3.0f + std::min(distance_with_positive_rotation, distance_with_negative_rotation)*2.0f);
|
||||
}
|
||||
if (angle > 360) angle -= 360;
|
||||
if (angle < 0) angle += 360;
|
||||
@ -195,4 +195,4 @@ void ModelViewWidget::clearRttProvider()
|
||||
{
|
||||
delete m_rtt_provider;
|
||||
m_rtt_provider = NULL;
|
||||
}
|
||||
}
|
||||
|
@ -605,7 +605,7 @@ public:
|
||||
|
||||
sfx_manager->quickSound( "wee" );
|
||||
|
||||
m_model_view->setRotateTo(30.0f, 150.0f);
|
||||
m_model_view->setRotateTo(30.0f, 1.0f);
|
||||
|
||||
player_id_w *= 2;
|
||||
player_name_w = 0;
|
||||
|
@ -35,7 +35,7 @@ using namespace GUIEngine;
|
||||
DEFINE_SCREEN_SINGLETON( SoccerSetupScreen );
|
||||
|
||||
#define KART_CONTINUOUS_ROTATION_SPEED 35.f
|
||||
#define KART_CONFIRMATION_ROTATION_SPEED 100.f
|
||||
#define KART_CONFIRMATION_ROTATION_SPEED 4.f
|
||||
#define KART_CONFIRMATION_TARGET_ANGLE 10.f
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
@ -199,6 +199,7 @@ GUIEngine::EventPropagation SoccerSetupScreen::filterActions( PlayerAction acti
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case PA_MENU_CANCEL:
|
||||
{
|
||||
@ -214,8 +215,8 @@ GUIEngine::EventPropagation SoccerSetupScreen::filterActions( PlayerAction acti
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user