Fix sidedness derp in LanguageRegistry.
This commit is contained in:
parent
9387bae26b
commit
4fc4accb6e
5 changed files with 21 additions and 1 deletions
|
@ -606,4 +606,10 @@ public class FMLClientHandler implements IFMLSidedHandler
|
|||
{
|
||||
return resourcePackMap.get(modId);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getCurrentLanguage()
|
||||
{
|
||||
return client.func_135016_M().func_135041_c().func_135034_a();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -496,4 +496,10 @@ public class FMLCommonHandler
|
|||
{
|
||||
sidedDelegate.updateResourcePackList();
|
||||
}
|
||||
|
||||
public String getCurrentLanguage()
|
||||
{
|
||||
|
||||
return sidedDelegate.getCurrentLanguage();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -66,4 +66,6 @@ public interface IFMLSidedHandler
|
|||
void addModAsResource(ModContainer container);
|
||||
|
||||
void updateResourcePackList();
|
||||
|
||||
String getCurrentLanguage();
|
||||
}
|
||||
|
|
|
@ -23,6 +23,7 @@ import java.util.logging.Level;
|
|||
|
||||
import com.google.common.base.Charsets;
|
||||
|
||||
import cpw.mods.fml.common.FMLCommonHandler;
|
||||
import cpw.mods.fml.common.FMLLog;
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import cpw.mods.fml.common.ModContainer;
|
||||
|
@ -46,7 +47,7 @@ public class LanguageRegistry
|
|||
|
||||
public String getStringLocalization(String key)
|
||||
{
|
||||
return getStringLocalization(key, Minecraft.func_71410_x().func_135016_M().func_135041_c().func_135034_a());
|
||||
return getStringLocalization(key, FMLCommonHandler.instance().getCurrentLanguage());
|
||||
}
|
||||
|
||||
public String getStringLocalization(String key, String lang)
|
||||
|
|
|
@ -260,4 +260,9 @@ public class FMLServerHandler implements IFMLSidedHandler
|
|||
{
|
||||
|
||||
}
|
||||
@Override
|
||||
public String getCurrentLanguage()
|
||||
{
|
||||
return "en_US";
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue