Fix wrong badge display

This commit is contained in:
Flakebi
2014-09-05 22:46:08 +02:00
parent a31ec772ff
commit 29a78d5cd8

View File

@@ -289,6 +289,18 @@ void PlayerKartWidget::setPlayerID(const int newPlayerID)
{
m_player_ident_spinner->setID(m_player_id);
}
m_model_view->unsetBadge(ZIPPER_BADGE);
m_model_view->unsetBadge(ANCHOR_BADGE);
// Add badge for per player difficulty if necessary
if (!m_parent_screen->m_from_overworld && (m_parent_screen->m_multiplayer || !m_parent_screen->profile_to_use->isSingleplayerDifficulty()))
{
PerPlayerDifficulty difficulty = m_parent_screen->profile_to_use->getDifficulty();
if (difficulty < PLAYER_DIFFICULTY_NORMAL)
m_model_view->setBadge(ZIPPER_BADGE);
else if (difficulty > PLAYER_DIFFICULTY_NORMAL)
m_model_view->setBadge(ANCHOR_BADGE);
}
} // setPlayerID
// ------------------------------------------------------------------------