Localize tile.blockConduitBundle and fix dim. trans. WAILA text

This commit is contained in:
tterrag1098 committed 2014-10-16 03:35:23 -04:00
1 parent 7cee0971cb
commit f3f8a2cd0e
3 files changed
+23 -9

No files matched your search

+2
View File
@@ -8,6 +8,8 @@ Changes
- WAILA support on all IInternalPowerReceptor and IConduitBundle (tterrag)
- WAILA support for photovoltaic panels (efficiency %) (tterrag)
- Allow killer joe's sword to charge from wireless chargers, this means that onUpdate() is called each tick (tterrag)
- Localize tile.blockConduitBundle.name to Conduit Connector (tterrag)
- Fix WAILA tooltip for dim.trans., was showing channel types even with no channels assigned to them (tterrag)
Bugs
- Fix tormented enderman head (and future head variants) dropping damage 0 always (tterrag)
+1
View File
@@ -709,6 +709,7 @@ enderio.gui.conduit.ioMode.input=Extract
enderio.gui.conduit.ioMode.output=Insert
enderio.gui.conduit.ioMode.disabled=Disabled
enderio.gui.conduit.ioMode.notSet=Default
tile.blockConduitBundle.name=Conduit Connector
enderio.gui.conduit.item.insertionFilter=Insert
enderio.gui.conduit.item.extractionFilter=Extract
@@ -108,23 +108,34 @@ public class BlockTransceiver extends AbstractMachineBlock<TileTransceiver> {
if (te instanceof TileTransceiver && player.isSneaking()) {
TileTransceiver trans = (TileTransceiver) te;
for (ChannelType type : ChannelType.VALUES) {
tooltip.add(EnumChatFormatting.WHITE + Lang.localize("trans." + type.name().toLowerCase()));
List<Channel> recieving = trans.getRecieveChannels(type);
List<Channel> sending = trans.getSendChannels(type);
List<Channel> sending = trans.getSendChannels(type);
String recieve = "[" + buildString(recieving) + "]";
String send = "[" + buildString(sending) + "]";
if(!"[]".equals(recieve)) {
tooltip.add(String.format("%s%s " + Util.TAB + ": %s%s", Util.TAB, Lang.localize("trans.recieving"), Util.TAB + Util.ALIGNRIGHT + EnumChatFormatting.WHITE, recieve));
String send = "[" + buildString(sending) + "]";
if(isEmpty(recieve) && isEmpty(send)) {
break;
}
if(!"[]".equals(send)) {
tooltip.add(String.format("%s%s " + Util.TAB + ": %s%s", Util.TAB, Lang.localize("trans.sending"), Util.TAB + Util.ALIGNRIGHT + EnumChatFormatting.WHITE, send));
tooltip.add(EnumChatFormatting.WHITE + Lang.localize("trans." + type.name().toLowerCase()));
if(!isEmpty(recieve)) {
tooltip.add(String.format("%s%s " + Util.TAB + ": %s%s", Util.TAB, Lang.localize("trans.recieving"), Util.TAB + Util.ALIGNRIGHT
+ EnumChatFormatting.WHITE, recieve));
}
if(!isEmpty(send)) {
tooltip.add(String.format("%s%s " + Util.TAB + ": %s%s", Util.TAB, Lang.localize("trans.sending"), Util.TAB + Util.ALIGNRIGHT
+ EnumChatFormatting.WHITE, send));
}
}
}
}
private boolean isEmpty(String str) {
return "[]".equals(str);
}
private String buildString(List<Channel> channels) {
StringBuilder sb = new StringBuilder();
for (Channel c : channels) {