Skip to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Draco18s

Members
  • Joined

  • Last visited

Everything posted by Draco18s

  1. Could methods: 1) Ask 2) Decompile the mod and look 3) Print out every god damn block name in the block list
  2. unlocalized name != block registry name GameRegistry.registerItem((new Item()).setUnlocalizedName("iron_nugget")), "my_iron_nugget");
  3. Only call the code if ExtraUtils is loaded.
  4. sifterRecipes.entrySet().iterator() ?
  5. Have you tried printing out what the IDs on the item are and comparing them to the ID you're looking for?
  6. Checking the stack for null after you reference it isn't going to do anything useful.
  7. Actually, I bet it would crash. You didn't check to make sure that the item in the currently equipped slot isn't null, and then you access its stackNBT.
  8. If you start doing any packet-sending code, then it could be your fault. Just remember not to send a packet all the time every time ten times over and you'll be fine.
  9. Let me guess: if you punch a zombie, it crashes. ItemStack stack = player.getCurrentEquippedItem(); //what value does stack contain when you punch a zombie? //what value does stack contain when a zombie punches you? NBTTagList ench = stack.getEnchantmentTagList();
  10. With Java, you can do anything. new File(DimensionManager.getWorldSaveDirectory()+"/region/r.0.0.mca").delete();//warning: will probably do bad thigns
  11. As for the bottom: you need to not render the bottom in the second pass.
  12. ConcurrentModificationException: You are modifying an array while another thread is trying to iterate through it.
  13. That's the Item renderer, show also the TileEntitySpecialRenderer class.
  14. It's not sided. But it gets sent any time the server sees that it needs to be sent. You'll want to call worldObj.markBlockForUpdate(xCoord, yCoord, zCoord); if you make any changes to the data and it needs to update right away.
  15. You need to save the data in an NBT tag (read/write to/from NBT methods) and then add: @Override public Packet getDescriptionPacket() { NBTTagCompound nbtTag = new NBTTagCompound(); writeToNBT(nbtTag); return new S35PacketUpdateTileEntity(xCoord, yCoord, zCoord, 1, nbtTag); } @Override public void onDataPacket(NetworkManager net, S35PacketUpdateTileEntity packet) { readFromNBT(packet.func_148857_g()); } So that the data is passed from server to client.
  16. http://1.bp.blogspot.com/_D_Z-D2tzi14/S8TZcKXqR-I/AAAAAAAACwg/F7AqxDrPjhg/s320/ALOT13.png[/img]
  17. You haven't overriden public void getSubItems(Item item, CreativeTabs tab, List list)
  18. Well, the class-level variable will turn sour as soon as you have multiple copies of the item and a server with multiple players. Second, you should check that the entity is of the desired type before casting. Third, I'm not sure that setting sneaking like that works. Mostly because it's a state that gets updated all the time based on your keyboard input.
  19. If the log is printed to the console, then the error is not in that snippet. QED.
  20. You need to supply a material. Look at all the other blocks: blockRegistry.addObject(20, "glass", (new BlockGlass(Material.glass, false))... public BlockStone() { super(Material.rock); //here this.setCreativeTab(CreativeTabs.tabBlock); } As for invisible, that has nothing to do with BlockContainer. You registered a renderer for your block, and likely, it isn't rendering anything.
  21. Nah, everyone else calls me an asshole because they're too [lazy|stupid|assholish] to go to the effort of helping themselves.
  22. ClientRegistry.bindTileEntitySpecialRenderer(TileEntityJohnnyBlockRubble.class, render);
  23. Long story short: you're going to find this almost impossible. I don't know how grass actually renders its sides (last I checked, it cheated), but the problem you're seeing has to do with the fact that the color multiplier applies to the whole texture. Best guess, you could try a transparent overlay texture which has the grass portion and is color multiplied, and the dirt underlay portion which is not. You'll have to look up two-pass rendering on your own.

Important Information

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

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.