public static void error(String str) {
        if(DebugLevel < DEBUG_LEVEL_ERROR){
            return;
        }
        synchronized (log) {
            try {
                log.write("[ERROR]"+Format.format(new Date())+str);
                log.newLine();
                log.flush();
            } catch (IOException ex) {
                ex.printStackTrace();
            }
        }
    }