|
1 | 1 | package dev.ftb.mods.ftbchunks.api;
|
2 | 2 |
|
| 3 | +import dev.ftb.mods.ftbchunks.FTBChunksWorldConfig; |
3 | 4 | import dev.ftb.mods.ftbteams.api.property.BooleanProperty;
|
4 | 5 | import dev.ftb.mods.ftbteams.api.property.PrivacyMode;
|
5 | 6 | import dev.ftb.mods.ftbteams.api.property.PrivacyProperty;
|
|
12 | 13 | */
|
13 | 14 | public class FTBChunksProperties {
|
14 | 15 | public static final BooleanProperty ALLOW_ALL_FAKE_PLAYERS
|
15 |
| - = new BooleanProperty(FTBChunksAPI.rl("allow_fake_players"), false); |
| 16 | + = new BooleanProperty(FTBChunksAPI.rl("allow_fake_players"), FTBChunksWorldConfig.DEF_ALLOW_FAKE_PLAYERS::get); |
16 | 17 | public static final StringListProperty ALLOW_NAMED_FAKE_PLAYERS
|
17 |
| - = new StringListProperty(FTBChunksAPI.rl("allow_named_fake_players"), new ArrayList<>()); |
| 18 | + = new StringListProperty(FTBChunksAPI.rl("allow_named_fake_players"), () -> new ArrayList<>(FTBChunksWorldConfig.DEF_ALLOW_NAMED_FAKE_PLAYERS.get())); |
18 | 19 | public static final BooleanProperty ALLOW_FAKE_PLAYERS_BY_ID
|
19 |
| - = new BooleanProperty(FTBChunksAPI.rl("allow_fake_players_by_id"), true); |
| 20 | + = new BooleanProperty(FTBChunksAPI.rl("allow_fake_players_by_id"), FTBChunksWorldConfig.DEF_ALLOW_FAKE_PLAYER_IDS::get); |
20 | 21 | public static final PrivacyProperty ENTITY_INTERACT_MODE
|
21 |
| - = new PrivacyProperty(FTBChunksAPI.rl("entity_interact_mode"), PrivacyMode.ALLIES); |
| 22 | + = new PrivacyProperty(FTBChunksAPI.rl("entity_interact_mode"), FTBChunksWorldConfig.DEF_ENTITY_INTERACT::get); |
22 | 23 | public static final PrivacyProperty NONLIVING_ENTITY_ATTACK_MODE
|
23 |
| - = new PrivacyProperty(FTBChunksAPI.rl("nonliving_entity_attack_mode"), PrivacyMode.ALLIES); |
| 24 | + = new PrivacyProperty(FTBChunksAPI.rl("nonliving_entity_attack_mode"), FTBChunksWorldConfig.DEF_NONLIVING_ENTITY_ATTACK::get); |
24 | 25 | public static final BooleanProperty ALLOW_EXPLOSIONS
|
25 |
| - = new BooleanProperty(FTBChunksAPI.rl("allow_explosions"), false); |
| 26 | + = new BooleanProperty(FTBChunksAPI.rl("allow_explosions"), FTBChunksWorldConfig.DEF_ALLOW_EXPLOSIONS::get); |
26 | 27 | public static final BooleanProperty ALLOW_MOB_GRIEFING
|
27 |
| - = new BooleanProperty(FTBChunksAPI.rl("allow_mob_griefing"), false); |
| 28 | + = new BooleanProperty(FTBChunksAPI.rl("allow_mob_griefing"), FTBChunksWorldConfig.DEF_MOB_GRIEFING::get); |
28 | 29 | public static final PrivacyProperty CLAIM_VISIBILITY
|
29 |
| - = new PrivacyProperty(FTBChunksAPI.rl("claim_visibility"), PrivacyMode.PUBLIC); |
| 30 | + = new PrivacyProperty(FTBChunksAPI.rl("claim_visibility"), FTBChunksWorldConfig.DEF_CLAIM_VISIBILITY::get); |
30 | 31 | public static final PrivacyProperty LOCATION_MODE
|
31 |
| - = new PrivacyProperty(FTBChunksAPI.rl("location_mode"), PrivacyMode.ALLIES); |
| 32 | + = new PrivacyProperty(FTBChunksAPI.rl("location_mode"), FTBChunksWorldConfig.DEF_PLAYER_VISIBILITY::get); |
32 | 33 | public static final BooleanProperty ALLOW_PVP
|
33 |
| - = new BooleanProperty(FTBChunksAPI.rl("allow_pvp"), true); |
| 34 | + = new BooleanProperty(FTBChunksAPI.rl("allow_pvp"), FTBChunksWorldConfig.DEF_PVP::get); |
34 | 35 |
|
35 | 36 | // FTB Chunks on Forge adds two separate block edit & interact properties
|
36 | 37 | public static final PrivacyProperty BLOCK_EDIT_MODE
|
37 |
| - = new PrivacyProperty(FTBChunksAPI.rl("block_edit_mode"), PrivacyMode.ALLIES); |
| 38 | + = new PrivacyProperty(FTBChunksAPI.rl("block_edit_mode"), FTBChunksWorldConfig.DEF_BLOCK_EDIT::get); |
38 | 39 | public static final PrivacyProperty BLOCK_INTERACT_MODE
|
39 |
| - = new PrivacyProperty(FTBChunksAPI.rl("block_interact_mode"), PrivacyMode.ALLIES); |
| 40 | + = new PrivacyProperty(FTBChunksAPI.rl("block_interact_mode"), FTBChunksWorldConfig.DEF_BLOCK_INTERACT::get); |
40 | 41 |
|
41 | 42 | // FTB Chunks on Fabric adds a combined block edit & interact property
|
42 | 43 | public static final PrivacyProperty BLOCK_EDIT_AND_INTERACT_MODE
|
43 |
| - = new PrivacyProperty(FTBChunksAPI.rl("block_edit_and_interact_mode"), PrivacyMode.ALLIES); |
| 44 | + = new PrivacyProperty(FTBChunksAPI.rl("block_edit_and_interact_mode"), FTBChunksWorldConfig.DEF_BLOCK_EDIT_INTERACT::get); |
44 | 45 |
|
45 | 46 | }
|
0 commit comments