[Change] Moved "Survives On" Setting to the client config
This commit is contained in:
parent
f89c305dfe
commit
3e7a2e869d
3 changed files with 11 additions and 11 deletions
|
@ -107,6 +107,11 @@ public class ClientConfig extends NamedPathConfig {
|
||||||
"rendering",
|
"rendering",
|
||||||
(config) -> config.get(CUSTOM_FOG_RENDERING)
|
(config) -> config.get(CUSTOM_FOG_RENDERING)
|
||||||
);
|
);
|
||||||
|
public static final ConfigToken<Boolean> SURVIES_ON_HINT = ConfigToken.Boolean(
|
||||||
|
true,
|
||||||
|
"survives_on_hint",
|
||||||
|
Configs.MAIN_INFO_CATEGORY
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
public ClientConfig() {
|
public ClientConfig() {
|
||||||
|
@ -189,4 +194,8 @@ public class ClientConfig extends NamedPathConfig {
|
||||||
public void setForceBetterXPreset(boolean v) {
|
public void setForceBetterXPreset(boolean v) {
|
||||||
set(FORCE_BETTERX_PRESET, v);
|
set(FORCE_BETTERX_PRESET, v);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean survivesOnHint() {
|
||||||
|
return get(ClientConfig.SURVIES_ON_HINT);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,18 +9,13 @@ public class MainConfig extends NamedPathConfig {
|
||||||
Configs.MAIN_INFO_CATEGORY
|
Configs.MAIN_INFO_CATEGORY
|
||||||
);
|
);
|
||||||
|
|
||||||
public static final ConfigToken<Boolean> SURVIES_ON_HINT = ConfigToken.Boolean(
|
|
||||||
true,
|
|
||||||
"survives_on_hint",
|
|
||||||
Configs.MAIN_INFO_CATEGORY
|
|
||||||
);
|
|
||||||
public static final ConfigToken<Boolean> APPLY_PATCHES = ConfigToken.Boolean(
|
public static final ConfigToken<Boolean> APPLY_PATCHES = ConfigToken.Boolean(
|
||||||
true,
|
true,
|
||||||
"applyPatches",
|
"applyPatches",
|
||||||
Configs.MAIN_PATCH_CATEGORY
|
Configs.MAIN_PATCH_CATEGORY
|
||||||
);
|
);
|
||||||
|
|
||||||
@ConfigUI(leftPadding = 8)
|
@ConfigUI(leftPadding = 8, topPadding = 8)
|
||||||
public static final ConfigToken<Boolean> REPAIR_BIOMES = DependendConfigToken.Boolean(
|
public static final ConfigToken<Boolean> REPAIR_BIOMES = DependendConfigToken.Boolean(
|
||||||
false,
|
false,
|
||||||
"repairBiomesOnLoad",
|
"repairBiomesOnLoad",
|
||||||
|
@ -45,8 +40,4 @@ public class MainConfig extends NamedPathConfig {
|
||||||
public boolean verboseLogging() {
|
public boolean verboseLogging() {
|
||||||
return get(VERBOSE_LOGGING);
|
return get(VERBOSE_LOGGING);
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean survivesOnHint() {
|
|
||||||
return get(SURVIES_ON_HINT);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -39,7 +39,7 @@ public interface SurvivesOnSpecialGround {
|
||||||
|
|
||||||
@Environment(EnvType.CLIENT)
|
@Environment(EnvType.CLIENT)
|
||||||
static void appendHoverText(List<Component> list, String description) {
|
static void appendHoverText(List<Component> list, String description) {
|
||||||
if (!Configs.MAIN_CONFIG.survivesOnHint()) return;
|
if (!Configs.CLIENT_CONFIG.survivesOnHint()) return;
|
||||||
final int MAX_LINES = 7;
|
final int MAX_LINES = 7;
|
||||||
List<String> lines = splitLines(description);
|
List<String> lines = splitLines(description);
|
||||||
if (lines.size() == 1) {
|
if (lines.size() == 1) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue