Only reset if we actually went to travel destination

This commit is contained in:
Pasi Kallinen
2020-10-17 12:13:17 +03:00
parent a9e4904131
commit 5ddafa5c81

View File

@@ -540,7 +540,8 @@ struct obj *scroll;
if (teleok(cc.x, cc.y, FALSE)) {
/* for scroll, discover it regardless of destination */
teleds(cc.x, cc.y, TELEDS_TELEPORT);
iflags.travelcc.x = iflags.travelcc.y = 0;
if (iflags.travelcc.x == cc.x && iflags.travelcc.y == cc.y)
iflags.travelcc.x = iflags.travelcc.y = 0;
return;
}
pline("Sorry...");