Fixed raid TESR.

This commit is contained in:
Florian Nücke 2014-12-26 13:20:19 +01:00
parent 3b578e71a6
commit 8e4190f303
2 changed files with 10 additions and 10 deletions

View File

@ -65,9 +65,9 @@ object RaidRenderer extends TileEntitySpecialRenderer {
private def renderSlot(r: WorldRenderer, slot: Int, icon: TextureAtlasSprite) {
val l = u1 + slot * fs
val h = u1 + (slot + 1) * fs
r.addVertexWithUV(l, 1, 0, icon.getInterpolatedU(l), icon.getMaxV)
r.addVertexWithUV(h, 1, 0, icon.getInterpolatedU(h), icon.getMaxV)
r.addVertexWithUV(h, 0, 0, icon.getInterpolatedU(h), icon.getMinV)
r.addVertexWithUV(l, 0, 0, icon.getInterpolatedU(l), icon.getMinV)
r.addVertexWithUV(l, 1, 0, icon.getInterpolatedU(l * 16), icon.getMaxV)
r.addVertexWithUV(h, 1, 0, icon.getInterpolatedU(h * 16), icon.getMaxV)
r.addVertexWithUV(h, 0, 0, icon.getInterpolatedU(h * 16), icon.getMinV)
r.addVertexWithUV(l, 0, 0, icon.getInterpolatedU(l * 16), icon.getMinV)
}
}

View File

@ -150,18 +150,18 @@ trait RedstoneAware extends RotationAware /* with IConnectable with IRedstoneEmi
protected def onRedstoneInputChanged(side: EnumFacing) {}
protected def onRedstoneOutputEnabledChanged() {
world.notifyBlocksOfNeighborChange(position, block)
world.notifyNeighborsOfStateChange(getPos, getBlockType)
if (isServer) ServerPacketSender.sendRedstoneState(this)
else world.markBlockForUpdate(position)
else world.markBlockForUpdate(getPos)
}
protected def onRedstoneOutputChanged(side: EnumFacing) {
val blockPos = position.offset(side)
world.notifyBlockOfNeighborChange(blockPos, block)
world.notifyBlocksOfNeighborChange(blockPos, world.getBlock(blockPos), side.getOpposite)
val blockPos = getPos.offset(side)
world.notifyNeighborsOfStateChange(blockPos, getBlockType)
world.notifyNeighborsOfStateExcept(blockPos, world.getBlockState(blockPos).getBlock, side.getOpposite)
if (isServer) ServerPacketSender.sendRedstoneState(this)
else world.markBlockForUpdate(position)
else world.markBlockForUpdate(getPos)
}
// ----------------------------------------------------------------------- //