remove redundant assignments on join()

The values assigned there are overwritten by later code.
This commit is contained in:
SHIRAKATA Kentaro
2025-05-29 18:53:09 +09:00
parent c258011fbc
commit 13f46e585f
-8
View File
@@ -448,8 +448,6 @@ join(int a, int b, boolean nxcor)
if (troom->lx > croom->hx) { if (troom->lx > croom->hx) {
dx = 1; dx = 1;
dy = 0; dy = 0;
xx = croom->hx + 1;
tx = troom->lx - 1;
if (!finddpos(&cc, DIR_E, croom)) if (!finddpos(&cc, DIR_E, croom))
return; return;
if (!finddpos(&tt, DIR_W, troom)) if (!finddpos(&tt, DIR_W, troom))
@@ -457,8 +455,6 @@ join(int a, int b, boolean nxcor)
} else if (troom->hy < croom->ly) { } else if (troom->hy < croom->ly) {
dy = -1; dy = -1;
dx = 0; dx = 0;
yy = croom->ly - 1;
ty = troom->hy + 1;
if (!finddpos(&cc, DIR_N, croom)) if (!finddpos(&cc, DIR_N, croom))
return; return;
if (!finddpos(&tt, DIR_S, troom)) if (!finddpos(&tt, DIR_S, troom))
@@ -466,8 +462,6 @@ join(int a, int b, boolean nxcor)
} else if (troom->hx < croom->lx) { } else if (troom->hx < croom->lx) {
dx = -1; dx = -1;
dy = 0; dy = 0;
xx = croom->lx - 1;
tx = troom->hx + 1;
if (!finddpos(&cc, DIR_W, croom)) if (!finddpos(&cc, DIR_W, croom))
return; return;
if (!finddpos(&tt, DIR_E, troom)) if (!finddpos(&tt, DIR_E, troom))
@@ -475,8 +469,6 @@ join(int a, int b, boolean nxcor)
} else { } else {
dy = 1; dy = 1;
dx = 0; dx = 0;
yy = croom->hy + 1;
ty = troom->ly - 1;
if (!finddpos(&cc, DIR_S, croom)) if (!finddpos(&cc, DIR_S, croom))
return; return;
if (!finddpos(&tt, DIR_N, troom)) if (!finddpos(&tt, DIR_N, troom))