Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Casual Dutchman

  • Content Count

  • Joined

  • Last visited

Everything posted by Casual Dutchman

  1. fixed it by experimenting with the GuiInventory function and my function.
  2. Tried several setting. disable it before rendering. disable it before, enable it after enable it before. enable it before, disable it after It did not help.
  3. So this Gui is a bit more advanced. It has a representation of the clicked mob. There is one problem. When it gets night, the gui is very dark. When it it day, the gui is light, normal. *see below code for the gui file **see below package comp101.client.gui; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiButton; import net.minecraft.client.gui.inventory.GuiContainer; import net.minecraft.client.renderer.RenderHelper; import net.minecraft.client.renderer.entity.RenderManager; import net.minecraft.client.resources.I18n; import net.m
  4. So I did this in the Entity class in the OnUpdate methode. But It still does not work and it still says it had a potentionel memory leak
  5. So it does not change a thing. for the way I does it. if(message.code == 10){ WorldServer worldserver = (WorldServer)ctx.getServerHandler().playerEntity.worldObj; EntityTracker track = worldserver.getEntityTracker(); Entity entity = ctx.getServerHandler().playerEntity.worldObj.getEntityByID(message.entityID); EntityHireable hire = (EntityHireable)entity; hire.Backpack = -1; track.func_151247_a(entity, Core.network.getPacketFrom(message)); } I this is text from the console: [19:43:28] [Client thread/ERROR] [FML]: Detected ongoing potential memory leak. 1
  6. How can I use the EntityTracker? I'm now checking the change and it works. (checked by println()) What do I need to do when I call the sendToAll(Message)?
  7. I mean when I checked if the itemstack and then use network.sendToServer() to change the itemstack again but then use by server so the server will change the itemstack. Maybe I could also modify the Slot class, the OnSlotChanged methode. So it will send a package to the server.
  8. That is a bit of a problem. I have no clue on how to do that thing. Should I just check it and then send a package to the server telling the item is changed so the model can be changed on all clients. Would that work, gonna test it right away
  9. Can't you just create a different png with an animation of all colors. Like the portal or fire. And then use that picture as an overlay on the sword.
  10. So, i'm sending stuf through packages with the Message stuff. (followed your thread on that) But how do I tell the other clients that something has changed?
  11. Try to do it, but how do I check if an item is added to an itemstack or removed. Let me be more specific. When you right click, a gui will open. There is an slot that will need an item. When this item is placed in there, there will be something added to the model. This works fine, but when on a server, the added thing to the model does not show an other client. Ho do I check this?
  12. I have made a mob which you can give an item and then the model will change a bit. Everytime I log on to my world, that change is not shown on screen. I create a simple println() to show if the item is stored in it and it does. How can I make the World or Server render the change when starting the world.
  13. Okay I was working on some stuff and I thought let's get a player skin when renaming the mob to it. This is just the normal Biped model, so the skin server would be great. I went digging in the RenderPlayer class and found the bindTexture part. It guides me to AbstractClientPlayer via getLocationSkin() this is a dead end, because it gets a stored ResourceLocation, that is set using a methode in this class by another class. That class is neary impossible to get, because of all the func_123456_a methodes. When I look in the AbstractClientPlayer class, I can see it has a getDow
  14. I'm sorry, I'm just being stupid. The item was a New Item instead of a New ItemBackPack That is the reason. next time I will double check every option before posting here. gawd, I feel dumb!
  15. I did not say that, I was just saying that you don't need it, it is usefull to see if the methode corresponds to the methode called by the extended class. With or without the @Override annotation, it does not work and I hace copied the methode over and over again from various other classes. Here is the Item class: nothing strange, no errors, registered just like other items. I just have no clue package mefa.Items; import java.util.List; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.nb
  16. Java.util.List This is also used by the first set of code from my previous post. This is not the problem.
  17. I'm sorry? Minecraft will get the methode as an overwritten methode. In the ItemStack class the methode is called int the getToolTip mothode. It will then get the addinformation methode from the item in the itemstack. if the custom item does not have this methode, it will use the empty methode in the Item class. btw, it did not work? I have no clue why not? look at the first and the second methode! the first one will display the information and de second not! //nothing fancy here, no override, no sideonly, nothing public void addInformation(ItemStack par1ItemStack,
  18. I created a custom Irecipe that adds a tier upon a succesfull recipe. But then comes the problem. Now I created a the AddInformation(things) methode to display more information. It just does not display. public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List par3List, boolean par4) { if(par1ItemStack.hasTagCompound()){ NBTTagCompound nbttagcompound = par1ItemStack.getTagCompound().getCompoundTag("backpack"); if(nbttagcompound != null){ if(nbttagcompound.hasKey("tier")){ int tier = nbttagcompound.getInteger("tier"); String
  19. I created a Item that will use custom itemstack's nbt tag lists. (same as Dyeable Leather armor) The only thing is, I will not use it to change color. I want it so that is you place in item A, the main item, All Items B increase the tier. The only problem is, it does not even create a new item in the crafting table; Just nothing. This is the register code: GameRegistry.addRecipe(new RecipeIncreaseTier()); Here is my Item Code: public boolean hasTier(ItemStack par1ItemStack) { return (!par1ItemStack.hasTagCompound() ? false : (!par1ItemStack.getTagComp
  20. It is not that difficult. btw, it is the only easy way to get it done! this is my getArmorModel methode: @Override @SideOnly(Side.CLIENT) public ModelBiped getArmorModel(EntityLivingBase entityLiving, ItemStack itemStack, int armorSlot) { ModelBiped armorModel = null; if(itemStack != null) { if(itemStack.getItem() instanceof ItemBackpack) { int type = ((ItemArmor)itemStack.getItem()).armorType; if(type == 1){ armorModel = Core.proxy.getArmorModel(0); } } if(armorModel != null){ armorModel.bipedBody.showModel = armorSlot == 1; armorModel.bip
  21. http://www.minecraftforum.net/forums/mapping-and-modding/mapping-and-modding-tutorials/1571595-1-7-2-how-to-code-custom-3d-armor-models-3d
  22. It's a shame the shouldrenderpass can only be up to 4 ties and the armor uses all the 4 passes. It there a way to get more passes for this methode?
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.