Search in sources :

Example 1 with WorldIdentifiers

use of com.viaversion.viaversion.api.minecraft.WorldIdentifiers in project ViaVersion by ViaVersion.

the class AbstractViaConfig method loadFields.

protected void loadFields() {
    checkForUpdates = getBoolean("checkforupdates", true);
    preventCollision = getBoolean("prevent-collision", true);
    useNewEffectIndicator = getBoolean("use-new-effect-indicator", true);
    useNewDeathmessages = getBoolean("use-new-deathmessages", true);
    suppressMetadataErrors = getBoolean("suppress-metadata-errors", false);
    shieldBlocking = getBoolean("shield-blocking", true);
    noDelayShieldBlocking = getBoolean("no-delay-shield-blocking", false);
    showShieldWhenSwordInHand = getBoolean("show-shield-when-sword-in-hand", false);
    hologramPatch = getBoolean("hologram-patch", false);
    pistonAnimationPatch = getBoolean("piston-animation-patch", false);
    bossbarPatch = getBoolean("bossbar-patch", true);
    bossbarAntiFlicker = getBoolean("bossbar-anti-flicker", false);
    hologramOffset = getDouble("hologram-y", -0.96D);
    maxPPS = getInt("max-pps", 800);
    maxPPSKickMessage = getString("max-pps-kick-msg", "Sending packets too fast? lag?");
    trackingPeriod = getInt("tracking-period", 6);
    warningPPS = getInt("tracking-warning-pps", 120);
    maxPPSWarnings = getInt("tracking-max-warnings", 3);
    maxPPSWarningsKickMessage = getString("tracking-max-kick-msg", "You are sending too many packets, :(");
    sendSupportedVersions = getBoolean("send-supported-versions", false);
    simulatePlayerTick = getBoolean("simulate-pt", true);
    itemCache = getBoolean("item-cache", true);
    nmsPlayerTicking = getBoolean("nms-player-ticking", true);
    replacePistons = getBoolean("replace-pistons", false);
    pistonReplacementId = getInt("replacement-piston-id", 0);
    chunkBorderFix = getBoolean("chunk-border-fix", false);
    autoTeam = getBoolean("auto-team", true);
    forceJsonTransform = getBoolean("force-json-transform", false);
    nbtArrayFix = getBoolean("chat-nbt-fix", true);
    blockedProtocolVersions = loadBlockedProtocolVersions();
    blockedDisconnectMessage = getString("block-disconnect-msg", "You are using an unsupported Minecraft version!");
    reloadDisconnectMessage = getString("reload-disconnect-msg", "Server reload, please rejoin!");
    minimizeCooldown = getBoolean("minimize-cooldown", true);
    teamColourFix = getBoolean("team-colour-fix", true);
    suppressConversionWarnings = getBoolean("suppress-conversion-warnings", false);
    disable1_13TabComplete = getBoolean("disable-1_13-auto-complete", false);
    serversideBlockConnections = getBoolean("serverside-blockconnections", true);
    reduceBlockStorageMemory = getBoolean("reduce-blockstorage-memory", false);
    flowerStemWhenBlockAbove = getBoolean("flowerstem-when-block-above", false);
    vineClimbFix = getBoolean("vine-climb-fix", false);
    snowCollisionFix = getBoolean("fix-low-snow-collision", false);
    infestedBlocksFix = getBoolean("fix-infested-block-breaking", true);
    tabCompleteDelay = getInt("1_13-tab-complete-delay", 0);
    truncate1_14Books = getBoolean("truncate-1_14-books", false);
    leftHandedHandling = getBoolean("left-handed-handling", true);
    fullBlockLightFix = getBoolean("fix-non-full-blocklight", false);
    healthNaNFix = getBoolean("fix-1_14-health-nan", true);
    instantRespawn = getBoolean("use-1_15-instant-respawn", false);
    ignoreLongChannelNames = getBoolean("ignore-long-1_16-channel-names", true);
    forcedUse1_17ResourcePack = getBoolean("forced-use-1_17-resource-pack", false);
    resourcePack1_17PromptMessage = getSerializedComponent("resource-pack-1_17-prompt");
    Map<String, String> worlds = get("map-1_16-world-names", Map.class, new HashMap<String, String>());
    map1_16WorldNames = new WorldIdentifiers(worlds.getOrDefault("overworld", WorldIdentifiers.OVERWORLD_DEFAULT), worlds.getOrDefault("nether", WorldIdentifiers.NETHER_DEFAULT), worlds.getOrDefault("end", WorldIdentifiers.END_DEFAULT));
    cache1_17Light = getBoolean("cache-1_17-light", true);
}
Also used : WorldIdentifiers(com.viaversion.viaversion.api.minecraft.WorldIdentifiers)

Aggregations

WorldIdentifiers (com.viaversion.viaversion.api.minecraft.WorldIdentifiers)1