mirror of
https://github.com/GTNewHorizons/TinkersConstruct.git
synced 2026-11-19 11:59:14 +00:00
Another fix for the modifier localization hack.
This commit is contained in:
1 parent
3dd9ee8591
commit
4badd85093
1 file changed
+6
-3
@@ -159,12 +159,15 @@ public final class ToolStationGuiHelper {
|
||||
String tipName = tags.getString(tooltip + tipNum);
|
||||
String locString = "modifier.toolstation." + EnumChatFormatting.getTextWithoutFormattingCodes(tipName);
|
||||
// strip out the '(X of Y)' in some for the localization strings.. sigh
|
||||
int bracket = locString.indexOf(" (");
|
||||
int bracket = locString.indexOf("(");
|
||||
if(bracket > 0)
|
||||
locString = locString.substring(0, bracket);
|
||||
locString = locString.replace(" ", "");
|
||||
if(StatCollector.canTranslate(locString))
|
||||
tipName = tipName.replace(EnumChatFormatting.getTextWithoutFormattingCodes(tipName), StatCollector.translateToLocal(locString));
|
||||
if(StatCollector.canTranslate(locString)) {
|
||||
tipName = tipName.replace(EnumChatFormatting.getTextWithoutFormattingCodes(tipName), StatCollector.translateToLocal(locString));
|
||||
if(bracket > 0)
|
||||
tipName += " " + tipName.substring(bracket);
|
||||
}
|
||||
write("- " + tipName);
|
||||
tipNum++;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user