3
0
Mirror von https://github.com/GeyserMC/Geyser.git synchronisiert 2024-10-03 08:21:06 +02:00

Adjust language strings for new options

Dieser Commit ist enthalten in:
Camotoy 2021-07-16 20:06:09 -04:00
Ursprung f03a2dd317
Commit 8e593a55a3
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 7EEFB66FE798081F
4 geänderte Dateien mit 25 neuen und 11 gelöschten Zeilen

Datei anzeigen

@ -39,8 +39,6 @@ Take a look [here](https://github.com/GeyserMC/Geyser/wiki/Setup) for how to set
- Some Entity Flags
- Structure block UI
Extended height features can be "supported", but require additional work.
## What can't be fixed
There are a few things Geyser is unable to support due to various differences between Minecraft Bedrock and Java. For a list of these limitations, see the [Current Limitations](https://github.com/GeyserMC/Geyser/wiki/Current-Limitations) page.

Datei anzeigen

@ -74,12 +74,16 @@ public class ChunkUtils {
* The minimum height Bedrock Edition will accept.
*/
private static final int MINIMUM_ACCEPTED_HEIGHT = 0;
private static final int MINIMUM_ACCEPTED_HEIGHT_OVERWORLD = GeyserConnector.getInstance().getConfig().isExtendedWorldHeight() ? -64 : MINIMUM_ACCEPTED_HEIGHT;
private static final int CAVES_AND_CLIFFS_MINIMUM_HEIGHT = -64;
private static final int MINIMUM_ACCEPTED_HEIGHT_OVERWORLD = GeyserConnector.getInstance().getConfig().isExtendedWorldHeight() ?
CAVES_AND_CLIFFS_MINIMUM_HEIGHT : MINIMUM_ACCEPTED_HEIGHT;
/**
* The maximum chunk height Bedrock Edition will accept, from the lowest point to the highest.
*/
private static final int MAXIMUM_ACCEPTED_HEIGHT = 256;
private static final int MAXIMUM_ACCEPTED_HEIGHT_OVERWORLD = GeyserConnector.getInstance().getConfig().isExtendedWorldHeight() ? 384 : MAXIMUM_ACCEPTED_HEIGHT;
private static final int CAVES_AND_CLIFFS_MAXIMUM_HEIGHT = 384;
private static final int MAXIMUM_ACCEPTED_HEIGHT_OVERWORLD = GeyserConnector.getInstance().getConfig().isExtendedWorldHeight() ?
CAVES_AND_CLIFFS_MAXIMUM_HEIGHT : MAXIMUM_ACCEPTED_HEIGHT;
public static final byte[] EMPTY_CHUNK_DATA;
public static final byte[] EMPTY_BIOME_DATA;
@ -454,11 +458,23 @@ public class ChunkUtils {
throw new RuntimeException("Maximum Y must be a multiple of 16!");
}
session.getChunkCache().setExtendedHeight(DimensionUtils.javaToBedrock(session.getDimension()) == 0 && session.getConnector().getConfig().isExtendedWorldHeight());
int dimension = DimensionUtils.javaToBedrock(session.getDimension());
boolean extendedHeight = dimension == 0 && session.getConnector().getConfig().isExtendedWorldHeight();
session.getChunkCache().setExtendedHeight(extendedHeight);
if (minY < (session.getChunkCache().isExtendedHeight() ? MINIMUM_ACCEPTED_HEIGHT_OVERWORLD : MINIMUM_ACCEPTED_HEIGHT)
|| maxY > (session.getChunkCache().isExtendedHeight() ? MAXIMUM_ACCEPTED_HEIGHT_OVERWORLD : MAXIMUM_ACCEPTED_HEIGHT)) {
session.getConnector().getLogger().warning(LanguageUtils.getLocaleStringLog("geyser.network.translator.chunk.out_of_bounds"));
if (minY < (extendedHeight ? MINIMUM_ACCEPTED_HEIGHT_OVERWORLD : MINIMUM_ACCEPTED_HEIGHT)
|| maxY > (extendedHeight ? MAXIMUM_ACCEPTED_HEIGHT_OVERWORLD : MAXIMUM_ACCEPTED_HEIGHT)) {
if (minY >= CAVES_AND_CLIFFS_MINIMUM_HEIGHT && maxY <= CAVES_AND_CLIFFS_MAXIMUM_HEIGHT && dimension == 0 && !session.getConnector().getConfig().isExtendedWorldHeight()) {
// This dimension uses heights that would be fixed by enabling the experimental toggle
session.getConnector().getLogger().warning(
LanguageUtils.getLocaleStringLog("geyser.network.translator.chunk.out_of_bounds.caves_and_cliffs",
"extended-world-height"));
} else {
session.getConnector().getLogger().warning(LanguageUtils.getLocaleStringLog("geyser.network.translator.chunk.out_of_bounds",
extendedHeight ? MINIMUM_ACCEPTED_HEIGHT_OVERWORLD : MINIMUM_ACCEPTED_HEIGHT,
extendedHeight ? MAXIMUM_ACCEPTED_HEIGHT_OVERWORLD : MAXIMUM_ACCEPTED_HEIGHT,
session.getDimension()));
}
}
session.getChunkCache().setMinY(minY);

Datei anzeigen

@ -57,9 +57,9 @@ remote:
# This is designed to be used for forced hosts on proxies
forward-hostname: false
# Allows the overworld world height to be extended from 0 - 255 to -64 - 320. This option cannot be changed during a reload.
# Allows the overworld world height to be extended from 0 - 255 to -64 - 319. This option cannot be changed during a reload.
# 1.17.0-1.17.2 Bedrock clients cannot connect with this option enabled.
# Performance issues may occur for Bedrock clients as this is an experimental toggle on their end.
# Performance issues and/or additional bugs may occur for Bedrock clients as this is an experimental toggle on their end.
extended-world-height: false
# Floodgate uses encryption to ensure use from authorised sources.

@ -1 +1 @@
Subproject commit fcc8f01e25e481c9c82f2ee9bff23111ec781dd7
Subproject commit c8923b1f71c7f66621729be47dec7f911606c6a1