Jump to content

Miclebrick

Members
  • Posts

    30
  • Joined

  • Last visited

Everything posted by Miclebrick

  1. I GOT IT TO WORK WITH ICUSTOMMODELLOADER! It now looks like a potato unless it is named Apple, in which case it looks like an apple. It works as expected My new code: http://pastebin.com/bQAWSUVx Now that I know how, I can use that same concept to make an actual system for it. (Code is very hacky, so anyone reading this shouldn't copy and paste )
  2. @SuppressWarnings("unchecked") private void removeItemFromMesher(Item item, int meta) { try { Field field1 = ItemModelMesher.class.getDeclaredField("simpleShapesCache"); field1.setAccessible(true); Map<Integer, IBakedModel> simpleShapesCache = (Map<Integer, IBakedModel>) field1.get(getMesher()); simpleShapesCache.remove(getIndex(item, meta)); field1.set(getMesher(), simpleShapesCache); Field field2 = ItemModelMesher.class.getDeclaredField("simpleShapes"); field2.setAccessible(true); Map<Integer, ModelResourceLocation> simpleShapes = (Map<Integer, ModelResourceLocation>) field2.get(getMesher()); simpleShapes.remove(getIndex(item, meta)); field2.set(getMesher(), simpleShapes); } catch (NoSuchFieldException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (SecurityException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (IllegalArgumentException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (IllegalAccessException e) { // TODO Auto-generated catch block e.printStackTrace(); } } I tried doing this on postinit, but it did nothing.
  3. I'm going to try to use reflection to remove the model first.
  4. I discovered in ItemModelMesher: public IBakedModel getItemModel(ItemStack stack) { Item item = stack.getItem(); IBakedModel ibakedmodel = this.getItemModel(item, this.getMetadata(stack)); if (ibakedmodel == null) { ItemMeshDefinition itemmeshdefinition = (ItemMeshDefinition)this.shapers.get(item); if (itemmeshdefinition != null) { ibakedmodel = this.modelManager.getModel(itemmeshdefinition.getModelLocation(stack)); } } if (ibakedmodel == null) { ibakedmodel = this.modelManager.getMissingModel(); } return ibakedmodel; } Does that mean that it's only called for nonexistent meshes? (It checks if baked mesh is null first)
  5. It seems the problem with ItemMeshDefinition is that getModelLocation() is never called. I can't figure out why.
  6. Is it possible to specify custom item overrides based off of nbt data?
  7. http://www.minecraftforge.net/forum/index.php/topic,37398.msg197123.html#msg197123 they were successfully able to use it in 1.9, so I do believe it should work in 1.9. Perhaps it doesn't work because I'm using it with vanilla items?
  8. If I handle the bake event, would I be able to do the original method?
  9. I made it turn to an apple when named Apple, but it crashes when it's a non-apple diamond sword! EDIT: Whoops, forgot to pastebin! http://pastebin.com/wsDQqW5w
  10. I figured out that you can use ItemOverrideList and handleItemState to get the itemstack info, but now I need to know how to generate a baked model from a model json file.
  11. Wouldn't an IBakedModel require me to model it in Techne? I want to use it with Minecraft json models, supplied by the resource pack.
  12. I don't have any access to the ItemStack here though, so how can I change it using the lore or name?
  13. Ok, thanks, I'll try that!
  14. I'm sorry, I tried reading it, but I can't quite understand what exactly I need to do. Could you please explain to me?
  15. Also, I noticed that MinecraftForgeClient.registerItemRenderer is not a thing in 1.9. Any reason for this?
  16. I'm trying to make a mod that changes vanilla item model based off of its name or lore. But before I get to that, I'm trying to get it to even change the model in the first place! Nothing seems to happen. Am I missing anything? Main mod file: http://pastebin.com/KKhrD2bC CustomItemModel: http://pastebin.com/sEXEffZ9 TestDiamondSwordModel: http://pastebin.com/hbjSJsaN
  17. I was wondering if it is possible to modify an existing item's model without using a coremod, and the entity textures as well. I am making a mod that is made for a server that is supposed to be able to be played on with or without mods. It works by changing these based off the display names. e.g. a zombie named Goblin would have a unique texture, an sword called Hammer would be shaped like a hammer, and have a hammer texture. Would this be possible without a coremod?
  18. I know Java. I just can't find a tutorial on making a coremod that actually works.
  19. I don't understand how to make a coremod. The tutorials I find are all outdated.
  20. So, I want it to have something where there is a list of names that have a skin that isn't from minecraft.net, but from inside mod files or somewhere else. So, let's say I had a list containing this: Bob Ronald And let's say from minecraft.net Bob has no skin so he's steve and Ronald is some random dude with Ronald Weasly as a skin. Inside the mod, I have Ronald.png and Bob.png. It changes their skin to that. Is it possible to make this? Because I don't see anything like this. (Yes, I have tried google. Nothing that aided me came up.)
  21. How do I send a packet to a server with the netty system?
  22. I can't seem to find any 1.7.2 mob creating tutorials. Can anyone tell me how?
×
×
  • Create New...

Important Information

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