Jump to content

RSDuck

Members
  • Posts

    4
  • Joined

  • Last visited

Converted

  • Gender
    Undisclosed
  • Personal Text
    I am new!

RSDuck's Achievements

Tree Puncher

Tree Puncher (2/8)

0

Reputation

  1. Ok, I solved the problem by adding a call of the function RenderHelper.disableStandardItemLighting after binding the texture. I don't know why Minecraft keeps the fixed Render pipeline light enabled when rendering tile entities with special renderer, but this seems to work.
  2. Hi, I'm working on a (ComputerCraft controlled) hologram projector. The hologram projector projects above it smaller versions of blocks which are set by a lua program, that runs on a computer. The projector tile entity implements IWorldAccess, so before rendering the RenderBlocks BlockAccess will be swapped out with mine and then I render the block by using RenderStandardBlock. My problem is that if the sky isn't occluded by other blocks, the model is displayed too dark, but the grass colors(and colors generally work). If the sky is rendered then the model renders with full brightness, but the colors aren't rendered. I already tried to disable brightness with reflection and with a custom tessellator draw method, nothing of this worked. Here is my rendering code: TileEntity projector = tile.getWorldObj().getTileEntity(tile.xCoord, tile.yCoord - 1, tile.zCoord); if (projector instanceof TileHologramProjector) { Tessellator t = Tessellator.instance; t.startDrawingQuads(); IBlockAccess backupAccess = RenderBlocks.getInstance().blockAccess; RenderBlocks.getInstance().blockAccess = (IBlockAccess) projector; try { int previousVertexCount = fVertexCount.getInt(t); for (int y1 = 0; y1 < TileHologramProjector.hologramHeight; y1++) { for (int z1 = 0; z1 < TileHologramProjector.hologramDepth; z1++) { for (int x1 = 0; x1 < TileHologramProjector.hologramWidth; x1++) { RenderBlocks.getInstance().renderBlockByRenderType( ((TileHologramProjector) projector).getBlock(x1, y1, z1), x1, y1, z1); if (fVertexCount.getInt(t) == previousVertexCount && !((TileHologramProjector) projector).isAirBlock(x1, y1, z1)) { RenderBlocks.getInstance().renderStandardBlock( ((TileHologramProjector) projector).getBlock(x1, y1, z1), x1, y1, z1); // RandomPeripherals.logger.info("Fallback // renderer!"); } previousVertexCount = fVertexCount.getInt(t); } } } } catch (Exception e) { e.printStackTrace(); } RenderBlocks.getInstance().blockAccess = backupAccess; GL11.glPushMatrix(); GL11.glTranslated(x, y, z); GL11.glScalef(0.125f, 0.125f, 0.125f); bindTexture(RandomPeripherals.proxy.blockResLoc); t.draw(); GL11.glPopMatrix(); }
  3. Yes it works, thanks !
  4. Hello, I'am about to build my mod, and then I get an error because I'am using string switches which are only available in Java 7 and up. There stands I should use -source 7 but where? I tried to add -source 7 as an argument for gradlew, put it on diffrent places in the build.gradlew file and I searched in the Internet and in the Forum but I can't find something.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.