Fix "name lookup of ‘i’ changed" warning in editor.cpp

I got this warning during compilation because there were two nested for
loops both defining i. Better to have different names to make sure some
compilers won't overwrite the outer variable with the inner one.
This commit is contained in:
Dav999-v authored and Ethan Lee committed 2020-10-13 22:39:12 -04:00
1 parent b8a4b4dfe7
commit 70e82dfe12
1 file changed
+3 -3
+3 -3
View File
@@ -2688,7 +2688,7 @@ void editorrender()
drawRect = graphics.tiles_rect;
drawRect.x += tpoint.x;
drawRect.y += tpoint.y;
for (int i = 0; i < 4; i++) {
for (int j = 0; j < 4; j++) {
if (custom_gray) BlitSurfaceTinted(graphics.entcolours[obj.customplatformtile],NULL, graphics.backBuffer, &drawRect, gray_ct);
else BlitSurfaceStandard(graphics.entcolours[obj.customplatformtile],NULL, graphics.backBuffer, &drawRect);
drawRect.x += 8;
@@ -2721,7 +2721,7 @@ void editorrender()
drawRect = graphics.tiles_rect;
drawRect.x += tpoint.x;
drawRect.y += tpoint.y;
for (int i = 0; i < 4; i++) {
for (int j = 0; j < 4; j++) {
if (custom_gray) BlitSurfaceTinted(graphics.entcolours[obj.customplatformtile],NULL, graphics.backBuffer, &drawRect, gray_ct);
else BlitSurfaceStandard(graphics.entcolours[obj.customplatformtile],NULL, graphics.backBuffer, &drawRect);
drawRect.x += 8;
@@ -2749,7 +2749,7 @@ void editorrender()
drawRect = graphics.tiles_rect;
drawRect.x += tpoint.x;
drawRect.y += tpoint.y;
for (int i = 0; i < 4; i++) {
for (int j = 0; j < 4; j++) {
if (custom_gray) BlitSurfaceTinted(graphics.entcolours[obj.customplatformtile],NULL, graphics.backBuffer, &drawRect, gray_ct);
else BlitSurfaceStandard(graphics.entcolours[obj.customplatformtile],NULL, graphics.backBuffer, &drawRect);
drawRect.x += 8;