Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package net.minecraft.client.resources;
- import net.minecraftforge.fml.relauncher.Side;
- import net.minecraftforge.fml.relauncher.SideOnly;
- @SideOnly(Side.CLIENT)
- public class I18n
- {
- private static Locale i18nLocale;
- static void setLocale(Locale i18nLocaleIn)
- {
- i18nLocale = i18nLocaleIn;
- }
- /**
- * Translates the given string and then formats it. Equivilant to String.format(translate(key), parameters).
- */
- public static String format(String translateKey, Object... parameters)
- {
- return i18nLocale.formatMessage(translateKey, parameters);
- }
- public static boolean hasKey(String key)
- {
- return i18nLocale.hasKey(key);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment