Improve tooltip

Now the metaitems can automatically seperate its tooltip to multiple lines with "////".
This commit is contained in:
Antifluxfield 2017-08-21 09:56:04 +08:00 committed by GitHub
parent 3b39210348
commit 78e03914a3

View file

@ -189,7 +189,9 @@ public abstract class GT_MetaBase_Item extends GT_Generic_Item implements ISpeci
@Override
public final void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean aF3_H) {
String tKey = getUnlocalizedName(aStack) + ".tooltip", tString = GT_LanguageManager.getTranslation(tKey);
String tKey = getUnlocalizedName(aStack) + ".tooltip";
String[] tStrings = GT_LanguageManager.getTranslation(tKey).split("////");
for (String tString : tStrings)
if (GT_Utility.isStringValid(tString) && !tKey.equals(tString)) aList.add(tString);
Long[]