Make sure that achievements depth is never greater than 2.

Current GUI doesn't allow it and it has no sense anyway.
This commit is contained in:
Deve 2018-11-11 01:41:49 +01:00
parent bf26e4add3
commit 90fb3f2c55

View File

@ -43,6 +43,7 @@ AchievementProgressDialog::AchievementProgressDialog(Achievement *achievement)
loadFromFile("online/achievement_progress_dialog.stkgui");
m_depth = m_achievement->getInfo()->getDepth();
assert (m_depth < 3);
m_progress_table = getWidget<ListWidget>("progress-tree");
assert(m_progress_table != NULL);