Jump to content

larsgerrits

Members
  • Posts

    3462
  • Joined

  • Last visited

  • Days Won

    17

Everything posted by larsgerrits

  1. First, go follow some coding conventions. If you've done that, move your new blockref(); before the new itemref(); call.
  2. You don't need the instance variable. You need to get the TileEntity in the render class using IBlockAccess#getTileEntity(x,y,z). That gives you a instance of the TileEntity which you can use for getting variables.
  3. Also, don't store the hasEffect in the item class, else it will be shared across all item instances.
  4. Hajjdajkdacljnvxkvlksjhlajncklhsciaukbkuawulhcakucjnsllhcahcjnakulcna.
  5. In the ExamplePipe class, you extend BasePipe. What class is that? I don't have that in my workspace? If i need to make it, what does it need to have?
  6. What do you want to do with FMP? In the Tutorials subforum is a tutorial on basic cables supporting covers. It isn't finished yet, and i'm working on making it Java coded (instead of scala in the tutorial).
  7. java.lang.NullPointerException: Unexpected error at net.minecraft.world.chunk.storage.ExtendedBlockStorage.func_150818_a(SourceFile:57) at net.minecraft.world.chunk.Chunk.func_150807_a(Chunk.java:595) at net.minecraft.world.World.setBlock(World.java:441) at net.minecraft.world.World.setBlock(World.java:576) at net.extend.mod.functions.addseed.onItemUse(addseed.java:48) What's on line 48 in the addseed class? BTW, You might want to look at some Java Coding Conventions, cause your naming is horrible.
  8. You are setting the minX and minY values to getMinX() and getMinY() method in GuiScreenWidget, but those are 0 because they're not initialised. Then you pass in those values, but because the passed in values are 0, you set the minX and minY values to 0. You have 2 options with your current setup: 1) in the RadioCrystalGui, call the super method without parameters, or 2) pass 176 and 166 (default values) instead of minX and minY.
  9. Don't know if this is the problem, but on this line: if(props.getRayTraceX(distance) != props.getLastPosX2() || props.getRayTraceY(distance) != props.getLastPosY2(){ You don't check for the Z coord. Maybe that's intended, but i may just point it out.
  10. You can use the RenderGameOverlayEvent, in which you can draw a ResourceLocation location to your image file.
  11. How would he know what those were? He just copied without nowing what the code does and expects it to run!
  12. What's wrong? What are you expecting it to do? We need more information!
  13. I suggest this tutorial: http://jabelarminecraft.blogspot.nl/p/complex-entity-models-including.html[/url. It is made by a guy called Jabelar who is pretty often on these forums and is a pretty good minecraft modder. He also has other tutorials that i found very helpful.
  14. What do you mean "does NOT work"? What doesn't work? What do you get?
  15. Make your own IRecipe. In a method you must check if the player has permission, and give the output. Else, don't.
  16. No, if world.isRemote == true, you are on the client, else you are on the server.
  17. Yeah, but your coords are probably way more then 4 blocks away. If you go to 0 0 0 you can move the items. Thats why you made it a dirty work-around, instead of making your own classes, which is the best solution.
  18. You can use the GuiOpenEvent, in which the GuiScreen object is null when closing a gui.
  19. Do you have a GitHub? If so, post the link so we have all the code. Else, post the IGuiHandler class and the Container class.
  20. From where do you call the addPower method? I think your client and server are desynchronized.
  21. Did you register the TileEntity?
  22. Knowing the middle of the gui is always in the middle of the screen, you can use (width-xSize)/2. That gives you the middle of the screen, and base your slots around that value (same for the y but height and ySize
  23. That is indeed the value that determines the color. It is the hexadecimal value for the color tht minecraft uses for the gui text. If you want to change the text color you can go into a image editor, get the color you want and there is somewhere a number that is made of numbers and letters. Then just copy that number, and paste that into there with 0x in front of it (example: 0xFF0000 is red).
  24. That is VERY basic java, almost the first thing you learn. It's called renaming parameters.
×
×
  • Create New...

Important Information

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