@Override
    public void act() throws RestartException {
        if (this.freaking) {
            if (this.gridX() * YSPanel.TILE_WIDTH == this.getX()
                    && this.gridY() * YSPanel.TILE_HEIGHT == this.getY()) {
                this.direction = this.getRandomDirection();
                this.wait++;
                if (this.wait > this.waitMax) {
                    this.freaking = false;
                    this.wait = 0;
                    this.waitMax = (int) (Math.random() * 10) * 10;
                    return;
                }
            }
            this.move(this.direction);
        } else {
            this.wait++;
            if (this.wait >= this.waitMax) {
                this.freaking = true;
                this.wait = 0;
                this.waitMax = 20;
            }
        }
    }