Package net.minestom.server.adventure
Class MinestomAdventure
java.lang.Object
net.minestom.server.adventure.MinestomAdventure
Adventure related constants, etc.
-
Field Summary
Modifier and TypeFieldDescriptionstatic boolean
If components should be automatically translated in outgoing packets.static BiFunction
<Component, Locale, Component> static final Codec
<org.jglrxavpok.hephaistos.nbt.NBT, String, org.jglrxavpok.hephaistos.nbt.NBTException, RuntimeException> A codec to convert between strings and NBT. -
Method Summary
Modifier and TypeMethodDescriptionstatic @NotNull Locale
Gets the default locale used to translate components when no overriding locale has been provided.static void
setDefaultLocale
(@Nullable Locale defaultLocale) Sets the default locale used to translate components when no overriding locale has been provided.
-
Field Details
-
NBT_CODEC
public static final Codec<org.jglrxavpok.hephaistos.nbt.NBT,String, NBT_CODECorg.jglrxavpok.hephaistos.nbt.NBTException, RuntimeException> A codec to convert between strings and NBT. -
AUTOMATIC_COMPONENT_TRANSLATION
public static boolean AUTOMATIC_COMPONENT_TRANSLATIONIf components should be automatically translated in outgoing packets. -
COMPONENT_TRANSLATOR
-
-
Method Details
-
getDefaultLocale
Gets the default locale used to translate components when no overriding locale has been provided.- Returns:
- the default locale
-
setDefaultLocale
Sets the default locale used to translate components when no overriding locale has been provided.- Parameters:
defaultLocale
- the new default, ornull
to return toLocale.getDefault()
-