Merge branch 'fix-trap' of https://github.com/argrath/NetHack into pr712
This commit is contained in:
+4
-1
@@ -3025,11 +3025,14 @@ find_random_launch_coord(struct trap *ttmp, coord *cc)
|
|||||||
int mindist = 4;
|
int mindist = 4;
|
||||||
int trycount = 0;
|
int trycount = 0;
|
||||||
xchar dx, dy;
|
xchar dx, dy;
|
||||||
xchar x = ttmp->tx, y = ttmp->ty;
|
xchar x, y;
|
||||||
|
|
||||||
if (!ttmp || !cc)
|
if (!ttmp || !cc)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
|
x = ttmp->tx;
|
||||||
|
y = ttmp->ty;
|
||||||
|
|
||||||
bcc.x = ttmp->tx + g.launchplace.x;
|
bcc.x = ttmp->tx + g.launchplace.x;
|
||||||
bcc.y = ttmp->ty + g.launchplace.y;
|
bcc.y = ttmp->ty + g.launchplace.y;
|
||||||
if (isok(bcc.x, bcc.y) && linedup(ttmp->tx, ttmp->ty, bcc.x, bcc.y, 1)) {
|
if (isok(bcc.x, bcc.y) && linedup(ttmp->tx, ttmp->ty, bcc.x, bcc.y, 1)) {
|
||||||
|
|||||||
Reference in New Issue
Block a user