Localize names

This commit is contained in:
Shadowfacts 2021-02-14 11:24:55 -05:00
parent c8cdf425cb
commit 27713aedba
Signed by: shadowfacts
GPG Key ID: 94A5AB95422746E5
2 changed files with 10 additions and 1 deletions

View File

@ -18,6 +18,7 @@ import net.minecraft.network.PacketByteBuf
import net.minecraft.screen.ScreenHandler
import net.minecraft.server.network.ServerPlayerEntity
import net.minecraft.text.LiteralText
import net.minecraft.text.TranslatableText
import net.minecraft.util.Tickable
import net.minecraft.util.math.Direction
import net.shadowfacts.phycon.api.Interface
@ -224,7 +225,7 @@ class TerminalBlockEntity: DeviceBlockEntity(PhyBlockEntities.TERMINAL), Invento
return TerminalScreenHandler(syncId, playerInv, this@TerminalBlockEntity)
}
override fun getDisplayName() = LiteralText("Terminal")
override fun getDisplayName() = TranslatableText("block.phycon.terminal")
override fun writeScreenOpeningData(player: ServerPlayerEntity, buf: PacketByteBuf) {
buf.writeBlockPos(this@TerminalBlockEntity.pos)

View File

@ -0,0 +1,8 @@
{
"block.phycon.switch": "Network Switch",
"block.phycon.network_interface": "Inventory Interface",
"block.phycon.terminal": "Terminal",
"block.phycon.cable": "Cable",
"item.phycon.screwdriver": "Screwdriver"
}