Skip to content

Commit

Permalink
deleted this accidentally oops
Browse files Browse the repository at this point in the history
  • Loading branch information
Vazkii committed Jan 8, 2024
1 parent fb38a2b commit b97ed6f
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions src/main/java/org/violetmoon/quark/base/proxy/CommonProxy.java
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,24 @@ public void recipe(ZRegister event) {
event.getRegistry().register(ExclusionRecipe.SERIALIZER, "exclusion", Registries.RECIPE_SERIALIZER);
}

//forge event
public void configChanged(ModConfigEvent event) {
if(!event.getConfig().getModId().equals(Quark.MOD_ID) || Quark.ZETA.configInternals == null)
return;

// https://github.com/VazkiiMods/Quark/commit/b0e00864f74539d8650cb349e88d0302a0fda8e4
// "The Forge config api writes to the config file on every single change
// to the config, which would cause the file watcher to trigger
// a config reload while the config gui is committing changes."
if(System.currentTimeMillis() - Quark.ZETA.configInternals.debounceTime() > 20)
handleQuarkConfigChange();
}

public void handleQuarkConfigChange() {
Quark.ZETA.configManager.onReload();
Quark.ZETA.loadBus.fire(new ZConfigChanged());
}

/**
* Use an item WITHOUT sending the use to the server. This will cause ghost interactions if used incorrectly!
*/
Expand Down

0 comments on commit b97ed6f

Please sign in to comment.