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


  • Posts

  • Joined

  • Last visited

Everything posted by __RikMuld__

  1. When I tried the new fluid system my liquids started acting very strange with vanilla liquids. I just extended the the fluid classic class for the liquids. I don't know if I did something wrong or that it's a bug, so I just place it here just to be sure.
  2. When I spawn in an entiti item the motion is always pointed to -x. It doens't matter if I do: entityItem.motionX = whatever; entityItem.motionY = whatever; entityItem.motionZ = whatever; The motion will get the motion I gave it but it will be pointed to -x. So if the motion I gave it is entityItem.motionZ = 1; then it will go to z and -x. The code I use to spawn the entity Item: public void dropStack(World world, int x, int y, int z, ItemStack stack, int posX, int posY, int posZ) { EntityItem item = new EntityItem(world, x+0.5, y+0.5, z+0.5, stack); item.motionX = item.motionY = item.motionZ = 0.0D; if(posX!=x) { if(posX>x)item.motionX = Math.random() * -0.2D; else if(posX<x)item.motionX = Math.random() * 0.2D; } if(posY!=y) { if(posY>y)item.motionY = Math.random() * -0.2D; else if(posY<y)item.motionY = Math.random() * 0.2D; } if(posZ!=z) { if(posZ>z)item.motionZ = Math.random() * -0.2D; else if(posZ<z)item.motionZ = Math.random() * 0.2D; } if(!world.isRemote)world.spawnEntityInWorld(item); }
  3. Of source I have but if I just do something like: tile.variable = something. it will only be registerd on the client side. But I want it to set it also on the server side.
  4. I want to send an variable from my gui to a tile entity, and how would i manage this? I didn't work with packedhandlers that much, but i know i need it.
  5. Does someone know were I can find the code for damage indicator bars for items (that thing you mainly see at the bottom of the icon by tools).
  6. I created an GUI but some slots are outside the base of the GUI, so when you pick things up from these slots the items get dropped immediately. Does anyone know how to fix this, i am fine with not dropping things at all on any place in the GUI, but when i tired to override the slot click method there were a lot of funcs and fields (like: field_94536_g, func_94532_c)so i didn't know what to edit to make it not drop things when you click outside the GUI. Container Code Inventory Code Gui Code To give you an idea off the problem if you take items out of the slots in the bleu part they will act normally and you will pick them up, but when you do it by the slots in the red part they will drop immediately.
  7. You could use a crafthandler for it. here is an example: https://github.com/Rikmuld/Camping-Mod/blob/master/common/rikmuld/core/handlers/CraftHandler.java and this would make an item never get destroyed when used in a crafting recipie: @Override public void onCrafting(EntityPlayer player, ItemStack item, IInventory inv) for(int i=0; i < inv.getSizeInventory(); i++) { if(inv.getStackInSlot(i) != null) { ItemStack j = inv.getStackInSlot(i); if(j.getItem() != null&&j.getItem()==The Item That Shouldn't get destroyed) { inv.setInventorySlotContents(i, j); } } } the itemstack in the method is the item you are crafting, so you also could specify the recipe for when it should not get destroyed. Ps. don't forget to register the crafting handler in you init for if you don't already have an craftHandler. GameRegistry.registerCraftingHandler(new CraftHandler());
  8. How did you fix it, i am also getting duplicate state id errors. not always thought around 1-20 times. achievement code
  9. I recently updated my mod to 1.5, and everything works properly except 2 things. the first things that i can not get working are my entities. if you spawn them they are falling throught the ground (probably only client side). the second things That is my bone meal event is not working how it Should be, you can click my plants and they will grow but, the bone meal amaunt stack will not be reduced. becouse you it thinks the current item == null, but that can not be becouse you are Clicking on something with the bone meal. mod source: https://github.com/Rikmuld/Camping-Mod the entity: https://github.com/Rikmuld/CampingMod/blob/master/common/rikmuld/entity/Camper.java The events: https://github.com/Rikmuld/Camping-Mod/blob/master/common/rikmuld/core/register/ModEvents.java The plant: https://github.com/Rikmuld/CampingMod/blob/master/common/rikmuld/block/plant/RadishCrop.java help will be appreciated. regards, rik mulder.
  10. they spawn now thanx. but now i have a new question: How do you add a texture to a new particle effect - i have a particle class - he spawns in the world now my particle is a big white box so how do i add a texture ( i want to make a colored flame particle)
  11. peas can anybody help me? here is the class for the costom particle: if i add it in global renderer it works but i don't want to do that, because i don't want to edit the main classes. so how can i add it to a block without doing that. didn't see you post but what do you mean.
  12. How? They have no name because i didn't call them in renderglobal
  13. I have add some new particles classes to the game but how do register them without calling them in RenderGlobal. because i don't want to edit main classes. --edit-- new question: How do you add a texture to a new particle effect - i have a particle class - he spawns in the world now my particle is a big white box so how do i add a texture ( i want to make a white flame particle)
  • Create New...

Important Information

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