Jump to content

larsgerrits

Members
  • Posts

    3462
  • Joined

  • Last visited

  • Days Won

    17

Everything posted by larsgerrits

  1. Maybe you could do it instead of like this.setBlockBounds(0,0,0,1,1F/16F*3F,1); to like this.setBlockBounds(0,1F/16F*8F,0,1,1F/16F*11F,1) . That will move it about 6 pixels up, with a width height of 3 pixels.
  2. Use the public void setBlockBoundsForItemRender() method.
  3. Make a custom IWorldGenerator class, copy the WorldGenMineable class and modify it a bit to check if the block is exposed to air and then generate it.
  4. I agree: would you believe that this public boolean onBlockActivated(World p_149727_1_, int p_149727_2_, int p_149727_3_, int p_149727_4_, EntityPlayer p_149727_5_, int p_149727_6_, float p_149727_7_, float p_149727_8_, float p_149727_9_) { return p_149727_1_.isRemote ? true : ItemLead.func_150909_a(p_149727_5_, p_149727_1_, p_149727_2_, p_149727_3_, p_149727_4_); } belongs to blockFence? I have never tried to right click a fence, but what the heck is that??? That method checks if you can place a leash on the fence. If you can place it, it places it and returns true, and otherwise it returns false and does nothing.
  5. And is there a reason not to update to 1.7? If your reason is about modpacks, that a horrible reason ad all the mods had all the time to update.
  6. You can use the TESR route, as long as you override canUpdate() in your TileEntity to return false, so it doesn't tick anymore.
  7. You should probably call your registerProxies in your Init method, so it registers after all the blocks are done.
  8. You have a mod that requires another mod, but that other mod isn't there.
  9. public void updateEntity() { // DO YOUR OPERATIONS WITH onPreviousTick AND currentVariable onPreviousTick=currentValue; } What part do you not understand?
  10. If you have a a GUI that doesn't have a inventory, return null in the getServerGuiElement method and call the openGui method client side.
  11. You can use buf.writeInt(int) and int = buf.readInt() . For more complex stuff, like strings, you can use the ByteBufUtils class. The "MyChannel" is the channel it registers to. If two or more mods use the same channel, you get both messages (I think). You should probably prefix your channel name with your modid.
  12. You need to send packets to tell the server a button was clicked, let the server decide if that was possible, and then set it to null.
  13. You do this [url=www.google.com]Word you want to be highlighted here![/url] That's gonna result in this: Word you want to be highlighted here!
  14. That's because there's no constructer that only accepts a Material. You need to use the constructor that accepts a Block and a integer (metadata).
  15. The methods you are interested in are these. That is all you need to draw the fluids.
  16. No, the markBlockForUpdate makes Minecraft call the getDescriptionPacket on the server, sends it to the client and calls onDataPacket on the client.
  17. That code needs to go into your TileEntity. You don't manually have to send them, Minecraft sends them for you. If you want to manually synchronize the TileEntity, use worldObj.markBlockForUpdate(xCoord,yCoord,zCoord);
  18. Here's some psuedo code: void writeToNBT(NBTTagCompound) { //call super method //write tank to nbt using tank.writeToNBT(); } void readFromNBT(NBTTagCompound) { //call super method //read tank from nbt using tank.readFromNBT(); } Packet getDescriptionPacket() { NBTTagCompound tag = new NBTTagCompound(); writeToNBT(tag); return new S35PacketUpdateTileEntity(x,y,z,1,tag); } void onDataPacket(NetworkManager, S35PacketUpdateTileEntity) { readFromNBT(packet.func_148857_g()); }
  19. I think it is. In the onBlockActivated, you are probably not checking for which side it is used on, so it updates both the client and the server. But the buildcraft pipes are probably only putting fluids on the server side, but not on the client side. You need to tell the client what fluids the server has.
  20. Your client is desynchronized from the server. Use the getDescriptionPacket and the onDataPacket methods.
  21. Where have you placed that? I did in the registerBlockIcons method after the initialization of the icons.
  22. You probably have a static instance of the fluid, use that to call the setIcons(stillIcon,flowingIcon) method.
  23. I had that problem too where the fluid was invisible in tanks. If you have a block implementation (for it to be placed in the world) with correct textures, you need to set YourFluid#setIcons(stillIcon,flowingIcon) so it has the proper textures.
  24. You need to bind the itemsheet first. Use this to bind the itemsheet: TextureManager manager = Minecraft.getMinecraft().renderEngine; manager.bindTexture(manager.getResourceLocation(1)); //RENDER ITEMS
  25. You can use the PlayerInteractEvent. The event has a world and coords of the block clicked if face != -1. With those, you can get the block, check if it's iron ore, and then replace it with your own.
×
×
  • Create New...

Important Information

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