mirror of
https://github.com/Winds-Studio/Leaf.git
synced 2025-12-25 09:59:15 +00:00
Optimize isEyeInFluid (#327)
* Optimize isEyeInFluid * Remove accidental formatting * Fix code removed by oblivion * Optimize isEyeInFluid * Update after rebase
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
package org.dreeam.leaf.config.modules.opt;
|
||||
|
||||
import org.dreeam.leaf.config.ConfigModules;
|
||||
import org.dreeam.leaf.config.EnumConfigCategory;
|
||||
|
||||
public class EyeFluidCache extends ConfigModules {
|
||||
|
||||
public String getBasePath() {
|
||||
return EnumConfigCategory.PERF.getBaseKeyName();
|
||||
}
|
||||
|
||||
public static boolean enabled = false;
|
||||
|
||||
@Override
|
||||
public void onLoaded() {
|
||||
enabled = config.getBoolean(getBasePath() + ".cache-eye-fluid-status", enabled,
|
||||
config.pickStringRegionBased(
|
||||
"Whether to cache the isEyeInFluid method to improve performance and reduce memory usage.",
|
||||
"是否为 isEyeInFluid 方法启用缓存,以优化性能并减少内存使用."));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user