blob: 37ed5e7bdc3231571c34c1ebab51717b9bdeca1a [file] [log] [blame] [raw]
package li.cil.oc.common.tileentity
import cpw.mods.fml.relauncher.Side
import cpw.mods.fml.relauncher.SideOnly
import li.cil.oc.Settings
import li.cil.oc.api
import li.cil.oc.api.network._
import net.minecraftforge.common.util.ForgeDirection
class PowerConverter extends traits.PowerAcceptor with traits.Environment with traits.NotAnalyzable {
val node = api.Network.newNode(this, Visibility.None).
withConnector(Settings.get.bufferConverter).
create()
@SideOnly(Side.CLIENT)
override protected def hasConnector(side: ForgeDirection) = true
override protected def connector(side: ForgeDirection) = Option(node)
override def energyThroughput = Settings.get.powerConverterRate
override def canUpdate = isServer
}