Пример #1
0
  /**
   * @param listeners Reload Listeners as well?
   * @param silent If silent is true, no notice of the reload will appear in the console.
   */
  public void reload(boolean listeners, boolean silent) {
    if (listeners) Assigner.unregisterAll();

    this.reloadConfig();
    config = this.getConfigx();
    load();
    TRThread.reload();

    // Stop TMetrics if the user disabled it in the config and reloaded.
    if (!config.getBoolean(ConfigFile.General, "UseTMetrics", true)) {
      tmetrics.stop();
    }

    if (listeners) {
      Assigner.assign();
      if (linkEEPatch()) Assigner.assignEEPatch();
    }

    if (!silent) log.info("TekkitRestrict Reloaded!");
  }