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


  • Posts

  • Joined

  • Last visited

Everything posted by Zer0HD2

  1. Still no luck on this - anyone got any ideas on how to do it?
  2. For some reason I can't change the syntax highlighting of the gist, it keeps reverting to plaintext. No idea what's going on there.
  3. The fields I posted in my first reply return integer values for the bottom and right edges.
  4. Can you show some code first? :L
  5. Right, sorry it's taken so long for me to respond to this, been busy at work. Anyway, here is the code for my PlayerTickEvent: Gist: https://gist.github.com/Zer0HD/9c2b3a54a8e6b61b2d07
  6. You want to get the X position relative to the centre of the screen, and the Y position relative to the bottom. That way it doesn't mess up when you resize the window. You can do this using event.resolution.getScaledHeight() and event.resolution.getScaledWidth(). The Y position of the top-left corner of the health bar region is 91 pixels to the left of the centre of the screen, the X position is around 40 pixels up from the bottom.
  7. Are all the other attributes working correctly? And you did @Override the method, right?
  8. This. Also, sorry, didn't realise people had replied to this - I'll post source code (both in a spoiler and in a gist ) when I get home from work.
  9. Anyone have any idea how to do this, or an alternate method of doing it?
  10. Ah, that'll be pretty useful. I'll take a look at pulling class names from that for each field/function.
  11. Editing fields and functions is done. There's a little edit link on the right hand side of the row for each entry now.
  12. Search function is working (need to sort out searching within a category, but that can wait). Working on deleting and editing entries now.
  13. Yep, that's one thing I noticed - I'll be getting that sorted as soon as I finish the search function.
  14. Is there any event in 1.7.2 which allows you to execute code when the player switches what item they're holding? I'm trying to create a system whereby a player needs to meet certain requirements to use certain items/tools. So far I've been using PlayerTickEvent, and using dropOneItem() to make the player drop the item, and give them a chat message, but they receive the message ~5 times and drop the previous item they were holding too.
  15. The PHP script for grabbing new entries from the CSV file is done, and I've run it manually once to populate the database. I'll set up the cron job to run once every few hours. I'll be making the search function today as well, since there are no categories in the CSV file, so I've had to drop everything into an "undefined" category.
  16. I can set up a cron job to automatically import any from the CSV file that aren't already in the database. I'll try to get that working today. I'll need to look at how to implement MCP Bot, but it should (should) be possible.
  17. What is it you're trying to store data about? Players? World? Also, do you want to be able to manually edit the data through config files, or do you want it to be stored in the world?
  18. So far I've done all of the functions listed in this thread and one of the fields (was testing whether the method for adding fields was working). Other than that, nothing. I'll be working on it more tomorrow, I'll put in some more options for editing/deleting entries, adding categories, etc.
  19. Alternatively, since it's a boolean, you can use: if(!Minecraft.getMinecraft().thePlayer.capabilities.isCreativeMode) { ... }
  20. isCreativeMode returns a boolean, so it should work in an if statement. I've used it like that before. As long as you have an instance of EntityPlayer, you can use this field. As Elyon said, Minecraft.getMinecraft().thePlayer returns the client player, in the form of an EntityPlayer.
  21. Yep, I'll manually activate it and figure out what's up with it. I wrote this in about 1.5 days, so it won't be perfect EDIT: Your account's activated. I'll be working on this again tomorrow (been fixing a couple of other sites today, so my brain's pretty fried), so I should be able to get most of these bugs ironed out. EDIT 2: I've fixed the verification mail issue. Should be sending correctly now.
  22. No, I mean an instance of EntityPlayer called player. player.capabilities.isCreativeMode returns a boolean value of true is the player is in creative. Take a look at the wolf interact method if you want to see an example of it being used in an if statement.
  23. I'm with tattyseal and Elyon on this one, you should definitely use Eclipse rather than manually using javac. But, if you do insist on keeping on with that method, the tutorials by Wuppy posted above are pretty good, you should read those.
  24. Have a look in the vanilla minecraft GUI code, specifically GuiIngame. That's the class that draws the HUD (toolbar, health, hunger, etc).
  • Create New...

Important Information

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