Skip to content

Instantly share code, notes, and snippets.

Created November 9, 2012 15:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/4046199 to your computer and use it in GitHub Desktop.
Save anonymous/4046199 to your computer and use it in GitHub Desktop.
VCMI Den of Thieves fix
--- client/GUIClasses.cpp (revision 3001)
+++ client/GUIClasses.cpp (working copy)
@@ -5589,7 +5589,8 @@
for (size_t j=0; j< 2; j++)
{
// origin of this row | offset for 2nd row| shift right for short rows
- int rowStartX = xpos + (j ? 6 : 0) + (rowLength[j] < 3 ? 12 : 0);
+ //if we have 2 rows, start either from mid or beginning (depending on count), otherwise
center the flags
+ int rowStartX = xpos + (j ? 6 + (rowLength[j] < 3 ? 12 : 0) : 24 - 6 * rowLength[j]);
int rowStartY = ypos + (j ? 4 : 0);
for (size_t i=0; i< rowLength[j]; i++)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment