protected void loadLevel(String path) {
        System.out.print("Trying to load Level from " + path + "... ");
        try {
            BufferedReader reader = new BufferedReader(new InputStreamReader(getClass().getResourceAsStream(path)));
            width = Integer.parseInt(reader.readLine());
            height = Integer.parseInt(reader.readLine());
            tiles = new int[width * height];

            String delimiter = "\\s+"; // Spaces
            for (int y = 0; y < height; y++) {
                String[] rowValues = reader.readLine().split(delimiter);
                for (int x = 0; x < width; x++) {
                    tiles[x + y * width] = Integer.parseInt(rowValues[x]);
                }
            }
            System.out.println("done.");
        } catch (IOException e) {
            System.out.println("failed.");
            e.printStackTrace();
        }
    }