private BufferedImage load(String file){
        if(textureMap.get(file) != null) return textureMap.get(file);
        BufferedImage image = null;
        try {
            image = ImageIO.read(getClass().getResourceAsStream(file));
        } catch (IOException e) {
            try {
                image = ImageIO.read(getClass().getResourceAsStream("/textures/missing_texture.png"));
            } catch (IOException e1) {
                e1.printStackTrace();
                System.exit(1);
            }
        }
        textureMap.put(file, image);
        return image;
    }