Forráskód Böngészése

Disallow skipping the last line

Thomas Dy 3 éve
szülő
commit
23291dea4f
1 módosított fájl, 2 hozzáadás és 1 törlés
  1. 2 1
      src/game/typing.ts

+ 2 - 1
src/game/typing.ts

@@ -290,7 +290,8 @@ class TypingPlayingScreen implements Screen {
       const skippable =
         autoComplete &&
         lastLine !== undefined &&
-        lastLine.end! - lastLine.start! > 3;
+        lastLine.end! - lastLine.start! > 3 &&
+        this.currentIndex < this.lines.length - 1;
       this.setWaiting(true, skippable);
     } else {
       if (this.currentIndex >= this.lines.length) {