public void pause(int steps) throws InterruptedException { if (Thread.currentThread().isInterrupted()) throw new InterruptedException(); applet.repaint(); Thread.sleep(steps * DELAY); }