OSDN Git Service

小箱を開けて「見る」と異常終了する問題を修正
authormaruhiro <maruhiro@bridge.ocn.ne.jp>
Fri, 23 Oct 2020 14:51:31 +0000 (23:51 +0900)
committermaruhiro <maruhiro@bridge.ocn.ne.jp>
Fri, 23 Oct 2020 14:51:31 +0000 (23:51 +0900)
COMMANDS.PAS

index 7bf5171..b876e6f 100644 (file)
@@ -216,7 +216,7 @@ if((en('a'))and(here(29)))or not(Prm in [6..24])then begin
          if(r[o]=Prm)then
           if not((Prm in[59..69])and(KeyHole)and(o=63))then
            begin writeln('',m[o,1],'\82ª\82 \82é\81B');
-            if(here(ropecon))and(o=ropecon)and not(ropecon in inven)then
+            if(ropecon<>Null)and(here(ropecon))and(o=ropecon)and not(ropecon in inven)then
              writeln('  \83\8d\81[\83v\82ª',m[o,1],'\82É\8c\8b\82Ñ\95t\82¯\82ç\82ê\82Ä\82¢\82é\81B');
             if(en('d'))and(o=70)and(here(70))then RL(147);
             if(o=SlotCon)and(here(o))then RL(388);
@@ -424,9 +424,9 @@ procedure MoveTo(NewRm : integer);
           begin RL(55);inven:=inven-[57];r[57]:=Prm;end
    else if not(57 in inven)and((ropecon in inven)or
           (ropecon in[60,56,44]))then r[57]:=NewRm
-   else if not(57 in inven)and(r[57]=Prm)and(r[ropecon]=NewRm)then
+   else if not(57 in inven)and(r[57]=Prm)and(ropecon<>Null)and(r[ropecon]=NewRm)then
           begin r[57]:=NewRm;RopeOld:=Prm;end
-   else if not(57 in inven)and(r[57]=Prm)and(NewRm=RopeOld)and
+   else if not(57 in inven)and(r[57]=Prm)and(NewRm=RopeOld)and(ropecon<>Null)and
               (r[ropecon]=Prm)then
           begin r[57]:=RopeOld;RopeOld:=Null;end;
    if(ropecon=Null)or((NewRm<>RopeOld)and(Prm<>RopeOld))then RopeOld:=Null;