diff options
| author | void_17 <61356189+void2012@users.noreply.github.com> | 2026-03-06 02:11:18 +0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-03-06 02:11:18 +0700 |
| commit | 55231bb8d3e1a4e2752ac3d444c4287eb0ca4e8b (patch) | |
| tree | 953c537a5c66e328e9f4ab29626cf738112d53c0 /Minecraft.Client/AchievementScreen.cpp | |
| parent | 7d6658fe5b3095f35093701b5ab669ffc291e875 (diff) | |
Remove AUTO_VAR macro and _toString function (#592)
Diffstat (limited to 'Minecraft.Client/AchievementScreen.cpp')
| -rw-r--r-- | Minecraft.Client/AchievementScreen.cpp | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/Minecraft.Client/AchievementScreen.cpp b/Minecraft.Client/AchievementScreen.cpp index 26f20326..902aed17 100644 --- a/Minecraft.Client/AchievementScreen.cpp +++ b/Minecraft.Client/AchievementScreen.cpp @@ -261,12 +261,10 @@ void AchievementScreen::renderBg(int xm, int ym, float a) glDepthFunc(GL_LEQUAL); glDisable(GL_TEXTURE_2D); - - AUTO_VAR(itEnd, Achievements::achievements->end()); - for (AUTO_VAR(it, Achievements::achievements->begin()); it != itEnd; it++) + + for ( Achievement *ach : *Achievements::achievements ) { - Achievement *ach = *it; //Achievements::achievements->at(i); - if (ach->requires == NULL) continue; + if ( ach == nullptr || ach->requires == nullptr) continue; int x1 = ach->x * ACHIEVEMENT_COORD_SCALE - (int) xScroll + 11 + xBigMap; int y1 = ach->y * ACHIEVEMENT_COORD_SCALE - (int) yScroll + 11 + yBigMap; @@ -298,12 +296,9 @@ void AchievementScreen::renderBg(int xm, int ym, float a) glDisable(GL_LIGHTING); glEnable(GL_RESCALE_NORMAL); glEnable(GL_COLOR_MATERIAL); - - itEnd = Achievements::achievements->end(); - for (AUTO_VAR(it, Achievements::achievements->begin()); it != itEnd; it++) - { - Achievement *ach = *it; //Achievements::achievements->at(i); + for ( Achievement *ach : *Achievements::achievements ) + { int x = ach->x * ACHIEVEMENT_COORD_SCALE - (int) xScroll; int y = ach->y * ACHIEVEMENT_COORD_SCALE - (int) yScroll; |
