Jump to content

GotoLink

Members
  • Posts

    2012
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by GotoLink

  1. Why would you need to throw on the client ? You'll need to send a packet to the client for the rendering, i think, and remove that func_110827_b from your code. I suggest you post more of your code, it will be easier for everyone to understand and help you.
  2. I think you should be more specific. I am sure you already searched for "public" keyword yourself, or used call hierarchy to found where calls to your method(s) of interest are mainly done. In the most general of case, I would say that what you are searching doesn't exist. There is no "public class CoreEngine ..."
  3. All possible fixes, but drop.remove was none of them. I thought since the "Iterator iterator" was nowhere defined, I had to define it. However, changing it to drop.remove fires out this error log... Yeah, this is why Eclipse is only a tool, not your brain As for the error, gcewing explained it well enough. [spoiler=The fix you should have found] Move event.drops.add(args); line out of the while loop. And please, stop ranting at pelep
  4. AFAIK, tileentity only exists after block is placed in world, so you'll have to use a custom blockrenderer if you want it to look different from vanilla blocks, when it is only an item (in your inventory, or floating around in the world). You can also use different vanilla rendering by changing of render type value in your block. (like, use 2 for cross squared a.k.a grass render) For example, you can use ISimpleBlockRenderer, use the methods to render your item in world and inventory, and register your renderer client side.
  5. The issue is within your PacketHandler class. You are probably using a client side method in a server part.
  6. So, what does Eclipse say of this underlined error ? Your import is good. I am trying to teach you how to read and learn code, and not copy/paste all over. [spoiler=The fix you should have found] drop.remove();
  7. Maybe you should write the reflection code instead of relying on that ObfuscationReflexionHelper.
  8. It is not that people aren't helping. It is that noone can help you if you don't ask the correct question. In your case, from the very beginning it should have been something like: Edit: Man, what are you doing with this onEntityDrop1 method ? Just place the code into a if(event.entityLiving instanceof EntityCow) { //code here } in your first method
  9. Maybe looking in EntityPlayer class ? /* ================================== Forge Start =====================================*/ /** * Returns a NBTTagCompound that can be used to store custom data for this entity. * It will be written, and read from disc, so it persists over world saves. * @return A NBTTagCompound */ public NBTTagCompound getEntityData() { if (customEntityData == null) { customEntityData = new NBTTagCompound(); } return customEntityData; }
  10. A power system should power things, right ? Maybe you should think of something that needs this power, as a start. Then how to calculate (add/remove/multiply powering ?), send (how it interacts, is it on contact, or a power field ?) this power. Basically, write down the properties of your power, like a physicist. Then build the classes that should interact for this power.
  11. private static final ResourceLocation field_110410_t = new ResourceLocation("machines:/textures/gui/atomizer.png"); Where did you put that texture ?
  12. They have been deprecated because you use this /** * Returns an array containing the indices of the slots that can be accessed by automation on the given side of this * block. */ int[] getAccessibleSlotsFromSide(int var1); Returned array as a length, so you don't have to give the size yourself. But if you are new to inventory management, maybe you should start with IInventory interface ?
  13. In your main class do: @Instance("machines") public static machines instance;
  14. I hope you meant "overriding" instead of "overloading". Overloading wouldn't do anything in most cases, since you can't tell Minecraft to call an overloaded method. Overriding on the contrary, allows many things, is commonly the easiest way and one of the basic principle of Java. I can't believe you are complaining about overriding. If the ModingAPI was perfect, you would only have to override.
  15. ItemStack stack; Iterator drop = event.drops.iterator(); while(drop.hasNext()) { stack = ((EntityItem)drop.next()).getEntityItem(); if(stack!=null && stack.getItem().itemID == Item.leather.itemID) { iterator.remove(); event.drops.add(new EntityItem(world,x,y,z, new ItemStack(furID)); } }
  16. http://www.minecraftforge.net/wiki/Metadata_Based_Subblocks That's for the basics. Just read every forge tutorial, if you prefer that way of learning.
  17. If you wrote something into EntityPlayer class, then you're doing it wrong.
  18. If the only thing you want to change is a texture, and you have less than 16, then metadata is recommended. As for tutorial, doesn't techne provide any help ?
  19. Wait, so you want to remove mob drop that are craftable ? Do they even exist ?
  20. Look in TextureMap Forge adds getTextureExtry(String name) method.
  21. In your container: @Override public boolean canInteractWith(EntityPlayer var1) { return false; } return true, or some case where it could be true.
  22. Use LivingAttack event. Cancel the event if player is wearing full armor.
  23. If you can already check for materials, and if you know what textures you already made, why do you need another check ? Just give your generic icon to any tool left.
  24. You couldn't find ISidedInventory interface ?
×
×
  • Create New...

Important Information

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