public static Map export(Element element) throws Exception {
        if (element == null || !element.active) {
            return null;
        }
        Map data = new HashMap();

        if (element instanceof Wall) {
            data.put("type", "wall");
        } else if (element instanceof Bomb) {
            data.put("type", "bomb");
        } else if(element instanceof Bonus) {
            data.put("type", "bonus");
            data.put("bonus_type", ((Bonus) element).getType());
        }

        if (data.isEmpty()) {
            throw new Exception("Unknown Element");
        }

        data.put("index", element.getIndex());
        data.put("breakable", element.isBreakable());
        data.put("walkable", element.isWalkable());

        return data;

    }