-
-
Notifications
You must be signed in to change notification settings - Fork 101
Expand file tree
/
Copy pathWorldConfig.java
More file actions
47 lines (37 loc) · 1.68 KB
/
WorldConfig.java
File metadata and controls
47 lines (37 loc) · 1.68 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
package de.srendi.advancedperipherals.common.configuration;
import net.minecraft.FieldsAreNonnullByDefault;
import net.minecraftforge.common.ForgeConfigSpec;
import net.minecraftforge.fml.config.ModConfig;
@FieldsAreNonnullByDefault
public class WorldConfig implements IAPConfig {
public final ForgeConfigSpec.BooleanValue enableVillagerStructures;
public final ForgeConfigSpec.BooleanValue givePlayerBookOnJoin;
public final ForgeConfigSpec.IntValue villagerStructureWeight;
public final ForgeConfigSpec.BooleanValue enableWanderingTraderTrades;
private final ForgeConfigSpec configSpec;
public WorldConfig() {
ForgeConfigSpec.Builder builder = new ForgeConfigSpec.Builder();
builder.comment("Config to adjust world settings").push("World");
enableVillagerStructures = builder.comment("Enable the villager structures for the computer scientist.").define("enableVillagerStructures", true);
givePlayerBookOnJoin = builder.comment("Gives the ap documentation to new players.").define("givePlayerBookOnJoin", true);
villagerStructureWeight = builder.comment("The weight of the villager structures.").defineInRange("villagerStructureWeight", 10, 0, 16000);
enableWanderingTraderTrades = builder.comment("Enable new wandering trader trades.").define("enableWanderingTraderTrades", true);
builder.pop();
configSpec = builder.build();
}
@Override
public ForgeConfigSpec getConfigSpec() {
return configSpec;
}
@Override
public String getFileName() {
return "world";
}
@Override
public ModConfig.Type getType() {
return ModConfig.Type.COMMON;
}
/*
[
*/
}