Class LanguageUtils
java.lang.Object
nl.mtvehicles.core.infrastructure.utils.LanguageUtils
Methods for changing plugin's language
-
Field Summary
Modifier and TypeFieldDescriptionContains information about whether player has language GUI opened -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
changeLanguage(org.bukkit.entity.Player p, Language language)
Change language of the pluginstatic void
changeLanguageMenu(org.bukkit.entity.Player p, int clickedSlot)
Called when a player clicks an item in /vehicle language menu, callschangeLanguage(Player, Language)
.static void
openLanguageGUI(org.bukkit.entity.Player p)
Open the language GUI selection to a player
-
Field Details
-
languageCheck
Contains information about whether player has language GUI opened
-
-
Constructor Details
-
LanguageUtils
public LanguageUtils()
-
-
Method Details
-
openLanguageGUI
public static void openLanguageGUI(org.bukkit.entity.Player p)Open the language GUI selection to a player -
changeLanguageMenu
public static void changeLanguageMenu(org.bukkit.entity.Player p, int clickedSlot)Called when a player clicks an item in /vehicle language menu, callschangeLanguage(Player, Language)
.- Parameters:
p
- Player who clickedclickedSlot
- Clicked slot (= ordinal ofLanguage
)
-
changeLanguage
Change language of the plugin- Parameters:
p
- Player who is changing the languagelanguage
- New language (Language
enum)
-