1.14.3 + more recipe fixes
This commit is contained in:
parent
5f134a7379
commit
18950e0b29
35 changed files with 240 additions and 251 deletions
|
@ -24,12 +24,12 @@
|
|||
|
||||
package techreborn.tiles;
|
||||
|
||||
import net.minecraft.ChatFormat;
|
||||
import net.minecraft.util.Formatting;
|
||||
import net.minecraft.block.entity.BlockEntity;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.CompoundTag;
|
||||
import net.minecraft.network.chat.TextComponent;
|
||||
import net.minecraft.text.LiteralText;
|
||||
import net.minecraft.sound.SoundCategory;
|
||||
import net.minecraft.util.Tickable;
|
||||
import reborncore.api.IToolDrop;
|
||||
|
@ -56,8 +56,8 @@ public class TileAlarm extends BlockEntity
|
|||
} else {
|
||||
selectedSound = 1;
|
||||
}
|
||||
ChatUtils.sendNoSpamMessages(MessageIDs.alarmID, new TextComponent(
|
||||
ChatFormat.GRAY + StringUtils.t("techreborn.message.alarm") + " " + "Alarm " + selectedSound));
|
||||
ChatUtils.sendNoSpamMessages(MessageIDs.alarmID, new LiteralText(
|
||||
Formatting.GRAY + StringUtils.t("techreborn.message.alarm") + " " + "Alarm " + selectedSound));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -25,8 +25,8 @@
|
|||
package techreborn.tiles;
|
||||
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.network.chat.Component;
|
||||
import net.minecraft.network.chat.TextComponent;
|
||||
import net.minecraft.text.LiteralText;
|
||||
import net.minecraft.text.Text;
|
||||
import reborncore.api.IListInfoProvider;
|
||||
import reborncore.client.containerBuilder.IContainerProvider;
|
||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||
|
@ -74,8 +74,8 @@ public class TileIndustrialCentrifuge extends TileGenericMachine implements ICon
|
|||
|
||||
// IListInfoProvider
|
||||
@Override
|
||||
public void addInfo(final List<Component> info, final boolean isRealTile, boolean hasData) {
|
||||
public void addInfo(final List<Text> info, final boolean isRealTile, boolean hasData) {
|
||||
super.addInfo(info, isRealTile, hasData);
|
||||
info.add(new TextComponent("Round and round it goes"));
|
||||
info.add(new LiteralText("Round and round it goes"));
|
||||
}
|
||||
}
|
|
@ -29,9 +29,8 @@ import net.minecraft.client.network.packet.BlockEntityUpdateS2CPacket;
|
|||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.CompoundTag;
|
||||
import net.minecraft.network.ClientConnection;
|
||||
import net.minecraft.network.chat.Component;
|
||||
import net.minecraft.network.chat.TextComponent;
|
||||
import net.minecraft.text.LiteralText;
|
||||
import net.minecraft.text.Text;
|
||||
import reborncore.api.IListInfoProvider;
|
||||
import reborncore.api.IToolDrop;
|
||||
import reborncore.api.tile.ItemHandlerProvider;
|
||||
|
@ -221,19 +220,19 @@ public class TileTechStorageBase extends TileMachineBase
|
|||
|
||||
// IListInfoProvider
|
||||
@Override
|
||||
public void addInfo(List<Component> info, boolean isRealTile, boolean hasData) {
|
||||
public void addInfo(List<Text> info, boolean isRealTile, boolean hasData) {
|
||||
if (isRealTile || hasData) {
|
||||
int size = 0;
|
||||
String name = "of nothing";
|
||||
if (!storedItem.isEmpty()) {
|
||||
name = storedItem.getCustomName().getString();
|
||||
name = storedItem.getName().getString();
|
||||
size += storedItem.getCount();
|
||||
}
|
||||
if (!inventory.getInvStack(1).isEmpty()) {
|
||||
name = inventory.getInvStack(1).getCustomName().getString();
|
||||
name = inventory.getInvStack(1).getName().getString();
|
||||
size += inventory.getInvStack(1).getCount();
|
||||
}
|
||||
info.add(new TextComponent(size + " " + name));
|
||||
info.add(new LiteralText(size + " " + name));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -24,15 +24,15 @@
|
|||
|
||||
package techreborn.tiles.cable;
|
||||
|
||||
import net.minecraft.ChatFormat;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.entity.BlockEntity;
|
||||
import net.minecraft.client.network.packet.BlockEntityUpdateS2CPacket;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.CompoundTag;
|
||||
import net.minecraft.network.chat.Component;
|
||||
import net.minecraft.network.chat.TextComponent;
|
||||
import net.minecraft.text.LiteralText;
|
||||
import net.minecraft.text.Text;
|
||||
import net.minecraft.util.Formatting;
|
||||
import net.minecraft.util.Tickable;
|
||||
import net.minecraft.util.math.Direction;
|
||||
import reborncore.api.IListInfoProvider;
|
||||
|
@ -159,13 +159,13 @@ public class TileCable extends BlockEntity
|
|||
|
||||
// IListInfoProvider
|
||||
@Override
|
||||
public void addInfo(List<Component> info, boolean isRealTile, boolean hasData) {
|
||||
public void addInfo(List<Text> info, boolean isRealTile, boolean hasData) {
|
||||
if (isRealTile) {
|
||||
info.add(new TextComponent(ChatFormat.GRAY + StringUtils.t("techreborn.tooltip.transferRate") + ": "
|
||||
+ ChatFormat.GOLD
|
||||
info.add(new LiteralText(Formatting.GRAY + StringUtils.t("techreborn.tooltip.transferRate") + ": "
|
||||
+ Formatting.GOLD
|
||||
+ PowerSystem.getLocaliszedPowerFormatted(transferRate / RebornCoreConfig.euPerFU) + "/t"));
|
||||
info.add(new TextComponent(ChatFormat.GRAY + StringUtils.t("techreborn.tooltip.tier") + ": "
|
||||
+ ChatFormat.GOLD + StringUtils.toFirstCapitalAllLowercase(cableType.tier.toString())));
|
||||
info.add(new LiteralText(Formatting.GRAY + StringUtils.t("techreborn.tooltip.tier") + ": "
|
||||
+ Formatting.GOLD + StringUtils.toFirstCapitalAllLowercase(cableType.tier.toString())));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -24,13 +24,13 @@
|
|||
|
||||
package techreborn.tiles.generator;
|
||||
|
||||
import net.minecraft.ChatFormat;
|
||||
import net.minecraft.text.LiteralText;
|
||||
import net.minecraft.util.Formatting;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.CompoundTag;
|
||||
import net.minecraft.network.chat.Component;
|
||||
import net.minecraft.network.chat.TextComponent;
|
||||
import net.minecraft.text.Text;
|
||||
import net.minecraft.util.math.Direction;
|
||||
import reborncore.api.IToolDrop;
|
||||
import reborncore.api.power.EnumPowerTier;
|
||||
|
@ -130,17 +130,17 @@ public class TileSolarPanel extends TilePowerAcceptor implements IToolDrop {
|
|||
|
||||
// TODO: Translate
|
||||
@Override
|
||||
public void addInfo(List<Component> info, boolean isRealTile, boolean hasData) {
|
||||
info.add(new TextComponent(ChatFormat.GRAY + "Internal Energy Storage: " + ChatFormat.GOLD
|
||||
public void addInfo(List<Text> info, boolean isRealTile, boolean hasData) {
|
||||
info.add(new LiteralText(Formatting.GRAY + "Internal Energy Storage: " + Formatting.GOLD
|
||||
+ PowerSystem.getLocaliszedPowerFormatted((int) getMaxPower())));
|
||||
|
||||
info.add(new TextComponent(ChatFormat.GRAY + "Generation Rate Day: " + ChatFormat.GOLD
|
||||
info.add(new LiteralText(Formatting.GRAY + "Generation Rate Day: " + Formatting.GOLD
|
||||
+ PowerSystem.getLocaliszedPowerFormatted(panel.generationRateD)));
|
||||
|
||||
info.add(new TextComponent(ChatFormat.GRAY + "Generation Rate Night: " + ChatFormat.GOLD
|
||||
info.add(new LiteralText(Formatting.GRAY + "Generation Rate Night: " + Formatting.GOLD
|
||||
+ PowerSystem.getLocaliszedPowerFormatted(panel.generationRateN)));
|
||||
|
||||
info.add(new TextComponent(ChatFormat.GRAY + "Tier: " + ChatFormat.GOLD
|
||||
info.add(new LiteralText(Formatting.GRAY + "Tier: " + Formatting.GOLD
|
||||
+ StringUtils.toFirstCapitalAllLowercase(getTier().toString())));
|
||||
}
|
||||
|
||||
|
|
|
@ -30,8 +30,8 @@ import net.minecraft.entity.player.PlayerEntity;
|
|||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.CompoundTag;
|
||||
import net.minecraft.network.ClientConnection;
|
||||
import net.minecraft.network.chat.Component;
|
||||
import net.minecraft.network.chat.TextComponent;
|
||||
import net.minecraft.text.LiteralText;
|
||||
import net.minecraft.text.Text;
|
||||
import reborncore.api.IListInfoProvider;
|
||||
import reborncore.api.IToolDrop;
|
||||
import reborncore.api.tile.ItemHandlerProvider;
|
||||
|
@ -133,15 +133,15 @@ public class TileQuantumTank extends TileMachineBase
|
|||
|
||||
// IListInfoProvider
|
||||
@Override
|
||||
public void addInfo(final List<Component> info, final boolean isRealTile, boolean hasData) {
|
||||
public void addInfo(final List<Text> info, final boolean isRealTile, boolean hasData) {
|
||||
if (isRealTile | hasData) {
|
||||
if (this.tank.getFluid() != null) {
|
||||
info.add(new TextComponent(this.tank.getFluidAmount() + " of " + this.tank.getFluidType().getName()));
|
||||
info.add(new LiteralText(this.tank.getFluidAmount() + " of " + this.tank.getFluidType().getName()));
|
||||
} else {
|
||||
info.add(new TextComponent("Empty"));
|
||||
info.add(new LiteralText("Empty"));
|
||||
}
|
||||
}
|
||||
info.add(new TextComponent("Capacity " + this.tank.getCapacity() + " mb"));
|
||||
info.add(new LiteralText("Capacity " + this.tank.getCapacity() + " mb"));
|
||||
}
|
||||
|
||||
// IContainerProvider
|
||||
|
|
|
@ -24,13 +24,13 @@
|
|||
|
||||
package techreborn.tiles.transformers;
|
||||
|
||||
import net.minecraft.ChatFormat;
|
||||
import net.minecraft.text.LiteralText;
|
||||
import net.minecraft.text.Text;
|
||||
import net.minecraft.util.Formatting;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.entity.BlockEntityType;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.network.chat.Component;
|
||||
import net.minecraft.network.chat.TextComponent;
|
||||
import net.minecraft.util.math.Direction;
|
||||
import reborncore.api.IListInfoProvider;
|
||||
import reborncore.api.IToolDrop;
|
||||
|
@ -146,11 +146,11 @@ public class TileTransformer extends TilePowerAcceptor
|
|||
|
||||
// IListInfoProvider
|
||||
@Override
|
||||
public void addInfo(List<Component> info, boolean isRealTile, boolean hasData) {
|
||||
info.add(new TextComponent(ChatFormat.GRAY + "Input Rate: " + ChatFormat.GOLD + PowerSystem.getLocaliszedPowerFormatted((int) getMaxInput())));
|
||||
info.add(new TextComponent(ChatFormat.GRAY + "Input Tier: " + ChatFormat.GOLD + StringUtils.toFirstCapitalAllLowercase(inputTier.toString())));
|
||||
info.add(new TextComponent(ChatFormat.GRAY + "Output Rate: " + ChatFormat.GOLD + PowerSystem.getLocaliszedPowerFormatted((int) getMaxOutput())));
|
||||
info.add(new TextComponent(ChatFormat.GRAY + "Output Tier: " + ChatFormat.GOLD + StringUtils.toFirstCapitalAllLowercase(ouputTier.toString())));
|
||||
public void addInfo(List<Text> info, boolean isRealTile, boolean hasData) {
|
||||
info.add(new LiteralText(Formatting.GRAY + "Input Rate: " + Formatting.GOLD + PowerSystem.getLocaliszedPowerFormatted((int) getMaxInput())));
|
||||
info.add(new LiteralText(Formatting.GRAY + "Input Tier: " + Formatting.GOLD + StringUtils.toFirstCapitalAllLowercase(inputTier.toString())));
|
||||
info.add(new LiteralText(Formatting.GRAY + "Output Rate: " + Formatting.GOLD + PowerSystem.getLocaliszedPowerFormatted((int) getMaxOutput())));
|
||||
info.add(new LiteralText(Formatting.GRAY + "Output Tier: " + Formatting.GOLD + StringUtils.toFirstCapitalAllLowercase(ouputTier.toString())));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue