Merge branch 'fix-trap' of https://github.com/argrath/NetHack into pr712

This commit is contained in:
nhmall
2022-03-25 08:21:49 -04:00

View File

@@ -3025,11 +3025,14 @@ find_random_launch_coord(struct trap *ttmp, coord *cc)
int mindist = 4;
int trycount = 0;
xchar dx, dy;
xchar x = ttmp->tx, y = ttmp->ty;
xchar x, y;
if (!ttmp || !cc)
return FALSE;
x = ttmp->tx;
y = ttmp->ty;
bcc.x = ttmp->tx + g.launchplace.x;
bcc.y = ttmp->ty + g.launchplace.y;
if (isok(bcc.x, bcc.y) && linedup(ttmp->tx, ttmp->ty, bcc.x, bcc.y, 1)) {