mirror of
https://github.com/coding-horror/basic-computer-games.git
synced 2025-12-28 05:33:48 -08:00
Merge pull request #400 from mcdurdin/patch-1
fix(amazing): guarantee exit on bottom row of maze
This commit is contained in:
@@ -117,10 +117,15 @@
|
||||
975 V(R,S)=3:Q=0:GOTO 1000
|
||||
980 V(R,S)=1:Q=0:R=1:S=1:GOTO 250
|
||||
1000 GOTO 210
|
||||
1010 FOR J=1 TO V
|
||||
1011 PRINT "I";
|
||||
1012 FOR I=1 TO H
|
||||
1013 IF V(I,J)<2 THEN 1030
|
||||
1010 IF Z=1 THEN 1015
|
||||
1011 X=INT(RND(1)*H+1)
|
||||
1012 IF V(X,V)=0 THEN 1014
|
||||
1013 V(X,V)=3: GOTO 1015
|
||||
1014 V(X,V)=1
|
||||
1015 FOR J=1 TO V
|
||||
1016 PRINT "I";
|
||||
1017 FOR I=1 TO H
|
||||
1018 IF V(I,J)<2 THEN 1030
|
||||
1020 PRINT " ";
|
||||
1021 GOTO 1040
|
||||
1030 PRINT " I";
|
||||
|
||||
Reference in New Issue
Block a user